diff options
Diffstat (limited to 'org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/MarkerRulerAction.java')
-rw-r--r-- | org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/MarkerRulerAction.java | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/MarkerRulerAction.java b/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/MarkerRulerAction.java index 41aaed68b22..cee66714461 100644 --- a/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/MarkerRulerAction.java +++ b/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/MarkerRulerAction.java @@ -409,7 +409,7 @@ public class MarkerRulerAction extends ResourceAction implements IUpdate { IInputValidator inputValidator= new IInputValidator() { @Override public String isValid(String newText) { - return (newText == null || newText.trim().length() == 0) ? " " : null; //$NON-NLS-1$ + return (newText == null || newText.trim().isEmpty()) ? " " : null; //$NON-NLS-1$ } }; AddBookmarkDialog dialog= new AddBookmarkDialog(fTextEditor.getSite().getShell(), title, message, proposal, inputValidator, addButtonText); @@ -422,7 +422,7 @@ public class MarkerRulerAction extends ResourceAction implements IUpdate { return false; label= label.trim(); - if (label.length() == 0) + if (label.isEmpty()) return false; MarkerUtilities.setMessage(attributes, label); |