diff --git a/designer-base/src/main/java/com/fr/design/gui/iscrollbar/UIScrollBarUI.java b/designer-base/src/main/java/com/fr/design/gui/iscrollbar/UIScrollBarUI.java index 8054a29eac..d3393054ae 100644 --- a/designer-base/src/main/java/com/fr/design/gui/iscrollbar/UIScrollBarUI.java +++ b/designer-base/src/main/java/com/fr/design/gui/iscrollbar/UIScrollBarUI.java @@ -1326,9 +1326,9 @@ public class UIScrollBarUI extends ScrollBarUI implements LayoutManager, SwingCo newModel.addChangeListener(modelListener); scrollbar.repaint(); scrollbar.revalidate(); - } else if ("orientation" == propertyName) { + } else if (StringUtils.equals("orientation", propertyName)) { updateButtonDirections(); - } else if ("componentOrientation" == propertyName) { + } else if (StringUtils.equals("componentOrientation", propertyName)) { updateButtonDirections(); InputMap inputMap = getInputMap(JComponent.WHEN_FOCUSED); SwingUtilities.replaceUIInputMap(scrollbar, JComponent.WHEN_FOCUSED, inputMap); diff --git a/designer-base/src/main/java/com/fr/design/gui/ispinner/UISpinner.java b/designer-base/src/main/java/com/fr/design/gui/ispinner/UISpinner.java index ba6913a38a..66a9a75755 100644 --- a/designer-base/src/main/java/com/fr/design/gui/ispinner/UISpinner.java +++ b/designer-base/src/main/java/com/fr/design/gui/ispinner/UISpinner.java @@ -9,9 +9,11 @@ import com.fr.design.gui.ibutton.UIButton; import com.fr.design.gui.ibutton.UIButtonUI; import com.fr.design.gui.itextfield.UINumberField; import com.fr.design.utils.gui.GUIPaintUtils; +import com.fr.stable.CommonUtils; import com.fr.stable.Constants; import com.fr.stable.StringUtils; +import com.fr.stable.collections.utils.MathUtils; import javax.swing.*; import javax.swing.event.ChangeEvent; import javax.swing.event.ChangeListener; @@ -109,7 +111,7 @@ public class UISpinner extends JPanel implements UIObserver, GlobalNameObserver } value = value < minValue ? minValue : value; value = value > maxValue ? maxValue : value; - if (value == this.value) { + if (CommonUtils.equals(value, this.value)) { return; } this.value = value; @@ -132,7 +134,7 @@ public class UISpinner extends JPanel implements UIObserver, GlobalNameObserver value = value < minValue ? minValue : value; value = value > maxValue ? maxValue : value; - if (value == this.value) { + if (CommonUtils.equals(value, this.value)) { return; } this.value = value; @@ -371,4 +373,4 @@ public class UISpinner extends JPanel implements UIObserver, GlobalNameObserver // jf.setSize(400, 400); // jf.setVisible(true); } -} \ No newline at end of file +} diff --git a/designer-base/src/main/java/com/fr/design/gui/syntax/ui/rsyntaxtextarea/modes/MakefileTokenMaker.java b/designer-base/src/main/java/com/fr/design/gui/syntax/ui/rsyntaxtextarea/modes/MakefileTokenMaker.java index f556cc5b77..30b4b6d859 100644 --- a/designer-base/src/main/java/com/fr/design/gui/syntax/ui/rsyntaxtextarea/modes/MakefileTokenMaker.java +++ b/designer-base/src/main/java/com/fr/design/gui/syntax/ui/rsyntaxtextarea/modes/MakefileTokenMaker.java @@ -10,12 +10,13 @@ */ package com.fr.design.gui.syntax.ui.rsyntaxtextarea.modes; -import java.io.*; +import com.fr.design.gui.syntax.ui.rsyntaxtextarea.AbstractJFlexTokenMaker; +import com.fr.design.gui.syntax.ui.rsyntaxtextarea.Token; +import com.fr.design.gui.syntax.ui.rsyntaxtextarea.TokenImpl; +import java.io.IOException; import java.util.Stack; import javax.swing.text.Segment; -import com.fr.design.gui.syntax.ui.rsyntaxtextarea.*; - /** * Scanner for makefiles.

@@ -762,8 +763,8 @@ public final void yybegin(int newState) { { addToken(Token.LITERAL_CHAR); } case 25: break; - case 12: - { if (!varDepths.empty() && varDepths.peek()==Boolean.TRUE) { + case 12: + { if (!varDepths.empty() && Boolean.TRUE.equals(varDepths.peek())) { varDepths.pop(); if (varDepths.empty()) { addToken(start,zzStartRead, Token.VARIABLE); yybegin(YYINITIAL); @@ -771,8 +772,8 @@ public final void yybegin(int newState) { } } case 26: break; - case 11: - { if (!varDepths.empty() && varDepths.peek()==Boolean.FALSE) { + case 11: + { if (!varDepths.empty() && Boolean.FALSE.equals(varDepths.peek())) { varDepths.pop(); if (varDepths.empty()) { addToken(start,zzStartRead, Token.VARIABLE); yybegin(YYINITIAL); @@ -864,4 +865,4 @@ public final void yybegin(int newState) { } -} \ No newline at end of file +}