Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMarkus Keller2015-11-29 21:11:24 +0000
committerMarkus Keller2015-12-01 01:50:38 +0000
commit64b34b614087b96e6cc92c72143768b98ae32602 (patch)
tree4f4f493fd8161f9a5885f11021cd14a923946e9f /org.eclipse.ui.editors
parentf01dd079500e382823d5d1767996cb9ef85233ee (diff)
downloadeclipse.platform.text-64b34b614087b96e6cc92c72143768b98ae32602.tar.gz
eclipse.platform.text-64b34b614087b96e6cc92c72143768b98ae32602.tar.xz
eclipse.platform.text-64b34b614087b96e6cc92c72143768b98ae32602.zip
Bug 478673: added @Override/@Deprecated and removed non-Javadoc boilerplate
Diffstat (limited to 'org.eclipse.ui.editors')
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/DefaultEncodingSupport.java18
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/DocumentReader.java29
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/EditorsUI.java1
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/EncodingActionGroup.java27
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/FileBufferOperationAction.java17
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/FileBufferOperationHandler.java6
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/FileDocumentProvider.java111
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/ForwardingDocumentProvider.java126
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/IEncodingActionsConstants.java1
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/IEncodingActionsDefinitionIds.java1
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/IEncodingActionsHelpContextIds.java1
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/StorageDocumentProvider.java64
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/TextEditor.java55
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/TextEditorActionContributor.java17
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/TextEditorPreferenceConstants.java29
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/TextEditorPreferencePage.java13
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/TextFileDocumentProvider.java267
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/TextSourceViewerConfiguration.java63
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/templates/ContributionTemplateStore.java6
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/quickdiff/CompositeRevertAction.java13
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/quickdiff/LastSaveReferenceProvider.java46
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/quickdiff/QuickDiffRestoreAction.java13
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/quickdiff/RestoreAction.java8
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/quickdiff/RevertBlockAction.java8
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/quickdiff/RevertLineAction.java8
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/quickdiff/RevertSelectionAction.java8
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/AbstractConfigurationBlockPreferencePage.java29
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/AccessibilityPreferencePage.java36
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/AnnotationsConfigurationBlock.java49
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/AnnotationsPreferencePage.java20
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/ConvertLineDelimitersAction.java6
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/EditorsPlugin.java11
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/EditorsPluginPreferenceInitializer.java5
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/FileEditorInputAdapterFactory.java9
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/HyperlinkDetectorsConfigurationBlock.java73
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/HyperlinkDetectorsPreferencePage.java20
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/IURIEditorInputAdapterFactory.java13
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/LanguageEditorPreferencePage.java16
-rwxr-xr-xorg.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/LinkedModeConfigurationBlock.java34
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/LinkedModePreferencePage.java17
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/NextPreviousPulldownActionDelegate.java33
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/NextPulldownActionDelegate.java4
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/NonExistingFileEditorInput.java36
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/OverlayPreferenceStore.java132
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/PreviousPulldownActionDelegate.java6
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/QuickDiffConfigurationBlock.java26
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/QuickDiffPreferencePage.java20
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/RefreshEditorAction.java4
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/RemoveTrailingWhitespaceHandler.java14
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/SelectResourcesBlock.java12
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/SelectResourcesDialog.java24
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/SharedTextColors.java9
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/SpellingConfigurationBlock.java86
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/SpellingPreferencePage.java20
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/StatusInfo.java24
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/TabFolderLayout.java2
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/TextEditorDefaultsPreferencePage.java58
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/UISynchronizationContext.java4
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/URLHyperlink.java5
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/URLHyperlinkDetector.java4
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/UntitledTextFileWizard.java12
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/WorkspaceOperationRunner.java4
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/internal/texteditor/AnnotationColumn.java53
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/internal/texteditor/BooleanPreferenceToggleAction.java8
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/internal/texteditor/DelegatingAnnotationPreference.java111
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/internal/texteditor/LineNumberColumn.java63
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/internal/texteditor/PropertyEventDispatcher.java1
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/internal/texteditor/SourceViewerInformationControl.java111
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/internal/texteditor/TextChangeHover.java19
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/AbstractDecoratedTextEditor.java126
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/AbstractDecoratedTextEditorPreferenceConstants.java3
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/AbstractMarkerAnnotationModel.java19
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/AddMarkerAction.java10
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/AddTaskAction.java4
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/BasicMarkerUpdater.java12
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/BookmarkRulerAction.java4
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/ChainedPreferenceStore.java132
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/ChangeEncodingAction.java29
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/DefaultMarkerAnnotationAccess.java38
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/ImageUtilities.java3
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/MarkerAnnotation.java16
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/MarkerAnnotationPreferences.java1
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/MarkerRulerAction.java12
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/MarkerRulerInfoAction.java2
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/MarkerUtilities.java1
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/MessageDialogPage.java3
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/ReadOnlyAnnotationPreference.java34
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/ResourceMarkerAnnotationModel.java21
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/ResourceMarkerAnnotationModelFactory.java4
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/RevisionHoverInformationControlCreator.java10
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/SelectMarkerRulerAction.java9
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/SelectMarkerRulerInfoAction.java2
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/SelectRulerAction.java4
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/SimpleMarkerAnnotation.java9
-rw-r--r--org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/TaskRulerAction.java8
95 files changed, 974 insertions, 1741 deletions
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/DefaultEncodingSupport.java b/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/DefaultEncodingSupport.java
index 8dede43cc..146c202d5 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/DefaultEncodingSupport.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/DefaultEncodingSupport.java
@@ -76,9 +76,11 @@ public class DefaultEncodingSupport implements IEncodingSupport {
IEclipsePreferences prefs= InstanceScope.INSTANCE.getNode(ResourcesPlugin.PI_RESOURCES);
fPreferenceChangeListener= new IPreferenceChangeListener() {
+ @Override
public void preferenceChange(PreferenceChangeEvent event) {
if (ResourcesPlugin.PREF_ENCODING.equals(event.getKey())) {
Runnable runnable= new Runnable() {
+ @Override
public void run() {
setEncoding(null, false); // null means: use default
}
@@ -142,7 +144,8 @@ public class DefaultEncodingSupport implements IEncodingSupport {
provider.setEncoding(input, encoding);
Runnable encodingSetter=
new Runnable() {
- public void run() {
+ @Override
+ public void run() {
fTextEditor.doRevertToSaved();
}
};
@@ -156,16 +159,12 @@ public class DefaultEncodingSupport implements IEncodingSupport {
}
}
- /*
- * @see IEncodingSupport#setEncoding(String)
- */
+ @Override
public void setEncoding(String encoding) {
setEncoding(encoding, true);
}
- /*
- * @see IEncodingSupport#getEncoding()
- */
+ @Override
public String getEncoding() {
IDocumentProvider p= fTextEditor.getDocumentProvider();
if (p instanceof IStorageDocumentProvider) {
@@ -175,9 +174,7 @@ public class DefaultEncodingSupport implements IEncodingSupport {
return null;
}
- /*
- * @see IEncodingSupport#getDefaultEncoding()
- */
+ @Override
public String getDefaultEncoding() {
IDocumentProvider p= fTextEditor.getDocumentProvider();
if (p instanceof IStorageDocumentProvider) {
@@ -297,6 +294,7 @@ public class DefaultEncodingSupport implements IEncodingSupport {
/*
* @see org.eclipse.swt.events.SelectionAdapter#widgetDefaultSelected(org.eclipse.swt.events.SelectionEvent)
*/
+ @Override
public void widgetSelected(SelectionEvent e) {
action.run();
}
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/DocumentReader.java b/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/DocumentReader.java
index 870f3d11d..e545e2a00 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/DocumentReader.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/DocumentReader.java
@@ -52,16 +52,12 @@ class DocumentReader extends Reader {
fDocument= document;
}
- /*
- * @see java.lang.CharSequence#length()
- */
+ @Override
public int length() {
return fDocument.getLength();
}
- /*
- * @see java.lang.CharSequence#charAt(int)
- */
+ @Override
public char charAt(int index) {
try {
return fDocument.getChar(index);
@@ -70,9 +66,7 @@ class DocumentReader extends Reader {
}
}
- /*
- * @see java.lang.CharSequence#subSequence(int, int)
- */
+ @Override
public CharSequence subSequence(int start, int end) {
try {
return fDocument.get(start, end - start);
@@ -87,16 +81,12 @@ class DocumentReader extends Reader {
*/
private class InternalDocumentListener implements IDocumentListener {
- /*
- * @see org.eclipse.jface.text.IDocumentListener#documentAboutToBeChanged(org.eclipse.jface.text.DocumentEvent)
- */
+ @Override
public void documentAboutToBeChanged(DocumentEvent event) {
handleDocumentAboutToBeChanged();
}
- /*
- * @see org.eclipse.jface.text.IDocumentListener#documentChanged(org.eclipse.jface.text.DocumentEvent)
- */
+ @Override
public void documentChanged(DocumentEvent event) {
}
}
@@ -130,9 +120,7 @@ class DocumentReader extends Reader {
fLength= fCharSequence.length();
}
- /*
- * @see java.io.InputStream#close()
- */
+ @Override
public void close() throws IOException {
synchronized (this) {
fCharSequence= null;
@@ -166,10 +154,7 @@ class DocumentReader extends Reader {
fDocumentListener= null;
}
- /*
- * @see java.io.Reader#read(char[], int, int)
- * @since 3.1
- */
+ @Override
public int read(char[] cbuf, int off, int len) throws IOException {
int i= 0;
try {
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/EditorsUI.java b/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/EditorsUI.java
index 1e625d261..dbcd3f534 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/EditorsUI.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/EditorsUI.java
@@ -152,6 +152,7 @@ public final class EditorsUI {
* @see org.eclipse.core.runtime.Plugin#getPluginPreferences()
* @deprecated As of 3.5, replaced by {@link #getPreferenceStore()}
*/
+ @Deprecated
public static org.eclipse.core.runtime.Preferences getPluginPreferences() {
return EditorsPlugin.getDefault().getPluginPreferences();
}
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/EncodingActionGroup.java b/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/EncodingActionGroup.java
index 3000cb584..8eec21f8c 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/EncodingActionGroup.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/EncodingActionGroup.java
@@ -48,6 +48,7 @@ import org.eclipse.ui.texteditor.TextEditorAction;
* @since 2.0
* @deprecated As of 3.1, encoding needs to be changed via properties dialog
*/
+@Deprecated
public class EncodingActionGroup extends ActionGroup {
private static final String FILE_CONTENT_ENCODING_FORMAT= TextEditorMessages.ResourceInfo_fileContentEncodingFormat;
@@ -109,9 +110,7 @@ public class EncodingActionGroup extends ActionGroup {
return null;
}
- /*
- * @see IAction#run()
- */
+ @Override
public void run() {
IEncodingSupport s= getEncodingSupport();
if (s != null)
@@ -146,9 +145,7 @@ public class EncodingActionGroup extends ActionGroup {
return null;
}
- /*
- * @see IUpdate#update()
- */
+ @Override
public void update() {
if (fEncoding == null) {
@@ -243,17 +240,13 @@ public class EncodingActionGroup extends ActionGroup {
super(bundle, prefix, editor);
}
- /*
- * @see IUpdate#update()
- */
+ @Override
public void update() {
ITextEditor editor= getTextEditor();
setEnabled(editor != null && !editor.isDirty());
}
- /*
- * @see IAction#run()
- */
+ @Override
public void run() {
ITextEditor editor= getTextEditor();
@@ -267,6 +260,7 @@ public class EncodingActionGroup extends ActionGroup {
String title= TextEditorMessages.Editor_ConvertEncoding_Custom_dialog_title;
String message= TextEditorMessages.Editor_ConvertEncoding_Custom_dialog_message;
IInputValidator inputValidator = new IInputValidator() {
+ @Override
public String isValid(String newText) {
return (newText == null || newText.length() == 0) ? " " : null; //$NON-NLS-1$
}
@@ -350,15 +344,14 @@ public class EncodingActionGroup extends ActionGroup {
fRetargetActions.add(new RetargetTextEditorAction(TextEditorMessages.getBundleForConstructedKeys(), "Editor.ConvertEncoding.Custom.", IEncodingActionsConstants.CUSTOM, IAction.AS_PUSH_BUTTON)); //$NON-NLS-1$
}
- /*
- * @see ActionGroup#fillActionBars(org.eclipse.ui.IActionBars)
- */
+ @Override
public void fillActionBars(IActionBars actionBars) {
IMenuManager menuManager= actionBars.getMenuManager();
IMenuManager editMenu= menuManager.findMenuUsingPath(IWorkbenchActionConstants.M_EDIT);
if (editMenu != null && fRetargetActions.size() > 0) {
MenuManager subMenu= new MenuManager(TextEditorMessages.Editor_ConvertEncoding_submenu_label);
subMenu.addMenuListener(new IMenuListener() {
+ @Override
public void menuAboutToShow(IMenuManager manager) {
update();
}
@@ -447,9 +440,7 @@ public class EncodingActionGroup extends ActionGroup {
((IUpdate) a).update();
}
- /*
- * @see ActionGroup#dispose()
- */
+ @Override
public void dispose() {
if (fTextEditor != null) {
fTextEditor.setAction(IEncodingActionsConstants.SYSTEM, null);
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/FileBufferOperationAction.java b/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/FileBufferOperationAction.java
index 59b7e96d3..598ecb548 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/FileBufferOperationAction.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/FileBufferOperationAction.java
@@ -65,25 +65,19 @@ public class FileBufferOperationAction extends Action implements IWorkbenchWindo
fFileBufferOperation= fileBufferOperation;
}
- /*
- * @see org.eclipse.ui.IWorkbenchWindowActionDelegate#dispose()
- */
+ @Override
public void dispose() {
fResources= null;
fWindow= null;
fFileBufferOperation= null;
}
- /*
- * @see org.eclipse.ui.IWorkbenchWindowActionDelegate#init(org.eclipse.ui.IWorkbenchWindow)
- */
+ @Override
public void init(IWorkbenchWindow window) {
fWindow= window;
}
- /*
- * @see org.eclipse.ui.IActionDelegate#selectionChanged(org.eclipse.jface.action.IAction, org.eclipse.jface.viewers.ISelection)
- */
+ @Override
public void selectionChanged(IAction action, ISelection selection) {
fResources= new HashSet();
@@ -142,9 +136,7 @@ public class FileBufferOperationAction extends Action implements IWorkbenchWindo
return window == null ? null : window.getShell();
}
- /*
- * @see org.eclipse.ui.IActionDelegate#run(org.eclipse.jface.action.IAction)
- */
+ @Override
public void run(IAction action) {
if (fResources != null && !fResources.isEmpty()) {
IFile[] files= collectFiles((IResource[]) fResources.toArray(new IResource[fResources.size()]));
@@ -173,6 +165,7 @@ public class FileBufferOperationAction extends Action implements IWorkbenchWindo
protected final void doRun(final IFile[] files, final IPath location, final IFileBufferOperation fileBufferOperation) {
Job job= new Job(fileBufferOperation.getOperationName()) {
+ @Override
protected IStatus run(IProgressMonitor monitor) {
IStatus status;
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/FileBufferOperationHandler.java b/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/FileBufferOperationHandler.java
index 7cc261c11..24ec9c2fe 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/FileBufferOperationHandler.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/FileBufferOperationHandler.java
@@ -188,6 +188,7 @@ public class FileBufferOperationHandler extends AbstractHandler {
*/
protected final void doRun(final IFile[] files, final IPath location, final IFileBufferOperation fileBufferOperation) {
Job job= new Job(fileBufferOperation.getOperationName()) {
+ @Override
protected IStatus run(IProgressMonitor monitor) {
IStatus status;
@@ -269,10 +270,7 @@ public class FileBufferOperationHandler extends AbstractHandler {
return true;
}
- /*
- * @see org.eclipse.core.commands.IHandler#execute(org.eclipse.core.commands.ExecutionEvent)
- * @since 3.1
- */
+ @Override
public Object execute(ExecutionEvent event) throws ExecutionException {
computeSelectedResources();
try {
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/FileDocumentProvider.java b/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/FileDocumentProvider.java
index 1704124bf..61e86952e 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/FileDocumentProvider.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/FileDocumentProvider.java
@@ -149,9 +149,7 @@ public class FileDocumentProvider extends StorageDocumentProvider {
protected void execute(IFileEditorInput input) throws Exception {
}
- /*
- * @see java.lang.Runnable#run()
- */
+ @Override
public void run() {
if (getElementInfo(fInput) == null) {
@@ -197,6 +195,7 @@ public class FileDocumentProvider extends StorageDocumentProvider {
* @param fileEditorInput the editor input to be synchronized
* @deprecated use <code>FileSynchronizer(IFileEditorInput)</code>
*/
+ @Deprecated
public FileSynchronizer(FileEditorInput fileEditorInput) {
fFileEditorInput= fileEditorInput;
}
@@ -226,9 +225,7 @@ public class FileDocumentProvider extends StorageDocumentProvider {
fIsInstalled= false;
}
- /*
- * @see IResourceChangeListener#resourceChanged(IResourceChangeEvent)
- */
+ @Override
public void resourceChanged(IResourceChangeEvent e) {
IResourceDelta delta= e.getDelta();
try {
@@ -239,9 +236,7 @@ public class FileDocumentProvider extends StorageDocumentProvider {
}
}
- /*
- * @see IResourceDeltaVisitor#visit(org.eclipse.core.resources.IResourceDelta)
- */
+ @Override
public boolean visit(IResourceDelta delta) throws CoreException {
if (delta == null)
return false;
@@ -262,6 +257,7 @@ public class FileDocumentProvider extends StorageDocumentProvider {
boolean isSynchronized= computeModificationStamp(getFile()) == info.fModificationStamp;
if ((IResourceDelta.ENCODING & delta.getFlags()) != 0 && isSynchronized) {
runnable= new SafeChange(fFileEditorInput) {
+ @Override
protected void execute(IFileEditorInput input) throws Exception {
handleElementContentChanged(input);
}
@@ -270,6 +266,7 @@ public class FileDocumentProvider extends StorageDocumentProvider {
if (runnable == null && (IResourceDelta.CONTENT & delta.getFlags()) != 0 && !isSynchronized) {
runnable= new SafeChange(fFileEditorInput) {
+ @Override
protected void execute(IFileEditorInput input) throws Exception {
handleElementContentChanged(input);
}
@@ -281,6 +278,7 @@ public class FileDocumentProvider extends StorageDocumentProvider {
if ((IResourceDelta.MOVED_TO & delta.getFlags()) != 0) {
final IPath path= delta.getMovedToPath();
runnable= new SafeChange(fFileEditorInput) {
+ @Override
protected void execute(IFileEditorInput input) throws Exception {
handleElementMoved(input, path);
}
@@ -289,6 +287,7 @@ public class FileDocumentProvider extends StorageDocumentProvider {
info= (FileInfo) getElementInfo(fFileEditorInput);
if (info != null && !info.fCanBeSaved) {
runnable= new SafeChange(fFileEditorInput) {
+ @Override
protected void execute(IFileEditorInput input) throws Exception {
handleElementDeleted(input);
}
@@ -372,6 +371,8 @@ public class FileDocumentProvider extends StorageDocumentProvider {
* @deprecated use file encoding based version
* @since 2.0
*/
+ @Deprecated
+ @Override
protected boolean setDocumentContent(IDocument document, IEditorInput editorInput) throws CoreException {
if (editorInput instanceof IFileEditorInput) {
IFile file= ((IFileEditorInput) editorInput).getFile();
@@ -389,10 +390,7 @@ public class FileDocumentProvider extends StorageDocumentProvider {
return super.setDocumentContent(document, editorInput);
}
- /*
- * @see StorageDocumentProvider#setDocumentContent(IDocument, IEditorInput, String)
- * @since 2.0
- */
+ @Override
protected boolean setDocumentContent(IDocument document, IEditorInput editorInput, String encoding) throws CoreException {
if (editorInput instanceof IFileEditorInput) {
IFile file= ((IFileEditorInput) editorInput).getFile();
@@ -440,9 +438,7 @@ public class FileDocumentProvider extends StorageDocumentProvider {
return super.setDocumentContent(document, editorInput, encoding);
}
- /*
- * @see AbstractDocumentProvider#createAnnotationModel(Object)
- */
+ @Override
protected IAnnotationModel createAnnotationModel(Object element) throws CoreException {
if (element instanceof IFileEditorInput) {
IFileEditorInput input= (IFileEditorInput) element;
@@ -486,9 +482,7 @@ public class FileDocumentProvider extends StorageDocumentProvider {
return modificationStamp;
}
- /*
- * @see IDocumentProvider#getModificationStamp(Object)
- */
+ @Override
public long getModificationStamp(Object element) {
if (element instanceof IFileEditorInput) {
@@ -499,9 +493,7 @@ public class FileDocumentProvider extends StorageDocumentProvider {
return super.getModificationStamp(element);
}
- /*
- * @see IDocumentProvider#getSynchronizationStamp(Object)
- */
+ @Override
public long getSynchronizationStamp(Object element) {
if (element instanceof IFileEditorInput) {
@@ -513,10 +505,7 @@ public class FileDocumentProvider extends StorageDocumentProvider {
return super.getSynchronizationStamp(element);
}
- /*
- * @see org.eclipse.ui.texteditor.AbstractDocumentProvider#doSynchronize(java.lang.Object)
- * @since 3.0
- */
+ @Override
protected void doSynchronize(Object element, IProgressMonitor monitor) throws CoreException {
if (element instanceof IFileEditorInput) {
@@ -541,9 +530,7 @@ public class FileDocumentProvider extends StorageDocumentProvider {
super.doSynchronize(element, monitor);
}
- /*
- * @see IDocumentProvider#isDeleted(Object)
- */
+ @Override
public boolean isDeleted(Object element) {
if (element instanceof IFileEditorInput) {
@@ -559,9 +546,7 @@ public class FileDocumentProvider extends StorageDocumentProvider {
return super.isDeleted(element);
}
- /*
- * @see AbstractDocumentProvider#doSaveDocument(IProgressMonitor, Object, IDocument, boolean)
- */
+ @Override
protected void doSaveDocument(IProgressMonitor monitor, Object element, IDocument document, boolean overwrite) throws CoreException {
if (element instanceof IFileEditorInput) {
@@ -716,9 +701,7 @@ public class FileDocumentProvider extends StorageDocumentProvider {
}
}
- /*
- * @see AbstractDocumentProvider#createElementInfo(Object)
- */
+ @Override
protected ElementInfo createElementInfo(Object element) throws CoreException {
if (element instanceof IFileEditorInput) {
@@ -793,9 +776,7 @@ public class FileDocumentProvider extends StorageDocumentProvider {
return Platform.getPreferencesService().getString(Platform.PI_RUNTIME, Platform.PREF_LINE_SEPARATOR, null, scopeContext);
}
- /*
- * @see AbstractDocumentProvider#disposeElementInfo(Object, ElementInfo)
- */
+ @Override
protected void disposeElementInfo(Object element, ElementInfo info) {
if (info instanceof FileInfo) {
FileInfo fileInfo= (FileInfo) info;
@@ -894,14 +875,12 @@ public class FileDocumentProvider extends StorageDocumentProvider {
* @see AbstractDocumentProvider#getElementInfo(Object)
* It's only here to circumvent visibility issues with certain compilers.
*/
+ @Override
protected ElementInfo getElementInfo(Object element) {
return super.getElementInfo(element);
}
- /*
- * @see AbstractDocumentProvider#doValidateState(Object, Object)
- * @since 2.0
- */
+ @Override
protected void doValidateState(Object element, Object computationContext) throws CoreException {
if (element instanceof IFileEditorInput) {
@@ -940,10 +919,7 @@ public class FileDocumentProvider extends StorageDocumentProvider {
return false;
}
- /*
- * @see IDocumentProviderExtension#isModifiable(Object)
- * @since 2.0
- */
+ @Override
public boolean isModifiable(Object element) {
if (!isStateValidated(element)) {
if (element instanceof IFileEditorInput)
@@ -952,10 +928,7 @@ public class FileDocumentProvider extends StorageDocumentProvider {
return super.isModifiable(element);
}
- /*
- * @see org.eclipse.ui.texteditor.AbstractDocumentProvider#doResetDocument(java.lang.Object, org.eclipse.core.runtime.IProgressMonitor)
- * @since 3.0
- */
+ @Override
protected void doResetDocument(Object element, IProgressMonitor monitor) throws CoreException {
if (element instanceof IFileEditorInput) {
IFileEditorInput input= (IFileEditorInput) element;
@@ -1002,10 +975,7 @@ public class FileDocumentProvider extends StorageDocumentProvider {
}
}
- /*
- * @see org.eclipse.ui.texteditor.IDocumentProviderExtension3#isSynchronized(java.lang.Object)
- * @since 3.0
- */
+ @Override
public boolean isSynchronized(Object element) {
if (element instanceof IFileEditorInput) {
if (getElementInfo(element) != null) {
@@ -1018,10 +988,7 @@ public class FileDocumentProvider extends StorageDocumentProvider {
return super.isSynchronized(element);
}
- /*
- * @see org.eclipse.ui.texteditor.IDocumentProviderExtension4#getContentType(java.lang.Object)
- * @since 3.1
- */
+ @Override
public IContentType getContentType(Object element) throws CoreException {
IContentType contentType= null;
if (!canSaveDocument(element) && element instanceof IFileEditorInput)
@@ -1062,6 +1029,7 @@ public class FileDocumentProvider extends StorageDocumentProvider {
* @return the persisted encoding
* @since 2.1
*/
+ @Override
protected String getPersistedEncoding(Object element) {
if (element instanceof IFileEditorInput) {
IFileEditorInput editorInput= (IFileEditorInput)element;
@@ -1103,6 +1071,7 @@ public class FileDocumentProvider extends StorageDocumentProvider {
* @throws org.eclipse.core.runtime.CoreException if persisting the encoding fails
* @since 2.1
*/
+ @Override
protected void persistEncoding(Object element, String encoding) throws CoreException {
if (element instanceof IFileEditorInput) {
IFileEditorInput editorInput= (IFileEditorInput)element;
@@ -1120,10 +1089,7 @@ public class FileDocumentProvider extends StorageDocumentProvider {
}
}
- /*
- * @see org.eclipse.ui.texteditor.AbstractDocumentProvider#getOperationRunner(org.eclipse.core.runtime.IProgressMonitor)
- * @since 3.0
- */
+ @Override
protected IRunnableContext getOperationRunner(IProgressMonitor monitor) {
if (fOperationRunner == null)
fOperationRunner = new WorkspaceOperationRunner();
@@ -1131,10 +1097,7 @@ public class FileDocumentProvider extends StorageDocumentProvider {
return fOperationRunner;
}
- /*
- * @see org.eclipse.ui.texteditor.AbstractDocumentProvider#getResetRule(java.lang.Object)
- * @since 3.0
- */
+ @Override
protected ISchedulingRule getResetRule(Object element) {
if (element instanceof IFileEditorInput) {
IFileEditorInput input= (IFileEditorInput) element;
@@ -1143,10 +1106,7 @@ public class FileDocumentProvider extends StorageDocumentProvider {
return null;
}
- /*
- * @see org.eclipse.ui.texteditor.AbstractDocumentProvider#getSaveRule(java.lang.Object)
- * @since 3.0
- */
+ @Override
protected ISchedulingRule getSaveRule(Object element) {
if (element instanceof IFileEditorInput) {
IFileEditorInput input= (IFileEditorInput) element;
@@ -1155,10 +1115,7 @@ public class FileDocumentProvider extends StorageDocumentProvider {
return null;
}
- /*
- * @see org.eclipse.ui.texteditor.AbstractDocumentProvider#getSynchronizeRule(java.lang.Object)
- * @since 3.0
- */
+ @Override
protected ISchedulingRule getSynchronizeRule(Object element) {
if (element instanceof IFileEditorInput) {
IFileEditorInput input= (IFileEditorInput) element;
@@ -1167,10 +1124,7 @@ public class FileDocumentProvider extends StorageDocumentProvider {
return null;
}
- /*
- * @see org.eclipse.ui.texteditor.AbstractDocumentProvider#getValidateStateRule(java.lang.Object)
- * @since 3.0
- */
+ @Override
protected ISchedulingRule getValidateStateRule(Object element) {
if (element instanceof IFileEditorInput) {
IFileEditorInput input= (IFileEditorInput) element;
@@ -1215,6 +1169,7 @@ public class FileDocumentProvider extends StorageDocumentProvider {
* @since 3.0
* @deprecated as of 3.0 this method is no longer in use and does nothing
*/
+ @Deprecated
protected void readUTF8BOM(IFile file, String encoding, Object element) throws CoreException {
}
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/ForwardingDocumentProvider.java b/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/ForwardingDocumentProvider.java
index 4a24195ff..f83346edd 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/ForwardingDocumentProvider.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/ForwardingDocumentProvider.java
@@ -107,9 +107,7 @@ public class ForwardingDocumentProvider implements IDocumentProvider, IDocumentP
fParentProvider= parentProvider;
}
- /*
- * @see org.eclipse.ui.texteditor.IDocumentProvider#connect(java.lang.Object)
- */
+ @Override
public void connect(Object element) throws CoreException {
fParentProvider.connect(element);
IDocument document= fParentProvider.getDocument(element);
@@ -120,107 +118,77 @@ public class ForwardingDocumentProvider implements IDocumentProvider, IDocumentP
}
}
- /*
- * @see org.eclipse.ui.texteditor.IDocumentProvider#disconnect(java.lang.Object)
- */
+ @Override
public void disconnect(Object element) {
fParentProvider.disconnect(element);
}
- /*
- * @see org.eclipse.ui.texteditor.IDocumentProvider#getDocument(java.lang.Object)
- */
+ @Override
public IDocument getDocument(Object element) {
return fParentProvider.getDocument(element);
}
- /*
- * @see org.eclipse.ui.texteditor.IDocumentProvider#resetDocument(java.lang.Object)
- */
+ @Override
public void resetDocument(Object element) throws CoreException {
fParentProvider.resetDocument(element);
}
- /*
- * @see org.eclipse.ui.texteditor.IDocumentProvider#saveDocument(org.eclipse.core.runtime.IProgressMonitor, java.lang.Object, org.eclipse.jface.text.IDocument, boolean)
- */
+ @Override
public void saveDocument(IProgressMonitor monitor, Object element, IDocument document, boolean overwrite) throws CoreException {
fParentProvider.saveDocument(monitor, element, document, overwrite);
}
- /*
- * @see org.eclipse.ui.texteditor.IDocumentProvider#getModificationStamp(java.lang.Object)
- */
+ @Override
public long getModificationStamp(Object element) {
return fParentProvider.getModificationStamp(element);
}
- /*
- * @see org.eclipse.ui.texteditor.IDocumentProvider#getSynchronizationStamp(java.lang.Object)
- */
+ @Override
public long getSynchronizationStamp(Object element) {
return fParentProvider.getSynchronizationStamp(element);
}
- /*
- * @see org.eclipse.ui.texteditor.IDocumentProvider#isDeleted(java.lang.Object)
- */
+ @Override
public boolean isDeleted(Object element) {
return fParentProvider.isDeleted(element);
}
- /*
- * @see org.eclipse.ui.texteditor.IDocumentProvider#mustSaveDocument(java.lang.Object)
- */
+ @Override
public boolean mustSaveDocument(Object element) {
return fParentProvider.mustSaveDocument(element);
}
- /*
- * @see org.eclipse.ui.texteditor.IDocumentProvider#canSaveDocument(java.lang.Object)
- */
+ @Override
public boolean canSaveDocument(Object element) {
return fParentProvider.canSaveDocument(element);
}
- /*
- * @see org.eclipse.ui.texteditor.IDocumentProvider#getAnnotationModel(java.lang.Object)
- */
+ @Override
public IAnnotationModel getAnnotationModel(Object element) {
return fParentProvider.getAnnotationModel(element);
}
- /*
- * @see org.eclipse.ui.texteditor.IDocumentProvider#aboutToChange(java.lang.Object)
- */
+ @Override
public void aboutToChange(Object element) {
fParentProvider.aboutToChange(element);
}
- /*
- * @see org.eclipse.ui.texteditor.IDocumentProvider#changed(java.lang.Object)
- */
+ @Override
public void changed(Object element) {
fParentProvider.changed(element);
}
- /*
- * @see org.eclipse.ui.texteditor.IDocumentProvider#addElementStateListener(org.eclipse.ui.texteditor.IElementStateListener)
- */
+ @Override
public void addElementStateListener(IElementStateListener listener) {
fParentProvider.addElementStateListener(listener);
}
- /*
- * @see org.eclipse.ui.texteditor.IDocumentProvider#removeElementStateListener(org.eclipse.ui.texteditor.IElementStateListener)
- */
+ @Override
public void removeElementStateListener(IElementStateListener listener) {
fParentProvider.removeElementStateListener(listener);
}
- /*
- * @see org.eclipse.ui.texteditor.IDocumentProviderExtension#isReadOnly(java.lang.Object)
- */
+ @Override
public boolean isReadOnly(Object element) {
if (fParentProvider instanceof IDocumentProviderExtension) {
IDocumentProviderExtension extension= (IDocumentProviderExtension)fParentProvider;
@@ -229,9 +197,7 @@ public class ForwardingDocumentProvider implements IDocumentProvider, IDocumentP
return false;
}
- /*
- * @see org.eclipse.ui.texteditor.IDocumentProviderExtension#isModifiable(java.lang.Object)
- */
+ @Override
public boolean isModifiable(Object element) {
if (fParentProvider instanceof IDocumentProviderExtension) {
IDocumentProviderExtension extension= (IDocumentProviderExtension)fParentProvider;
@@ -240,9 +206,7 @@ public class ForwardingDocumentProvider implements IDocumentProvider, IDocumentP
return true;
}
- /*
- * @see org.eclipse.ui.texteditor.IDocumentProviderExtension#validateState(java.lang.Object, java.lang.Object)
- */
+ @Override
public void validateState(Object element, Object computationContext) throws CoreException {
if (fParentProvider instanceof IDocumentProviderExtension) {
IDocumentProviderExtension extension= (IDocumentProviderExtension)fParentProvider;
@@ -250,9 +214,7 @@ public class ForwardingDocumentProvider implements IDocumentProvider, IDocumentP
}
}
- /*
- * @see org.eclipse.ui.texteditor.IDocumentProviderExtension#isStateValidated(java.lang.Object)
- */
+ @Override
public boolean isStateValidated(Object element) {
if (fParentProvider instanceof IDocumentProviderExtension) {
IDocumentProviderExtension extension= (IDocumentProviderExtension)fParentProvider;
@@ -261,9 +223,7 @@ public class ForwardingDocumentProvider implements IDocumentProvider, IDocumentP
return true;
}
- /*
- * @see org.eclipse.ui.texteditor.IDocumentProviderExtension#updateStateCache(java.lang.Object)
- */
+ @Override
public void updateStateCache(Object element) throws CoreException {
if (fParentProvider instanceof IDocumentProviderExtension) {
IDocumentProviderExtension extension= (IDocumentProviderExtension)fParentProvider;
@@ -271,9 +231,7 @@ public class ForwardingDocumentProvider implements IDocumentProvider, IDocumentP
}
}
- /*
- * @see org.eclipse.ui.texteditor.IDocumentProviderExtension#setCanSaveDocument(java.lang.Object)
- */
+ @Override
public void setCanSaveDocument(Object element) {
if (fParentProvider instanceof IDocumentProviderExtension) {
IDocumentProviderExtension extension= (IDocumentProviderExtension)fParentProvider;
@@ -281,9 +239,7 @@ public class ForwardingDocumentProvider implements IDocumentProvider, IDocumentP
}
}
- /*
- * @see org.eclipse.ui.texteditor.IDocumentProviderExtension#getStatus(java.lang.Object)
- */
+ @Override
public IStatus getStatus(Object element) {
if (fParentProvider instanceof IDocumentProviderExtension) {
IDocumentProviderExtension extension= (IDocumentProviderExtension)fParentProvider;
@@ -292,9 +248,7 @@ public class ForwardingDocumentProvider implements IDocumentProvider, IDocumentP
return null;
}
- /*
- * @see org.eclipse.ui.texteditor.IDocumentProviderExtension#synchronize(java.lang.Object)
- */
+ @Override
public void synchronize(Object element) throws CoreException {
if (fParentProvider instanceof IDocumentProviderExtension) {
IDocumentProviderExtension extension= (IDocumentProviderExtension)fParentProvider;
@@ -302,9 +256,7 @@ public class ForwardingDocumentProvider implements IDocumentProvider, IDocumentP
}
}
- /*
- * @see org.eclipse.ui.texteditor.IDocumentProviderExtension2#setProgressMonitor(org.eclipse.core.runtime.IProgressMonitor)
- */
+ @Override
public void setProgressMonitor(IProgressMonitor progressMonitor) {
if (fParentProvider instanceof IDocumentProviderExtension2) {
IDocumentProviderExtension2 extension= (IDocumentProviderExtension2)fParentProvider;
@@ -312,9 +264,7 @@ public class ForwardingDocumentProvider implements IDocumentProvider, IDocumentP
}
}
- /*
- * @see org.eclipse.ui.texteditor.IDocumentProviderExtension2#getProgressMonitor()
- */
+ @Override
public IProgressMonitor getProgressMonitor() {
if (fParentProvider instanceof IDocumentProviderExtension2) {
IDocumentProviderExtension2 extension= (IDocumentProviderExtension2)fParentProvider;
@@ -323,9 +273,7 @@ public class ForwardingDocumentProvider implements IDocumentProvider, IDocumentP
return null;
}
- /*
- * @see org.eclipse.ui.texteditor.IDocumentProviderExtension3#isSynchronized(java.lang.Object)
- */
+ @Override
public boolean isSynchronized(Object element) {
if (fParentProvider instanceof IDocumentProviderExtension3) {
IDocumentProviderExtension3 extension= (IDocumentProviderExtension3)fParentProvider;
@@ -334,10 +282,7 @@ public class ForwardingDocumentProvider implements IDocumentProvider, IDocumentP
return true;
}
- /*
- * @see org.eclipse.ui.texteditor.IDocumentProviderExtension5#isNotSynchronizedException(Object, CoreException)
- * @since 3.2
- */
+ @Override
public boolean isNotSynchronizedException(Object element, CoreException ex) {
if (fParentProvider instanceof IDocumentProviderExtension5) {
IDocumentProviderExtension5 extension= (IDocumentProviderExtension5)fParentProvider;
@@ -346,10 +291,7 @@ public class ForwardingDocumentProvider implements IDocumentProvider, IDocumentP
return false;
}
- /*
- * @see org.eclipse.ui.texteditor.IDocumentProviderExtension4#getContentType(java.lang.Object)
- * @since 3.1
- */
+ @Override
public IContentType getContentType(Object element) throws CoreException {
if (fParentProvider instanceof IDocumentProviderExtension4) {
IDocumentProviderExtension4 extension= (IDocumentProviderExtension4)fParentProvider;
@@ -358,9 +300,7 @@ public class ForwardingDocumentProvider implements IDocumentProvider, IDocumentP
return null;
}
- /*
- * @see org.eclipse.ui.editors.text.IStorageDocumentProvider#getDefaultEncoding()
- */
+ @Override
public String getDefaultEncoding() {
if (fParentProvider instanceof IStorageDocumentProvider) {
IStorageDocumentProvider provider= (IStorageDocumentProvider)fParentProvider;
@@ -369,9 +309,7 @@ public class ForwardingDocumentProvider implements IDocumentProvider, IDocumentP
return null;
}
- /*
- * @see org.eclipse.ui.editors.text.IStorageDocumentProvider#getEncoding(java.lang.Object)
- */
+ @Override
public String getEncoding(Object element) {
if (fParentProvider instanceof IStorageDocumentProvider) {
IStorageDocumentProvider provider= (IStorageDocumentProvider)fParentProvider;
@@ -380,9 +318,7 @@ public class ForwardingDocumentProvider implements IDocumentProvider, IDocumentP
return null;
}
- /*
- * @see org.eclipse.ui.editors.text.IStorageDocumentProvider#setEncoding(java.lang.Object, java.lang.String)
- */
+ @Override
public void setEncoding(Object element, String encoding) {
if (fParentProvider instanceof IStorageDocumentProvider) {
IStorageDocumentProvider provider= (IStorageDocumentProvider)fParentProvider;
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/IEncodingActionsConstants.java b/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/IEncodingActionsConstants.java
index 5dd863a2a..3217edef1 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/IEncodingActionsConstants.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/IEncodingActionsConstants.java
@@ -22,6 +22,7 @@ package org.eclipse.ui.editors.text;
* @noextend This interface is not intended to be extended by clients.
*
*/
+@Deprecated
public interface IEncodingActionsConstants {
/**
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/IEncodingActionsDefinitionIds.java b/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/IEncodingActionsDefinitionIds.java
index 2466c67b4..16cf31c6b 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/IEncodingActionsDefinitionIds.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/IEncodingActionsDefinitionIds.java
@@ -21,6 +21,7 @@ package org.eclipse.ui.editors.text;
* @noimplement This interface is not intended to be implemented by clients.
* @noextend This interface is not intended to be extended by clients.
*/
+@Deprecated
public interface IEncodingActionsDefinitionIds {
/**
* Action definition id of the action to change the encoding into default.
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/IEncodingActionsHelpContextIds.java b/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/IEncodingActionsHelpContextIds.java
index fdb13d9d1..e322991c5 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/IEncodingActionsHelpContextIds.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/IEncodingActionsHelpContextIds.java
@@ -23,6 +23,7 @@ import org.eclipse.ui.texteditor.IAbstractTextEditorHelpContextIds;
* @noimplement This interface is not intended to be implemented by clients.
* @noextend This interface is not intended to be extended by clients.
*/
+@Deprecated
public interface IEncodingActionsHelpContextIds {
/**
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/StorageDocumentProvider.java b/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/StorageDocumentProvider.java
index 6f2d4b896..d3d573795 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/StorageDocumentProvider.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/StorageDocumentProvider.java
@@ -114,6 +114,7 @@ public class StorageDocumentProvider extends AbstractDocumentProvider implements
*
* @deprecated use encoding based version instead
*/
+ @Deprecated
protected void setDocumentContent(IDocument document, InputStream contentStream) throws CoreException {
setDocumentContent(document, contentStream, null);
}
@@ -172,6 +173,7 @@ public class StorageDocumentProvider extends AbstractDocumentProvider implements
* @deprecated use the encoding based version instead
* @since 2.0
*/
+ @Deprecated
protected boolean setDocumentContent(IDocument document, IEditorInput editorInput) throws CoreException {
return setDocumentContent(document, editorInput, null);
}
@@ -203,9 +205,7 @@ public class StorageDocumentProvider extends AbstractDocumentProvider implements
return false;
}
- /*
- * @see AbstractDocumentProvider#createAnnotationModel(Object)
- */
+ @Override
protected IAnnotationModel createAnnotationModel(Object element) throws CoreException {
return null;
}
@@ -219,9 +219,7 @@ public class StorageDocumentProvider extends AbstractDocumentProvider implements
return new Document();
}
- /*
- * @see AbstractDocumentProvider#createDocument(Object)
- */
+ @Override
protected IDocument createDocument(Object element) throws CoreException {
if (element instanceof IEditorInput) {
@@ -247,10 +245,7 @@ public class StorageDocumentProvider extends AbstractDocumentProvider implements
protected void setupDocument(Object element, IDocument document) {
}
- /*
- * @see AbstractDocumentProvider#createElementInfo(Object)
- * @since 2.0
- */
+ @Override
protected ElementInfo createElementInfo(Object element) throws CoreException {
if (element instanceof IStorageEditorInput) {
@@ -274,9 +269,7 @@ public class StorageDocumentProvider extends AbstractDocumentProvider implements
return super.createElementInfo(element);
}
- /*
- * @see AbstractDocumentProvider#doSaveDocument(IProgressMonitor, Object, IDocument, boolean)
- */
+ @Override
protected void doSaveDocument(IProgressMonitor monitor, Object element, IDocument document, boolean overwrite) throws CoreException {
}
@@ -323,10 +316,7 @@ public class StorageDocumentProvider extends AbstractDocumentProvider implements
}
}
- /*
- * @see IDocumentProviderExtension#isReadOnly(Object)
- * @since 2.0
- */
+ @Override
public boolean isReadOnly(Object element) {
if (element instanceof IStorageEditorInput) {
StorageInfo info= (StorageInfo) getElementInfo(element);
@@ -344,10 +334,7 @@ public class StorageDocumentProvider extends AbstractDocumentProvider implements
return super.isReadOnly(element);
}
- /*
- * @see org.eclipse.ui.texteditor.IDocumentProviderExtension5#isNotSynchronizedException(Object, CoreException)
- * @since 3.2
- */
+ @Override
public boolean isNotSynchronizedException(Object element, CoreException ex) {
IStatus status= ex.getStatus();
if (status == null || status instanceof MultiStatus)
@@ -359,10 +346,7 @@ public class StorageDocumentProvider extends AbstractDocumentProvider implements
return status.getCode() == IResourceStatus.OUT_OF_SYNC_LOCAL;
}
- /*
- * @see IDocumentProviderExtension#isModifiable(Object)
- * @since 2.0
- */
+ @Override
public boolean isModifiable(Object element) {
if (element instanceof IStorageEditorInput) {
StorageInfo info= (StorageInfo) getElementInfo(element);
@@ -380,10 +364,7 @@ public class StorageDocumentProvider extends AbstractDocumentProvider implements
return super.isModifiable(element);
}
- /*
- * @see AbstractDocumentProvider#doUpdateStateCache(Object)
- * @since 2.0
- */
+ @Override
protected void doUpdateStateCache(Object element) throws CoreException {
if (element instanceof IStorageEditorInput) {
StorageInfo info= (StorageInfo) getElementInfo(element);
@@ -393,18 +374,12 @@ public class StorageDocumentProvider extends AbstractDocumentProvider implements
super.doUpdateStateCache(element);
}
- /*
- * @see IStorageDocumentProvider#getDefaultEncoding()
- * @since 2.0
- */
+ @Override
public String getDefaultEncoding() {
return ResourcesPlugin.getEncoding();
}
- /*
- * @see IStorageDocumentProvider#getEncoding(Object)
- * @since 2.0
- */
+ @Override
public String getEncoding(Object element) {
if (element instanceof IStorageEditorInput) {
StorageInfo info= (StorageInfo) getElementInfo(element);
@@ -415,10 +390,7 @@ public class StorageDocumentProvider extends AbstractDocumentProvider implements
return null;
}
- /*
- * @see IStorageDocumentProvider#setEncoding(Object, String)
- * @since 2.0
- */
+ @Override
public void setEncoding(Object element, String encoding) {
if (element instanceof IStorageEditorInput) {
StorageInfo info= (StorageInfo) getElementInfo(element);
@@ -433,10 +405,7 @@ public class StorageDocumentProvider extends AbstractDocumentProvider implements
}
}
- /*
- * @see org.eclipse.ui.texteditor.IDocumentProviderExtension4#getContentType(java.lang.Object)
- * @since 3.1
- */
+ @Override
public IContentType getContentType(Object element) throws CoreException {
if (element instanceof IStorageEditorInput) {
IStorage storage= ((IStorageEditorInput) element).getStorage();
@@ -514,10 +483,7 @@ public class StorageDocumentProvider extends AbstractDocumentProvider implements
// Default is to do nothing
}
- /*
- * @see org.eclipse.ui.texteditor.AbstractDocumentProvider#getOperationRunner(org.eclipse.core.runtime.IProgressMonitor)
- * @since 3.0
- */
+ @Override
protected IRunnableContext getOperationRunner(IProgressMonitor monitor) {
return null;
}
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/TextEditor.java b/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/TextEditor.java
index a8895cb3b..7493d9094 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/TextEditor.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/TextEditor.java
@@ -71,6 +71,7 @@ public class TextEditor extends AbstractDecoratedTextEditor {
* providing a custom source viewer configuration, subclasses may extend
* this method.
*/
+ @Override
protected void initializeEditor() {
super.initializeEditor();
setEditorContextMenuId("#TextEditorContext"); //$NON-NLS-1$
@@ -80,10 +81,7 @@ public class TextEditor extends AbstractDecoratedTextEditor {
setInsertMode(INSERT);
}
- /*
- * @see IWorkbenchPart#dispose()
- * @since 2.0
- */
+ @Override
public void dispose() {
if (fEncodingSupport != null) {
fEncodingSupport.dispose();
@@ -106,26 +104,18 @@ public class TextEditor extends AbstractDecoratedTextEditor {
fEncodingSupport.initialize(this);
}
- /*
- * @see org.eclipse.ui.part.EditorPart#isSaveAsAllowed()
- */
+ @Override
public boolean isSaveAsAllowed() {
return true;
}
- /*
- * @see AbstractTextEditor#createActions()
- * @since 2.0
- */
+ @Override
protected void createActions() {
installEncodingSupport();
super.createActions();
}
- /*
- * @see StatusTextEditor#getStatusHeader(IStatus)
- * @since 2.0
- */
+ @Override
protected String getStatusHeader(IStatus status) {
if (fEncodingSupport != null) {
String message= fEncodingSupport.getStatusHeader(status);
@@ -135,10 +125,7 @@ public class TextEditor extends AbstractDecoratedTextEditor {
return super.getStatusHeader(status);
}
- /*
- * @see StatusTextEditor#getStatusBanner(IStatus)
- * @since 2.0
- */
+ @Override
protected String getStatusBanner(IStatus status) {
if (fEncodingSupport != null) {
String message= fEncodingSupport.getStatusBanner(status);
@@ -148,10 +135,7 @@ public class TextEditor extends AbstractDecoratedTextEditor {
return super.getStatusBanner(status);
}
- /*
- * @see StatusTextEditor#getStatusMessage(IStatus)
- * @since 2.0
- */
+ @Override
protected String getStatusMessage(IStatus status) {
if (fEncodingSupport != null) {
String message= fEncodingSupport.getStatusMessage(status);
@@ -161,40 +145,28 @@ public class TextEditor extends AbstractDecoratedTextEditor {
return super.getStatusMessage(status);
}
- /*
- * @see AbstractTextEditor#doSetInput(IEditorInput)
- * @since 2.0
- */
+ @Override
protected void doSetInput(IEditorInput input) throws CoreException {
super.doSetInput(input);
if (fEncodingSupport != null)
fEncodingSupport.reset();
}
- /*
- * @see IAdaptable#getAdapter(java.lang.Class)
- * @since 2.0
- */
+ @Override
public Object getAdapter(Class adapter) {
if (IEncodingSupport.class.equals(adapter))
return fEncodingSupport;
return super.getAdapter(adapter);
}
- /*
- * @see org.eclipse.ui.texteditor.AbstractTextEditor#updatePropertyDependentActions()
- * @since 2.0
- */
+ @Override
protected void updatePropertyDependentActions() {
super.updatePropertyDependentActions();
if (fEncodingSupport != null)
fEncodingSupport.reset();
}
- /*
- * @see org.eclipse.ui.texteditor.AbstractDecoratedTextEditor#handlePreferenceStoreChanged(org.eclipse.jface.util.PropertyChangeEvent)
- * @since 3.3
- */
+ @Override
protected void handlePreferenceStoreChanged(PropertyChangeEvent event) {
if (event.getProperty().equals(SpellingService.PREFERENCE_SPELLING_ENABLED)) {
ISourceViewer viewer= getSourceViewer();
@@ -218,10 +190,7 @@ public class TextEditor extends AbstractDecoratedTextEditor {
super.handlePreferenceStoreChanged(event);
}
- /*
- * @see org.eclipse.ui.texteditor.AbstractTextEditor#editorContextMenuAboutToShow(org.eclipse.jface.action.IMenuManager)
- * @since 3.0
- */
+ @Override
protected void editorContextMenuAboutToShow(IMenuManager menu) {
super.editorContextMenuAboutToShow(menu);
addAction(menu, ITextEditorActionConstants.GROUP_EDIT, ITextEditorActionConstants.SHIFT_RIGHT);
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/TextEditorActionContributor.java b/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/TextEditorActionContributor.java
index bd89a8c6a..d5300ca4e 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/TextEditorActionContributor.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/TextEditorActionContributor.java
@@ -121,10 +121,7 @@ public class TextEditorActionContributor extends BasicTextEditorActionContributo
fRetargetShowInformationAction.setAction(getAction(textEditor, ITextEditorActionConstants.SHOW_INFORMATION));
}
- /*
- * @see org.eclipse.ui.texteditor.BasicTextEditorActionContributor#contributeToMenu(org.eclipse.jface.action.IMenuManager)
- * @since 3.3
- */
+ @Override
public void contributeToMenu(IMenuManager menu) {
super.contributeToMenu(menu);
@@ -136,25 +133,19 @@ public class TextEditorActionContributor extends BasicTextEditorActionContributo
}
}
- /*
- * @see IEditorActionBarContributor#setActiveEditor(org.eclipse.ui.IEditorPart)
- */
+ @Override
public void setActiveEditor(IEditorPart part) {
super.setActiveEditor(part);
doSetActiveEditor(part);
}
- /*
- * @see IEditorActionBarContributor#dispose()
- */
+ @Override
public void dispose() {
doSetActiveEditor(null);
super.dispose();
}
- /*
- * @see EditorActionBarContributor#init(org.eclipse.ui.IActionBars)
- */
+ @Override
public void init(IActionBars bars) {
super.init(bars);
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/TextEditorPreferenceConstants.java b/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/TextEditorPreferenceConstants.java
index a50e0d635..194cad4de 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/TextEditorPreferenceConstants.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/TextEditorPreferenceConstants.java
@@ -38,6 +38,7 @@ public class TextEditorPreferenceConstants {
* </p>
* @deprecated As of 3.0, replaced by {@link org.eclipse.ui.texteditor.AbstractDecoratedTextEditorPreferenceConstants}
*/
+ @Deprecated
public final static String EDITOR_CURRENT_LINE= "currentLine"; //$NON-NLS-1$
/**
@@ -51,6 +52,7 @@ public class TextEditorPreferenceConstants {
* @see org.eclipse.jface.preference.PreferenceConverter
* @deprecated As of 3.0, replaced by {@link org.eclipse.ui.texteditor.AbstractDecoratedTextEditorPreferenceConstants}
*/
+ @Deprecated
public final static String EDITOR_CURRENT_LINE_COLOR= "currentLineColor"; //$NON-NLS-1$
/**
@@ -61,6 +63,7 @@ public class TextEditorPreferenceConstants {
* </p>
* @deprecated As of 3.0, replaced by {@link org.eclipse.ui.texteditor.AbstractDecoratedTextEditorPreferenceConstants}
*/
+ @Deprecated
public final static String EDITOR_PRINT_MARGIN= "printMargin"; //$NON-NLS-1$
/**
@@ -74,6 +77,7 @@ public class TextEditorPreferenceConstants {
* @see org.eclipse.jface.preference.PreferenceConverter
* @deprecated As of 3.0,, replaced by {@link org.eclipse.ui.texteditor.AbstractDecoratedTextEditorPreferenceConstants}
*/
+ @Deprecated
public final static String EDITOR_PRINT_MARGIN_COLOR= "printMarginColor"; //$NON-NLS-1$
/**
@@ -84,6 +88,7 @@ public class TextEditorPreferenceConstants {
* </p>
* @deprecated As of 3.0,, replaced by {@link org.eclipse.ui.texteditor.AbstractDecoratedTextEditorPreferenceConstants}
*/
+ @Deprecated
public final static String EDITOR_PRINT_MARGIN_COLUMN= "printMarginColumn"; //$NON-NLS-1$
/**
@@ -96,6 +101,7 @@ public class TextEditorPreferenceConstants {
* @since 2.1
* @deprecated As of 3.0, replaced by {@link org.eclipse.ui.texteditor.AbstractDecoratedTextEditorPreferenceConstants}
*/
+ @Deprecated
public final static String EDITOR_UNKNOWN_INDICATION= "othersIndication"; //$NON-NLS-1$
/**
@@ -111,6 +117,7 @@ public class TextEditorPreferenceConstants {
* @since 2.1
* @deprecated As of 3.0, replaced by {@link org.eclipse.ui.texteditor.AbstractDecoratedTextEditorPreferenceConstants}
*/
+ @Deprecated
public final static String EDITOR_UNKNOWN_INDICATION_COLOR= "othersIndicationColor"; //$NON-NLS-1$
/**
@@ -122,6 +129,7 @@ public class TextEditorPreferenceConstants {
* @since 2.1
* @deprecated As of 3.0, replaced by {@link org.eclipse.ui.texteditor.AbstractDecoratedTextEditorPreferenceConstants}
*/
+ @Deprecated
public final static String EDITOR_UNKNOWN_INDICATION_IN_OVERVIEW_RULER= "othersIndicationInOverviewRuler"; //$NON-NLS-1$
/**
@@ -132,6 +140,7 @@ public class TextEditorPreferenceConstants {
* </p>
* @deprecated As of 3.0, replaced by {@link org.eclipse.ui.texteditor.AbstractDecoratedTextEditorPreferenceConstants}
*/
+ @Deprecated
public final static String EDITOR_OVERVIEW_RULER= "overviewRuler"; //$NON-NLS-1$
/**
@@ -142,6 +151,7 @@ public class TextEditorPreferenceConstants {
* </p>
* @deprecated As of 3.0, replaced by {@link org.eclipse.ui.texteditor.AbstractDecoratedTextEditorPreferenceConstants}
*/
+ @Deprecated
public final static String EDITOR_LINE_NUMBER_RULER= "lineNumberRuler"; //$NON-NLS-1$
/**
@@ -156,96 +166,115 @@ public class TextEditorPreferenceConstants {
* @see #EDITOR_LINE_NUMBER_RULER
* @deprecated As of 3.0, replaced by {@link org.eclipse.ui.texteditor.AbstractDecoratedTextEditorPreferenceConstants}
*/
+ @Deprecated
public final static String EDITOR_LINE_NUMBER_RULER_COLOR= "lineNumberColor"; //$NON-NLS-1$
/**
* @deprecated As of 2.1, provided by <code>org.eclipse.ui.editors.markerAnnotationSpecification</code> extension point
*/
+ @Deprecated
public final static String EDITOR_PROBLEM_INDICATION= "problemIndication"; //$NON-NLS-1$
/**
* @deprecated As of 2.1, provided by <code>org.eclipse.ui.editors.markerAnnotationSpecification</code> extension point
*/
+ @Deprecated
public final static String EDITOR_PROBLEM_INDICATION_COLOR= "problemIndicationColor"; //$NON-NLS-1$
/**
* @deprecated As of 2.1, provided by <code>org.eclipse.ui.editors.markerAnnotationSpecification</code> extension point
*/
+ @Deprecated
public final static String EDITOR_WARNING_INDICATION= "warningIndication"; //$NON-NLS-1$
/**
* @deprecated As of 2.1, provided by <code>org.eclipse.ui.editors.markerAnnotationSpecification</code> extension point
*/
+ @Deprecated
public final static String EDITOR_WARNING_INDICATION_COLOR= "warningIndicationColor"; //$NON-NLS-1$
/**
* @deprecated As of 2.1, provided by <code>org.eclipse.ui.editors.markerAnnotationSpecification</code> extension point
*/
+ @Deprecated
public final static String EDITOR_INFO_INDICATION= "infoIndication"; //$NON-NLS-1$
/**
* @deprecated As of 2.1, provided by <code>org.eclipse.ui.editors.markerAnnotationSpecification</code> extension point
*/
+ @Deprecated
public final static String EDITOR_INFO_INDICATION_COLOR= "infoIndicationColor"; //$NON-NLS-1$
/**
* @deprecated As of 2.1, provided by <code>org.eclipse.ui.editors.markerAnnotationSpecification</code> extension point
*/
+ @Deprecated
public final static String EDITOR_TASK_INDICATION= "taskIndication"; //$NON-NLS-1$
/**
* @deprecated As of 2.1, provided by <code>org.eclipse.ui.editors.markerAnnotationSpecification</code> extension point
*/
+ @Deprecated
public final static String EDITOR_TASK_INDICATION_COLOR= "taskIndicationColor"; //$NON-NLS-1$
/**
* @deprecated As of 2.1, provided by <code>org.eclipse.ui.editors.markerAnnotationSpecification</code> extension point
*/
+ @Deprecated
public final static String EDITOR_BOOKMARK_INDICATION= "bookmarkIndication"; //$NON-NLS-1$
/**
* @deprecated As of 2.1, provided by <code>org.eclipse.ui.editors.markerAnnotationSpecification</code> extension point
*/
+ @Deprecated
public final static String EDITOR_BOOKMARK_INDICATION_COLOR= "bookmarkIndicationColor"; //$NON-NLS-1$
/**
* @deprecated As of 2.1, provided by <code>org.eclipse.ui.editors.markerAnnotationSpecification</code> extension point
*/
+ @Deprecated
public final static String EDITOR_SEARCH_RESULT_INDICATION= "searchResultIndication"; //$NON-NLS-1$
/**
* @deprecated As of 2.1, provided by <code>org.eclipse.ui.editors.markerAnnotationSpecification</code> extension point
*/
+ @Deprecated
public final static String EDITOR_SEARCH_RESULT_INDICATION_COLOR= "searchResultIndicationColor"; //$NON-NLS-1$
/**
* @deprecated As of 2.1, provided by <code>org.eclipse.ui.editors.markerAnnotationSpecification</code> extension point
*/
+ @Deprecated
public final static String EDITOR_ERROR_INDICATION_IN_OVERVIEW_RULER= "errorIndicationInOverviewRuler"; //$NON-NLS-1$
/**
* @deprecated As of 2.1, provided by <code>org.eclipse.ui.editors.markerAnnotationSpecification</code> extension point
*/
+ @Deprecated
public final static String EDITOR_WARNING_INDICATION_IN_OVERVIEW_RULER= "warningIndicationInOverviewRuler"; //$NON-NLS-1$
/**
* @deprecated As of 2.1, provided by <code>org.eclipse.ui.editors.markerAnnotationSpecification</code> extension point
*/
+ @Deprecated
public final static String EDITOR_INFO_INDICATION_IN_OVERVIEW_RULER= "infoIndicationInOverviewRuler"; //$NON-NLS-1$
/**
* @deprecated As of 2.1, provided by <code>org.eclipse.ui.editors.markerAnnotationSpecification</code> extension point
*/
+ @Deprecated
public final static String EDITOR_TASK_INDICATION_IN_OVERVIEW_RULER= "taskIndicationInOverviewRuler"; //$NON-NLS-1$
/**
* @deprecated As of 2.1, provided by <code>org.eclipse.ui.editors.markerAnnotationSpecification</code> extension point
*/
+ @Deprecated
public final static String EDITOR_BOOKMARK_INDICATION_IN_OVERVIEW_RULER= "bookmarkIndicationInOverviewRuler"; //$NON-NLS-1$
/**
* @deprecated As of 2.1, provided by <code>org.eclipse.ui.editors.markerAnnotationSpecification</code> extension point
*/
+ @Deprecated
public final static String EDITOR_SEARCH_RESULT_INDICATION_IN_OVERVIEW_RULER= "searchResultIndicationInOverviewRuler"; //$NON-NLS-1$
/**
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/TextEditorPreferencePage.java b/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/TextEditorPreferencePage.java
index 7a0ccdb6e..a99b4f1e7 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/TextEditorPreferencePage.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/TextEditorPreferencePage.java
@@ -43,6 +43,7 @@ import org.eclipse.ui.texteditor.AbstractTextEditor;
* </p>
* @deprecated As of 2.1, fonts are managed by the workbench, no longer supported
*/
+@Deprecated
public class TextEditorPreferencePage extends FieldEditorPreferencePage implements IWorkbenchPreferencePage {
/**
@@ -62,24 +63,18 @@ public class TextEditorPreferencePage extends FieldEditorPreferencePage implemen
setPreferenceStore(new ScopedPreferenceStore(InstanceScope.INSTANCE, "org.eclipse.ui.workbench")); //$NON-NLS-1$
}
- /*
- * @see IDialogPage#createControl(org.eclipse.swt.widgets.Composite)
- */
+ @Override
public void createControl(Composite parent) {
super.createControl(parent);
PlatformUI.getWorkbench().getHelpSystem().setHelp(getControl(), ITextEditorHelpContextIds.TEXT_EDITOR_PREFERENCE_PAGE);
}
- /*
- * @see FieldEditorPreferencePage#createFieldEditors()
- */
+ @Override
public void createFieldEditors() {
addField(new FontFieldEditor(JFaceResources.TEXT_FONT, TextEditorMessages.PreferencePage_fontEditor, getFieldEditorParent()));
}
- /*
- * @see IWorkbenchPreferencePage#init(org.eclipse.ui.IWorkbench)
- */
+ @Override
public void init(IWorkbench workbench) {
}
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/TextFileDocumentProvider.java b/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/TextFileDocumentProvider.java
index 8d0509ee8..b7b051a8c 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/TextFileDocumentProvider.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/TextFileDocumentProvider.java
@@ -124,9 +124,7 @@ public class TextFileDocumentProvider implements IDocumentProvider, IDocumentPro
*/
protected abstract void execute(IProgressMonitor monitor) throws CoreException;
- /*
- * @see org.eclipse.jface.operation.IRunnableWithProgress#run(org.eclipse.core.runtime.IProgressMonitor)
- */
+ @Override
public void run(IProgressMonitor monitor) throws InvocationTargetException, InterruptedException {
try {
execute(monitor);
@@ -135,9 +133,7 @@ public class TextFileDocumentProvider implements IDocumentProvider, IDocumentPro
}
}
- /*
- * @see org.eclipse.ui.texteditor.ISchedulingRuleProvider#getSchedulingRule()
- */
+ @Override
public ISchedulingRule getSchedulingRule() {
return ResourcesPlugin.getWorkspace().getRoot();
}
@@ -146,40 +142,72 @@ public class TextFileDocumentProvider implements IDocumentProvider, IDocumentPro
/**
* @deprecated As of 3.3 - do not use
*/
+ @Deprecated
static protected class NullProvider implements IDocumentProvider, IDocumentProviderExtension, IDocumentProviderExtension2, IDocumentProviderExtension3, IDocumentProviderExtension4, IDocumentProviderExtension5, IStorageDocumentProvider {
static final private IStatus STATUS_ERROR= new Status(IStatus.ERROR, EditorsUI.PLUGIN_ID, IStatus.OK, TextEditorMessages.NullProvider_error, null);
+ @Override
public void connect(Object element) throws CoreException {}
+ @Override
public void disconnect(Object element) {}
+ @Override
public IDocument getDocument(Object element) { return null; }
+ @Override
public void resetDocument(Object element) throws CoreException {}
+ @Override
public void saveDocument(IProgressMonitor monitor, Object element, IDocument document, boolean overwrite) throws CoreException {}
+ @Override
public long getModificationStamp(Object element) { return 0; }
+ @Override
public long getSynchronizationStamp(Object element) { return 0; }
+ @Override
public boolean isDeleted(Object element) { return true; }
+ @Override
public boolean mustSaveDocument(Object element) { return false; }
+ @Override
public boolean canSaveDocument(Object element) { return false; }
+ @Override
public IAnnotationModel getAnnotationModel(Object element) { return null; }
+ @Override
public void aboutToChange(Object element) {}
+ @Override
public void changed(Object element) {}
+ @Override
public void addElementStateListener(IElementStateListener listener) {}
+ @Override
public void removeElementStateListener(IElementStateListener listener) {}
+ @Override
public boolean isReadOnly(Object element) { return true; }
+ @Override
public boolean isModifiable(Object element) { return false; }
+ @Override
public void validateState(Object element, Object computationContext) throws CoreException {}
+ @Override
public boolean isStateValidated(Object element) { return true; }
+ @Override
public void updateStateCache(Object element) throws CoreException {}
+ @Override
public void setCanSaveDocument(Object element) {}
+ @Override
public IStatus getStatus(Object element) { return STATUS_ERROR; }
+ @Override
public void synchronize(Object element) throws CoreException {}
+ @Override
public void setProgressMonitor(IProgressMonitor progressMonitor) {}
+ @Override
public IProgressMonitor getProgressMonitor() { return new NullProgressMonitor(); }
+ @Override
public boolean isSynchronized(Object element) { return true; }
+ @Override
public boolean isNotSynchronizedException(Object element, CoreException ex) { return false; }
+ @Override
public String getDefaultEncoding() { return null; }
+ @Override
public String getEncoding(Object element) { return null; }
+ @Override
public void setEncoding(Object element, String encoding) {}
+ @Override
public IContentType getContentType(Object element) throws CoreException { return null; }
}
@@ -206,16 +234,12 @@ public class TextFileDocumentProvider implements IDocumentProvider, IDocumentPro
fElement= element;
}
- /*
- * @see java.util.Iterator#hasNext()
- */
+ @Override
public boolean hasNext() {
return fElement != null;
}
- /*
- * @see java.util.Iterator#next()
- */
+ @Override
public Object next() {
if (fElement != null) {
Object result= fElement;
@@ -225,9 +249,7 @@ public class TextFileDocumentProvider implements IDocumentProvider, IDocumentPro
throw new NoSuchElementException();
}
- /*
- * @see java.util.Iterator#remove()
- */
+ @Override
public void remove() {
throw new UnsupportedOperationException();
}
@@ -238,9 +260,7 @@ public class TextFileDocumentProvider implements IDocumentProvider, IDocumentPro
public FileBufferListener() {
}
- /*
- * @see org.eclipse.core.buffer.text.IBufferedFileListener#bufferContentAboutToBeReplaced(org.eclipse.core.buffer.text.IBufferedFile)
- */
+ @Override
public void bufferContentAboutToBeReplaced(IFileBuffer file) {
List list= new ArrayList(fElementStateListeners);
Iterator e= list.iterator();
@@ -252,9 +272,7 @@ public class TextFileDocumentProvider implements IDocumentProvider, IDocumentPro
}
}
- /*
- * @see org.eclipse.core.buffer.text.IBufferedFileListener#bufferContentReplaced(org.eclipse.core.buffer.text.IBufferedFile)
- */
+ @Override
public void bufferContentReplaced(IFileBuffer file) {
List list= new ArrayList(fElementStateListeners);
Iterator e= list.iterator();
@@ -266,18 +284,14 @@ public class TextFileDocumentProvider implements IDocumentProvider, IDocumentPro
}
}
- /*
- * @see org.eclipse.core.buffer.text.IBufferedFileListener#stateChanging(org.eclipse.core.buffer.text.IBufferedFile)
- */
+ @Override
public void stateChanging(IFileBuffer file) {
Iterator i= getElements(file);
while (i.hasNext())
fireElementStateChanging(i.next());
}
- /*
- * @see org.eclipse.core.buffer.text.IBufferedFileListener#dirtyStateChanged(org.eclipse.core.buffer.text.IBufferedFile, boolean)
- */
+ @Override
public void dirtyStateChanged(IFileBuffer file, boolean isDirty) {
List list= new ArrayList(fElementStateListeners);
Iterator e= list.iterator();
@@ -289,9 +303,7 @@ public class TextFileDocumentProvider implements IDocumentProvider, IDocumentPro
}
}
- /*
- * @see org.eclipse.core.buffer.text.IBufferedFileListener#stateValidationChanged(org.eclipse.core.buffer.text.IBufferedFile, boolean)
- */
+ @Override
public void stateValidationChanged(IFileBuffer file, boolean isStateValidated) {
List list= new ArrayList(fElementStateListeners);
Iterator e= list.iterator();
@@ -306,9 +318,7 @@ public class TextFileDocumentProvider implements IDocumentProvider, IDocumentPro
}
}
- /*
- * @see org.eclipse.core.buffer.text.IBufferedFileListener#underlyingFileMoved(org.eclipse.core.buffer.text.IBufferedFile, org.eclipse.core.runtime.IPath)
- */
+ @Override
public void underlyingFileMoved(IFileBuffer file, IPath newLocation) {
IWorkspace workspace=ResourcesPlugin.getWorkspace();
IFile newFile= workspace.getRoot().getFile(newLocation);
@@ -323,9 +333,7 @@ public class TextFileDocumentProvider implements IDocumentProvider, IDocumentPro
}
}
- /*
- * @see org.eclipse.core.buffer.text.IBufferedFileListener#underlyingFileDeleted(org.eclipse.core.buffer.text.IBufferedFile)
- */
+ @Override
public void underlyingFileDeleted(IFileBuffer file) {
List list= new ArrayList(fElementStateListeners);
Iterator e= list.iterator();
@@ -337,25 +345,19 @@ public class TextFileDocumentProvider implements IDocumentProvider, IDocumentPro
}
}
- /*
- * @see org.eclipse.core.buffer.text.IBufferedFileListener#stateChangeFailed(org.eclipse.core.buffer.text.IBufferedFile)
- */
+ @Override
public void stateChangeFailed(IFileBuffer file) {
Iterator i= getElements(file);
while (i.hasNext())
fireElementStateChangeFailed(i.next());
}
- /*
- * @see org.eclipse.core.filebuffers.IFileBufferListener#bufferCreated(org.eclipse.core.filebuffers.IFileBuffer)
- */
+ @Override
public void bufferCreated(IFileBuffer buffer) {
// ignore
}
- /*
- * @see org.eclipse.core.filebuffers.IFileBufferListener#bufferDisposed(org.eclipse.core.filebuffers.IFileBuffer)
- */
+ @Override
public void bufferDisposed(IFileBuffer buffer) {
// ignore
}
@@ -468,9 +470,7 @@ public class TextFileDocumentProvider implements IDocumentProvider, IDocumentPro
}
}
- /*
- * @see org.eclipse.ui.texteditor.IDocumentProvider#connect(java.lang.Object)
- */
+ @Override
public void connect(Object element) throws CoreException {
FileInfo info= (FileInfo) fFileInfoMap.get(element);
if (info == null) {
@@ -635,9 +635,7 @@ public class TextFileDocumentProvider implements IDocumentProvider, IDocumentPro
return null;
}
- /*
- * @see org.eclipse.ui.texteditor.IDocumentProvider#disconnect(java.lang.Object)
- */
+ @Override
public void disconnect(Object element) {
FileInfo info= (FileInfo) fFileInfoMap.get(element);
@@ -714,9 +712,7 @@ public class TextFileDocumentProvider implements IDocumentProvider, IDocumentPro
return new SingleElementIterator(value);
}
- /*
- * @see org.eclipse.ui.texteditor.IDocumentProvider#getDocument(java.lang.Object)
- */
+ @Override
public IDocument getDocument(Object element) {
FileInfo info= (FileInfo) fFileInfoMap.get(element);
if (info != null)
@@ -724,16 +720,12 @@ public class TextFileDocumentProvider implements IDocumentProvider, IDocumentPro
return getParentProvider().getDocument(element);
}
- /*
- * @see org.eclipse.ui.texteditor.IDocumentProvider#resetDocument(java.lang.Object)
- */
+ @Override
public void resetDocument(Object element) throws CoreException {
final FileInfo info= (FileInfo) fFileInfoMap.get(element);
if (info != null) {
DocumentProviderOperation operation= new DocumentProviderOperation() {
- /*
- * @see org.eclipse.ui.editors.text.TextFileDocumentProvider.DocumentProviderOperation#execute(org.eclipse.core.runtime.IProgressMonitor)
- */
+ @Override
protected void execute(IProgressMonitor monitor) throws CoreException {
info.fTextFileBuffer.revert(monitor);
@@ -742,9 +734,7 @@ public class TextFileDocumentProvider implements IDocumentProvider, IDocumentPro
markerModel.resetMarkers();
}
}
- /*
- * @see org.eclipse.ui.editors.text.TextFileDocumentProvider.DocumentProviderOperation#getSchedulingRule()
- */
+ @Override
public ISchedulingRule getSchedulingRule() {
if (info.fElement instanceof IFileEditorInput) {
IFileEditorInput input= (IFileEditorInput) info.fElement;
@@ -759,9 +749,7 @@ public class TextFileDocumentProvider implements IDocumentProvider, IDocumentPro
}
}
- /*
- * @see IDocumentProvider#saveDocument(IProgressMonitor, Object, IDocument, boolean)
- */
+ @Override
public final void saveDocument(IProgressMonitor monitor, Object element, IDocument document, boolean overwrite) throws CoreException {
if (element == null)
@@ -788,15 +776,11 @@ public class TextFileDocumentProvider implements IDocumentProvider, IDocumentPro
}
return new DocumentProviderOperation() {
- /*
- * @see org.eclipse.ui.editors.text.TextFileDocumentProvider.DocumentProviderOperation#execute(org.eclipse.core.runtime.IProgressMonitor)
- */
+ @Override
public void execute(IProgressMonitor monitor) throws CoreException {
commitFileBuffer(monitor, info, overwrite);
}
- /*
- * @see org.eclipse.ui.editors.text.TextFileDocumentProvider.DocumentProviderOperation#getSchedulingRule()
- */
+ @Override
public ISchedulingRule getSchedulingRule() {
if (info.fElement instanceof IFileEditorInput) {
IFileEditorInput input= (IFileEditorInput) info.fElement;
@@ -810,15 +794,11 @@ public class TextFileDocumentProvider implements IDocumentProvider, IDocumentPro
final IFile file= ((IFileEditorInput) element).getFile();
return new DocumentProviderOperation() {
- /*
- * @see org.eclipse.ui.editors.text.TextFileDocumentProvider.DocumentProviderOperation#execute(org.eclipse.core.runtime.IProgressMonitor)
- */
+ @Override
public void execute(IProgressMonitor monitor) throws CoreException {
createFileFromDocument(monitor, file, document);
}
- /*
- * @see org.eclipse.ui.editors.text.TextFileDocumentProvider.DocumentProviderOperation#getSchedulingRule()
- */
+ @Override
public ISchedulingRule getSchedulingRule() {
return computeSchedulingRule(file);
}
@@ -826,15 +806,11 @@ public class TextFileDocumentProvider implements IDocumentProvider, IDocumentPro
} else if (element instanceof IURIEditorInput) {
final URI uri= ((IURIEditorInput)element).getURI();
return new DocumentProviderOperation() {
- /*
- * @see org.eclipse.ui.editors.text.TextFileDocumentProvider.DocumentProviderOperation#execute(org.eclipse.core.runtime.IProgressMonitor)
- */
+ @Override
public void execute(IProgressMonitor monitor) throws CoreException {
createFileStoreFromDocument(monitor, uri, document);
}
- /*
- * @see org.eclipse.ui.editors.text.TextFileDocumentProvider.DocumentProviderOperation#getSchedulingRule()
- */
+ @Override
public ISchedulingRule getSchedulingRule() {
return null;
}
@@ -920,9 +896,7 @@ public class TextFileDocumentProvider implements IDocumentProvider, IDocumentPro
}
}
- /*
- * @see org.eclipse.ui.texteditor.IDocumentProvider#getModificationStamp(java.lang.Object)
- */
+ @Override
public long getModificationStamp(Object element) {
FileInfo info= (FileInfo) fFileInfoMap.get(element);
if (info != null)
@@ -930,9 +904,7 @@ public class TextFileDocumentProvider implements IDocumentProvider, IDocumentPro
return getParentProvider().getModificationStamp(element);
}
- /*
- * @see org.eclipse.ui.texteditor.IDocumentProvider#getSynchronizationStamp(java.lang.Object)
- */
+ @Override
public long getSynchronizationStamp(Object element) {
FileInfo info= (FileInfo) fFileInfoMap.get(element);
if (info != null)
@@ -940,9 +912,7 @@ public class TextFileDocumentProvider implements IDocumentProvider, IDocumentPro
return getParentProvider().getSynchronizationStamp(element);
}
- /*
- * @see org.eclipse.ui.texteditor.IDocumentProvider#isDeleted(java.lang.Object)
- */
+ @Override
public boolean isDeleted(Object element) {
FileInfo info= (FileInfo) fFileInfoMap.get(element);
if (info != null) {
@@ -952,9 +922,7 @@ public class TextFileDocumentProvider implements IDocumentProvider, IDocumentPro
return getParentProvider().isDeleted(element);
}
- /*
- * @see org.eclipse.ui.texteditor.IDocumentProvider#mustSaveDocument(java.lang.Object)
- */
+ @Override
public boolean mustSaveDocument(Object element) {
FileInfo info= (FileInfo) fFileInfoMap.get(element);
if (info != null)
@@ -962,9 +930,7 @@ public class TextFileDocumentProvider implements IDocumentProvider, IDocumentPro
return getParentProvider().mustSaveDocument(element);
}
- /*
- * @see org.eclipse.ui.texteditor.IDocumentProvider#canSaveDocument(java.lang.Object)
- */
+ @Override
public boolean canSaveDocument(Object element) {
FileInfo info= (FileInfo) fFileInfoMap.get(element);
if (info != null)
@@ -972,9 +938,7 @@ public class TextFileDocumentProvider implements IDocumentProvider, IDocumentPro
return getParentProvider().canSaveDocument(element);
}
- /*
- * @see org.eclipse.ui.texteditor.IDocumentProvider#getAnnotationModel(java.lang.Object)
- */
+ @Override
public IAnnotationModel getAnnotationModel(Object element) {
FileInfo info= (FileInfo) fFileInfoMap.get(element);
if (info != null)
@@ -982,27 +946,21 @@ public class TextFileDocumentProvider implements IDocumentProvider, IDocumentPro
return getParentProvider().getAnnotationModel(element);
}
- /*
- * @see org.eclipse.ui.texteditor.IDocumentProvider#aboutToChange(java.lang.Object)
- */
+ @Override
public void aboutToChange(Object element) {
FileInfo info= (FileInfo) fFileInfoMap.get(element);
if (info == null)
getParentProvider().aboutToChange(element);
}
- /*
- * @see org.eclipse.ui.texteditor.IDocumentProvider#changed(java.lang.Object)
- */
+ @Override
public void changed(Object element) {
FileInfo info= (FileInfo) fFileInfoMap.get(element);
if (info == null)
getParentProvider().changed(element);
}
- /*
- * @see org.eclipse.ui.texteditor.IDocumentProvider#addElementStateListener(org.eclipse.ui.texteditor.IElementStateListener)
- */
+ @Override
public void addElementStateListener(IElementStateListener listener) {
Assert.isNotNull(listener);
if (!fElementStateListeners.contains(listener)) {
@@ -1015,9 +973,7 @@ public class TextFileDocumentProvider implements IDocumentProvider, IDocumentPro
getParentProvider().addElementStateListener(listener);
}
- /*
- * @see org.eclipse.ui.texteditor.IDocumentProvider#removeElementStateListener(org.eclipse.ui.texteditor.IElementStateListener)
- */
+ @Override
public void removeElementStateListener(IElementStateListener listener) {
Assert.isNotNull(listener);
fElementStateListeners.remove(listener);
@@ -1028,9 +984,7 @@ public class TextFileDocumentProvider implements IDocumentProvider, IDocumentPro
getParentProvider().removeElementStateListener(listener);
}
- /*
- * @see org.eclipse.ui.texteditor.IDocumentProviderExtension#isReadOnly(java.lang.Object)
- */
+ @Override
public boolean isReadOnly(Object element) {
FileInfo info= (FileInfo) fFileInfoMap.get(element);
if (info != null)
@@ -1038,9 +992,7 @@ public class TextFileDocumentProvider implements IDocumentProvider, IDocumentPro
return ((IDocumentProviderExtension) getParentProvider()).isReadOnly(element);
}
- /*
- * @see org.eclipse.ui.texteditor.IDocumentProviderExtension#isModifiable(java.lang.Object)
- */
+ @Override
public boolean isModifiable(Object element) {
FileInfo info= (FileInfo) fFileInfoMap.get(element);
if (info != null)
@@ -1048,22 +1000,16 @@ public class TextFileDocumentProvider implements IDocumentProvider, IDocumentPro
return ((IDocumentProviderExtension) getParentProvider()).isModifiable(element);
}
- /*
- * @see org.eclipse.ui.texteditor.IDocumentProviderExtension#validateState(java.lang.Object, java.lang.Object)
- */
+ @Override
public void validateState(Object element, final Object computationContext) throws CoreException {
final FileInfo info= (FileInfo) fFileInfoMap.get(element);
if (info != null) {
DocumentProviderOperation operation= new DocumentProviderOperation() {
- /*
- * @see org.eclipse.ui.editors.text.TextFileDocumentProvider.DocumentProviderOperation#execute(org.eclipse.core.runtime.IProgressMonitor)
- */
+ @Override
protected void execute(IProgressMonitor monitor) throws CoreException {
info.fTextFileBuffer.validateState(monitor, computationContext);
}
- /*
- * @see org.eclipse.ui.editors.text.TextFileDocumentProvider.DocumentProviderOperation#getSchedulingRule()
- */
+ @Override
public ISchedulingRule getSchedulingRule() {
if (info.fElement instanceof IFileEditorInput) {
IFileEditorInput input= (IFileEditorInput) info.fElement;
@@ -1077,9 +1023,7 @@ public class TextFileDocumentProvider implements IDocumentProvider, IDocumentPro
((IDocumentProviderExtension) getParentProvider()).validateState(element, computationContext);
}
- /*
- * @see org.eclipse.ui.texteditor.IDocumentProviderExtension#isStateValidated(java.lang.Object)
- */
+ @Override
public boolean isStateValidated(Object element) {
FileInfo info= (FileInfo) fFileInfoMap.get(element);
if (info != null)
@@ -1087,9 +1031,7 @@ public class TextFileDocumentProvider implements IDocumentProvider, IDocumentPro
return ((IDocumentProviderExtension) getParentProvider()).isStateValidated(element);
}
- /*
- * @see org.eclipse.ui.texteditor.IDocumentProviderExtension#updateStateCache(java.lang.Object)
- */
+ @Override
public void updateStateCache(Object element) throws CoreException {
FileInfo info= (FileInfo) fFileInfoMap.get(element);
if (info != null) {
@@ -1104,18 +1046,14 @@ public class TextFileDocumentProvider implements IDocumentProvider, IDocumentPro
}
}
- /*
- * @see org.eclipse.ui.texteditor.IDocumentProviderExtension#setCanSaveDocument(java.lang.Object)
- */
+ @Override
public void setCanSaveDocument(Object element) {
FileInfo info= (FileInfo) fFileInfoMap.get(element);
if (info == null)
((IDocumentProviderExtension) getParentProvider()).setCanSaveDocument(element);
}
- /*
- * @see org.eclipse.ui.texteditor.IDocumentProviderExtension#getStatus(java.lang.Object)
- */
+ @Override
public IStatus getStatus(Object element) {
FileInfo info= (FileInfo) fFileInfoMap.get(element);
if (info == null)
@@ -1146,22 +1084,16 @@ public class TextFileDocumentProvider implements IDocumentProvider, IDocumentPro
return status;
}
- /*
- * @see org.eclipse.ui.texteditor.IDocumentProviderExtension#synchronize(java.lang.Object)
- */
+ @Override
public void synchronize(Object element) throws CoreException {
final FileInfo info= (FileInfo) fFileInfoMap.get(element);
if (info != null) {
DocumentProviderOperation operation= new DocumentProviderOperation() {
- /*
- * @see org.eclipse.ui.editors.text.TextFileDocumentProvider.DocumentProviderOperation#execute(org.eclipse.core.runtime.IProgressMonitor)
- */
+ @Override
protected void execute(IProgressMonitor monitor) throws CoreException {
info.fTextFileBuffer.revert(monitor);
}
- /*
- * @see org.eclipse.ui.editors.text.TextFileDocumentProvider.DocumentProviderOperation#getSchedulingRule()
- */
+ @Override
public ISchedulingRule getSchedulingRule() {
if (info.fElement instanceof IFileEditorInput) {
IFileEditorInput input= (IFileEditorInput) info.fElement;
@@ -1176,24 +1108,18 @@ public class TextFileDocumentProvider implements IDocumentProvider, IDocumentPro
}
}
- /*
- * @see org.eclipse.ui.texteditor.IDocumentProviderExtension2#setProgressMonitor(org.eclipse.core.runtime.IProgressMonitor)
- */
+ @Override
public void setProgressMonitor(IProgressMonitor progressMonitor) {
fProgressMonitor= progressMonitor;
((IDocumentProviderExtension2) getParentProvider()).setProgressMonitor(progressMonitor);
}
- /*
- * @see org.eclipse.ui.texteditor.IDocumentProviderExtension2#getProgressMonitor()
- */
+ @Override
public IProgressMonitor getProgressMonitor() {
return fProgressMonitor;
}
- /*
- * @see org.eclipse.ui.texteditor.IDocumentProviderExtension3#isSynchronized(java.lang.Object)
- */
+ @Override
public boolean isSynchronized(Object element) {
FileInfo info= (FileInfo) fFileInfoMap.get(element);
if (info != null)
@@ -1201,10 +1127,7 @@ public class TextFileDocumentProvider implements IDocumentProvider, IDocumentPro
return ((IDocumentProviderExtension3) getParentProvider()).isSynchronized(element);
}
- /*
- * @see org.eclipse.ui.texteditor.IDocumentProviderExtension5#isNotSynchronizedException(Object, CoreException)
- * @since 3.2
- */
+ @Override
public boolean isNotSynchronizedException(Object element, CoreException ex) {
IStatus status= ex.getStatus();
if (status == null || status instanceof MultiStatus)
@@ -1216,16 +1139,12 @@ public class TextFileDocumentProvider implements IDocumentProvider, IDocumentPro
return status.getCode() == IResourceStatus.OUT_OF_SYNC_LOCAL;
}
- /*
- * @see org.eclipse.ui.editors.text.IStorageDocumentProvider#getDefaultEncoding()
- */
+ @Override
public String getDefaultEncoding() {
return FileBuffers.getTextFileBufferManager().getDefaultEncoding();
}
- /*
- * @see org.eclipse.ui.editors.text.IStorageDocumentProvider#getEncoding(java.lang.Object)
- */
+ @Override
public String getEncoding(Object element) {
FileInfo info= (FileInfo) fFileInfoMap.get(element);
if (info != null)
@@ -1233,9 +1152,7 @@ public class TextFileDocumentProvider implements IDocumentProvider, IDocumentPro
return ((IStorageDocumentProvider) getParentProvider()).getEncoding(element);
}
- /*
- * @see org.eclipse.ui.editors.text.IStorageDocumentProvider#setEncoding(java.lang.Object, java.lang.String)
- */
+ @Override
public void setEncoding(Object element, String encoding) {
FileInfo info= (FileInfo) fFileInfoMap.get(element);
if (info != null)
@@ -1244,10 +1161,7 @@ public class TextFileDocumentProvider implements IDocumentProvider, IDocumentPro
((IStorageDocumentProvider) getParentProvider()).setEncoding(element, encoding);
}
- /*
- * @see org.eclipse.ui.texteditor.IDocumentProviderExtension4#getContentType(java.lang.Object)
- * @since 3.1
- */
+ @Override
public IContentType getContentType(Object element) throws CoreException {
FileInfo info= (FileInfo) fFileInfoMap.get(element);
if (info != null)
@@ -1290,6 +1204,7 @@ public class TextFileDocumentProvider implements IDocumentProvider, IDocumentPro
* @return the system file for the given file info
* @deprecated As of 3.2, replaced by {@link #getFileStore(org.eclipse.ui.editors.text.TextFileDocumentProvider.FileInfo)}
*/
+ @Deprecated
protected File getSystemFile(FileInfo info) {
IPath path= info.fTextFileBuffer.getLocation();
return FileBuffers.getSystemFileAtLocation(path);
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/TextSourceViewerConfiguration.java b/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/TextSourceViewerConfiguration.java
index 0360565af..db85c0dc6 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/TextSourceViewerConfiguration.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/TextSourceViewerConfiguration.java
@@ -90,11 +90,10 @@ public class TextSourceViewerConfiguration extends SourceViewerConfiguration {
fPreferenceStore= preferenceStore;
}
- /*
- * @see org.eclipse.jface.text.source.SourceViewerConfiguration#getAnnotationHover(org.eclipse.jface.text.source.ISourceViewer)
- */
+ @Override
public IAnnotationHover getAnnotationHover(ISourceViewer sourceViewer) {
return new DefaultAnnotationHover() {
+ @Override
protected boolean isIncluded(Annotation annotation) {
return isShowInVerticalRuler(annotation);
}
@@ -117,12 +116,10 @@ public class TextSourceViewerConfiguration extends SourceViewerConfiguration {
return true;
}
- /*
- * @see org.eclipse.jface.text.source.SourceViewerConfiguration#getOverviewRulerAnnotationHover(org.eclipse.jface.text.source.ISourceViewer)
- * @since 3.2
- */
+ @Override
public IAnnotationHover getOverviewRulerAnnotationHover(ISourceViewer sourceViewer) {
return new DefaultAnnotationHover(true) {
+ @Override
protected boolean isIncluded(Annotation annotation) {
return isShowInOverviewRuler(annotation);
}
@@ -144,18 +141,12 @@ public class TextSourceViewerConfiguration extends SourceViewerConfiguration {
return true;
}
- /*
- * @see SourceViewerConfiguration#getConfiguredTextHoverStateMasks(ISourceViewer, String)
- * @since 3.2
- */
+ @Override
public int[] getConfiguredTextHoverStateMasks(ISourceViewer sourceViewer, String contentType) {
return new int[] { ITextViewerExtension2.DEFAULT_HOVER_STATE_MASK };
}
- /*
- * @see SourceViewerConfiguration#getTextHover(ISourceViewer, String)
- * @since 3.2
- */
+ @Override
public ITextHover getTextHover(ISourceViewer sourceViewer, String contentType) {
return new TextHover(sourceViewer);
}
@@ -193,19 +184,14 @@ public class TextSourceViewerConfiguration extends SourceViewerConfiguration {
return EditorsUI.getAnnotationPreferenceLookup().getAnnotationPreference(annotation);
}
- /*
- * @see org.eclipse.jface.text.source.SourceViewerConfiguration#getTabWidth(org.eclipse.jface.text.source.ISourceViewer)
- */
+ @Override
public int getTabWidth(ISourceViewer sourceViewer) {
if (fPreferenceStore == null)
return super.getTabWidth(sourceViewer);
return fPreferenceStore.getInt(AbstractDecoratedTextEditorPreferenceConstants.EDITOR_TAB_WIDTH);
}
- /*
- * @see org.eclipse.jface.text.source.SourceViewerConfiguration#getIndentPrefixes(org.eclipse.jface.text.source.ISourceViewer, java.lang.String)
- * @since 3.3
- */
+ @Override
public String[] getIndentPrefixes(ISourceViewer sourceViewer, String contentType) {
String[] indentPrefixes= getIndentPrefixesForTab(getTabWidth(sourceViewer));
if (indentPrefixes == null)
@@ -222,10 +208,7 @@ public class TextSourceViewerConfiguration extends SourceViewerConfiguration {
return indentPrefixes;
}
- /*
- * @see org.eclipse.jface.text.source.SourceViewerConfiguration#getHyperlinkDetectors(org.eclipse.jface.text.source.ISourceViewer)
- * @since 3.1
- */
+ @Override
public IHyperlinkDetector[] getHyperlinkDetectors(ISourceViewer sourceViewer) {
if (sourceViewer == null || fPreferenceStore == null)
return super.getHyperlinkDetectors(sourceViewer);
@@ -279,10 +262,7 @@ public class TextSourceViewerConfiguration extends SourceViewerConfiguration {
return targets;
}
- /*
- * @see org.eclipse.jface.text.source.SourceViewerConfiguration#getHyperlinkStateMask(org.eclipse.jface.text.source.ISourceViewer)
- * @since 3.1
- */
+ @Override
public int getHyperlinkStateMask(ISourceViewer sourceViewer) {
if (fPreferenceStore == null)
return super.getHyperlinkStateMask(sourceViewer);
@@ -296,10 +276,7 @@ public class TextSourceViewerConfiguration extends SourceViewerConfiguration {
return modifierMask;
}
- /*
- * @see org.eclipse.jface.text.source.SourceViewerConfiguration#getHyperlinkPresenter(org.eclipse.jface.text.source.ISourceViewer)
- * @since 3.1
- */
+ @Override
public IHyperlinkPresenter getHyperlinkPresenter(ISourceViewer sourceViewer) {
if (fPreferenceStore == null)
return new MultipleHyperlinkPresenter(new RGB(0, 0, 255));
@@ -356,10 +333,7 @@ public class TextSourceViewerConfiguration extends SourceViewerConfiguration {
return stateMask;
}
- /*
- * @see org.eclipse.jface.text.source.SourceViewerConfiguration#getUndoManager(org.eclipse.jface.text.source.ISourceViewer)
- * @since 3.1
- */
+ @Override
public IUndoManager getUndoManager(ISourceViewer sourceViewer) {
if (fPreferenceStore == null || !fPreferenceStore.contains(AbstractDecoratedTextEditorPreferenceConstants.EDITOR_UNDO_HISTORY_SIZE))
return super.getUndoManager(sourceViewer);
@@ -378,6 +352,7 @@ public class TextSourceViewerConfiguration extends SourceViewerConfiguration {
* @see org.eclipse.jface.text.source.SourceViewerConfiguration#getReconciler(org.eclipse.jface.text.source.ISourceViewer)
* @since 3.3
*/
+ @Override
public IReconciler getReconciler(ISourceViewer sourceViewer) {
if (fPreferenceStore == null || !fPreferenceStore.getBoolean(SpellingService.PREFERENCE_SPELLING_ENABLED))
return null;
@@ -392,10 +367,7 @@ public class TextSourceViewerConfiguration extends SourceViewerConfiguration {
return reconciler;
}
- /*
- * @see org.eclipse.jface.text.source.SourceViewerConfiguration#getQuickAssistAssistant(org.eclipse.jface.text.source.ISourceViewer)
- * @since 3.3
- */
+ @Override
public IQuickAssistAssistant getQuickAssistAssistant(ISourceViewer sourceViewer) {
if (fPreferenceStore == null || !fPreferenceStore.getBoolean(SpellingService.PREFERENCE_SPELLING_ENABLED))
return null;
@@ -416,6 +388,7 @@ public class TextSourceViewerConfiguration extends SourceViewerConfiguration {
*/
private IInformationControlCreator getQuickAssistAssistantInformationControlCreator() {
return new IInformationControlCreator() {
+ @Override
public IInformationControl createInformationControl(Shell parent) {
return new DefaultInformationControl(parent, EditorsPlugin.getAdditionalInfoAffordanceString());
}
@@ -458,15 +431,15 @@ public class TextSourceViewerConfiguration extends SourceViewerConfiguration {
super(sourceViewer);
}
+ @Override
protected boolean isIncluded(Annotation annotation) {
return isShownInText(annotation);
}
- /*
- * @see org.eclipse.jface.text.ITextHoverExtension#getHoverControlCreator()
- */
+ @Override
public IInformationControlCreator getHoverControlCreator() {
return new IInformationControlCreator() {
+ @Override
public IInformationControl createInformationControl(Shell parent) {
return new DefaultInformationControl(parent, EditorsUI.getTooltipAffordanceString());
}
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/templates/ContributionTemplateStore.java b/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/templates/ContributionTemplateStore.java
index c8e265c69..83f1c579c 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/templates/ContributionTemplateStore.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/editors/text/templates/ContributionTemplateStore.java
@@ -102,6 +102,7 @@ public class ContributionTemplateStore extends TemplateStore {
*
* @throws IOException {@inheritDoc}
*/
+ @Override
protected void loadContributedTemplates() throws IOException {
IConfigurationElement[] extensions= getTemplateExtensions();
Collection contributed= readContributedTemplates(extensions);
@@ -255,10 +256,7 @@ public class ContributionTemplateStore extends TemplateStore {
return id != null && id.trim().length() != 0; // TODO test validity?
}
- /*
- * @see org.eclipse.jface.text.templates.persistence.TemplateStore#handleException(java.io.IOException)
- * @since 3.2
- */
+ @Override
protected void handleException(IOException x) {
EditorsPlugin.log(x);
}
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/quickdiff/CompositeRevertAction.java b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/quickdiff/CompositeRevertAction.java
index 081a961f7..b1a60d2d4 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/quickdiff/CompositeRevertAction.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/quickdiff/CompositeRevertAction.java
@@ -56,9 +56,7 @@ public final class CompositeRevertAction extends Action implements IUpdate, ISel
update();
}
- /*
- * @see org.eclipse.ui.texteditor.IUpdate#update()
- */
+ @Override
public void update() {
for (int i= 0; i < fActions.length; i++) {
if (fActions[i] instanceof IUpdate)
@@ -72,17 +70,12 @@ public final class CompositeRevertAction extends Action implements IUpdate, ISel
setToolTipText(action.getToolTipText());
}
- /*
- * @see org.eclipse.jface.viewers.ISelectionChangedListener#selectionChanged(org.eclipse.jface.viewers.SelectionChangedEvent)
- * @since 3.3
- */
+ @Override
public void selectionChanged(SelectionChangedEvent event) {
update();
}
- /*
- * @see org.eclipse.jface.action.IAction#run()
- */
+ @Override
public void run() {
IAction action= getEnabledAction();
if (action != null)
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/quickdiff/LastSaveReferenceProvider.java b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/quickdiff/LastSaveReferenceProvider.java
index bc84f2a44..aa3391391 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/quickdiff/LastSaveReferenceProvider.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/quickdiff/LastSaveReferenceProvider.java
@@ -110,24 +110,21 @@ public class LastSaveReferenceProvider implements IQuickDiffReferenceProvider, I
* @param monitor {@inheritDoc}
* @return {@link Status#OK_STATUS}
*/
+ @Override
protected IStatus run(IProgressMonitor monitor) {
readDocument(monitor, false);
return Status.OK_STATUS;
}
}
- /*
- * @see org.eclipse.ui.texteditor.quickdiff.IQuickDiffReferenceProvider#getReference(org.eclipse.core.runtime.IProgressMonitor)
- */
+ @Override
public IDocument getReference(IProgressMonitor monitor) {
if (!fDocumentRead)
readDocument(monitor, true); // force reading it
return fReference;
}
- /*
- * @see org.eclipse.ui.texteditor.quickdiff.IQuickDiffReferenceProvider#dispose()
- */
+ @Override
public void dispose() {
IProgressMonitor monitor= fProgressMonitor;
if (monitor != null) {
@@ -148,16 +145,12 @@ public class LastSaveReferenceProvider implements IQuickDiffReferenceProvider, I
}
}
- /*
- * @see org.eclipse.ui.texteditor.quickdiff.IQuickDiffReferenceProvider#getId()
- */
+ @Override
public String getId() {
return fId;
}
- /*
- * @see org.eclipse.ui.texteditor.quickdiff.IQuickDiffProviderImplementation#setActiveEditor(org.eclipse.ui.texteditor.ITextEditor)
- */
+ @Override
public void setActiveEditor(ITextEditor targetEditor) {
IDocumentProvider provider= null;
IEditorInput input= null;
@@ -179,16 +172,12 @@ public class LastSaveReferenceProvider implements IQuickDiffReferenceProvider, I
}
}
- /*
- * @see org.eclipse.ui.texteditor.quickdiff.IQuickDiffProviderImplementation#isEnabled()
- */
+ @Override
public boolean isEnabled() {
return fEditorInput != null && fDocumentProvider != null;
}
- /*
- * @see org.eclipse.ui.texteditor.quickdiff.IQuickDiffProviderImplementation#setId(java.lang.String)
- */
+ @Override
public void setId(String id) {
fId= id;
}
@@ -324,6 +313,7 @@ public class LastSaveReferenceProvider implements IQuickDiffReferenceProvider, I
// see https://bugs.eclipse.org/bugs/show_bug.cgi?id=56871
Runnable runnable= new Runnable() {
+ @Override
public void run() {
synchronized (fLock) {
if (fDocumentProvider == provider)
@@ -443,9 +433,7 @@ public class LastSaveReferenceProvider implements IQuickDiffReferenceProvider, I
/* IElementStateListener implementation */
- /*
- * @see org.eclipse.ui.texteditor.IElementStateListener#elementDirtyStateChanged(java.lang.Object, boolean)
- */
+ @Override
public void elementDirtyStateChanged(Object element, boolean isDirty) {
if (!isDirty && element == fEditorInput) {
// document has been saved or reverted - recreate reference
@@ -453,15 +441,11 @@ public class LastSaveReferenceProvider implements IQuickDiffReferenceProvider, I
}
}
- /*
- * @see org.eclipse.ui.texteditor.IElementStateListener#elementContentAboutToBeReplaced(java.lang.Object)
- */
+ @Override
public void elementContentAboutToBeReplaced(Object element) {
}
- /*
- * @see org.eclipse.ui.texteditor.IElementStateListener#elementContentReplaced(java.lang.Object)
- */
+ @Override
public void elementContentReplaced(Object element) {
if (element == fEditorInput) {
// document has been reverted or replaced
@@ -469,15 +453,11 @@ public class LastSaveReferenceProvider implements IQuickDiffReferenceProvider, I
}
}
- /*
- * @see org.eclipse.ui.texteditor.IElementStateListener#elementDeleted(java.lang.Object)
- */
+ @Override
public void elementDeleted(Object element) {
}
- /*
- * @see org.eclipse.ui.texteditor.IElementStateListener#elementMoved(java.lang.Object, java.lang.Object)
- */
+ @Override
public void elementMoved(Object originalElement, Object movedElement) {
}
}
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/quickdiff/QuickDiffRestoreAction.java b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/quickdiff/QuickDiffRestoreAction.java
index 42b7f1369..438b1e8e8 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/quickdiff/QuickDiffRestoreAction.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/quickdiff/QuickDiffRestoreAction.java
@@ -70,9 +70,7 @@ public abstract class QuickDiffRestoreAction extends TextEditorAction implements
*/
protected abstract void runCompoundChange();
- /*
- * @see org.eclipse.jface.action.IAction#run()
- */
+ @Override
public void run() {
ITextEditor editor= getTextEditor();
if (editor == null || !validateEditorInputState())
@@ -86,9 +84,7 @@ public abstract class QuickDiffRestoreAction extends TextEditorAction implements
}
- /*
- * @see org.eclipse.ui.texteditor.IUpdate#update()
- */
+ @Override
public void update() {
/*
* Update only works if we're updated from the ruler action
@@ -99,10 +95,7 @@ public abstract class QuickDiffRestoreAction extends TextEditorAction implements
setEnabled(computeEnablement());
}
- /*
- * @see org.eclipse.jface.viewers.ISelectionChangedListener#selectionChanged(org.eclipse.jface.viewers.SelectionChangedEvent)
- * @since 3.3
- */
+ @Override
public void selectionChanged(SelectionChangedEvent event) {
update();
}
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/quickdiff/RestoreAction.java b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/quickdiff/RestoreAction.java
index 312275015..295f0c446 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/quickdiff/RestoreAction.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/quickdiff/RestoreAction.java
@@ -41,9 +41,7 @@ public class RestoreAction extends QuickDiffRestoreAction {
super(QuickDiffMessages.getResourceBundle(), PREFIX, editor, isRulerAction);
}
- /*
- * @see org.eclipse.ui.internal.texteditor.quickdiff.QuickDiffRestoreAction#computeEnablement()
- */
+ @Override
public boolean computeEnablement() {
if (!super.computeEnablement())
return false;
@@ -73,9 +71,7 @@ public class RestoreAction extends QuickDiffRestoreAction {
return true;
}
- /*
- * @see org.eclipse.ui.internal.editors.quickdiff.QuickDiffRestoreAction#runCompoundChange()
- */
+ @Override
public void runCompoundChange() {
if (!isEnabled())
return;
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/quickdiff/RevertBlockAction.java b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/quickdiff/RevertBlockAction.java
index 890a38a4d..ad6b4707f 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/quickdiff/RevertBlockAction.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/quickdiff/RevertBlockAction.java
@@ -40,9 +40,7 @@ public class RevertBlockAction extends QuickDiffRestoreAction {
super(QuickDiffMessages.getResourceBundle(), PREFIX, editor, isRulerAction);
}
- /*
- * @see org.eclipse.ui.internal.texteditor.quickdiff.QuickDiffRestoreAction#computeEnablement()
- */
+ @Override
public boolean computeEnablement() {
if (!super.computeEnablement())
return false;
@@ -72,9 +70,7 @@ public class RevertBlockAction extends QuickDiffRestoreAction {
return false;
}
- /*
- * @see org.eclipse.ui.internal.editors.quickdiff.QuickDiffRestoreAction#runCompoundChange()
- */
+ @Override
public void runCompoundChange() {
if (!isEnabled())
return;
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/quickdiff/RevertLineAction.java b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/quickdiff/RevertLineAction.java
index dbb7daa7d..aa1cc5e99 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/quickdiff/RevertLineAction.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/quickdiff/RevertLineAction.java
@@ -38,9 +38,7 @@ public class RevertLineAction extends QuickDiffRestoreAction {
super(QuickDiffMessages.getResourceBundle(), "RevertLineAction.", editor, isRulerAction); //$NON-NLS-1$
}
- /*
- * @see org.eclipse.ui.internal.texteditor.quickdiff.QuickDiffRestoreAction#computeEnablement()
- */
+ @Override
public boolean computeEnablement() {
if (!super.computeEnablement())
return false;
@@ -62,9 +60,7 @@ public class RevertLineAction extends QuickDiffRestoreAction {
return true;
}
- /*
- * @see org.eclipse.ui.internal.editors.quickdiff.QuickDiffRestoreAction#runCompoundChange()
- */
+ @Override
public void runCompoundChange() {
if (!isEnabled())
return;
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/quickdiff/RevertSelectionAction.java b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/quickdiff/RevertSelectionAction.java
index 55d1d7035..0f2599b20 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/quickdiff/RevertSelectionAction.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/quickdiff/RevertSelectionAction.java
@@ -40,9 +40,7 @@ public class RevertSelectionAction extends QuickDiffRestoreAction {
super(QuickDiffMessages.getResourceBundle(), "RevertSelectionAction.", editor, isRulerAction); //$NON-NLS-1$
}
- /*
- * @see org.eclipse.ui.internal.texteditor.quickdiff.QuickDiffRestoreAction#computeEnablement()
- */
+ @Override
public boolean computeEnablement() {
if (!super.computeEnablement())
return false;
@@ -72,9 +70,7 @@ public class RevertSelectionAction extends QuickDiffRestoreAction {
return false;
}
- /*
- * @see org.eclipse.ui.internal.editors.quickdiff.QuickDiffRestoreAction#runCompoundChange()
- */
+ @Override
public void runCompoundChange() {
// recheck if run without being enabled
if (!isEnabled())
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/AbstractConfigurationBlockPreferencePage.java b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/AbstractConfigurationBlockPreferencePage.java
index d4d51edff..89ee31ce4 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/AbstractConfigurationBlockPreferencePage.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/AbstractConfigurationBlockPreferencePage.java
@@ -49,23 +49,17 @@ abstract class AbstractConfigurationBlockPreferencePage extends PreferencePage i
protected abstract void setDescription();
protected abstract void setPreferenceStore();
- /*
- * @see IWorkbenchPreferencePage#init()
- */
+ @Override
public void init(IWorkbench workbench) {
}
- /*
- * @see PreferencePage#createControl(Composite)
- */
+ @Override
public void createControl(Composite parent) {
super.createControl(parent);
PlatformUI.getWorkbench().getHelpSystem().setHelp(getControl(), getHelpId());
}
- /*
- * @see PreferencePage#createContents(Composite)
- */
+ @Override
protected Control createContents(Composite parent) {
fOverlayStore.load();
@@ -83,9 +77,7 @@ abstract class AbstractConfigurationBlockPreferencePage extends PreferencePage i
fConfigurationBlock.initialize();
}
- /*
- * @see PreferencePage#performOk()
- */
+ @Override
public boolean performOk() {
if (!fConfigurationBlock.canPerformOk())
@@ -98,9 +90,7 @@ abstract class AbstractConfigurationBlockPreferencePage extends PreferencePage i
return true;
}
- /*
- * @see PreferencePage#performDefaults()
- */
+ @Override
public void performDefaults() {
fOverlayStore.loadDefaults();
@@ -109,9 +99,7 @@ abstract class AbstractConfigurationBlockPreferencePage extends PreferencePage i
super.performDefaults();
}
- /*
- * @see DialogPage#dispose()
- */
+ @Override
public void dispose() {
fConfigurationBlock.dispose();
@@ -124,10 +112,7 @@ abstract class AbstractConfigurationBlockPreferencePage extends PreferencePage i
super.dispose();
}
- /*
- * @see org.eclipse.jface.preference.PreferencePage#applyData(java.lang.Object)
- * @since 3.4
- */
+ @Override
public void applyData(Object data) {
fConfigurationBlock.applyData(data);
}
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/AccessibilityPreferencePage.java b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/AccessibilityPreferencePage.java
index 5fafdcd8b..63c1bccbd 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/AccessibilityPreferencePage.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/AccessibilityPreferencePage.java
@@ -76,6 +76,7 @@ public class AccessibilityPreferencePage extends PreferencePage implements IWork
super(preference);
fText= control;
}
+ @Override
public void initialize() {
String value= fOverlayStore.getString(fPreference.getKey());
fText.setText(value);
@@ -89,6 +90,7 @@ public class AccessibilityPreferencePage extends PreferencePage implements IWork
super(preference);
fControl= control;
}
+ @Override
public void initialize() {
boolean value= fOverlayStore.getBoolean(fPreference.getKey());
fControl.setSelection(value);
@@ -104,6 +106,7 @@ public class AccessibilityPreferencePage extends PreferencePage implements IWork
fControl= control;
fDomain= domain;
}
+ @Override
public void initialize() {
int value= fOverlayStore.getInt(fPreference.getKey());
EnumValue enumValue= fDomain.getValueByInteger(value);
@@ -151,6 +154,7 @@ public class AccessibilityPreferencePage extends PreferencePage implements IWork
fMin= min;
}
+ @Override
public IStatus validate(Object value) {
StatusInfo status= new StatusInfo();
if (value instanceof String && ((String)value).length() == 0) {
@@ -191,9 +195,11 @@ public class AccessibilityPreferencePage extends PreferencePage implements IWork
public int getIntValue() {
return fValue;
}
+ @Override
public final int hashCode() {
return getIntValue();
}
+ @Override
public boolean equals(Object obj) {
if (obj instanceof EnumValue) {
return ((EnumValue) obj).getIntValue() == fValue;
@@ -247,6 +253,7 @@ public class AccessibilityPreferencePage extends PreferencePage implements IWork
addValue(from++);
}
+ @Override
public IStatus validate(Object value) {
StatusInfo status= new StatusInfo();
if (value instanceof String && ((String)value).length() == 0) {
@@ -274,6 +281,7 @@ public class AccessibilityPreferencePage extends PreferencePage implements IWork
}
static class BooleanDomain extends Domain {
+ @Override
public IStatus validate(Object value) {
StatusInfo status= new StatusInfo();
if (value instanceof String && ((String)value).length() == 0) {
@@ -352,6 +360,7 @@ public class AccessibilityPreferencePage extends PreferencePage implements IWork
}
+ @Override
protected Label createDescriptionLabel(Composite parent) {
return null; // no description for new look
}
@@ -370,15 +379,11 @@ public class AccessibilityPreferencePage extends PreferencePage implements IWork
return new OverlayPreferenceStore(getPreferenceStore(), keys);
}
- /*
- * @see IWorkbenchPreferencePage#init()
- */
+ @Override
public void init(IWorkbench workbench) {
}
- /*
- * @see PreferencePage#createControl(Composite)
- */
+ @Override
public void createControl(Composite parent) {
super.createControl(parent);
PlatformUI.getWorkbench().getHelpSystem().setHelp(getControl(), ITextEditorHelpContextIds.ACCESSIBILITY_PREFERENCE_PAGE);
@@ -415,9 +420,7 @@ public class AccessibilityPreferencePage extends PreferencePage implements IWork
return appearanceComposite;
}
- /*
- * @see PreferencePage#createContents(Composite)
- */
+ @Override
protected Control createContents(Composite parent) {
fOverlayStore.load();
@@ -447,17 +450,13 @@ public class AccessibilityPreferencePage extends PreferencePage implements IWork
}
- /*
- * @see PreferencePage#performOk()
- */
+ @Override
public boolean performOk() {
fOverlayStore.propagate();
return true;
}
- /*
- * @see PreferencePage#performDefaults()
- */
+ @Override
protected void performDefaults() {
fOverlayStore.loadDefaults();
@@ -472,9 +471,7 @@ public class AccessibilityPreferencePage extends PreferencePage implements IWork
super.performDefaults();
}
- /*
- * @see DialogPage#dispose()
- */
+ @Override
public void dispose() {
if (fOverlayStore != null) {
@@ -497,6 +494,7 @@ public class AccessibilityPreferencePage extends PreferencePage implements IWork
gd.horizontalSpan= 2;
checkBox.setLayoutData(gd);
checkBox.addSelectionListener(new SelectionAdapter() {
+ @Override
public void widgetSelected(SelectionEvent e) {
boolean value= checkBox.getSelection();
IStatus status= domain.validate(Boolean.valueOf(value));
@@ -520,6 +518,7 @@ public class AccessibilityPreferencePage extends PreferencePage implements IWork
}
SelectionListener listener= new SelectionListener() {
+ @Override
public void widgetSelected(SelectionEvent e) {
boolean state= master.getSelection();
for (int i= 0; i < slaves.length; i++) {
@@ -527,6 +526,7 @@ public class AccessibilityPreferencePage extends PreferencePage implements IWork
}
}
+ @Override
public void widgetDefaultSelected(SelectionEvent e) {}
};
master.addSelectionListener(listener);
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/AnnotationsConfigurationBlock.java b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/AnnotationsConfigurationBlock.java
index a11004f01..a0d8f4018 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/AnnotationsConfigurationBlock.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/AnnotationsConfigurationBlock.java
@@ -94,13 +94,16 @@ class AnnotationsConfigurationBlock implements IPreferenceConfigurationBlock {
private static final class ItemContentProvider implements IStructuredContentProvider {
+ @Override
public Object[] getElements(Object inputElement) {
return (ListItem[]) inputElement;
}
+ @Override
public void dispose() {
}
+ @Override
public void inputChanged(Viewer viewer, Object oldInput, Object newInput) {
}
}
@@ -108,10 +111,12 @@ class AnnotationsConfigurationBlock implements IPreferenceConfigurationBlock {
private final class ItemLabelProvider extends LabelProvider {
+ @Override
public String getText(Object element) {
return ((ListItem)element).label;
}
+ @Override
public Image getImage(Object element) {
ListItem item= (ListItem)element;
return item.image;
@@ -120,6 +125,7 @@ class AnnotationsConfigurationBlock implements IPreferenceConfigurationBlock {
private static class ArrayLabelProvider extends LabelProvider {
+ @Override
public String getText(Object element) {
return ((String[]) element)[0].toString();
}
@@ -182,9 +188,7 @@ class AnnotationsConfigurationBlock implements IPreferenceConfigurationBlock {
return keys;
}
- /*
- * @see org.eclipse.ui.internal.editors.text.IPreferenceConfigurationBlock#createControl(org.eclipse.swt.widgets.Composite)
- */
+ @Override
public Control createControl(Composite parent) {
PixelConverter pixelConverter= new PixelConverter(parent);
@@ -294,16 +298,19 @@ class AnnotationsConfigurationBlock implements IPreferenceConfigurationBlock {
fAnnotationTypeViewer.addSelectionChangedListener(new ISelectionChangedListener() {
+ @Override
public void selectionChanged(SelectionChangedEvent event) {
handleAnnotationListSelection();
}
});
fShowInTextCheckBox.addSelectionListener(new SelectionListener() {
+ @Override
public void widgetDefaultSelected(SelectionEvent e) {
// do nothing
}
+ @Override
public void widgetSelected(SelectionEvent e) {
ListItem item= getSelectedItem();
final boolean value= fShowInTextCheckBox.getSelection();
@@ -328,10 +335,12 @@ class AnnotationsConfigurationBlock implements IPreferenceConfigurationBlock {
});
fShowInOverviewRulerCheckBox.addSelectionListener(new SelectionListener() {
+ @Override
public void widgetDefaultSelected(SelectionEvent e) {
// do nothing
}
+ @Override
public void widgetSelected(SelectionEvent e) {
ListItem item= getSelectedItem();
fStore.setValue(item.overviewRulerKey, fShowInOverviewRulerCheckBox.getSelection());
@@ -340,10 +349,12 @@ class AnnotationsConfigurationBlock implements IPreferenceConfigurationBlock {
});
fShowInVerticalRulerCheckBox.addSelectionListener(new SelectionListener() {
+ @Override
public void widgetDefaultSelected(SelectionEvent e) {
// do nothing
}
+ @Override
public void widgetSelected(SelectionEvent e) {
ListItem item= getSelectedItem();
fStore.setValue(item.verticalRulerKey, fShowInVerticalRulerCheckBox.getSelection());
@@ -352,10 +363,12 @@ class AnnotationsConfigurationBlock implements IPreferenceConfigurationBlock {
});
fIsNextPreviousTargetCheckBox.addSelectionListener(new SelectionListener() {
+ @Override
public void widgetDefaultSelected(SelectionEvent e) {
// do nothing
}
+ @Override
public void widgetSelected(SelectionEvent e) {
ListItem item= getSelectedItem();
fStore.setValue(item.isNextPreviousNavigationKey, fIsNextPreviousTargetCheckBox.getSelection());
@@ -364,10 +377,12 @@ class AnnotationsConfigurationBlock implements IPreferenceConfigurationBlock {
});
foregroundColorButton.addSelectionListener(new SelectionListener() {
+ @Override
public void widgetDefaultSelected(SelectionEvent e) {
// do nothing
}
+ @Override
public void widgetSelected(SelectionEvent e) {
ListItem item= getSelectedItem();
PreferenceConverter.setValue(fStore, item.colorKey, fAnnotationForegroundColorEditor.getColorValue());
@@ -377,9 +392,7 @@ class AnnotationsConfigurationBlock implements IPreferenceConfigurationBlock {
fDecorationViewer.addSelectionChangedListener(new ISelectionChangedListener() {
- /*
- * @see org.eclipse.jface.viewers.ISelectionChangedListener#selectionChanged(org.eclipse.jface.viewers.SelectionChangedEvent)
- */
+ @Override
public void selectionChanged(SelectionChangedEvent event) {
String[] decoration= (String[]) ((IStructuredSelection) fDecorationViewer.getSelection()).getFirstElement();
ListItem item= getSelectedItem();
@@ -428,6 +441,7 @@ class AnnotationsConfigurationBlock implements IPreferenceConfigurationBlock {
* @see org.eclipse.ui.internal.editors.text.IPreferenceConfigurationBlock#applyData(java.lang.Object)
* @since 3.4
*/
+ @Override
public void applyData(Object data) {
if (!(data instanceof String))
return;
@@ -437,6 +451,7 @@ class AnnotationsConfigurationBlock implements IPreferenceConfigurationBlock {
if (data.equals(element.label)) {
final Control control= fAnnotationTypeViewer.getControl();
control.getDisplay().asyncExec(new Runnable() {
+ @Override
public void run() {
control.setFocus();
fAnnotationTypeViewer.setSelection(new StructuredSelection(element), true);
@@ -447,22 +462,16 @@ class AnnotationsConfigurationBlock implements IPreferenceConfigurationBlock {
}
}
- /*
- * @see org.eclipse.ui.internal.editors.text.IPreferenceConfigurationBlock#canPerformOk()
- */
+ @Override
public boolean canPerformOk() {
return true;
}
- /*
- * @see PreferencePage#performOk()
- */
+ @Override
public void performOk() {
}
- /*
- * @see PreferencePage#performDefaults()
- */
+ @Override
public void performDefaults() {
fStore.loadDefaults();
fAnnotationTypeViewer.refresh();
@@ -502,10 +511,12 @@ class AnnotationsConfigurationBlock implements IPreferenceConfigurationBlock {
+ @Override
public void initialize() {
fAnnotationTypeViewer.setInput(fListModel);
fAnnotationTypeViewer.getControl().getDisplay().asyncExec(new Runnable() {
+ @Override
public void run() {
if (fAnnotationTypeViewer != null && !fAnnotationTypeViewer.getControl().isDisposed()) {
fAnnotationTypeViewer.setSelection(new StructuredSelection(fListModel[0]));
@@ -534,9 +545,7 @@ class AnnotationsConfigurationBlock implements IPreferenceConfigurationBlock {
}
Comparator comparator= new Comparator() {
- /*
- * @see java.util.Comparator#compare(java.lang.Object, java.lang.Object)
- */
+ @Override
public int compare(Object o1, Object o2) {
if (!(o2 instanceof ListItem))
return -1;
@@ -655,9 +664,7 @@ class AnnotationsConfigurationBlock implements IPreferenceConfigurationBlock {
return false;
}
- /*
- * @see IPreferenceConfigurationBlock#dispose()
- */
+ @Override
public void dispose() {
ImageRegistry registry= EditorsPlugin.getDefault().getImageRegistry();
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/AnnotationsPreferencePage.java b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/AnnotationsPreferencePage.java
index c4771d20d..fa0c26184 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/AnnotationsPreferencePage.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/AnnotationsPreferencePage.java
@@ -27,38 +27,28 @@ import org.eclipse.ui.editors.text.ITextEditorHelpContextIds;
*/
public class AnnotationsPreferencePage extends AbstractConfigurationBlockPreferencePage {
- /*
- * @see org.eclipse.ui.internal.editors.text.AbstractConfigureationBlockPreferencePage#getHelpId()
- */
+ @Override
protected String getHelpId() {
return ITextEditorHelpContextIds.TEXT_EDITOR_PREFERENCE_PAGE;
}
- /*
- * @see org.eclipse.ui.internal.editors.text.AbstractConfigurationBlockPreferencePage#setDescription()
- */
+ @Override
protected void setDescription() {
String description= TextEditorMessages.AnnotationsConfigurationBlock_description;
setDescription(description);
}
- /*
- * @see org.eclipse.jface.preference.PreferencePage#createDescriptionLabel(org.eclipse.swt.widgets.Composite)
- */
+ @Override
protected Label createDescriptionLabel(Composite parent) {
return null;
}
- /*
- * @see org.eclipse.ui.internal.editors.text.AbstractConfigurationBlockPreferencePage#setPreferenceStore()
- */
+ @Override
protected void setPreferenceStore() {
setPreferenceStore(EditorsPlugin.getDefault().getPreferenceStore());
}
- /*
- * @see org.eclipse.ui.internal.editors.text.AbstractConfigureationBlockPreferencePage#createConfigurationBlock(org.eclipse.ui.internal.editors.text.OverlayPreferenceStore)
- */
+ @Override
protected IPreferenceConfigurationBlock createConfigurationBlock(OverlayPreferenceStore overlayPreferenceStore) {
return new AnnotationsConfigurationBlock(overlayPreferenceStore);
}
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/ConvertLineDelimitersAction.java b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/ConvertLineDelimitersAction.java
index 5dd535b02..f635e2aea 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/ConvertLineDelimitersAction.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/ConvertLineDelimitersAction.java
@@ -67,16 +67,19 @@ public class ConvertLineDelimitersAction extends FileBufferOperationAction {
return label;
}
+ @Override
protected boolean isAcceptableLocation(IPath location) {
ITextFileBufferManager manager= FileBuffers.getTextFileBufferManager();
return location != null && manager.isTextFileLocation(location, fStrictCheckIfTextLocation);
}
+ @Override
public void selectionChanged(IAction action, ISelection selection) {
super.selectionChanged(action, selection);
fStrictCheckIfTextLocation= !(selection instanceof ITextSelection);
}
+ @Override
protected IFile[] collectFiles(final IResource[] resources) {
fStrictCheckIfTextLocation= fStrictCheckIfTextLocation || resources.length != 1 || resources[0].getType() != IResource.FILE;
if (containsOnlyFiles(resources)) {
@@ -85,12 +88,14 @@ public class ConvertLineDelimitersAction extends FileBufferOperationAction {
}
final IFilter filter= new IFilter() {
+ @Override
public boolean accept(IResource resource) {
return resource != null && isAcceptableLocation(resource.getFullPath());
}
};
SelectResourcesDialog dialog= new SelectResourcesDialog(getShell(), getDialogTitle(), TextEditorMessages.ConvertLineDelimitersAction_dialog_description, filter) {
+ @Override
protected Composite createSelectionButtonGroup(Composite parent) {
Composite buttonGroup= super.createSelectionButtonGroup(parent);
@@ -100,6 +105,7 @@ public class ConvertLineDelimitersAction extends FileBufferOperationAction {
button.setFont(JFaceResources.getDialogFont());
button.setSelection(fStrictCheckIfTextLocation);
button.addSelectionListener(new SelectionAdapter() {
+ @Override
public void widgetSelected(SelectionEvent event) {
fStrictCheckIfTextLocation= button.getSelection();
refresh();
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/EditorsPlugin.java b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/EditorsPlugin.java
index 80574942c..9c1367dd1 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/EditorsPlugin.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/EditorsPlugin.java
@@ -197,15 +197,13 @@ public class EditorsPlugin extends AbstractUIPlugin {
return fMarkerAnnotationPreferences;
}
- /*
- * @see org.eclipse.ui.plugin.AbstractUIPlugin#start(org.osgi.framework.BundleContext)
- * @since 3.3
- */
+ @Override
public void start(BundleContext context) throws Exception {
super.start(context);
if (PlatformUI.isWorkbenchRunning()) {
fThemeListener= new IPropertyChangeListener() {
+ @Override
public void propertyChange(PropertyChangeEvent event) {
if (IThemeManager.CHANGE_CURRENT_THEME.equals(event.getProperty()))
EditorsPluginPreferenceInitializer.setThemeBasedPreferences(getPreferenceStore(), true);
@@ -215,10 +213,7 @@ public class EditorsPlugin extends AbstractUIPlugin {
}
}
- /*
- * @see org.eclipse.ui.plugin.AbstractUIPlugin#stop(org.osgi.framework.BundleContext)
- * @since 3.0
- */
+ @Override
public void stop(BundleContext context) throws Exception {
if (fSharedTextColors != null) {
fSharedTextColors.dispose();
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/EditorsPluginPreferenceInitializer.java b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/EditorsPluginPreferenceInitializer.java
index 1a4050a09..13d068bf2 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/EditorsPluginPreferenceInitializer.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/EditorsPluginPreferenceInitializer.java
@@ -34,10 +34,7 @@ import org.eclipse.ui.editors.text.TextEditorPreferenceConstants;
*/
public class EditorsPluginPreferenceInitializer extends AbstractPreferenceInitializer {
- /*
- * @see org.eclipse.core.runtime.preferences.AbstractPreferenceInitializer#initializeDefaultPreferences()
- * @since 3.1
- */
+ @Override
public void initializeDefaultPreferences() {
IPreferenceStore store= EditorsPlugin.getDefault().getPreferenceStore();
TextEditorPreferenceConstants.initializeDefaultValues(store);
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/FileEditorInputAdapterFactory.java b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/FileEditorInputAdapterFactory.java
index 2afe6ddc7..e7f5a3d18 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/FileEditorInputAdapterFactory.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/FileEditorInputAdapterFactory.java
@@ -29,6 +29,7 @@ public class FileEditorInputAdapterFactory implements IAdapterFactory {
/*
* @see org.eclipse.ui.editors.text.ILocationProvider#getLocation(java.lang.Object)
*/
+ @Override
public IPath getPath(Object element) {
if (element instanceof IFileEditorInput) {
IFileEditorInput input= (IFileEditorInput) element;
@@ -44,9 +45,7 @@ public class FileEditorInputAdapterFactory implements IAdapterFactory {
/** The provided location provider */
private ILocationProvider fLocationProvider= new LocationProvider();
- /*
- * @see org.eclipse.core.runtime.IAdapterFactory#getAdapter(java.lang.Object, java.lang.Class)
- */
+ @Override
public Object getAdapter(Object adaptableObject, Class adapterType) {
if (ILocationProvider.class.equals(adapterType)) {
if (adaptableObject instanceof IFile)
@@ -55,9 +54,7 @@ public class FileEditorInputAdapterFactory implements IAdapterFactory {
return null;
}
- /*
- * @see org.eclipse.core.runtime.IAdapterFactory#getAdapterList()
- */
+ @Override
public Class[] getAdapterList() {
return ADAPTER_LIST;
}
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/HyperlinkDetectorsConfigurationBlock.java b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/HyperlinkDetectorsConfigurationBlock.java
index 060b8e343..2724db091 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/HyperlinkDetectorsConfigurationBlock.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/HyperlinkDetectorsConfigurationBlock.java
@@ -89,13 +89,16 @@ class HyperlinkDetectorsConfigurationBlock implements IPreferenceConfigurationBl
private static final class ItemContentProvider implements IStructuredContentProvider {
+ @Override
public Object[] getElements(Object inputElement) {
return (ListItem[]) inputElement;
}
+ @Override
public void dispose() {
}
+ @Override
public void inputChanged(Viewer viewer, Object oldInput, Object newInput) {
}
}
@@ -103,16 +106,12 @@ class HyperlinkDetectorsConfigurationBlock implements IPreferenceConfigurationBl
private final class ItemLabelProvider implements ITableLabelProvider {
- /*
- * @see org.eclipse.jface.viewers.ITableLabelProvider#getColumnImage(java.lang.Object, int)
- */
+ @Override
public Image getColumnImage(Object element, int columnIndex) {
return null;
}
- /*
- * @see org.eclipse.jface.viewers.ITableLabelProvider#getColumnText(java.lang.Object, int)
- */
+ @Override
public String getColumnText(Object element, int columnIndex) {
switch (columnIndex) {
case 0:
@@ -130,28 +129,20 @@ class HyperlinkDetectorsConfigurationBlock implements IPreferenceConfigurationBl
return null; // cannot happen
}
- /*
- * @see org.eclipse.jface.viewers.IBaseLabelProvider#addListener(org.eclipse.jface.viewers.ILabelProviderListener)
- */
+ @Override
public void addListener(ILabelProviderListener listener) {
}
- /*
- * @see org.eclipse.jface.viewers.IBaseLabelProvider#dispose()
- */
+ @Override
public void dispose() {
}
- /*
- * @see org.eclipse.jface.viewers.IBaseLabelProvider#isLabelProperty(java.lang.Object, java.lang.String)
- */
+ @Override
public boolean isLabelProperty(Object element, String property) {
return false;
}
- /*
- * @see org.eclipse.jface.viewers.IBaseLabelProvider#removeListener(org.eclipse.jface.viewers.ILabelProviderListener)
- */
+ @Override
public void removeListener(ILabelProviderListener listener) {
}
}
@@ -200,9 +191,7 @@ class HyperlinkDetectorsConfigurationBlock implements IPreferenceConfigurationBl
return keys;
}
- /*
- * @see org.eclipse.ui.internal.editors.text.IPreferenceConfigurationBlock#createControl(org.eclipse.swt.widgets.Composite)
- */
+ @Override
public Control createControl(Composite parent) {
PixelConverter pixelConverter= new PixelConverter(parent);
@@ -219,6 +208,7 @@ class HyperlinkDetectorsConfigurationBlock implements IPreferenceConfigurationBl
String label= TextEditorMessages.HyperlinksEnabled_label;
fHyperlinksEnabledCheckBox= addCheckBox(composite, label, AbstractDecoratedTextEditorPreferenceConstants.EDITOR_HYPERLINKS_ENABLED, 0);
fHyperlinksEnabledCheckBox.addSelectionListener(new SelectionListener() {
+ @Override
public void widgetSelected(SelectionEvent e) {
boolean state= fHyperlinksEnabledCheckBox.getSelection();
fHyperlinkDefaultKeyModifierText.setEnabled(state);
@@ -226,6 +216,7 @@ class HyperlinkDetectorsConfigurationBlock implements IPreferenceConfigurationBl
fHyperlinkDetectorsViewer.getTable().setEnabled(state);
handleHyperlinkKeyModifierModified();
}
+ @Override
public void widgetDefaultSelected(SelectionEvent e) {
}
});
@@ -236,10 +227,12 @@ class HyperlinkDetectorsConfigurationBlock implements IPreferenceConfigurationBl
fHyperlinkDefaultKeyModifierText.addKeyListener(new KeyListener() {
private boolean isModifierCandidate;
+ @Override
public void keyPressed(KeyEvent e) {
isModifierCandidate= e.keyCode > 0 && e.character == 0 && e.stateMask == 0;
}
+ @Override
public void keyReleased(KeyEvent e) {
if (isModifierCandidate && e.stateMask > 0 && e.stateMask == e.stateMask && e.character == 0) {// && e.time -time < 1000) {
String modifierString= fHyperlinkDefaultKeyModifierText.getText();
@@ -273,6 +266,7 @@ class HyperlinkDetectorsConfigurationBlock implements IPreferenceConfigurationBl
});
fHyperlinkDefaultKeyModifierText.addModifyListener(new ModifyListener() {
+ @Override
public void modifyText(ModifyEvent e) {
handleHyperlinkDefaultKeyModifierModified();
}
@@ -297,9 +291,11 @@ class HyperlinkDetectorsConfigurationBlock implements IPreferenceConfigurationBl
hyperlinkDetectorTable.setFont(parent.getFont());
hyperlinkDetectorTable.addSelectionListener(new SelectionListener() {
+ @Override
public void widgetSelected(SelectionEvent e) {
handleListSelection();
}
+ @Override
public void widgetDefaultSelected(SelectionEvent e) {
}
});
@@ -322,9 +318,7 @@ class HyperlinkDetectorsConfigurationBlock implements IPreferenceConfigurationBl
fHyperlinkDetectorsViewer.setUseHashlookup(true);
fHyperlinkDetectorsViewer.addCheckStateListener(new ICheckStateListener() {
- /*
- * @see org.eclipse.jface.viewers.ICheckStateListener#checkStateChanged(org.eclipse.jface.viewers.CheckStateChangedEvent)
- */
+ @Override
public void checkStateChanged(CheckStateChangedEvent event) {
String id= ((ListItem)event.getElement()).id;
if (id == null)
@@ -347,10 +341,12 @@ class HyperlinkDetectorsConfigurationBlock implements IPreferenceConfigurationBl
fHyperlinkKeyModifierText.addKeyListener(new KeyListener() {
private boolean isModifierCandidate;
+ @Override
public void keyPressed(KeyEvent e) {
isModifierCandidate= e.keyCode > 0 && e.character == 0 && e.stateMask == 0;
}
+ @Override
public void keyReleased(KeyEvent e) {
if (isModifierCandidate && e.stateMask > 0 && e.stateMask == e.stateMask && e.character == 0) {// && e.time -time < 1000) {
String modifierString= fHyperlinkKeyModifierText.getText();
@@ -384,6 +380,7 @@ class HyperlinkDetectorsConfigurationBlock implements IPreferenceConfigurationBl
});
fHyperlinkKeyModifierText.addModifyListener(new ModifyListener() {
+ @Override
public void modifyText(ModifyEvent e) {
handleHyperlinkKeyModifierModified();
}
@@ -392,10 +389,7 @@ class HyperlinkDetectorsConfigurationBlock implements IPreferenceConfigurationBl
return composite;
}
- /*
- * @see org.eclipse.ui.internal.editors.text.IPreferenceConfigurationBlock#applyData(java.lang.Object)
- * @since 3.4
- */
+ @Override
public void applyData(Object data) {
}
@@ -417,6 +411,7 @@ class HyperlinkDetectorsConfigurationBlock implements IPreferenceConfigurationBl
gd.horizontalSpan= 2;
checkBox.setLayoutData(gd);
checkBox.addSelectionListener(new SelectionAdapter() {
+ @Override
public void widgetSelected(SelectionEvent e) {
boolean value= checkBox.getSelection();
fStore.setValue(key, value);
@@ -440,6 +435,7 @@ class HyperlinkDetectorsConfigurationBlock implements IPreferenceConfigurationBl
textControl.setTextLimit(textLimit);
textControl.addModifyListener(new ModifyListener() {
+ @Override
public void modifyText(ModifyEvent e) {
String value= textControl.getText();
if (key != null)
@@ -458,23 +454,17 @@ class HyperlinkDetectorsConfigurationBlock implements IPreferenceConfigurationBl
return result.toArray();
}
- /*
- * @see org.eclipse.ui.internal.editors.text.IPreferenceConfigurationBlock#canPerformOk()
- */
+ @Override
public boolean canPerformOk() {
return true;
}
- /*
- * @see PreferencePage#performOk()
- */
+ @Override
public void performOk() {
fStore.setValue(AbstractDecoratedTextEditorPreferenceConstants.EDITOR_HYPERLINK_KEY_MODIFIER_MASK, computeStateMask(fHyperlinkKeyModifierText.getText()));
}
- /*
- * @see PreferencePage#performDefaults()
- */
+ @Override
public void performDefaults() {
fStore.loadDefaults();
initialize();
@@ -494,6 +484,7 @@ class HyperlinkDetectorsConfigurationBlock implements IPreferenceConfigurationBl
}
+ @Override
public void initialize() {
String modifierString= fStore.getString(AbstractDecoratedTextEditorPreferenceConstants.EDITOR_HYPERLINK_KEY_MODIFIER);
if (computeStateMask(modifierString) == -1) {
@@ -534,9 +525,7 @@ class HyperlinkDetectorsConfigurationBlock implements IPreferenceConfigurationBl
}
Comparator comparator= new Comparator() {
- /*
- * @see java.util.Comparator#compare(java.lang.Object, java.lang.Object)
- */
+ @Override
public int compare(Object o1, Object o2) {
if (!(o2 instanceof ListItem))
return -1;
@@ -733,9 +722,7 @@ class HyperlinkDetectorsConfigurationBlock implements IPreferenceConfigurationBl
}
}
- /*
- * @see org.eclipse.ui.internal.editors.text.IPreferenceConfigurationBlock#dispose()
- */
+ @Override
public void dispose() {
}
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/HyperlinkDetectorsPreferencePage.java b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/HyperlinkDetectorsPreferencePage.java
index 508b0cf25..3b5c6fa87 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/HyperlinkDetectorsPreferencePage.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/HyperlinkDetectorsPreferencePage.java
@@ -27,38 +27,28 @@ import org.eclipse.ui.editors.text.ITextEditorHelpContextIds;
*/
public class HyperlinkDetectorsPreferencePage extends AbstractConfigurationBlockPreferencePage {
- /*
- * @see org.eclipse.ui.internal.editors.text.AbstractConfigureationBlockPreferencePage#getHelpId()
- */
+ @Override
protected String getHelpId() {
return ITextEditorHelpContextIds.TEXT_EDITOR_PREFERENCE_PAGE;
}
- /*
- * @see org.eclipse.ui.internal.editors.text.AbstractConfigurationBlockPreferencePage#setDescription()
- */
+ @Override
protected void setDescription() {
String description= TextEditorMessages.HyperlinkDetectorsConfigurationBlock_description;
setDescription(description);
}
- /*
- * @see org.eclipse.jface.preference.PreferencePage#createDescriptionLabel(org.eclipse.swt.widgets.Composite)
- */
+ @Override
protected Label createDescriptionLabel(Composite parent) {
return super.createDescriptionLabel(parent);
}
- /*
- * @see org.eclipse.ui.internal.editors.text.AbstractConfigurationBlockPreferencePage#setPreferenceStore()
- */
+ @Override
protected void setPreferenceStore() {
setPreferenceStore(EditorsPlugin.getDefault().getPreferenceStore());
}
- /*
- * @see org.eclipse.ui.internal.editors.text.AbstractConfigureationBlockPreferencePage#createConfigurationBlock(org.eclipse.ui.internal.editors.text.OverlayPreferenceStore)
- */
+ @Override
protected IPreferenceConfigurationBlock createConfigurationBlock(OverlayPreferenceStore overlayPreferenceStore) {
return new HyperlinkDetectorsConfigurationBlock(this, overlayPreferenceStore);
}
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/IURIEditorInputAdapterFactory.java b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/IURIEditorInputAdapterFactory.java
index 59ac9442f..10023802f 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/IURIEditorInputAdapterFactory.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/IURIEditorInputAdapterFactory.java
@@ -34,6 +34,7 @@ public class IURIEditorInputAdapterFactory implements IAdapterFactory {
/*
* @see org.eclipse.ui.editors.text.ILocationProvider#getLocation(java.lang.Object)
*/
+ @Override
public IPath getPath(Object element) {
URI uri= getURI(element);
if (uri != null)
@@ -41,9 +42,7 @@ public class IURIEditorInputAdapterFactory implements IAdapterFactory {
return null;
}
- /*
- * @see org.eclipse.ui.editors.text.ILocationProviderExtension#getURI(java.lang.Object)
- */
+ @Override
public URI getURI(Object element) {
if (element instanceof IURIEditorInput) {
IURIEditorInput input= (IURIEditorInput)element;
@@ -60,9 +59,7 @@ public class IURIEditorInputAdapterFactory implements IAdapterFactory {
/** The provided location provider */
private ILocationProvider fLocationProvider= new LocationProvider();
- /*
- * @see org.eclipse.core.runtime.IAdapterFactory#getAdapter(java.lang.Object, java.lang.Class)
- */
+ @Override
public Object getAdapter(Object adaptableObject, Class adapterType) {
if (ILocationProvider.class.equals(adapterType)) {
if (adaptableObject instanceof IURIEditorInput)
@@ -71,9 +68,7 @@ public class IURIEditorInputAdapterFactory implements IAdapterFactory {
return null;
}
- /*
- * @see org.eclipse.core.runtime.IAdapterFactory#getAdapterList()
- */
+ @Override
public Class[] getAdapterList() {
return ADAPTER_LIST;
}
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/LanguageEditorPreferencePage.java b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/LanguageEditorPreferencePage.java
index 8b60b2803..d6d28628f 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/LanguageEditorPreferencePage.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/LanguageEditorPreferencePage.java
@@ -44,32 +44,24 @@ public class LanguageEditorPreferencePage extends PreferencePage implements IWor
setPreferenceStore(EditorsPlugin.getDefault().getPreferenceStore());
}
- /*
- * @see IWorkbenchPreferencePage#init()
- */
+ @Override
public void init(IWorkbench workbench) {
}
- /*
- * @see PreferencePage#createControl(Composite)
- */
+ @Override
public void createControl(Composite parent) {
super.createControl(parent);
PlatformUI.getWorkbench().getHelpSystem().setHelp(getControl(), ITextEditorHelpContextIds.TEXT_EDITOR_PREFERENCE_PAGE);
}
- /*
- * @see PreferencePage#createContents(Composite)
- */
+ @Override
protected Control createContents(Composite parent) {
Composite composite= new Composite(parent, SWT.NONE);
return composite;
}
- /*
- * @see PreferencePage#performOk()
- */
+ @Override
public boolean performOk() {
return true;
}
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/LinkedModeConfigurationBlock.java b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/LinkedModeConfigurationBlock.java
index 648fe3fad..38a5dae78 100755
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/LinkedModeConfigurationBlock.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/LinkedModeConfigurationBlock.java
@@ -93,25 +93,30 @@ class LinkedModeConfigurationBlock implements IPreferenceConfigurationBlock {
private static final class ItemContentProvider implements IStructuredContentProvider {
+ @Override
public Object[] getElements(Object inputElement) {
return (ListItem[]) inputElement;
}
+ @Override
public void dispose() {
}
+ @Override
public void inputChanged(Viewer viewer, Object oldInput, Object newInput) {
}
}
private final class ItemLabelProvider extends LabelProvider {
+ @Override
public String getText(Object element) {
return ((ListItem) element).label;
}
}
private static class ArrayLabelProvider extends LabelProvider {
+ @Override
public String getText(Object element) {
return ((String[]) element)[0].toString();
}
@@ -214,6 +219,7 @@ class LinkedModeConfigurationBlock implements IPreferenceConfigurationBlock {
* @param parent the parent composite
* @return the control for the preference page
*/
+ @Override
public Control createControl(Composite parent) {
OverlayPreferenceStore store= getPreferenceStore();
store.load();
@@ -289,16 +295,19 @@ class LinkedModeConfigurationBlock implements IPreferenceConfigurationBlock {
createDependency(fShowInTextCheckBox, new Control[] {label, foregroundColorButton});
fAnnotationTypeViewer.addSelectionChangedListener(new ISelectionChangedListener() {
+ @Override
public void selectionChanged(SelectionChangedEvent event) {
handleAnnotationListSelection();
}
});
fShowInTextCheckBox.addSelectionListener(new SelectionListener() {
+ @Override
public void widgetDefaultSelected(SelectionEvent e) {
// do nothing
}
+ @Override
public void widgetSelected(SelectionEvent e) {
ListItem item= getSelectedItem();
final boolean value= fShowInTextCheckBox.getSelection();
@@ -320,10 +329,12 @@ class LinkedModeConfigurationBlock implements IPreferenceConfigurationBlock {
});
foregroundColorButton.addSelectionListener(new SelectionListener() {
+ @Override
public void widgetDefaultSelected(SelectionEvent e) {
// do nothing
}
+ @Override
public void widgetSelected(SelectionEvent e) {
ListItem item= getSelectedItem();
PreferenceConverter.setValue(getPreferenceStore(), item.colorKey, fAnnotationForegroundColorEditor.getColorValue());
@@ -332,9 +343,7 @@ class LinkedModeConfigurationBlock implements IPreferenceConfigurationBlock {
fDecorationViewer.addSelectionChangedListener(new ISelectionChangedListener() {
- /*
- * @see org.eclipse.jface.viewers.ISelectionChangedListener#selectionChanged(org.eclipse.jface.viewers.SelectionChangedEvent)
- */
+ @Override
public void selectionChanged(SelectionChangedEvent event) {
String[] decoration= (String[]) ((IStructuredSelection) fDecorationViewer.getSelection()).getFirstElement();
ListItem item= getSelectedItem();
@@ -357,10 +366,7 @@ class LinkedModeConfigurationBlock implements IPreferenceConfigurationBlock {
}
- /*
- * @see org.eclipse.ui.internal.editors.text.IPreferenceConfigurationBlock#applyData(java.lang.Object)
- * @since 3.4
- */
+ @Override
public void applyData(Object data) {
}
@@ -432,14 +438,13 @@ class LinkedModeConfigurationBlock implements IPreferenceConfigurationBlock {
updateDecorationViewer(item, true);
}
- /*
- * @see org.eclipse.jdt.internal.ui.preferences.IPreferenceConfigurationBlock#initialize()
- */
+ @Override
public void initialize() {
initializeFields();
fAnnotationTypeViewer.setInput(fListModel);
fAnnotationTypeViewer.getControl().getDisplay().asyncExec(new Runnable() {
+ @Override
public void run() {
if (fAnnotationTypeViewer != null && !fAnnotationTypeViewer.getControl().isDisposed()) {
fAnnotationTypeViewer.setSelection(new StructuredSelection(fListModel[0]));
@@ -488,6 +493,7 @@ class LinkedModeConfigurationBlock implements IPreferenceConfigurationBlock {
}
+ @Override
public void performOk() {
getPreferenceStore().propagate();
@@ -499,6 +505,7 @@ class LinkedModeConfigurationBlock implements IPreferenceConfigurationBlock {
}
+ @Override
public void performDefaults() {
getPreferenceStore().loadDefaults();
@@ -511,6 +518,7 @@ class LinkedModeConfigurationBlock implements IPreferenceConfigurationBlock {
initializeFields();
}
+ @Override
public void dispose() {
OverlayPreferenceStore store= getPreferenceStore();
if (store != null) {
@@ -526,6 +534,7 @@ class LinkedModeConfigurationBlock implements IPreferenceConfigurationBlock {
Assert.isTrue(slaves.length > 0);
indent(slaves[0]);
SelectionListener listener= new SelectionListener() {
+ @Override
public void widgetSelected(SelectionEvent e) {
boolean state= master.getSelection();
for (int i= 0; i < slaves.length; i++) {
@@ -533,6 +542,7 @@ class LinkedModeConfigurationBlock implements IPreferenceConfigurationBlock {
}
}
+ @Override
public void widgetDefaultSelected(SelectionEvent e) {}
};
master.addSelectionListener(listener);
@@ -553,9 +563,7 @@ class LinkedModeConfigurationBlock implements IPreferenceConfigurationBlock {
}
}
- /*
- * @see org.eclipse.ui.internal.editors.text.IPreferenceConfigurationBlock#canPerformOk()
- */
+ @Override
public boolean canPerformOk() {
return true;
}
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/LinkedModePreferencePage.java b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/LinkedModePreferencePage.java
index 8c5015a97..f1ebb227d 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/LinkedModePreferencePage.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/LinkedModePreferencePage.java
@@ -25,36 +25,29 @@ import org.eclipse.ui.editors.text.ITextEditorHelpContextIds;
*/
public final class LinkedModePreferencePage extends AbstractConfigurationBlockPreferencePage {
- /*
- * @see org.eclipse.ui.internal.editors.text.AbstractConfigureationBlockPreferencePage#getHelpId()
- */
+ @Override
protected String getHelpId() {
return ITextEditorHelpContextIds.TEXT_EDITOR_PREFERENCE_PAGE;
}
- /*
- * @see org.eclipse.ui.internal.editors.text.AbstractConfigurationBlockPreferencePage#setDescription()
- */
+ @Override
protected void setDescription() {
String description= TextEditorMessages.LinkedModeConfigurationBlock_linking_title;
setDescription(description);
}
- /*
- * @see org.org.eclipse.ui.internal.editors.text.AbstractConfigurationBlockPreferencePage#setPreferenceStore()
- */
+ @Override
protected void setPreferenceStore() {
setPreferenceStore(EditorsUI.getPreferenceStore());
}
+ @Override
protected Label createDescriptionLabel(Composite parent) {
return null; // no description for new look.
}
- /*
- * @see org.eclipse.ui.internal.editors.text.AbstractConfigureationBlockPreferencePage#createConfigurationBlock(org.eclipse.ui.internal.editors.text.OverlayPreferenceStore)
- */
+ @Override
protected IPreferenceConfigurationBlock createConfigurationBlock(OverlayPreferenceStore overlayPreferenceStore) {
return new LinkedModeConfigurationBlock(overlayPreferenceStore);
}
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/NextPreviousPulldownActionDelegate.java b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/NextPreviousPulldownActionDelegate.java
index 3ad885761..64e5392e0 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/NextPreviousPulldownActionDelegate.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/NextPreviousPulldownActionDelegate.java
@@ -76,17 +76,12 @@ public abstract class NextPreviousPulldownActionDelegate extends Action implemen
setChecked(fStore.getBoolean(fKey));
}
- /*
- * @see IAction#run()
- */
+ @Override
public void run() {
fStore.setValue(fKey, isChecked());
}
- /*
- * @see java.lang.Comparable#compareTo(java.lang.Object)
- * @since 3.2
- */
+ @Override
public int compareTo(Object o) {
if (!(o instanceof NavigationEnablementAction))
return -1;
@@ -106,9 +101,7 @@ public abstract class NextPreviousPulldownActionDelegate extends Action implemen
*/
public abstract String getPreferenceKey(AnnotationPreference annotationPreference);
- /*
- * @see org.eclipse.jface.action.IMenuCreator#getMenu(org.eclipse.swt.widgets.Control)
- */
+ @Override
public Menu getMenu(Control parent) {
if (fMenu != null)
fMenu.dispose();
@@ -126,9 +119,7 @@ public abstract class NextPreviousPulldownActionDelegate extends Action implemen
fStore= EditorsPlugin.getDefault().getPreferenceStore();
}
- /*
- * @see org.eclipse.jface.action.IMenuCreator#getMenu(org.eclipse.swt.widgets.Menu)
- */
+ @Override
public Menu getMenu(Menu parent) {
if (fMenu == null) {
fMenu= new Menu(parent);
@@ -138,9 +129,7 @@ public abstract class NextPreviousPulldownActionDelegate extends Action implemen
return fMenu;
}
- /*
- * @see org.eclipse.jface.action.IMenuCreator#dispose()
- */
+ @Override
public void dispose() {
if (fMenu != null) {
fMenu.dispose();
@@ -196,21 +185,15 @@ public abstract class NextPreviousPulldownActionDelegate extends Action implemen
return (IAction[]) containers.toArray(new Action[containers.size()]);
}
- /*
- * @see org.eclipse.ui.IWorkbenchWindowActionDelegate#init(org.eclipse.ui.IWorkbenchWindow)
- */
+ @Override
public void init(IWorkbenchWindow window) {
}
- /*
- * @see org.eclipse.ui.IActionDelegate#run(org.eclipse.jface.action.IAction)
- */
+ @Override
public void run(IAction action) {
}
- /*
- * @see org.eclipse.ui.IActionDelegate#selectionChanged(org.eclipse.jface.action.IAction, org.eclipse.jface.viewers.ISelection)
- */
+ @Override
public void selectionChanged(IAction action, ISelection selection) {
}
}
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/NextPulldownActionDelegate.java b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/NextPulldownActionDelegate.java
index b997d82b8..8fe3dd06e 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/NextPulldownActionDelegate.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/NextPulldownActionDelegate.java
@@ -20,9 +20,7 @@ import org.eclipse.ui.texteditor.AnnotationPreference;
*/
public class NextPulldownActionDelegate extends NextPreviousPulldownActionDelegate {
- /*
- * @see org.eclipse.ui.internal.texteditor.NextPreviousPulldownActionDelegate#getPreferenceKey(AnnotationPreference)
- */
+ @Override
public String getPreferenceKey(AnnotationPreference annotationPreference) {
return annotationPreference.getIsGoToNextNavigationTargetKey();
}
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/NonExistingFileEditorInput.java b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/NonExistingFileEditorInput.java
index 3d68ea5a7..33b367064 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/NonExistingFileEditorInput.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/NonExistingFileEditorInput.java
@@ -44,53 +44,39 @@ public class NonExistingFileEditorInput implements IEditorInput, ILocationProvid
fName= namePrefix + " " + fgNonExisting; //$NON-NLS-1$
}
- /*
- * @see org.eclipse.ui.IEditorInput#exists()
- */
+ @Override
public boolean exists() {
return false;
}
- /*
- * @see org.eclipse.ui.IEditorInput#getImageDescriptor()
- */
+ @Override
public ImageDescriptor getImageDescriptor() {
return PlatformUI.getWorkbench().getEditorRegistry().getImageDescriptor(fName);
}
- /*
- * @see org.eclipse.ui.IEditorInput#getName()
- */
+ @Override
public String getName() {
return fName;
}
- /*
- * @see org.eclipse.ui.IEditorInput#getPersistable()
- */
+ @Override
public IPersistableElement getPersistable() {
return null;
}
- /*
- * @see org.eclipse.ui.IEditorInput#getToolTipText()
- */
+ @Override
public String getToolTipText() {
return fName;
}
- /*
- * @see org.eclipse.core.runtime.IAdaptable#getAdapter(java.lang.Class)
- */
+ @Override
public Object getAdapter(Class adapter) {
if (ILocationProvider.class.equals(adapter))
return this;
return Platform.getAdapterManager().getAdapter(this, adapter);
}
- /*
- * @see org.eclipse.ui.editors.text.ILocationProvider#getPath(java.lang.Object)
- */
+ @Override
public IPath getPath(Object element) {
if (element instanceof NonExistingFileEditorInput) {
NonExistingFileEditorInput input= (NonExistingFileEditorInput)element;
@@ -99,9 +85,7 @@ public class NonExistingFileEditorInput implements IEditorInput, ILocationProvid
return null;
}
- /*
- * @see java.lang.Object#equals(java.lang.Object)
- */
+ @Override
public boolean equals(Object o) {
if (o == this)
return true;
@@ -114,9 +98,7 @@ public class NonExistingFileEditorInput implements IEditorInput, ILocationProvid
return false;
}
- /*
- * @see java.lang.Object#hashCode()
- */
+ @Override
public int hashCode() {
return fFileStore.hashCode();
}
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/OverlayPreferenceStore.java b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/OverlayPreferenceStore.java
index 99e57d289..91fe56cf4 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/OverlayPreferenceStore.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/OverlayPreferenceStore.java
@@ -60,9 +60,7 @@ class OverlayPreferenceStore implements IPreferenceStore {
*/
private class PropertyListener implements IPropertyChangeListener {
- /*
- * @see IPropertyChangeListener#propertyChange(PropertyChangeEvent)
- */
+ @Override
public void propertyChange(PropertyChangeEvent event) {
OverlayKey key= findOverlayKey(event.getProperty());
if (key != null)
@@ -281,238 +279,174 @@ class OverlayPreferenceStore implements IPreferenceStore {
}
}
- /*
- * @see IPreferenceStore#addPropertyChangeListener(org.eclipse.jface.util.IPropertyChangeListener)
- */
+ @Override
public void addPropertyChangeListener(IPropertyChangeListener listener) {
fStore.addPropertyChangeListener(listener);
}
- /*
- * @see IPreferenceStore#removePropertyChangeListener(org.eclipse.jface.util.IPropertyChangeListener)
- */
+ @Override
public void removePropertyChangeListener(IPropertyChangeListener listener) {
fStore.removePropertyChangeListener(listener);
}
- /*
- * @see IPreferenceStore#firePropertyChangeEvent(java.lang.String, java.lang.Object, java.lang.Object)
- */
+ @Override
public void firePropertyChangeEvent(String name, Object oldValue, Object newValue) {
fStore.firePropertyChangeEvent(name, oldValue, newValue);
}
- /*
- * @see IPreferenceStore#contains(java.lang.String)
- */
+ @Override
public boolean contains(String name) {
return fStore.contains(name);
}
- /*
- * @see IPreferenceStore#getBoolean(java.lang.String)
- */
+ @Override
public boolean getBoolean(String name) {
return fStore.getBoolean(name);
}
- /*
- * @see IPreferenceStore#getDefaultBoolean(java.lang.String)
- */
+ @Override
public boolean getDefaultBoolean(String name) {
return fStore.getDefaultBoolean(name);
}
- /*
- * @see IPreferenceStore#getDefaultDouble(java.lang.String)
- */
+ @Override
public double getDefaultDouble(String name) {
return fStore.getDefaultDouble(name);
}
- /*
- * @see IPreferenceStore#getDefaultFloat(String)
- */
+ @Override
public float getDefaultFloat(String name) {
return fStore.getDefaultFloat(name);
}
- /*
- * @see IPreferenceStore#getDefaultInt(String)
- */
+ @Override
public int getDefaultInt(String name) {
return fStore.getDefaultInt(name);
}
- /*
- * @see IPreferenceStore#getDefaultLong(String)
- */
+ @Override
public long getDefaultLong(String name) {
return fStore.getDefaultLong(name);
}
- /*
- * @see IPreferenceStore#getDefaultString(String)
- */
+ @Override
public String getDefaultString(String name) {
return fStore.getDefaultString(name);
}
- /*
- * @see IPreferenceStore#getDouble(String)
- */
+ @Override
public double getDouble(String name) {
return fStore.getDouble(name);
}
- /*
- * @see IPreferenceStore#getFloat(String)
- */
+ @Override
public float getFloat(String name) {
return fStore.getFloat(name);
}
- /*
- * @see IPreferenceStore#getInt(String)
- */
+ @Override
public int getInt(String name) {
return fStore.getInt(name);
}
- /*
- * @see IPreferenceStore#getLong(String)
- */
+ @Override
public long getLong(String name) {
return fStore.getLong(name);
}
- /*
- * @see IPreferenceStore#getString(String)
- */
+ @Override
public String getString(String name) {
return fStore.getString(name);
}
- /*
- * @see IPreferenceStore#isDefault(String)
- */
+ @Override
public boolean isDefault(String name) {
return fStore.isDefault(name);
}
- /*
- * @see IPreferenceStore#needsSaving()
- */
+ @Override
public boolean needsSaving() {
return fStore.needsSaving();
}
- /*
- * @see IPreferenceStore#putValue(String, String)
- */
+ @Override
public void putValue(String name, String value) {
if (covers(name))
fStore.putValue(name, value);
}
- /*
- * @see IPreferenceStore#setDefault(String, double)
- */
+ @Override
public void setDefault(String name, double value) {
if (covers(name))
fStore.setDefault(name, value);
}
- /*
- * @see IPreferenceStore#setDefault(String, float)
- */
+ @Override
public void setDefault(String name, float value) {
if (covers(name))
fStore.setDefault(name, value);
}
- /*
- * @see IPreferenceStore#setDefault(String, int)
- */
+ @Override
public void setDefault(String name, int value) {
if (covers(name))
fStore.setDefault(name, value);
}
- /*
- * @see IPreferenceStore#setDefault(String, long)
- */
+ @Override
public void setDefault(String name, long value) {
if (covers(name))
fStore.setDefault(name, value);
}
- /*
- * @see IPreferenceStore#setDefault(String, String)
- */
+ @Override
public void setDefault(String name, String value) {
if (covers(name))
fStore.setDefault(name, value);
}
- /*
- * @see IPreferenceStore#setDefault(String, boolean)
- */
+ @Override
public void setDefault(String name, boolean value) {
if (covers(name))
fStore.setDefault(name, value);
}
- /*
- * @see IPreferenceStore#setToDefault(String)
- */
+ @Override
public void setToDefault(String name) {
fStore.setToDefault(name);
}
- /*
- * @see IPreferenceStore#setValue(String, double)
- */
+ @Override
public void setValue(String name, double value) {
if (covers(name))
fStore.setValue(name, value);
}
- /*
- * @see IPreferenceStore#setValue(String, float)
- */
+ @Override
public void setValue(String name, float value) {
if (covers(name))
fStore.setValue(name, value);
}
- /*
- * @see IPreferenceStore#setValue(String, int)
- */
+ @Override
public void setValue(String name, int value) {
if (covers(name))
fStore.setValue(name, value);
}
- /*
- * @see IPreferenceStore#setValue(String, long)
- */
+ @Override
public void setValue(String name, long value) {
if (covers(name))
fStore.setValue(name, value);
}
- /*
- * @see IPreferenceStore#setValue(String, String)
- */
+ @Override
public void setValue(String name, String value) {
if (covers(name))
fStore.setValue(name, value);
}
- /*
- * @see IPreferenceStore#setValue(String, boolean)
- */
+ @Override
public void setValue(String name, boolean value) {
if (covers(name))
fStore.setValue(name, value);
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/PreviousPulldownActionDelegate.java b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/PreviousPulldownActionDelegate.java
index 749bf2958..1c14ed60a 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/PreviousPulldownActionDelegate.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/PreviousPulldownActionDelegate.java
@@ -20,10 +20,8 @@ import org.eclipse.ui.texteditor.AnnotationPreference;
*/
public class PreviousPulldownActionDelegate extends NextPreviousPulldownActionDelegate {
- /*
- * @see org.eclipse.ui.internal.texteditor.NextPreviousPulldownActionDelegate#getPreferenceKey(AnnotationPreference)
- */
- public String getPreferenceKey(AnnotationPreference annotationPreference) {
+ @Override
+public String getPreferenceKey(AnnotationPreference annotationPreference) {
return annotationPreference.getIsGoToPreviousNavigationTargetKey();
}
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/QuickDiffConfigurationBlock.java b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/QuickDiffConfigurationBlock.java
index a8944b869..fc48a4af8 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/QuickDiffConfigurationBlock.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/QuickDiffConfigurationBlock.java
@@ -56,8 +56,10 @@ class QuickDiffConfigurationBlock implements IPreferenceConfigurationBlock {
private Map fCheckBoxes= new HashMap();
private SelectionListener fCheckBoxListener= new SelectionListener() {
+ @Override
public void widgetDefaultSelected(SelectionEvent e) {
}
+ @Override
public void widgetSelected(SelectionEvent e) {
Button button= (Button) e.widget;
fStore.setValue((String) fCheckBoxes.get(button), button.getSelection());
@@ -212,6 +214,7 @@ class QuickDiffConfigurationBlock implements IPreferenceConfigurationBlock {
* @param parent the parent composite
* @return the created child composite
*/
+ @Override
public Control createControl(Composite parent) {
Composite composite= new Composite(parent, SWT.NONE);
GridLayout layout= new GridLayout();
@@ -223,12 +226,14 @@ class QuickDiffConfigurationBlock implements IPreferenceConfigurationBlock {
String label= TextEditorMessages.QuickDiffConfigurationBlock_showForNewEditors;
fEnablementCheckbox= addCheckBox(composite, label, AbstractDecoratedTextEditorPreferenceConstants.QUICK_DIFF_ALWAYS_ON, 0);
fEnablementCheckbox.addSelectionListener(new SelectionListener() {
+ @Override
public void widgetSelected(SelectionEvent e) {
boolean enabled= fEnablementCheckbox.getSelection();
fStore.setValue(SpellingService.PREFERENCE_SPELLING_ENABLED, enabled);
updateEnablement();
}
+ @Override
public void widgetDefaultSelected(SelectionEvent e) {
}
});
@@ -245,12 +250,14 @@ class QuickDiffConfigurationBlock implements IPreferenceConfigurationBlock {
gd.horizontalIndent= 10;
fQuickDiffOverviewRulerCheckBox.setLayoutData(gd);
fQuickDiffOverviewRulerCheckBox.addSelectionListener(new SelectionListener() {
+ @Override
public void widgetSelected(SelectionEvent e) {
for (int i= 0; i < fQuickDiffModel.length; i++) {
fStore.setValue(fQuickDiffModel[i][1], fQuickDiffOverviewRulerCheckBox.getSelection());
}
}
+ @Override
public void widgetDefaultSelected(SelectionEvent e) {
}
});
@@ -286,10 +293,12 @@ class QuickDiffConfigurationBlock implements IPreferenceConfigurationBlock {
changeColorButton.setLayoutData(gd);
final int index= i;
changeColorButton.addSelectionListener(new SelectionListener() {
+ @Override
public void widgetDefaultSelected(SelectionEvent e) {
// do nothing
}
+ @Override
public void widgetSelected(SelectionEvent e) {
String key= fQuickDiffModel[index][0];
PreferenceConverter.setValue(fStore, key, editor.getColorValue());
@@ -322,10 +331,12 @@ class QuickDiffConfigurationBlock implements IPreferenceConfigurationBlock {
fQuickDiffProviderCombo.setLayoutData(gd);
fQuickDiffProviderCombo.addSelectionListener(new SelectionListener() {
+ @Override
public void widgetDefaultSelected(SelectionEvent e) {
// do nothing
}
+ @Override
public void widgetSelected(SelectionEvent e) {
int i= fQuickDiffProviderCombo.getSelectionIndex();
fStore.setValue(AbstractDecoratedTextEditorPreferenceConstants.QUICK_DIFF_DEFAULT_PROVIDER, fQuickDiffProviderListModel[i][0]);
@@ -342,10 +353,7 @@ class QuickDiffConfigurationBlock implements IPreferenceConfigurationBlock {
return composite;
}
- /*
- * @see org.eclipse.ui.internal.editors.text.IPreferenceConfigurationBlock#applyData(java.lang.Object)
- * @since 3.4
- */
+ @Override
public void applyData(Object data) {
}
@@ -382,6 +390,7 @@ class QuickDiffConfigurationBlock implements IPreferenceConfigurationBlock {
fQuickDiffProviderCombo.redraw();
}
+ @Override
public void initialize() {
for (int i= 0; i < fQuickDiffProviderListModel.length; i++) {
@@ -389,6 +398,7 @@ class QuickDiffConfigurationBlock implements IPreferenceConfigurationBlock {
fQuickDiffProviderCombo.add(label);
}
fQuickDiffProviderCombo.getDisplay().asyncExec(new Runnable() {
+ @Override
public void run() {
updateProviderList();
}
@@ -408,13 +418,16 @@ class QuickDiffConfigurationBlock implements IPreferenceConfigurationBlock {
updateQuickDiffControls();
}
+ @Override
public boolean canPerformOk() {
return true;
}
+ @Override
public void performOk() {
}
+ @Override
public void performDefaults() {
initializeFields();
updateProviderList();
@@ -430,10 +443,7 @@ class QuickDiffConfigurationBlock implements IPreferenceConfigurationBlock {
fQuickDiffOverviewRulerCheckBox.setSelection(quickdiffOverviewRuler);
}
- /*
- * @see org.eclipse.ui.internal.editors.text.IPreferenceConfigurationBlock#dispose()
- * @since 3.0
- */
+ @Override
public void dispose() {
}
}
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/QuickDiffPreferencePage.java b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/QuickDiffPreferencePage.java
index 06bb9b2bf..af9cad305 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/QuickDiffPreferencePage.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/QuickDiffPreferencePage.java
@@ -27,38 +27,28 @@ import org.eclipse.ui.editors.text.ITextEditorHelpContextIds;
*/
public class QuickDiffPreferencePage extends AbstractConfigurationBlockPreferencePage {
- /*
- * @see org.eclipse.ui.internal.editors.text.AbstractConfigureationBlockPreferencePage#getHelpId()
- */
+ @Override
protected String getHelpId() {
return ITextEditorHelpContextIds.TEXT_EDITOR_PREFERENCE_PAGE;
}
- /*
- * @see org.eclipse.jface.preference.PreferencePage#createDescriptionLabel(org.eclipse.swt.widgets.Composite)
- */
+ @Override
protected Label createDescriptionLabel(Composite parent) {
return null; // no description for new look
}
- /*
- * @see org.eclipse.ui.internal.editors.text.AbstractConfigurationBlockPreferencePage#setDescription()
- */
+ @Override
protected void setDescription() {
String description= TextEditorMessages.QuickDiffConfigurationBlock_description;
setDescription(description);
}
- /*
- * @see org.org.eclipse.ui.internal.editors.text.AbstractConfigurationBlockPreferencePage#setPreferenceStore()
- */
+ @Override
protected void setPreferenceStore() {
setPreferenceStore(EditorsPlugin.getDefault().getPreferenceStore());
}
- /*
- * @see org.eclipse.ui.internal.editors.text.AbstractConfigureationBlockPreferencePage#createConfigurationBlock(org.eclipse.ui.internal.editors.text.OverlayPreferenceStore)
- */
+ @Override
protected IPreferenceConfigurationBlock createConfigurationBlock(OverlayPreferenceStore overlayPreferenceStore) {
return new QuickDiffConfigurationBlock(overlayPreferenceStore);
}
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/RefreshEditorAction.java b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/RefreshEditorAction.java
index 48d69da3e..d574dc90f 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/RefreshEditorAction.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/RefreshEditorAction.java
@@ -35,9 +35,7 @@ public class RefreshEditorAction extends RefreshAction implements IUpdate {
update();
}
- /*
- * @see org.eclipse.ui.texteditor.IUpdate#update()
- */
+ @Override
public void update() {
final IResource resource= fTextEditor == null ? null : (IResource)fTextEditor.getEditorInput().getAdapter(IResource.class);
if (resource != null)
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/RemoveTrailingWhitespaceHandler.java b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/RemoveTrailingWhitespaceHandler.java
index f98113b7e..3ab60367b 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/RemoveTrailingWhitespaceHandler.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/RemoveTrailingWhitespaceHandler.java
@@ -49,17 +49,13 @@ public class RemoveTrailingWhitespaceHandler extends FileBufferOperationHandler
super(new RemoveTrailingWhitespaceOperation());
}
- /*
- * @see org.eclipse.ui.editors.text.FileBufferOperationHandler#isAcceptableLocation(org.eclipse.core.runtime.IPath)
- */
+ @Override
protected boolean isAcceptableLocation(IPath location) {
ITextFileBufferManager manager= FileBuffers.getTextFileBufferManager();
return location != null && manager.isTextFileLocation(location, fStrictCheckIfTextLocation);
}
- /*
- * @see org.eclipse.ui.editors.text.FileBufferOperationHandler#collectFiles(org.eclipse.core.resources.IResource[])
- */
+ @Override
protected IFile[] collectFiles(IResource[] resources) {
IFile[] files= super.collectFiles(resources);
files= filterUnacceptableFiles(files);
@@ -67,6 +63,7 @@ public class RemoveTrailingWhitespaceHandler extends FileBufferOperationHandler
return files;
final IFilter filter= new IFilter() {
+ @Override
public boolean accept(IResource resource) {
return resource != null && isAcceptableLocation(resource.getFullPath());
}
@@ -116,10 +113,7 @@ public class RemoveTrailingWhitespaceHandler extends FileBufferOperationHandler
return (IFile[]) filtered.toArray(new IFile[filtered.size()]);
}
- /*
- * @see org.eclipse.core.commands.AbstractHandler#setEnabled(java.lang.Object)
- * @since 3.7
- */
+ @Override
public void setEnabled(Object evaluationContext) {
fStrictCheckIfTextLocation= true;
if (evaluationContext instanceof IEvaluationContext) {
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/SelectResourcesBlock.java b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/SelectResourcesBlock.java
index 2d9a01544..ac6e768c5 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/SelectResourcesBlock.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/SelectResourcesBlock.java
@@ -160,10 +160,12 @@ class SelectResourcesBlock implements ICheckStateListener, ISelectionChangedList
* @param event the check state event
* @see org.eclipse.jface.viewers.ICheckStateListener#checkStateChanged(org.eclipse.jface.viewers.CheckStateChangedEvent)
*/
+ @Override
public void checkStateChanged(final CheckStateChangedEvent event) {
//Potentially long operation - show a busy cursor
BusyIndicator.showWhile(treeViewer.getControl().getDisplay(), new Runnable() {
+ @Override
public void run() {
if (event.getCheckable().equals(treeViewer))
treeItemChecked(event.getElement(), event.getChecked());
@@ -288,6 +290,7 @@ class SelectResourcesBlock implements ICheckStateListener, ISelectionChangedList
*/
private void expandTreeElement(final Object element) {
BusyIndicator.showWhile(treeViewer.getControl().getDisplay(), new Runnable() {
+ @Override
public void run() {
// First see if the children need to be given their checked
@@ -407,10 +410,12 @@ class SelectResourcesBlock implements ICheckStateListener, ISelectionChangedList
IElementFilter passThroughFilter= new IElementFilter() {
+ @Override
public void filterElements(Collection elements) throws InterruptedException {
returnValue.addAll(elements);
}
+ @Override
public void filterElements(Object[] elements) throws InterruptedException {
for (int i= 0; i < elements.length; i++) {
returnValue.add(elements[i]);
@@ -561,6 +566,7 @@ class SelectResourcesBlock implements ICheckStateListener, ISelectionChangedList
for (int i= 0; i < array.length; i++) {
final ICheckStateListener l= (ICheckStateListener) array[i];
SafeRunner.run(new SafeRunnable() {
+ @Override
public void run() {
l.checkStateChanged(event);
}
@@ -583,6 +589,7 @@ class SelectResourcesBlock implements ICheckStateListener, ISelectionChangedList
//Potentially long operation - show a busy cursor
BusyIndicator.showWhile(treeViewer.getControl().getDisplay(), new Runnable() {
+ @Override
public void run() {
setListForWhiteSelection(treeElement);
listViewer.setAllChecked(true);
@@ -640,6 +647,7 @@ class SelectResourcesBlock implements ICheckStateListener, ISelectionChangedList
*
* @param event SelectionChangedEvent
*/
+ @Override
public void selectionChanged(SelectionChangedEvent event) {
IStructuredSelection selection= (IStructuredSelection) event.getSelection();
Object selectedElement= selection.getFirstElement();
@@ -672,6 +680,7 @@ class SelectResourcesBlock implements ICheckStateListener, ISelectionChangedList
//Potentially long operation - show a busy cursor
BusyIndicator.showWhile(treeViewer.getControl().getDisplay(), new Runnable() {
+ @Override
public void run() {
setTreeChecked(root, selection);
listViewer.setAllChecked(selection);
@@ -682,6 +691,7 @@ class SelectResourcesBlock implements ICheckStateListener, ISelectionChangedList
public void refresh() {
//Potentially long operation - show a busy cursor
BusyIndicator.showWhile(treeViewer.getControl().getDisplay(), new Runnable() {
+ @Override
public void run() {
treeViewer.refresh();
populateListViewer(currentTreeSelection);
@@ -778,6 +788,7 @@ class SelectResourcesBlock implements ICheckStateListener, ISelectionChangedList
*
* @param event the collapse event
*/
+ @Override
public void treeCollapsed(TreeExpansionEvent event) {
// We don't need to do anything with this
}
@@ -787,6 +798,7 @@ class SelectResourcesBlock implements ICheckStateListener, ISelectionChangedList
*
* @param event the expansion event
*/
+ @Override
public void treeExpanded(TreeExpansionEvent event) {
expandTreeElement(event.getElement());
}
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/SelectResourcesDialog.java b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/SelectResourcesDialog.java
index 897ffeb0f..87cd0b0b7 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/SelectResourcesDialog.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/SelectResourcesDialog.java
@@ -77,10 +77,7 @@ class SelectResourcesDialog extends Dialog {
fAcceptableLocationsFilter= acceptableLocationsFilter;
}
- /*
- * @see org.eclipse.jface.dialogs.Dialog#isResizable()
- * @since 3.4
- */
+ @Override
protected boolean isResizable() {
return true;
}
@@ -99,9 +96,7 @@ class SelectResourcesDialog extends Dialog {
return (IResource[]) items.toArray(new IResource[items.size()]);
}
- /*
- * @see org.eclipse.jface.window.Window#configureShell(org.eclipse.swt.widgets.Shell)
- */
+ @Override
protected void configureShell(Shell newShell) {
super.configureShell(newShell);
@@ -109,9 +104,7 @@ class SelectResourcesDialog extends Dialog {
newShell.setText(fTitle);
}
- /*
- * @see org.eclipse.jface.dialogs.Dialog#createDialogArea(org.eclipse.swt.widgets.Composite)
- */
+ @Override
protected Control createDialogArea(Composite parent) {
Composite composite= (Composite) super.createDialogArea(parent);
Label label= new Label(composite, SWT.LEFT);
@@ -120,6 +113,7 @@ class SelectResourcesDialog extends Dialog {
fResourceGroup= new SelectResourcesBlock(composite, ResourcesPlugin.getWorkspace().getRoot(), getResourceProvider(IResource.FOLDER | IResource.PROJECT), WorkbenchLabelProvider.getDecoratingWorkbenchLabelProvider(), getResourceProvider(IResource.FILE), WorkbenchLabelProvider.getDecoratingWorkbenchLabelProvider(), SWT.NONE, useHeightHint(parent));
fResourceGroup.addCheckStateListener(new ICheckStateListener() {
+ @Override
public void checkStateChanged(CheckStateChangedEvent event) {
updateSelectionCount();
}
@@ -142,7 +136,8 @@ class SelectResourcesDialog extends Dialog {
private ITreeContentProvider getResourceProvider(final int resourceType) {
return new WorkbenchContentProvider() {
- public Object[] getChildren(Object o) {
+ @Override
+ public Object[] getChildren(Object o) {
if (o instanceof IWorkspaceRoot) {
HashSet projects= new HashSet();
for (int i= 0; i < fInput.length; i++) {
@@ -195,6 +190,7 @@ class SelectResourcesDialog extends Dialog {
Button selectButton= createButton(buttonComposite, IDialogConstants.SELECT_ALL_ID, TextEditorMessages.SelectResourcesDialog_selectAll, false);
SelectionListener listener= new SelectionAdapter() {
+ @Override
public void widgetSelected(SelectionEvent e) {
fResourceGroup.setAllSelections(true);
updateSelectionCount();
@@ -207,6 +203,7 @@ class SelectResourcesDialog extends Dialog {
Button deselectButton= createButton(buttonComposite, IDialogConstants.DESELECT_ALL_ID, TextEditorMessages.SelectResourcesDialog_deselectAll, false);
listener= new SelectionAdapter() {
+ @Override
public void widgetSelected(SelectionEvent e) {
fResourceGroup.setAllSelections(false);
updateSelectionCount();
@@ -220,6 +217,7 @@ class SelectResourcesDialog extends Dialog {
Button selectTypesButton= createButton(buttonComposite, IDialogConstants.SELECT_TYPES_ID, TextEditorMessages.SelectResourcesDialog_filterSelection, false);
listener= new SelectionAdapter() {
+ @Override
public void widgetSelected(SelectionEvent e) {
handleSelectFileTypes();
}
@@ -248,6 +246,7 @@ class SelectResourcesDialog extends Dialog {
private void filterSelection() {
final IFilter filter= new IFilter() {
+ @Override
public boolean accept(IResource resource) {
return hasAcceptedFileType(resource);
}
@@ -257,7 +256,8 @@ class SelectResourcesDialog extends Dialog {
final IResource[] resources= (IResource[]) list.toArray(new IResource[list.size()]);
Runnable runnable = new Runnable() {
- public void run() {
+ @Override
+ public void run() {
setSelection(resources, filter);
}
};
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/SharedTextColors.java b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/SharedTextColors.java
index eccaeda0b..047968bd0 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/SharedTextColors.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/SharedTextColors.java
@@ -34,9 +34,7 @@ class SharedTextColors implements ISharedTextColors {
super();
}
- /*
- * @see ISharedTextColors#getColor(RGB)
- */
+ @Override
public Color getColor(RGB rgb) {
if (rgb == null)
return null;
@@ -51,6 +49,7 @@ class SharedTextColors implements ISharedTextColors {
colorTable= new HashMap(10);
fDisplayTable.put(display, colorTable);
display.disposeExec(new Runnable() {
+ @Override
public void run() {
dispose(display);
}
@@ -66,9 +65,7 @@ class SharedTextColors implements ISharedTextColors {
return color;
}
- /*
- * @see ISharedTextColors#dispose()
- */
+ @Override
public void dispose() {
if (fDisplayTable == null)
return;
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/SpellingConfigurationBlock.java b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/SpellingConfigurationBlock.java
index d28884cdd..1d711e1d2 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/SpellingConfigurationBlock.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/SpellingConfigurationBlock.java
@@ -85,9 +85,7 @@ class SpellingConfigurationBlock implements IPreferenceConfigurationBlock {
fMessage= message;
}
- /*
- * @see org.eclipse.ui.texteditor.spelling.ISpellingPreferenceBlock#createControl(org.eclipse.swt.widgets.Composite)
- */
+ @Override
public Control createControl(Composite composite) {
Composite inner= new Composite(composite, SWT.NONE);
inner.setLayout(new FillLayout(SWT.VERTICAL));
@@ -98,46 +96,32 @@ class SpellingConfigurationBlock implements IPreferenceConfigurationBlock {
return inner;
}
- /*
- * @see org.eclipse.ui.texteditor.spelling.ISpellingPreferenceBlock#initialize(org.eclipse.ui.texteditor.spelling.IStatusMonitor)
- */
+ @Override
public void initialize(IPreferenceStatusMonitor statusMonitor) {
}
- /*
- * @see org.eclipse.ui.texteditor.spelling.ISpellingPreferenceBlock#canPerformOk()
- */
+ @Override
public boolean canPerformOk() {
return true;
}
- /*
- * @see org.eclipse.ui.texteditor.spelling.ISpellingPreferenceBlock#performOk()
- */
+ @Override
public void performOk() {
}
- /*
- * @see org.eclipse.ui.texteditor.spelling.ISpellingPreferenceBlock#performDefaults()
- */
+ @Override
public void performDefaults() {
}
- /*
- * @see org.eclipse.ui.texteditor.spelling.ISpellingPreferenceBlock#performRevert()
- */
+ @Override
public void performRevert() {
}
- /*
- * @see org.eclipse.ui.texteditor.spelling.ISpellingPreferenceBlock#dispose()
- */
+ @Override
public void dispose() {
}
- /*
- * @see org.eclipse.ui.texteditor.spelling.ISpellingPreferenceBlock#setEnabled(boolean)
- */
+ @Override
public void setEnabled(boolean enabled) {
fLabel.setEnabled(enabled);
}
@@ -163,9 +147,7 @@ class SpellingConfigurationBlock implements IPreferenceConfigurationBlock {
fForwardedMonitor= forwardedMonitor;
}
- /*
- * @see org.eclipse.ui.texteditor.spelling.IPreferenceStatusMonitor#statusChanged(org.eclipse.core.runtime.IStatus)
- */
+ @Override
public void statusChanged(IStatus status) {
fStatus= status;
fForwardedMonitor.statusChanged(status);
@@ -239,6 +221,7 @@ class SpellingConfigurationBlock implements IPreferenceConfigurationBlock {
* @param parent the parent composite
* @return the control for the preference page
*/
+ @Override
public Control createControl(Composite parent) {
Composite composite= new Composite(parent, SWT.NULL);
@@ -266,12 +249,14 @@ class SpellingConfigurationBlock implements IPreferenceConfigurationBlock {
gd= new GridData(GridData.HORIZONTAL_ALIGN_BEGINNING | GridData.VERTICAL_ALIGN_BEGINNING);
fEnablementCheckbox.setLayoutData(gd);
fEnablementCheckbox.addSelectionListener(new SelectionListener() {
+ @Override
public void widgetSelected(SelectionEvent e) {
boolean enabled= fEnablementCheckbox.getSelection();
fStore.setValue(SpellingService.PREFERENCE_SPELLING_ENABLED, enabled);
updateCheckboxDependencies();
}
+ @Override
public void widgetDefaultSelected(SelectionEvent e) {
}
});
@@ -324,10 +309,7 @@ class SpellingConfigurationBlock implements IPreferenceConfigurationBlock {
return composite;
}
- /*
- * @see org.eclipse.ui.internal.editors.text.IPreferenceConfigurationBlock#applyData(java.lang.Object)
- * @since 3.4
- */
+ @Override
public void applyData(Object data) {
}
@@ -336,42 +318,33 @@ class SpellingConfigurationBlock implements IPreferenceConfigurationBlock {
final ComboViewer viewer= new ComboViewer(fProviderCombo);
viewer.setContentProvider(new IStructuredContentProvider() {
- /*
- * @see org.eclipse.jface.viewers.IContentProvider#dispose()
- */
+ @Override
public void dispose() {
}
- /*
- * @see org.eclipse.jface.viewers.IContentProvider#inputChanged(org.eclipse.jface.viewers.Viewer, java.lang.Object, java.lang.Object)
- */
+ @Override
public void inputChanged(Viewer v, Object oldInput, Object newInput) {
}
- /*
- * @see org.eclipse.jface.viewers.IStructuredContentProvider#getElements(java.lang.Object)
- */
+ @Override
public Object[] getElements(Object inputElement) {
return fProviderDescriptors.values().toArray();
}
});
viewer.setLabelProvider(new LabelProvider() {
- /*
- * @see org.eclipse.jface.viewers.LabelProvider#getImage(java.lang.Object)
- */
+ @Override
public Image getImage(Object element) {
return null;
}
- /*
- * @see org.eclipse.jface.viewers.LabelProvider#getText(java.lang.Object)
- */
+ @Override
public String getText(Object element) {
return ((SpellingEngineDescriptor) element).getLabel();
}
});
viewer.addSelectionChangedListener(new ISelectionChangedListener() {
+ @Override
public void selectionChanged(SelectionChangedEvent event) {
IStructuredSelection sel= (IStructuredSelection) event.getSelection();
if (sel.isEmpty())
@@ -379,9 +352,11 @@ class SpellingConfigurationBlock implements IPreferenceConfigurationBlock {
if (fCurrentBlock != null && fStatusMonitor.getStatus() != null && fStatusMonitor.getStatus().matches(IStatus.ERROR))
if (isPerformRevert()) {
ISafeRunnable runnable= new ISafeRunnable() {
+ @Override
public void run() throws Exception {
fCurrentBlock.performRevert();
}
+ @Override
public void handleException(Throwable x) {
}
};
@@ -426,9 +401,11 @@ class SpellingConfigurationBlock implements IPreferenceConfigurationBlock {
final ISpellingPreferenceBlock preferenceBlock= (ISpellingPreferenceBlock) fProviderPreferences.get(id);
if (preferenceBlock != null) {
ISafeRunnable runnable= new ISafeRunnable() {
+ @Override
public void run() throws Exception {
preferenceBlock.setEnabled(enabled);
}
+ @Override
public void handleException(Throwable x) {
}
};
@@ -472,9 +449,11 @@ class SpellingConfigurationBlock implements IPreferenceConfigurationBlock {
if (control == null) {
final Control[] result= new Control[1];
ISafeRunnable runnable= new ISafeRunnable() {
+ @Override
public void run() throws Exception {
result[0]= fCurrentBlock.createControl(fGroup);
}
+ @Override
public void handleException(Throwable x) {
}
};
@@ -496,19 +475,23 @@ class SpellingConfigurationBlock implements IPreferenceConfigurationBlock {
fStatusMonitor.statusChanged(new StatusInfo());
ISafeRunnable runnable= new ISafeRunnable() {
+ @Override
public void run() throws Exception {
fCurrentBlock.initialize(fStatusMonitor);
}
+ @Override
public void handleException(Throwable x) {
}
};
SafeRunner.run(runnable);
}
+ @Override
public void initialize() {
restoreFromPreferences();
}
+ @Override
public boolean canPerformOk() {
SpellingEngineDescriptor desc= EditorsUI.getSpellingService().getActiveSpellingEngineDescriptor(fStore);
String id= desc != null ? desc.getId() : ""; //$NON-NLS-1$
@@ -518,9 +501,11 @@ class SpellingConfigurationBlock implements IPreferenceConfigurationBlock {
final Boolean[] result= new Boolean[] { Boolean.TRUE };
ISafeRunnable runnable= new ISafeRunnable() {
+ @Override
public void run() throws Exception {
result[0]= Boolean.valueOf(block.canPerformOk());
}
+ @Override
public void handleException(Throwable x) {
}
};
@@ -528,13 +513,16 @@ class SpellingConfigurationBlock implements IPreferenceConfigurationBlock {
return result[0].booleanValue();
}
+ @Override
public void performOk() {
for (Iterator it= fProviderPreferences.values().iterator(); it.hasNext();) {
final ISpellingPreferenceBlock block= (ISpellingPreferenceBlock) it.next();
ISafeRunnable runnable= new ISafeRunnable() {
+ @Override
public void run() throws Exception {
block.performOk();
}
+ @Override
public void handleException(Throwable x) {
}
};
@@ -542,14 +530,17 @@ class SpellingConfigurationBlock implements IPreferenceConfigurationBlock {
}
}
+ @Override
public void performDefaults() {
restoreFromPreferences();
for (Iterator it= fProviderPreferences.values().iterator(); it.hasNext();) {
final ISpellingPreferenceBlock block= (ISpellingPreferenceBlock) it.next();
ISafeRunnable runnable= new ISafeRunnable() {
+ @Override
public void run() throws Exception {
block.performDefaults();
}
+ @Override
public void handleException(Throwable x) {
}
};
@@ -557,13 +548,16 @@ class SpellingConfigurationBlock implements IPreferenceConfigurationBlock {
}
}
+ @Override
public void dispose() {
for (Iterator it= fProviderPreferences.values().iterator(); it.hasNext();) {
final ISpellingPreferenceBlock block= (ISpellingPreferenceBlock) it.next();
ISafeRunnable runnable= new ISafeRunnable() {
+ @Override
public void run() throws Exception {
block.dispose();
}
+ @Override
public void handleException(Throwable x) {
}
};
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/SpellingPreferencePage.java b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/SpellingPreferencePage.java
index 4468562b6..5d2752a08 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/SpellingPreferencePage.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/SpellingPreferencePage.java
@@ -32,9 +32,7 @@ public class SpellingPreferencePage extends AbstractConfigurationBlockPreference
*/
private class StatusMonitor implements IPreferenceStatusMonitor {
- /*
- * @see org.eclipse.ui.texteditor.spelling.IStatusMonitor#statusChanged(org.eclipse.core.runtime.IStatus)
- */
+ @Override
public void statusChanged(IStatus status) {
handleStatusChanged(status);
}
@@ -50,29 +48,21 @@ public class SpellingPreferencePage extends AbstractConfigurationBlockPreference
StatusUtil.applyToStatusLine(this, status);
}
- /*
- * @see org.eclipse.ui.internal.editors.text.AbstractConfigureationBlockPreferencePage#getHelpId()
- */
+ @Override
protected String getHelpId() {
return ITextEditorHelpContextIds.SPELLING_PREFERENCE_PAGE;
}
- /*
- * @see org.eclipse.ui.internal.editors.text.AbstractConfigurationBlockPreferencePage#setDescription()
- */
+ @Override
protected void setDescription() {
}
- /*
- * @see org.eclipse.ui.internal.editors.text.AbstractConfigurationBlockPreferencePage#setPreferenceStore()
- */
+ @Override
protected void setPreferenceStore() {
setPreferenceStore(EditorsPlugin.getDefault().getPreferenceStore());
}
- /*
- * @see org.eclipse.ui.internal.editors.text.AbstractConfigureationBlockPreferencePage#createConfigurationBlock(org.eclipse.ui.internal.editors.text.OverlayPreferenceStore)
- */
+ @Override
protected IPreferenceConfigurationBlock createConfigurationBlock(OverlayPreferenceStore overlayPreferenceStore) {
return new SpellingConfigurationBlock(overlayPreferenceStore, new StatusMonitor());
}
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/StatusInfo.java b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/StatusInfo.java
index 6e8bb39c7..57a0bdaf5 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/StatusInfo.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/StatusInfo.java
@@ -48,9 +48,7 @@ class StatusInfo implements IStatus {
fSeverity= severity;
}
- /*
- * @see org.eclipse.core.runtime.IStatus#isOK()
- */
+ @Override
public boolean isOK() {
return fSeverity == IStatus.OK;
}
@@ -85,9 +83,7 @@ class StatusInfo implements IStatus {
return fSeverity == IStatus.ERROR;
}
- /*
- * @see IStatus#getMessage()
- */
+ @Override
public String getMessage() {
return fStatusMessage;
}
@@ -133,9 +129,7 @@ class StatusInfo implements IStatus {
fSeverity= IStatus.OK;
}
- /*
- * @see IStatus#matches(int)
- */
+ @Override
public boolean matches(int severityMask) {
return (fSeverity & severityMask) != 0;
}
@@ -145,20 +139,17 @@ class StatusInfo implements IStatus {
*
* @see IStatus#isMultiStatus()
*/
+ @Override
public boolean isMultiStatus() {
return false;
}
- /*
- * @see IStatus#getSeverity()
- */
+ @Override
public int getSeverity() {
return fSeverity;
}
- /*
- * @see IStatus#getPlugin()
- */
+ @Override
public String getPlugin() {
return EditorsUI.PLUGIN_ID;
}
@@ -168,6 +159,7 @@ class StatusInfo implements IStatus {
*
* @see IStatus#getException()
*/
+ @Override
public Throwable getException() {
return null;
}
@@ -177,6 +169,7 @@ class StatusInfo implements IStatus {
*
* @see IStatus#getCode()
*/
+ @Override
public int getCode() {
return fSeverity;
}
@@ -186,6 +179,7 @@ class StatusInfo implements IStatus {
*
* @see IStatus#getChildren()
*/
+ @Override
public IStatus[] getChildren() {
return new IStatus[0];
}
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/TabFolderLayout.java b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/TabFolderLayout.java
index 622ca4341..017831218 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/TabFolderLayout.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/TabFolderLayout.java
@@ -29,6 +29,7 @@ class TabFolderLayout extends Layout {
/*
* @see org.eclipse.swt.widgets.Layout#computeSize(org.eclipse.swt.widgets.Composite, int, int, boolean)
*/
+ @Override
protected Point computeSize (Composite composite, int wHint, int hHint, boolean flushCache) {
if (wHint != SWT.DEFAULT && hHint != SWT.DEFAULT)
return new Point(wHint, hHint);
@@ -55,6 +56,7 @@ class TabFolderLayout extends Layout {
/*
* @see org.eclipse.swt.widgets.Layout#layout(org.eclipse.swt.widgets.Composite, boolean)
*/
+ @Override
protected void layout (Composite composite, boolean flushCache) {
Rectangle rect= composite.getClientArea();
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/TextEditorDefaultsPreferencePage.java b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/TextEditorDefaultsPreferencePage.java
index 85e569c9b..571c0d701 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/TextEditorDefaultsPreferencePage.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/TextEditorDefaultsPreferencePage.java
@@ -102,6 +102,7 @@ public class TextEditorDefaultsPreferencePage extends PreferencePage implements
super(preference);
fText= control;
}
+ @Override
public void initialize() {
String value= fPreferenceStore.getString(fPreference.getKey());
fText.setText(value);
@@ -115,6 +116,7 @@ public class TextEditorDefaultsPreferencePage extends PreferencePage implements
super(preference);
fControl= control;
}
+ @Override
public void initialize() {
boolean value= fPreferenceStore.getBoolean(fPreference.getKey());
fControl.setSelection(value);
@@ -130,6 +132,7 @@ public class TextEditorDefaultsPreferencePage extends PreferencePage implements
fControl= control;
fDomain= domain;
}
+ @Override
public void initialize() {
int value= fPreferenceStore.getInt(fPreference.getKey());
EnumValue enumValue= fDomain.getValueByInteger(value);
@@ -150,6 +153,7 @@ public class TextEditorDefaultsPreferencePage extends PreferencePage implements
fControl= control;
fDomain= domain;
}
+ @Override
public void initialize() {
int value= fPreferenceStore.getInt(fPreference.getKey());
EnumValue enumValue= fDomain.getValueByInteger(value);
@@ -199,6 +203,7 @@ public class TextEditorDefaultsPreferencePage extends PreferencePage implements
fMin= min;
}
+ @Override
public IStatus validate(Object value) {
StatusInfo status= new StatusInfo();
if (value instanceof String && ((String)value).length() == 0) {
@@ -238,9 +243,11 @@ public class TextEditorDefaultsPreferencePage extends PreferencePage implements
public int getIntValue() {
return fValue;
}
+ @Override
public final int hashCode() {
return getIntValue();
}
+ @Override
public boolean equals(Object obj) {
if (obj instanceof EnumValue) {
return ((EnumValue) obj).getIntValue() == fValue;
@@ -294,6 +301,7 @@ public class TextEditorDefaultsPreferencePage extends PreferencePage implements
addValue(from++);
}
+ @Override
public IStatus validate(Object value) {
StatusInfo status= new StatusInfo();
if (value instanceof String && ((String)value).length() == 0) {
@@ -328,6 +336,7 @@ public class TextEditorDefaultsPreferencePage extends PreferencePage implements
}
static class BooleanDomain extends Domain {
+ @Override
public IStatus validate(Object value) {
StatusInfo status= new StatusInfo();
if (value instanceof String && ((String)value).length() == 0) {
@@ -421,11 +430,13 @@ public class TextEditorDefaultsPreferencePage extends PreferencePage implements
return new OverlayPreferenceStore(fParentPreferenceStore, keys);
}
+ @Override
protected void configureShell(Shell newShell) {
super.configureShell(newShell);
newShell.setText(TextEditorMessages.TextEditorDefaultsPreferencePage_showWhitespaceCharactersDialogTitle);
}
+ @Override
protected Control createContents(Composite parent) {
Control contents= super.createContents(parent);
Dialog.applyDialogFont(contents);
@@ -442,6 +453,7 @@ public class TextEditorDefaultsPreferencePage extends PreferencePage implements
}
}
+ @Override
protected Control createDialogArea(Composite parent) {
Composite composite= (Composite)super.createDialogArea(parent);
@@ -579,6 +591,7 @@ public class TextEditorDefaultsPreferencePage extends PreferencePage implements
gd.horizontalIndent= indentation;
checkBox.setLayoutData(gd);
checkBox.addSelectionListener(new SelectionAdapter() {
+ @Override
public void widgetSelected(SelectionEvent e) {
boolean value= checkBox.getSelection();
IStatus status= domain.validate(Boolean.valueOf(value));
@@ -607,6 +620,7 @@ public class TextEditorDefaultsPreferencePage extends PreferencePage implements
if (domain != null) {
textControl.addModifyListener(new ModifyListener() {
+ @Override
public void modifyText(ModifyEvent e) {
String value= textControl.getText();
IStatus status= domain.validate(value);
@@ -626,6 +640,7 @@ public class TextEditorDefaultsPreferencePage extends PreferencePage implements
return new Control[] { labelControl, textControl };
}
+ @Override
protected void okPressed() {
super.okPressed();
fDialogOverlayStore.propagate();
@@ -735,15 +750,11 @@ public class TextEditorDefaultsPreferencePage extends PreferencePage implements
return new OverlayPreferenceStore(getPreferenceStore(), keys);
}
- /*
- * @see IWorkbenchPreferencePage#init()
- */
+ @Override
public void init(IWorkbench workbench) {
}
- /*
- * @see PreferencePage#createControl(Composite)
- */
+ @Override
public void createControl(Composite parent) {
super.createControl(parent);
PlatformUI.getWorkbench().getHelpSystem().setHelp(getControl(), ITextEditorHelpContextIds.TEXT_EDITOR_PREFERENCE_PAGE);
@@ -786,6 +797,7 @@ public class TextEditorDefaultsPreferencePage extends PreferencePage implements
Link fontLink= new Link(appearanceComposite, SWT.NONE);
fontLink.setText(TextEditorMessages.TextEditorPreferencePage_Font_link);
fontLink.addSelectionListener(new SelectionAdapter() {
+ @Override
public void widgetSelected(SelectionEvent e) {
PreferencesUtil.createPreferenceDialogOn(getShell(), "org.eclipse.ui.preferencePages.ColorsAndFonts", null, "selectFont:" + JFaceResources.TEXT_FONT); //$NON-NLS-1$ //$NON-NLS-2$
}
@@ -831,6 +843,7 @@ public class TextEditorDefaultsPreferencePage extends PreferencePage implements
createDependency(showPrintMarginButton, showPrintMargin, printMarginControls);
showPrintMarginButton.addSelectionListener(new SelectionAdapter() {
+ @Override
public void widgetSelected(SelectionEvent e) {
updateStatus(printMarginDomain);
}
@@ -848,6 +861,7 @@ public class TextEditorDefaultsPreferencePage extends PreferencePage implements
String linkText= TextEditorMessages.TextEditorDefaultsPreferencePage_showWhitespaceCharactersLinkText;
Preference showWhitespaceCharacters= new Preference(AbstractDecoratedTextEditorPreferenceConstants.EDITOR_SHOW_WHITESPACE_CHARACTERS, label, null);
addCheckBoxWithLink(appearanceComposite, showWhitespaceCharacters, linkText, new BooleanDomain(), 0, new SelectionAdapter() {
+ @Override
public void widgetSelected(SelectionEvent e) {
Dialog dialog= new WhitespaceCharacterPainterOptionsDialog(Display.getDefault().getActiveShell(), fOverlayStore);
dialog.open();
@@ -923,6 +937,7 @@ public class TextEditorDefaultsPreferencePage extends PreferencePage implements
foregroundColorButton.setLayoutData(gd);
SelectionListener colorDefaultSelectionListener= new SelectionListener() {
+ @Override
public void widgetSelected(SelectionEvent e) {
boolean systemDefault= fAppearanceColorDefault.getSelection();
fAppearanceColorEditor.getButton().setEnabled(!systemDefault);
@@ -935,6 +950,7 @@ public class TextEditorDefaultsPreferencePage extends PreferencePage implements
if (key != null)
fOverlayStore.setValue(key, systemDefault);
}
+ @Override
public void widgetDefaultSelected(SelectionEvent e) {}
};
@@ -948,17 +964,21 @@ public class TextEditorDefaultsPreferencePage extends PreferencePage implements
fAppearanceColorDefault.addSelectionListener(colorDefaultSelectionListener);
fAppearanceColorList.addSelectionListener(new SelectionListener() {
+ @Override
public void widgetDefaultSelected(SelectionEvent e) {
// do nothing
}
+ @Override
public void widgetSelected(SelectionEvent e) {
handleAppearanceColorListSelection();
}
});
foregroundColorButton.addSelectionListener(new SelectionListener() {
+ @Override
public void widgetDefaultSelected(SelectionEvent e) {
// do nothing
}
+ @Override
public void widgetSelected(SelectionEvent e) {
int i= fAppearanceColorList.getSelectionIndex();
if (i == -1)
@@ -972,6 +992,7 @@ public class TextEditorDefaultsPreferencePage extends PreferencePage implements
Link link= new Link(appearanceComposite, SWT.NONE);
link.setText(TextEditorMessages.TextEditorPreferencePage_colorsAndFonts_link);
link.addSelectionListener(new SelectionAdapter() {
+ @Override
public void widgetSelected(SelectionEvent e) {
PreferencesUtil.createPreferenceDialogOn(getShell(), "org.eclipse.ui.preferencePages.ColorsAndFonts", null, "selectCategory:org.eclipse.ui.workbenchMisc"); //$NON-NLS-1$ //$NON-NLS-2$
}
@@ -989,9 +1010,7 @@ public class TextEditorDefaultsPreferencePage extends PreferencePage implements
return appearanceComposite;
}
- /*
- * @see PreferencePage#createContents(Composite)
- */
+ @Override
protected Control createContents(Composite parent) {
initializeDefaultColors();
@@ -1013,6 +1032,7 @@ public class TextEditorDefaultsPreferencePage extends PreferencePage implements
for (int i= 0; i < fAppearanceColorListModel.length; i++)
fAppearanceColorList.add(fAppearanceColorListModel[i][0]);
fAppearanceColorList.getDisplay().asyncExec(new Runnable() {
+ @Override
public void run() {
if (fAppearanceColorList != null && !fAppearanceColorList.isDisposed()) {
fAppearanceColorList.select(0);
@@ -1063,17 +1083,13 @@ public class TextEditorDefaultsPreferencePage extends PreferencePage implements
}
}
- /*
- * @see PreferencePage#performOk()
- */
+ @Override
public boolean performOk() {
fOverlayStore.propagate();
return true;
}
- /*
- * @see PreferencePage#performDefaults()
- */
+ @Override
protected void performDefaults() {
fOverlayStore.loadDefaults();
@@ -1085,9 +1101,7 @@ public class TextEditorDefaultsPreferencePage extends PreferencePage implements
super.performDefaults();
}
- /*
- * @see DialogPage#dispose()
- */
+ @Override
public void dispose() {
if (fOverlayStore != null) {
@@ -1125,6 +1139,7 @@ public class TextEditorDefaultsPreferencePage extends PreferencePage implements
gd.horizontalSpan= 2;
checkBox.setLayoutData(gd);
checkBox.addSelectionListener(new SelectionAdapter() {
+ @Override
public void widgetSelected(SelectionEvent e) {
checkboxControlChanged(preference, domain, checkBox);
}
@@ -1155,6 +1170,7 @@ public class TextEditorDefaultsPreferencePage extends PreferencePage implements
gd= new GridData(GridData.FILL, GridData.CENTER, false, false);
checkBox.setLayoutData(gd);
checkBox.addSelectionListener(new SelectionAdapter() {
+ @Override
public void widgetSelected(SelectionEvent e) {
checkboxControlChanged(preference, domain, checkBox);
}
@@ -1166,6 +1182,7 @@ public class TextEditorDefaultsPreferencePage extends PreferencePage implements
link.setLayoutData(gd);
if (listener != null) {
link.addSelectionListener(new SelectionAdapter() {
+ @Override
public void widgetSelected(SelectionEvent e) {
listener.widgetSelected(e);
}
@@ -1194,6 +1211,7 @@ public class TextEditorDefaultsPreferencePage extends PreferencePage implements
}
combo.addSelectionListener(new SelectionAdapter() {
+ @Override
public void widgetSelected(SelectionEvent e) {
int index= combo.getSelectionIndex();
EnumValue value= domain.getValueByIndex(index);
@@ -1239,6 +1257,7 @@ public class TextEditorDefaultsPreferencePage extends PreferencePage implements
spinner.setPageIncrement(4);
spinner.addSelectionListener(new SelectionAdapter() {
+ @Override
public void widgetSelected(SelectionEvent e) {
int index= spinner.getSelection();
EnumValue value= domain.getValueByInteger(index);
@@ -1270,6 +1289,7 @@ public class TextEditorDefaultsPreferencePage extends PreferencePage implements
if (domain != null) {
textControl.addModifyListener(new ModifyListener() {
+ @Override
public void modifyText(ModifyEvent e) {
String value= textControl.getText();
IStatus status= domain.validate(value);
@@ -1296,6 +1316,7 @@ public class TextEditorDefaultsPreferencePage extends PreferencePage implements
}
SelectionListener listener= new SelectionListener() {
+ @Override
public void widgetSelected(SelectionEvent e) {
boolean state= master.getSelection();
for (int i= 0; i < slaves.length; i++) {
@@ -1303,6 +1324,7 @@ public class TextEditorDefaultsPreferencePage extends PreferencePage implements
}
}
+ @Override
public void widgetDefaultSelected(SelectionEvent e) {}
};
master.addSelectionListener(listener);
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/UISynchronizationContext.java b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/UISynchronizationContext.java
index 2f5dfde94..eb373f2e8 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/UISynchronizationContext.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/UISynchronizationContext.java
@@ -26,9 +26,7 @@ import org.eclipse.ui.PlatformUI;
*/
public class UISynchronizationContext implements ISynchronizationContext {
- /*
- * @see org.eclipse.core.filebuffers.ISynchronizationContext#run(java.lang.Runnable)
- */
+ @Override
public void run(Runnable runnable) {
if (Display.getCurrent() != null) {
runnable.run();
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/URLHyperlink.java b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/URLHyperlink.java
index 2ca11abc2..f174c1f6c 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/URLHyperlink.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/URLHyperlink.java
@@ -39,10 +39,7 @@ final class URLHyperlink extends org.eclipse.jface.text.hyperlink.URLHyperlink {
super(region, urlString);
}
- /*
- * @see org.eclipse.jface.text.hyperlink.URLHyperlink#open()
- * @since 3.1
- */
+ @Override
public void open() {
// Create the browser
IWorkbenchBrowserSupport support= PlatformUI.getWorkbench().getBrowserSupport();
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/URLHyperlinkDetector.java b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/URLHyperlinkDetector.java
index 51f421db0..b616604ef 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/URLHyperlinkDetector.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/URLHyperlinkDetector.java
@@ -22,9 +22,7 @@ import org.eclipse.jface.text.hyperlink.IHyperlink;
*/
public class URLHyperlinkDetector extends org.eclipse.jface.text.hyperlink.URLHyperlinkDetector {
- /*
- * @see org.eclipse.jface.text.hyperlink.IHyperlinkDetector#detectHyperlinks(org.eclipse.jface.text.ITextViewer, org.eclipse.jface.text.IRegion, boolean)
- */
+ @Override
public IHyperlink[] detectHyperlinks(ITextViewer textViewer, IRegion region, boolean canShowMultipleHyperlinks) {
IHyperlink[] result= super.detectHyperlinks(textViewer, region, canShowMultipleHyperlinks);
if (result == null)
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/UntitledTextFileWizard.java b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/UntitledTextFileWizard.java
index 383b9d55c..62e09c339 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/UntitledTextFileWizard.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/UntitledTextFileWizard.java
@@ -42,9 +42,7 @@ public class UntitledTextFileWizard extends Wizard implements INewWizard {
public UntitledTextFileWizard() {
}
- /*
- * @see org.eclipse.ui.IWorkbenchWindowActionDelegate#dispose()
- */
+ @Override
public void dispose() {
fWindow= null;
}
@@ -68,9 +66,7 @@ public class UntitledTextFileWizard extends Wizard implements INewWizard {
return new NonExistingFileEditorInput(fileStore, TextEditorMessages.NewTextEditorAction_namePrefix);
}
- /*
- * @see org.eclipse.jface.wizard.Wizard#performFinish()
- */
+ @Override
public boolean performFinish() {
IFileStore fileStore= queryFileStore();
IEditorInput input= createEditorInput(fileStore);
@@ -85,9 +81,7 @@ public class UntitledTextFileWizard extends Wizard implements INewWizard {
return true;
}
- /*
- * @see org.eclipse.ui.IWorkbenchWizard#init(org.eclipse.ui.IWorkbench, org.eclipse.jface.viewers.IStructuredSelection)
- */
+ @Override
public void init(IWorkbench workbench, IStructuredSelection selection) {
fWindow= workbench.getActiveWorkbenchWindow();
}
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/WorkspaceOperationRunner.java b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/WorkspaceOperationRunner.java
index 8b1a7f5d0..514a066d9 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/WorkspaceOperationRunner.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/editors/text/WorkspaceOperationRunner.java
@@ -57,9 +57,7 @@ public class WorkspaceOperationRunner implements IRunnableContext {
return fProgressMonitor;
}
- /*
- * @see org.eclipse.jface.operation.IRunnableContext#run(boolean, boolean, org.eclipse.jface.operation.IRunnableWithProgress)
- */
+ @Override
public void run(boolean fork, boolean cancelable, IRunnableWithProgress runnable) throws InvocationTargetException, InterruptedException {
if (runnable instanceof ISchedulingRuleProvider)
run(runnable, ((ISchedulingRuleProvider)runnable).getSchedulingRule());
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/texteditor/AnnotationColumn.java b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/texteditor/AnnotationColumn.java
index 54efed5e8..06c344b6e 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/texteditor/AnnotationColumn.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/texteditor/AnnotationColumn.java
@@ -62,53 +62,39 @@ public class AnnotationColumn extends AbstractContributedRulerColumn implements
private final MarkerAnnotationPreferences fAnnotationPreferences= EditorsPlugin.getDefault().getMarkerAnnotationPreferences();
private IPropertyChangeListener fPropertyListener;
- /*
- * @see org.eclipse.jface.text.source.IVerticalRulerColumn#createControl(org.eclipse.jface.text.source.CompositeRuler, org.eclipse.swt.widgets.Composite)
- */
+ @Override
public Control createControl(CompositeRuler parentRuler, Composite parentControl) {
initialize();
Control control= fDelegate.createControl(parentRuler, parentControl);
return control;
}
- /*
- * @see org.eclipse.jface.text.source.IVerticalRulerColumn#getControl()
- */
+ @Override
public Control getControl() {
return fDelegate.getControl();
}
- /*
- * @see org.eclipse.jface.text.source.IVerticalRulerColumn#getWidth()
- */
+ @Override
public int getWidth() {
return fDelegate.getWidth();
}
- /*
- * @see org.eclipse.jface.text.source.IVerticalRulerColumn#redraw()
- */
+ @Override
public void redraw() {
fDelegate.redraw();
}
- /*
- * @see org.eclipse.jface.text.source.IVerticalRulerColumn#setFont(org.eclipse.swt.graphics.Font)
- */
+ @Override
public void setFont(Font font) {
fDelegate.setFont(font);
}
- /*
- * @see org.eclipse.jface.text.source.IVerticalRulerColumn#setModel(org.eclipse.jface.text.source.IAnnotationModel)
- */
+ @Override
public void setModel(IAnnotationModel model) {
fDelegate.setModel(model);
}
- /*
- * @see org.eclipse.ui.texteditor.rulers.AbstractContributedRulerColumn#columnRemoved()
- */
+ @Override
public void columnRemoved() {
if (fPropertyListener != null) {
IPreferenceStore store= getPreferenceStore();
@@ -141,6 +127,7 @@ public class AnnotationColumn extends AbstractContributedRulerColumn implements
// link to preference store
fPropertyListener= new IPropertyChangeListener() {
+ @Override
public void propertyChange(PropertyChangeEvent event) {
String property= event.getProperty();
AnnotationPreference annotationPreference= getVerticalRulerAnnotationPreference(property);
@@ -193,52 +180,40 @@ public class AnnotationColumn extends AbstractContributedRulerColumn implements
fDelegate= column;
}
- /*
- * @see org.eclipse.jface.text.source.IVerticalRulerInfoExtension#addVerticalRulerListener(org.eclipse.jface.text.source.IVerticalRulerListener)
- */
+ @Override
public void addVerticalRulerListener(IVerticalRulerListener listener) {
if (fDelegate instanceof IVerticalRulerInfoExtension)
((IVerticalRulerInfoExtension) fDelegate).addVerticalRulerListener(listener);
}
- /*
- * @see org.eclipse.jface.text.source.IVerticalRulerInfoExtension#getHover()
- */
+ @Override
public IAnnotationHover getHover() {
if (fDelegate instanceof IVerticalRulerInfoExtension)
return ((IVerticalRulerInfoExtension) fDelegate).getHover();
return null;
}
- /*
- * @see org.eclipse.jface.text.source.IVerticalRulerInfoExtension#getModel()
- */
+ @Override
public IAnnotationModel getModel() {
if (fDelegate instanceof IVerticalRulerInfoExtension)
return ((IVerticalRulerInfoExtension) fDelegate).getModel();
return null;
}
- /*
- * @see org.eclipse.jface.text.source.IVerticalRulerInfoExtension#removeVerticalRulerListener(org.eclipse.jface.text.source.IVerticalRulerListener)
- */
+ @Override
public void removeVerticalRulerListener(IVerticalRulerListener listener) {
if (fDelegate instanceof IVerticalRulerInfoExtension)
((IVerticalRulerInfoExtension) fDelegate).removeVerticalRulerListener(listener);
}
- /*
- * @see org.eclipse.jface.text.source.IVerticalRulerInfo#getLineOfLastMouseButtonActivity()
- */
+ @Override
public int getLineOfLastMouseButtonActivity() {
if (fDelegate instanceof IVerticalRulerInfo)
return ((IVerticalRulerInfo)fDelegate).getLineOfLastMouseButtonActivity();
return -1;
}
- /*
- * @see org.eclipse.jface.text.source.IVerticalRulerInfo#toDocumentLineNumber(int)
- */
+ @Override
public int toDocumentLineNumber(int y_coordinate) {
if (fDelegate instanceof IVerticalRulerInfo)
return ((IVerticalRulerInfo)fDelegate).toDocumentLineNumber(y_coordinate);
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/texteditor/BooleanPreferenceToggleAction.java b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/texteditor/BooleanPreferenceToggleAction.java
index 34fe82ed2..b2476835d 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/texteditor/BooleanPreferenceToggleAction.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/texteditor/BooleanPreferenceToggleAction.java
@@ -38,16 +38,12 @@ public class BooleanPreferenceToggleAction extends ResourceAction implements IUp
update();
}
- /*
- * @see org.eclipse.ui.texteditor.IUpdate#update()
- */
+ @Override
public void update() {
setChecked(fPreferences.getBoolean(fKey));
}
- /*
- * @see org.eclipse.jface.action.Action#run()
- */
+ @Override
public void run() {
boolean state= fPreferences.getBoolean(fKey);
fPreferences.setValue(fKey, !state);
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/texteditor/DelegatingAnnotationPreference.java b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/texteditor/DelegatingAnnotationPreference.java
index f986d4f46..85efcfb30 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/texteditor/DelegatingAnnotationPreference.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/texteditor/DelegatingAnnotationPreference.java
@@ -76,23 +76,17 @@ public class DelegatingAnnotationPreference extends AnnotationPreference {
return false;
}
- /*
- * @see org.eclipse.ui.texteditor.AnnotationPreference#getAnnotationType()
- */
+ @Override
public Object getAnnotationType() {
return fType.getType();
}
- /*
- * @see org.eclipse.ui.texteditor.AnnotationPreference#contributesToHeader()
- */
+ @Override
public boolean contributesToHeader() {
return getBooleanAttributeValue(HEADER_VALUE);
}
- /*
- * @see org.eclipse.ui.texteditor.AnnotationPreference#getAnnotationImageProvider()
- */
+ @Override
public IAnnotationImageProvider getAnnotationImageProvider() {
if (!isCached(IMAGE_PROVIDER)) {
AnnotationPreference preference= getDefiningPreference(IMAGE_PROVIDER);
@@ -106,86 +100,62 @@ public class DelegatingAnnotationPreference extends AnnotationPreference {
return super.getAnnotationImageProvider();
}
- /*
- * @see org.eclipse.ui.texteditor.AnnotationPreference#getColorPreferenceKey()
- */
+ @Override
public String getColorPreferenceKey() {
return (String) getAttributeValue(COLOR_PREFERENCE_KEY);
}
- /*
- * @see org.eclipse.ui.texteditor.AnnotationPreference#getColorPreferenceValue()
- */
+ @Override
public RGB getColorPreferenceValue() {
return (RGB) getAttributeValue(COLOR_PREFERENCE_VALUE);
}
- /*
- * @see org.eclipse.ui.texteditor.AnnotationPreference#getHighlightPreferenceKey()
- */
+ @Override
public String getHighlightPreferenceKey() {
return (String) getAttributeValue(HIGHLIGHT_PREFERENCE_KEY);
}
- /*
- * @see org.eclipse.ui.texteditor.AnnotationPreference#getHighlightPreferenceValue()
- */
+ @Override
public boolean getHighlightPreferenceValue() {
return getBooleanAttributeValue(HIGHLIGHT_PREFERENCE_VALUE);
}
- /*
- * @see org.eclipse.ui.texteditor.AnnotationPreference#getImageDescriptor()
- */
+ @Override
public ImageDescriptor getImageDescriptor() {
return (ImageDescriptor) getAttributeValue(IMAGE_DESCRIPTOR);
}
- /*
- * @see org.eclipse.ui.texteditor.AnnotationPreference#getQuickFixImageDescriptor()
- */
+ @Override
public ImageDescriptor getQuickFixImageDescriptor() {
return (ImageDescriptor) getAttributeValue(QUICK_FIX_IMAGE_DESCRIPTOR);
}
- /*
- * @see org.eclipse.ui.texteditor.AnnotationPreference#getIsGoToNextNavigationTargetKey()
- */
+ @Override
public String getIsGoToNextNavigationTargetKey() {
return (String) getAttributeValue(IS_GO_TO_NEXT_TARGET_KEY);
}
- /*
- * @see org.eclipse.ui.texteditor.AnnotationPreference#getIsGoToPreviousNavigationTargetKey()
- */
+ @Override
public String getIsGoToPreviousNavigationTargetKey() {
return (String) getAttributeValue(IS_GO_TO_PREVIOUS_TARGET_KEY);
}
- /*
- * @see org.eclipse.ui.texteditor.AnnotationPreference#getOverviewRulerPreferenceKey()
- */
+ @Override
public String getOverviewRulerPreferenceKey() {
return (String) getAttributeValue(OVERVIEW_RULER_PREFERENCE_KEY);
}
- /*
- * @see org.eclipse.ui.texteditor.AnnotationPreference#getOverviewRulerPreferenceValue()
- */
+ @Override
public boolean getOverviewRulerPreferenceValue() {
return getBooleanAttributeValue(OVERVIEW_RULER_PREFERENCE_VALUE);
}
- /*
- * @see org.eclipse.ui.texteditor.AnnotationPreference#getPreferenceLabel()
- */
+ @Override
public String getPreferenceLabel() {
return (String) getAttributeValue(PREFERENCE_LABEL);
}
- /*
- * @see org.eclipse.ui.texteditor.AnnotationPreference#getPresentationLayer()
- */
+ @Override
public int getPresentationLayer() {
Object value= getAttributeValue(PRESENTATION_LAYER);
if (value instanceof Integer)
@@ -193,89 +163,62 @@ public class DelegatingAnnotationPreference extends AnnotationPreference {
return IAnnotationAccessExtension.DEFAULT_LAYER;
}
- /*
- * @see org.eclipse.ui.texteditor.AnnotationPreference#getShowInNextPrevDropdownToolbarActionKey()
- */
+ @Override
public String getShowInNextPrevDropdownToolbarActionKey() {
return (String) getAttributeValue(SHOW_IN_NAVIGATION_DROPDOWN_KEY);
}
- /*
- * @see org.eclipse.ui.texteditor.AnnotationPreference#getSymbolicImageName()
- */
+ @Override
public String getSymbolicImageName() {
return (String) getAttributeValue(SYMBOLIC_IMAGE_NAME);
}
- /*
- * @see org.eclipse.ui.texteditor.AnnotationPreference#getTextPreferenceKey()
- */
+ @Override
public String getTextPreferenceKey() {
return (String) getAttributeValue(TEXT_PREFERENCE_KEY);
}
- /*
- * @see org.eclipse.ui.texteditor.AnnotationPreference#getTextPreferenceValue()
- */
+ @Override
public boolean getTextPreferenceValue() {
return getBooleanAttributeValue(TEXT_PREFERENCE_VALUE);
}
- /*
- * @see org.eclipse.ui.texteditor.AnnotationPreference#getVerticalRulerPreferenceKey()
- */
+ @Override
public String getVerticalRulerPreferenceKey() {
return (String) getAttributeValue(VERTICAL_RULER_PREFERENCE_KEY);
}
- /*
- * @see org.eclipse.ui.texteditor.AnnotationPreference#getVerticalRulerPreferenceValue()
- */
+ @Override
public boolean getVerticalRulerPreferenceValue() {
return getBooleanAttributeValue(VERTICAL_RULER_PREFERENCE_VALUE);
}
- /*
- * @see org.eclipse.ui.texteditor.AnnotationPreference#isGoToNextNavigationTarget()
- */
+ @Override
public boolean isGoToNextNavigationTarget() {
return getBooleanAttributeValue(IS_GO_TO_NEXT_TARGET_VALUE);
}
- /*
- * @see org.eclipse.ui.texteditor.AnnotationPreference#isGoToPreviousNavigationTarget()
- */
+ @Override
public boolean isGoToPreviousNavigationTarget() {
return getBooleanAttributeValue(IS_GO_TO_PREVIOUS_TARGET_VALUE);
}
- /*
- * @see org.eclipse.ui.texteditor.AnnotationPreference#isShowInNextPrevDropdownToolbarAction()
- */
+ @Override
public boolean isShowInNextPrevDropdownToolbarAction() {
return getBooleanAttributeValue(SHOW_IN_NAVIGATION_DROPDOWN_VALUE);
}
- /*
- * @see org.eclipse.ui.texteditor.AnnotationPreference#getTextStylePreferenceKey()
- * @since 3.8
- */
+ @Override
public String getTextStylePreferenceKey() {
return (String)getAttributeValue(TEXT_STYLE_PREFERENCE_KEY);
}
- /*
- * @see org.eclipse.ui.texteditor.AnnotationPreference#getTextStyleValue()
- * @since 3.8
- */
+ @Override
public String getTextStyleValue() {
return (String)getAttributeValue(TEXT_STYLE_PREFERENCE_VALUE);
}
- /*
- * @see org.eclipse.ui.texteditor.AnnotationPreference#getValue(java.lang.Object)
- * @since 3.8
- */
+ @Override
public Object getValue(Object attribute) {
return getAttributeValue(attribute);
}
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/texteditor/LineNumberColumn.java b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/texteditor/LineNumberColumn.java
index 90e0aabbd..f639325d1 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/texteditor/LineNumberColumn.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/texteditor/LineNumberColumn.java
@@ -113,9 +113,7 @@ public class LineNumberColumn extends AbstractContributedRulerColumn implements
private ISourceViewer fViewer;
private ICompatibilityForwarder fForwarder;
- /*
- * @see org.eclipse.jface.text.source.IVerticalRulerColumn#createControl(org.eclipse.jface.text.source.CompositeRuler, org.eclipse.swt.widgets.Composite)
- */
+ @Override
public Control createControl(CompositeRuler parentRuler, Composite parentControl) {
Assert.isTrue(fDelegate != null);
ITextViewer viewer= parentRuler.getTextViewer();
@@ -126,97 +124,73 @@ public class LineNumberColumn extends AbstractContributedRulerColumn implements
return control;
}
- /*
- * @see org.eclipse.jface.text.source.IVerticalRulerColumn#getControl()
- */
+ @Override
public Control getControl() {
return fDelegate.getControl();
}
- /*
- * @see org.eclipse.jface.text.source.IVerticalRulerColumn#getWidth()
- */
+ @Override
public int getWidth() {
return fDelegate.getWidth();
}
- /*
- * @see org.eclipse.jface.text.source.IVerticalRulerColumn#redraw()
- */
+ @Override
public void redraw() {
fDelegate.redraw();
}
- /*
- * @see org.eclipse.jface.text.source.IVerticalRulerColumn#setFont(org.eclipse.swt.graphics.Font)
- */
+ @Override
public void setFont(Font font) {
fDelegate.setFont(font);
}
- /*
- * @see org.eclipse.jface.text.source.IVerticalRulerColumn#setModel(org.eclipse.jface.text.source.IAnnotationModel)
- */
+ @Override
public void setModel(IAnnotationModel model) {
if (getQuickDiffPreference())
fDelegate.setModel(model);
}
- /*
- * @see org.eclipse.jface.text.source.IVerticalRulerInfo#getLineOfLastMouseButtonActivity()
- */
+ @Override
public int getLineOfLastMouseButtonActivity() {
if (fDelegate instanceof IVerticalRulerInfo)
return ((IVerticalRulerInfo)fDelegate).getLineOfLastMouseButtonActivity();
return -1;
}
- /*
- * @see org.eclipse.jface.text.source.IVerticalRulerInfo#toDocumentLineNumber(int)
- */
+ @Override
public int toDocumentLineNumber(int y_coordinate) {
if (fDelegate instanceof IVerticalRulerInfo)
return ((IVerticalRulerInfo)fDelegate).toDocumentLineNumber(y_coordinate);
return -1;
}
- /*
- * @see org.eclipse.jface.text.source.IVerticalRulerInfoExtension#addVerticalRulerListener(org.eclipse.jface.text.source.IVerticalRulerListener)
- */
+ @Override
public void addVerticalRulerListener(IVerticalRulerListener listener) {
if (fDelegate instanceof IVerticalRulerInfoExtension)
((IVerticalRulerInfoExtension) fDelegate).addVerticalRulerListener(listener);
}
- /*
- * @see org.eclipse.jface.text.source.IVerticalRulerInfoExtension#getHover()
- */
+ @Override
public IAnnotationHover getHover() {
if (fDelegate instanceof IVerticalRulerInfoExtension)
return ((IVerticalRulerInfoExtension) fDelegate).getHover();
return null;
}
- /*
- * @see org.eclipse.jface.text.source.IVerticalRulerInfoExtension#getModel()
- */
+ @Override
public IAnnotationModel getModel() {
if (fDelegate instanceof IVerticalRulerInfoExtension)
return ((IVerticalRulerInfoExtension) fDelegate).getModel();
return null;
}
- /*
- * @see org.eclipse.jface.text.source.IVerticalRulerInfoExtension#removeVerticalRulerListener(org.eclipse.jface.text.source.IVerticalRulerListener)
- */
+ @Override
public void removeVerticalRulerListener(IVerticalRulerListener listener) {
if (fDelegate instanceof IVerticalRulerInfoExtension)
((IVerticalRulerInfoExtension) fDelegate).removeVerticalRulerListener(listener);
}
- /*
- * @see org.eclipse.ui.texteditor.rulers.AbstractContributedRulerColumn#columnRemoved()
- */
+ @Override
public void columnRemoved() {
if (fDispatcher != null) {
fDispatcher.dispose();
@@ -265,12 +239,14 @@ public class LineNumberColumn extends AbstractContributedRulerColumn implements
fDispatcher= new PropertyEventDispatcher(store);
fDispatcher.addPropertyChangeListener(FG_COLOR_KEY, new IPropertyChangeListener() {
+ @Override
public void propertyChange(PropertyChangeEvent event) {
updateForegroundColor(store, fDelegate);
fDelegate.redraw();
}
});
IPropertyChangeListener backgroundHandler= new IPropertyChangeListener() {
+ @Override
public void propertyChange(PropertyChangeEvent event) {
updateBackgroundColor(store, fDelegate);
fDelegate.redraw();
@@ -280,6 +256,7 @@ public class LineNumberColumn extends AbstractContributedRulerColumn implements
fDispatcher.addPropertyChangeListener(USE_DEFAULT_BG_KEY, backgroundHandler);
fDispatcher.addPropertyChangeListener(LINE_NUMBER_KEY, new IPropertyChangeListener() {
+ @Override
public void propertyChange(PropertyChangeEvent event) {
// only handle quick diff on/off information, but not ruler visibility (handled by AbstractDecoratedTextEditor)
updateLineNumbersVisibility(fDelegate);
@@ -287,30 +264,35 @@ public class LineNumberColumn extends AbstractContributedRulerColumn implements
});
fDispatcher.addPropertyChangeListener(AbstractDecoratedTextEditorPreferenceConstants.QUICK_DIFF_CHARACTER_MODE, new IPropertyChangeListener() {
+ @Override
public void propertyChange(PropertyChangeEvent event) {
updateCharacterMode(store, fDelegate);
}
});
fDispatcher.addPropertyChangeListener(AbstractDecoratedTextEditorPreferenceConstants.REVISION_RULER_RENDERING_MODE, new IPropertyChangeListener() {
+ @Override
public void propertyChange(PropertyChangeEvent event) {
updateRevisionRenderingMode(store, fDelegate);
}
});
fDispatcher.addPropertyChangeListener(AbstractDecoratedTextEditorPreferenceConstants.REVISION_RULER_SHOW_AUTHOR, new IPropertyChangeListener() {
+ @Override
public void propertyChange(PropertyChangeEvent event) {
updateRevisionAuthorVisibility(store, fDelegate);
}
});
fDispatcher.addPropertyChangeListener(AbstractDecoratedTextEditorPreferenceConstants.REVISION_RULER_SHOW_REVISION, new IPropertyChangeListener() {
+ @Override
public void propertyChange(PropertyChangeEvent event) {
updateRevisionIdVisibility(store, fDelegate);
}
});
fDispatcher.addPropertyChangeListener(AbstractDecoratedTextEditorPreferenceConstants.QUICK_DIFF_ALWAYS_ON, new IPropertyChangeListener() {
+ @Override
public void propertyChange(PropertyChangeEvent event) {
updateQuickDiffVisibility(fDelegate);
}
@@ -318,6 +300,7 @@ public class LineNumberColumn extends AbstractContributedRulerColumn implements
if (changedPref != null) {
fDispatcher.addPropertyChangeListener(changedPref.getColorPreferenceKey(), new IPropertyChangeListener() {
+ @Override
public void propertyChange(PropertyChangeEvent event) {
updateChangedColor(changedPref, store, fDelegate);
fDelegate.redraw();
@@ -326,6 +309,7 @@ public class LineNumberColumn extends AbstractContributedRulerColumn implements
}
if (addedPref != null) {
fDispatcher.addPropertyChangeListener(addedPref.getColorPreferenceKey(), new IPropertyChangeListener() {
+ @Override
public void propertyChange(PropertyChangeEvent event) {
updateAddedColor(addedPref, store, fDelegate);
fDelegate.redraw();
@@ -334,6 +318,7 @@ public class LineNumberColumn extends AbstractContributedRulerColumn implements
}
if (deletedPref != null) {
fDispatcher.addPropertyChangeListener(deletedPref.getColorPreferenceKey(), new IPropertyChangeListener() {
+ @Override
public void propertyChange(PropertyChangeEvent event) {
updateDeletedColor(deletedPref, store, fDelegate);
fDelegate.redraw();
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/texteditor/PropertyEventDispatcher.java b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/texteditor/PropertyEventDispatcher.java
index a035895b6..35f49ff81 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/texteditor/PropertyEventDispatcher.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/texteditor/PropertyEventDispatcher.java
@@ -27,6 +27,7 @@ public final class PropertyEventDispatcher {
private final Map fReverseMap= new HashMap();
private final IPreferenceStore fStore;
private final IPropertyChangeListener fListener= new IPropertyChangeListener() {
+ @Override
public void propertyChange(PropertyChangeEvent event) {
firePropertyChange(event);
}
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/texteditor/SourceViewerInformationControl.java b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/texteditor/SourceViewerInformationControl.java
index e0dee289f..d298c3afb 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/texteditor/SourceViewerInformationControl.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/texteditor/SourceViewerInformationControl.java
@@ -149,11 +149,13 @@ class SourceViewerInformationControl implements IInformationControl, IInformatio
fText.addKeyListener(new KeyListener() {
+ @Override
public void keyPressed(KeyEvent e) {
if (e.character == 0x1B) // ESC
fShell.dispose();
}
+ @Override
public void keyReleased(KeyEvent e) {}
});
@@ -221,9 +223,7 @@ class SourceViewerInformationControl implements IInformationControl, IInformatio
setInformation(null);
}
- /*
- * @see IInformationControl#setInformation(String)
- */
+ @Override
public void setInformation(String content) {
if (content == null) {
fViewer.setInput(null);
@@ -239,16 +239,12 @@ class SourceViewerInformationControl implements IInformationControl, IInformatio
fViewer.getTextWidget().setHorizontalPixel(fHorizontalScrollPixel);
}
- /*
- * @see IInformationControl#setVisible(boolean)
- */
+ @Override
public void setVisible(boolean visible) {
fShell.setVisible(visible);
}
- /*
- * @see org.eclipse.swt.events.DisposeListener#widgetDisposed(org.eclipse.swt.events.DisposeEvent)
- */
+ @Override
public void widgetDisposed(DisposeEvent event) {
if (fStatusTextFont != null && !fStatusTextFont.isDisposed())
fStatusTextFont.dispose();
@@ -262,9 +258,7 @@ class SourceViewerInformationControl implements IInformationControl, IInformatio
fText= null;
}
- /*
- * @see org.eclipse.jface.text.IInformationControl#dispose()
- */
+ @Override
public final void dispose() {
if (fShell != null && !fShell.isDisposed())
fShell.dispose();
@@ -272,9 +266,7 @@ class SourceViewerInformationControl implements IInformationControl, IInformatio
widgetDisposed(null);
}
- /*
- * @see IInformationControl#setSize(int, int)
- */
+ @Override
public void setSize(int width, int height) {
if (fStatusField != null) {
@@ -289,24 +281,18 @@ class SourceViewerInformationControl implements IInformationControl, IInformatio
fShell.pack(true);
}
- /*
- * @see IInformationControl#setLocation(Point)
- */
+ @Override
public void setLocation(Point location) {
fShell.setLocation(location);
}
- /*
- * @see IInformationControl#setSizeConstraints(int, int)
- */
+ @Override
public void setSizeConstraints(int maxWidth, int maxHeight) {
fMaxWidth= maxWidth;
fMaxHeight= maxHeight;
}
- /*
- * @see IInformationControl#computeSizeHint()
- */
+ @Override
public Point computeSizeHint() {
// compute the preferred size
int x= SWT.DEFAULT;
@@ -324,66 +310,48 @@ class SourceViewerInformationControl implements IInformationControl, IInformatio
return size;
}
- /*
- * @see IInformationControl#addDisposeListener(DisposeListener)
- */
+ @Override
public void addDisposeListener(DisposeListener listener) {
fShell.addDisposeListener(listener);
}
- /*
- * @see IInformationControl#removeDisposeListener(DisposeListener)
- */
+ @Override
public void removeDisposeListener(DisposeListener listener) {
fShell.removeDisposeListener(listener);
}
- /*
- * @see IInformationControl#setForegroundColor(Color)
- */
+ @Override
public void setForegroundColor(Color foreground) {
fText.setForeground(foreground);
}
- /*
- * @see IInformationControl#setBackgroundColor(Color)
- */
+ @Override
public void setBackgroundColor(Color background) {
fText.setBackground(background);
}
- /*
- * @see IInformationControl#isFocusControl()
- */
+ @Override
public boolean isFocusControl() {
return fShell.getDisplay().getActiveShell() == fShell;
}
- /*
- * @see IInformationControl#setFocus()
- */
+ @Override
public void setFocus() {
fShell.forceFocus();
fText.setFocus();
}
- /*
- * @see IInformationControl#addFocusListener(FocusListener)
- */
+ @Override
public void addFocusListener(FocusListener listener) {
fText.addFocusListener(listener);
}
- /*
- * @see IInformationControl#removeFocusListener(FocusListener)
- */
+ @Override
public void removeFocusListener(FocusListener listener) {
fText.removeFocusListener(listener);
}
- /*
- * @see IInformationControlExtension#hasContents()
- */
+ @Override
public boolean hasContents() {
return fText.getCharCount() > 0;
}
@@ -440,10 +408,7 @@ class SourceViewerInformationControl implements IInformationControl, IInformatio
}
- /*
- * @see org.eclipse.jface.text.IInformationControlExtension3#computeTrim()
- * @since 3.4
- */
+ @Override
public Rectangle computeTrim() {
Rectangle trim= fShell.computeTrim(0, 0, 0, 0);
addInternalTrim(trim);
@@ -463,46 +428,32 @@ class SourceViewerInformationControl implements IInformationControl, IInformatio
}
}
- /*
- * @see org.eclipse.jface.text.IInformationControlExtension3#getBounds()
- * @since 3.4
- */
+ @Override
public Rectangle getBounds() {
return fShell.getBounds();
}
- /*
- * @see org.eclipse.jface.text.IInformationControlExtension3#restoresLocation()
- * @since 3.4
- */
+ @Override
public boolean restoresLocation() {
return false;
}
- /*
- * @see org.eclipse.jface.text.IInformationControlExtension3#restoresSize()
- * @since 3.4
- */
+ @Override
public boolean restoresSize() {
return false;
}
- /*
- * @see org.eclipse.jface.text.IInformationControlExtension5#getInformationPresenterControlCreator()
- * @since 3.4
- */
+ @Override
public IInformationControlCreator getInformationPresenterControlCreator() {
return new IInformationControlCreator() {
+ @Override
public IInformationControl createInformationControl(Shell parent) {
return new SourceViewerInformationControl(parent, true, fSymbolicFontName, null);
}
};
}
- /*
- * @see org.eclipse.jface.text.IInformationControlExtension5#containsControl(org.eclipse.swt.widgets.Control)
- * @since 3.4
- */
+ @Override
public boolean containsControl(Control control) {
do {
if (control == fShell)
@@ -514,18 +465,12 @@ class SourceViewerInformationControl implements IInformationControl, IInformatio
return false;
}
- /*
- * @see org.eclipse.jface.text.IInformationControlExtension5#isVisible()
- * @since 3.4
- */
+ @Override
public boolean isVisible() {
return fShell != null && !fShell.isDisposed() && fShell.isVisible();
}
- /*
- * @see org.eclipse.jface.text.IInformationControlExtension5#computeSizeConstraints(int, int)
- * @since 3.4
- */
+ @Override
public Point computeSizeConstraints(int widthInChars, int heightInChars) {
GC gc= new GC(fText);
gc.setFont(fTextFont);
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/texteditor/TextChangeHover.java b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/texteditor/TextChangeHover.java
index b5b5190e3..fc1a190c6 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/internal/texteditor/TextChangeHover.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/internal/texteditor/TextChangeHover.java
@@ -34,26 +34,21 @@ public class TextChangeHover extends LineChangeHover {
/** The last created information control. */
private int fLastScrollIndex= 0;
- /*
- * @see org.eclipse.jface.text.source.LineChangeHover#getTabReplacement()
- */
+ @Override
protected String getTabReplacement() {
return Character.toString('\t');
}
- /*
- * @see org.eclipse.jface.text.source.LineChangeHover#getHoverInfo(org.eclipse.jface.text.source.ISourceViewer, org.eclipse.jface.text.source.ILineRange, int)
- */
+ @Override
public Object getHoverInfo(ISourceViewer sourceViewer, ILineRange lineRange, int visibleLines) {
fLastScrollIndex= sourceViewer.getTextWidget().getHorizontalPixel();
return super.getHoverInfo(sourceViewer, lineRange, visibleLines);
}
- /*
- * @see org.eclipse.jface.text.source.IAnnotationHoverExtension#getHoverControlCreator()
- */
+ @Override
public IInformationControlCreator getHoverControlCreator() {
return new IInformationControlCreator() {
+ @Override
public IInformationControl createInformationControl(Shell parent) {
SourceViewerInformationControl control= new SourceViewerInformationControl(parent, false, JFaceResources.TEXT_FONT, EditorsUI.getTooltipAffordanceString());
control.setHorizontalScrollPixel(fLastScrollIndex);
@@ -62,12 +57,10 @@ public class TextChangeHover extends LineChangeHover {
};
}
- /*
- * @see org.eclipse.jface.text.information.IInformationProviderExtension2#getInformationPresenterControlCreator()
- * @since 3.3
- */
+ @Override
public IInformationControlCreator getInformationPresenterControlCreator() {
return new IInformationControlCreator() {
+ @Override
public IInformationControl createInformationControl(Shell parent) {
return new SourceViewerInformationControl(parent, true, JFaceResources.TEXT_FONT, null);
}
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/AbstractDecoratedTextEditor.java b/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/AbstractDecoratedTextEditor.java
index f8cf4a605..8b2775ffb 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/AbstractDecoratedTextEditor.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/AbstractDecoratedTextEditor.java
@@ -226,6 +226,7 @@ public abstract class AbstractDecoratedTextEditor extends StatusTextEditor {
* Adapter class for <code>IGotoMarker</code>.
*/
private class GotoMarkerAdapter implements IGotoMarker {
+ @Override
public void gotoMarker(IMarker marker) {
AbstractDecoratedTextEditor.this.gotoMarker(marker);
}
@@ -361,9 +362,7 @@ public abstract class AbstractDecoratedTextEditor extends StatusTextEditor {
setKeyBindingScopes(new String[] { "org.eclipse.ui.textEditorScope" }); //$NON-NLS-1$
}
- /*
- * @see IWorkbenchPart#dispose()
- */
+ @Override
public void dispose() {
if (fSourceViewerDecorationSupport != null) {
fSourceViewerDecorationSupport.dispose();
@@ -383,9 +382,7 @@ public abstract class AbstractDecoratedTextEditor extends StatusTextEditor {
super.dispose();
}
- /*
- * @see org.eclipse.ui.texteditor.AbstractTextEditor#createSourceViewer(Composite, IVerticalRuler, int)
- */
+ @Override
protected ISourceViewer createSourceViewer(Composite parent, IVerticalRuler ruler, int styles) {
fAnnotationAccess= getAnnotationAccess();
@@ -443,6 +440,7 @@ public abstract class AbstractDecoratedTextEditor extends StatusTextEditor {
/*
* @see org.eclipse.ui.texteditor.AbstractTextEditor.createPartControl(Composite)
*/
+ @Override
public void createPartControl(Composite parent) {
super.createPartControl(parent);
if (fSourceViewerDecorationSupport != null)
@@ -501,13 +499,11 @@ public abstract class AbstractDecoratedTextEditor extends StatusTextEditor {
getEditorSite().registerContextMenu(fOverviewRulerContextMenuId, menuManager, getSelectionProvider(), false);
}
- /*
- * @see org.eclipse.ui.texteditor.AbstractTextEditor#createContextMenuListener()
- * @since 3.4
- */
+ @Override
protected IMenuListener createContextMenuListener() {
final IMenuListener superListener= super.createContextMenuListener();
return new IMenuListener() {
+ @Override
public void menuAboutToShow(IMenuManager menu) {
if (!getOverviewRulerContextMenuId().equals(menu.getId())) {
superListener.menuAboutToShow(menu);
@@ -519,10 +515,7 @@ public abstract class AbstractDecoratedTextEditor extends StatusTextEditor {
};
}
- /*
- * @see org.eclipse.ui.texteditor.StatusTextEditor#createStatusControl(org.eclipse.swt.widgets.Composite, org.eclipse.core.runtime.IStatus)
- * @since 3.1
- */
+ @Override
protected Control createStatusControl(Composite parent, final IStatus status) {
Object adapter= getAdapter(IEncodingSupport.class);
DefaultEncodingSupport encodingSupport= null;
@@ -566,9 +559,7 @@ public abstract class AbstractDecoratedTextEditor extends StatusTextEditor {
return store != null ? store.getBoolean(OVERVIEW_RULER) : false;
}
- /*
- * @see org.eclipse.ui.texteditor.ITextEditorExtension3#showChangeInformation(boolean)
- */
+ @Override
public void showChangeInformation(boolean show) {
if (show == isChangeInformationShowing())
return;
@@ -586,17 +577,12 @@ public abstract class AbstractDecoratedTextEditor extends StatusTextEditor {
}
}
- /*
- * @see org.eclipse.ui.texteditor.ITextEditorExtension3#isChangeInformationShowing()
- */
+ @Override
public boolean isChangeInformationShowing() {
return fLineColumn != null && fLineColumn.isShowingChangeInformation();
}
- /*
- * @see org.eclipse.ui.texteditor.ITextEditorExtension4#showRevisionInformation(org.eclipse.jface.text.revisions.RevisionInformation, java.lang.String)
- * @since 3.2
- */
+ @Override
public void showRevisionInformation(RevisionInformation info, String quickDiffProviderId) {
if (info.getHoverControlCreator() == null)
info.setHoverControlCreator(new RevisionHoverInformationControlCreator(false));
@@ -716,6 +702,7 @@ public abstract class AbstractDecoratedTextEditor extends StatusTextEditor {
* @return a new change ruler column
* @deprecated as of 3.3. Not called any longer, replaced by {@link #createLineNumberRulerColumn()}
*/
+ @Deprecated
protected IChangeRulerColumn createChangeRulerColumn() {
/*
* Left for compatibility. See LineNumberColumn.
@@ -733,6 +720,7 @@ public abstract class AbstractDecoratedTextEditor extends StatusTextEditor {
*
* @see AbstractTextEditor#createVerticalRuler()
*/
+ @Override
protected IVerticalRuler createVerticalRuler() {
return createCompositeRuler();
}
@@ -760,15 +748,10 @@ public abstract class AbstractDecoratedTextEditor extends StatusTextEditor {
return new AnnotationRulerColumn(VERTICAL_RULER_WIDTH, getAnnotationAccess());
}
- /*
- * @see org.eclipse.ui.texteditor.AbstractTextEditor#createColumnSupport()
- * @since 3.3
- */
+ @Override
protected final IColumnSupport createColumnSupport() {
return new ColumnSupport(this, RulerColumnRegistry.getDefault()) {
- /*
- * @see org.eclipse.ui.texteditor.rulers.ColumnSupport#initializeColumn(org.eclipse.ui.texteditor.rulers.AbstractContributedRulerColumn)
- */
+ @Override
protected void initializeColumn(IContributedRulerColumn column) {
super.initializeColumn(column);
RulerColumnDescriptor descriptor= column.getDescriptor();
@@ -779,12 +762,15 @@ public abstract class AbstractDecoratedTextEditor extends StatusTextEditor {
} else if (LineNumberColumn.ID.equals(descriptor.getId())) {
fLineColumn= ((LineNumberColumn) column);
fLineColumn.setForwarder(new LineNumberColumn.ICompatibilityForwarder() {
+ @Override
public IVerticalRulerColumn createLineNumberRulerColumn() {
return AbstractDecoratedTextEditor.this.createLineNumberRulerColumn();
}
+ @Override
public boolean isQuickDiffEnabled() {
return AbstractDecoratedTextEditor.this.isPrefQuickDiffAlwaysOn();
}
+ @Override
public boolean isLineNumberRulerVisible() {
return AbstractDecoratedTextEditor.this.isLineNumberRulerVisible();
}
@@ -793,9 +779,7 @@ public abstract class AbstractDecoratedTextEditor extends StatusTextEditor {
}
}
- /*
- * @see org.eclipse.ui.texteditor.AbstractTextEditor.ColumnSupport#dispose()
- */
+ @Override
public void dispose() {
fLineColumn= null;
super.dispose();
@@ -803,9 +787,7 @@ public abstract class AbstractDecoratedTextEditor extends StatusTextEditor {
};
}
- /*
- * @see AbstractTextEditor#handlePreferenceStoreChanged(PropertyChangeEvent)
- */
+ @Override
protected void handlePreferenceStoreChanged(PropertyChangeEvent event) {
try {
@@ -993,6 +975,7 @@ public abstract class AbstractDecoratedTextEditor extends StatusTextEditor {
* @param marker the marker to go to
* @deprecated visibility will be reduced, use <code>getAdapter(IGotoMarker.class) for accessing this method</code>
*/
+ @Deprecated
public void gotoMarker(IMarker marker) {
if (fIsUpdatingMarkerViews)
return;
@@ -1049,20 +1032,14 @@ public abstract class AbstractDecoratedTextEditor extends StatusTextEditor {
}
}
- /*
- * @see org.eclipse.ui.texteditor.AbstractTextEditor#isEditable()
- * @since 3.3
- */
+ @Override
public boolean isEditable() {
if (!super.isEditable())
return false;
return fIsEditingDerivedFileAllowed;
}
- /*
- * @see org.eclipse.ui.texteditor.StatusTextEditor#validateEditorInputState()
- * @since 3.3
- */
+ @Override
public boolean validateEditorInputState() {
if (!super.validateEditorInputState())
return false;
@@ -1116,6 +1093,7 @@ public abstract class AbstractDecoratedTextEditor extends StatusTextEditor {
*
* @see org.eclipse.ui.texteditor.StatusTextEditor#isErrorStatus(org.eclipse.core.runtime.IStatus)
*/
+ @Override
protected boolean isErrorStatus(IStatus status) {
if (!super.isErrorStatus(status))
return false;
@@ -1144,9 +1122,7 @@ public abstract class AbstractDecoratedTextEditor extends StatusTextEditor {
return status.getCode() == IResourceStatus.READ_ONLY_LOCAL;
}
- /*
- * @see org.eclipse.ui.texteditor.AbstractTextEditor#createActions()
- */
+ @Override
protected void createActions() {
super.createActions();
@@ -1167,6 +1143,7 @@ public abstract class AbstractDecoratedTextEditor extends StatusTextEditor {
markAsPropertyDependentAction(ITextEditorActionConstants.CHANGE_ENCODING, true);
action= new ResourceAction(TextEditorMessages.getBundleForConstructedKeys(), "Editor.ToggleLineNumbersAction.", IAction.AS_CHECK_BOX) { //$NON-NLS-1$
+ @Override
public void run() {
toggleLineNumberRuler();
}
@@ -1175,6 +1152,7 @@ public abstract class AbstractDecoratedTextEditor extends StatusTextEditor {
setAction(ITextEditorActionConstants.LINENUMBERS_TOGGLE, action);
action= new ResourceAction(TextEditorMessages.getBundleForConstructedKeys(), "Editor.ToggleQuickDiffAction.", IAction.AS_CHECK_BOX) { //$NON-NLS-1$
+ @Override
public void run() {
toggleQuickDiffRuler();
}
@@ -1204,6 +1182,7 @@ public abstract class AbstractDecoratedTextEditor extends StatusTextEditor {
setAction(ITextEditorActionConstants.QUICKDIFF_REVERT, action2);
action= new ResourceAction(TextEditorMessages.getBundleForConstructedKeys(), "Editor.HideRevisionInformationAction.") { //$NON-NLS-1$
+ @Override
public void run() {
if (fLineColumn != null)
fLineColumn.hideRevisionInformation();
@@ -1212,6 +1191,7 @@ public abstract class AbstractDecoratedTextEditor extends StatusTextEditor {
setAction(ITextEditorActionConstants.REVISION_HIDE_INFO, action);
action= new ResourceAction(TextEditorMessages.getBundleForConstructedKeys(), "Editor.CycleRevisionRenderingAction.") { //$NON-NLS-1$
+ @Override
public void run() {
final RenderingMode[] modes= { IRevisionRulerColumnExtension.AGE, IRevisionRulerColumnExtension.AUTHOR, IRevisionRulerColumnExtension.AUTHOR_SHADED_BY_AGE};
IPreferenceStore store= EditorsUI.getPreferenceStore();
@@ -1243,6 +1223,7 @@ public abstract class AbstractDecoratedTextEditor extends StatusTextEditor {
else
shell= null;
action= new ResourceAction(TextEditorMessages.getBundleForConstructedKeys(), "Editor.RulerPreferencesAction.") { //$NON-NLS-1$
+ @Override
public void run() {
String[] preferencePages= collectRulerMenuPreferencePages();
if (preferencePages.length > 0 && (shell == null || !shell.isDisposed()))
@@ -1253,6 +1234,7 @@ public abstract class AbstractDecoratedTextEditor extends StatusTextEditor {
setAction(ITextEditorActionConstants.RULER_PREFERENCES, action);
action= new ResourceAction(TextEditorMessages.getBundleForConstructedKeys(), "Editor.ContextPreferencesAction.") { //$NON-NLS-1$
+ @Override
public void run() {
String[] preferencePages= collectContextMenuPreferencePages();
if (preferencePages.length > 0 && (shell == null || !shell.isDisposed()))
@@ -1273,6 +1255,7 @@ public abstract class AbstractDecoratedTextEditor extends StatusTextEditor {
createPrintAction();
action= new ResourceAction(TextEditorMessages.getBundleForConstructedKeys(), "Editor.ShowChangeRulerInformation.", IAction.AS_PUSH_BUTTON) { //$NON-NLS-1$
+ @Override
public void run() {
showChangeRulerInformation();
}
@@ -1281,6 +1264,7 @@ public abstract class AbstractDecoratedTextEditor extends StatusTextEditor {
setAction(ITextEditorActionConstants.SHOW_CHANGE_RULER_INFORMATION, action);
action= new ResourceAction(TextEditorMessages.getBundleForConstructedKeys(), "Editor.ShowRulerAnnotationInformation.", IAction.AS_PUSH_BUTTON) { //$NON-NLS-1$
+ @Override
public void run() {
showRulerAnnotationInformation();
}
@@ -1373,6 +1357,7 @@ public abstract class AbstractDecoratedTextEditor extends StatusTextEditor {
final ISourceViewer viewer= getSourceViewer();
ResourceAction action= new ResourceAction(TextEditorMessages.getBundleForConstructedKeys(), "Editor.Print.") { //$NON-NLS-1$
+ @Override
public void run() {
StyledTextPrintOptions options= new StyledTextPrintOptions();
options.printTextFontStyle= true;
@@ -1400,6 +1385,7 @@ public abstract class AbstractDecoratedTextEditor extends StatusTextEditor {
setAction(ITextEditorActionConstants.PRINT, action);
}
+ @Override
public Object getAdapter(Class adapter) {
if (IGotoMarker.class.equals(adapter))
return fGotoMarkerAdapter;
@@ -1409,6 +1395,7 @@ public abstract class AbstractDecoratedTextEditor extends StatusTextEditor {
if (adapter == IShowInSource.class) {
return new IShowInSource() {
+ @Override
public ShowInContext getShowInContext() {
ISelection selection= null;
ISelectionProvider selectionProvider= getSelectionProvider();
@@ -1437,6 +1424,7 @@ public abstract class AbstractDecoratedTextEditor extends StatusTextEditor {
*
* @see org.eclipse.ui.texteditor.AbstractTextEditor#setDocumentProvider(org.eclipse.ui.IEditorInput)
*/
+ @Override
protected void setDocumentProvider(IEditorInput input) {
fImplicitDocumentProvider= DocumentProviderRegistry.getDefault().getDocumentProvider(input);
IDocumentProvider provider= super.getDocumentProvider();
@@ -1446,9 +1434,7 @@ public abstract class AbstractDecoratedTextEditor extends StatusTextEditor {
}
}
- /*
- * @see org.eclipse.ui.texteditor.ITextEditor#getDocumentProvider()
- */
+ @Override
public IDocumentProvider getDocumentProvider() {
IDocumentProvider provider= super.getDocumentProvider();
if (provider == null)
@@ -1456,9 +1442,7 @@ public abstract class AbstractDecoratedTextEditor extends StatusTextEditor {
return provider;
}
- /*
- * @see org.eclipse.ui.texteditor.AbstractTextEditor#disposeDocumentProvider()
- */
+ @Override
protected void disposeDocumentProvider() {
super.disposeDocumentProvider();
fImplicitDocumentProvider= null;
@@ -1470,6 +1454,7 @@ public abstract class AbstractDecoratedTextEditor extends StatusTextEditor {
* This implementation also updates change information in the quick diff
* ruler.
*/
+ @Override
protected void doSetInput(IEditorInput input) throws CoreException {
fIsDerivedStateValidated= false;
fIsEditingDerivedFileAllowed= true;
@@ -1486,10 +1471,7 @@ public abstract class AbstractDecoratedTextEditor extends StatusTextEditor {
}
}
- /*
- * @see org.eclipse.ui.texteditor.StatusTextEditor#handleEditorInputChanged()
- * @since 3.7
- */
+ @Override
protected void handleEditorInputChanged() {
final IDocumentProvider provider= getDocumentProvider();
IEditorInput input= getEditorInput();
@@ -1508,6 +1490,7 @@ public abstract class AbstractDecoratedTextEditor extends StatusTextEditor {
* @param progressMonitor the progress monitor to be used
* @since 3.2
*/
+ @Override
protected void performSaveAs(IProgressMonitor progressMonitor) {
Shell shell= PlatformUI.getWorkbench().getModalDialogShellProvider().getShell();
final IEditorInput input= getEditorInput();
@@ -1643,6 +1626,7 @@ public abstract class AbstractDecoratedTextEditor extends StatusTextEditor {
* @param exception the exception to handle
* @since 3.6
*/
+ @Override
protected void openSaveErrorDialog(String title, String message, CoreException exception) {
IStatus status= exception.getStatus();
final IDocumentProvider documentProvider= getDocumentProvider();
@@ -1657,6 +1641,7 @@ public abstract class AbstractDecoratedTextEditor extends StatusTextEditor {
ErrorDialog errorDialog= new ErrorDialog(getSite().getShell(), title, message, status, IStatus.ERROR) {
+ @Override
protected void createButtonsForButtonBar(Composite parent) {
super.createButtonsForButtonBar(parent);
createButton(parent, saveAsUTF8ButtonId, TextEditorMessages.AbstractDecoratedTextEditor_save_error_Dialog_button_saveAsUTF8, false);
@@ -1664,6 +1649,7 @@ public abstract class AbstractDecoratedTextEditor extends StatusTextEditor {
createButton(parent, selectUnmappableCharButtonId, TextEditorMessages.AbstractDecoratedTextEditor_save_error_Dialog_button_selectUnmappable, false);
}
+ @Override
protected void buttonPressed(int id) {
if (id == saveAsUTF8ButtonId || id == selectUnmappableCharButtonId) {
setReturnCode(id);
@@ -1672,6 +1658,7 @@ public abstract class AbstractDecoratedTextEditor extends StatusTextEditor {
super.buttonPressed(id);
}
+ @Override
protected boolean shouldShowDetailsButton() {
return false;
}
@@ -1780,6 +1767,7 @@ public abstract class AbstractDecoratedTextEditor extends StatusTextEditor {
final Shell shell= getSite().getShell();
IAction action= new ResourceAction(TextEditorMessages.getBundleForConstructedKeys(), "Editor.RulerPreferencesAction.") { //$NON-NLS-1$
+ @Override
public void run() {
String[] preferencePages= collectOverviewRulerMenuPreferencePages();
if (preferencePages.length > 0 && (shell == null || !shell.isDisposed())) {
@@ -1814,10 +1802,7 @@ public abstract class AbstractDecoratedTextEditor extends StatusTextEditor {
return null;
}
- /*
- * @see org.eclipse.ui.texteditor.AbstractTextEditor#rulerContextMenuAboutToShow(org.eclipse.jface.action.IMenuManager)
- * @since 3.1
- */
+ @Override
protected void rulerContextMenuAboutToShow(IMenuManager menu) {
/*
* XXX: workaround for reliable menu item ordering.
@@ -1881,6 +1866,7 @@ public abstract class AbstractDecoratedTextEditor extends StatusTextEditor {
for (int i= 0; i < modes.length; i++) {
final String mode= modes[i].name();
IAction action= new Action(labels[i], IAction.AS_RADIO_BUTTON) {
+ @Override
public void run() {
// set preference globally, LineNumberColumn reacts on preference change
uiStore.setValue(AbstractDecoratedTextEditorPreferenceConstants.REVISION_RULER_RENDERING_MODE, mode);
@@ -1929,6 +1915,7 @@ public abstract class AbstractDecoratedTextEditor extends StatusTextEditor {
continue;
final boolean isVisible= support.isColumnVisible(descriptor);
IAction action= new Action(MessageFormat.format(TextEditorMessages.AbstractDecoratedTextEditor_show_ruler_label, new Object[] {descriptor.getName()}), IAction.AS_CHECK_BOX) {
+ @Override
public void run() {
if (descriptor.isGlobal())
// column state is modified via preference listener of AbstractTextEditor
@@ -1973,10 +1960,7 @@ public abstract class AbstractDecoratedTextEditor extends StatusTextEditor {
showChangeInformation(current);
}
- /*
- * @see org.eclipse.ui.texteditor.AbstractTextEditor#editorContextMenuAboutToShow(org.eclipse.jface.action.IMenuManager)
- * @since 3.1
- */
+ @Override
protected void editorContextMenuAboutToShow(IMenuManager menu) {
super.editorContextMenuAboutToShow(menu);
@@ -1993,6 +1977,7 @@ public abstract class AbstractDecoratedTextEditor extends StatusTextEditor {
// XXX: Internal reference will get fixed during 3.7, see https://bugs.eclipse.org/bugs/show_bug.cgi?id=307026
openWithSubMenu.add(new OpenWithMenu(page, editorInput) {
+ @Override
protected void openEditor(IEditorDescriptor editorDescriptor, boolean openUsingDescriptor) {
super.openEditor(editorDescriptor, openUsingDescriptor);
ISelection selection= getSelectionProvider().getSelection();
@@ -2033,6 +2018,7 @@ public abstract class AbstractDecoratedTextEditor extends StatusTextEditor {
final IEditorInput input= editor.getEditorInput();
if (input instanceof IFileEditorInput) {
WorkspaceModifyOperation op= new WorkspaceModifyOperation() {
+ @Override
protected void execute(IProgressMonitor monitor) throws CoreException {
IMarker marker= null;
try {
@@ -2141,10 +2127,7 @@ public abstract class AbstractDecoratedTextEditor extends StatusTextEditor {
};
}
- /*
- * @see AbstractTextEditor#getUndoRedoOperationApprover(IUndoContext)
- * @since 3.1
- */
+ @Override
protected IOperationApprover getUndoRedoOperationApprover(IUndoContext undoContext) {
IEditorInput input= getEditorInput();
if (input != null && input.getAdapter(IResource.class) != null)
@@ -2164,6 +2147,7 @@ public abstract class AbstractDecoratedTextEditor extends StatusTextEditor {
* @return <code>true</code> if this is a target, <code>false</code> otherwise
* @since 3.2
*/
+ @Override
protected boolean isNavigationTarget(Annotation annotation) {
AnnotationPreference preference= getAnnotationPreferenceLookup().getAnnotationPreference(annotation);
// See bug 41689
@@ -2180,6 +2164,7 @@ public abstract class AbstractDecoratedTextEditor extends StatusTextEditor {
* </p>
* @since 3.2
*/
+ @Override
public Annotation gotoAnnotation(boolean forward) {
Annotation annotation= super.gotoAnnotation(forward);
if (annotation != null)
@@ -2222,6 +2207,7 @@ public abstract class AbstractDecoratedTextEditor extends StatusTextEditor {
* @see org.eclipse.ui.texteditor.AbstractTextEditor#isTabConversionEnabled()
* @since 3.3
*/
+ @Override
protected boolean isTabsToSpacesConversionEnabled() {
return getPreferenceStore() != null && getPreferenceStore().getBoolean(AbstractDecoratedTextEditorPreferenceConstants.EDITOR_SPACES_FOR_TABS);
}
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/AbstractDecoratedTextEditorPreferenceConstants.java b/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/AbstractDecoratedTextEditorPreferenceConstants.java
index 7bd29665e..5e98a71b8 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/AbstractDecoratedTextEditorPreferenceConstants.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/AbstractDecoratedTextEditorPreferenceConstants.java
@@ -135,6 +135,7 @@ public class AbstractDecoratedTextEditorPreferenceConstants {
* </p>
* @deprecated as of 3.0 there are no UNKNOWN annotations any more
*/
+ @Deprecated
public final static String EDITOR_UNKNOWN_INDICATION= "othersIndication"; //$NON-NLS-1$
/**
@@ -149,6 +150,7 @@ public class AbstractDecoratedTextEditorPreferenceConstants {
* @see PreferenceConverter
* @deprecated As of 3.0, there are no UNKNOWN annotations any more
*/
+ @Deprecated
public final static String EDITOR_UNKNOWN_INDICATION_COLOR= "othersIndicationColor"; //$NON-NLS-1$
/**
@@ -159,6 +161,7 @@ public class AbstractDecoratedTextEditorPreferenceConstants {
* </p>
* @deprecated As of 3.0, there are no UNKNOWN annotations any more
*/
+ @Deprecated
public final static String EDITOR_UNKNOWN_INDICATION_IN_OVERVIEW_RULER= "othersIndicationInOverviewRuler"; //$NON-NLS-1$
/**
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/AbstractMarkerAnnotationModel.java b/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/AbstractMarkerAnnotationModel.java
index 59479cf23..7ba1f7788 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/AbstractMarkerAnnotationModel.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/AbstractMarkerAnnotationModel.java
@@ -241,6 +241,7 @@ public abstract class AbstractMarkerAnnotationModel extends AnnotationModel impl
* Connects to the source of markers as marker change listener.
* @see AnnotationModel#connected()
*/
+ @Override
protected void connected() {
listenToMarkerChanges(true);
@@ -348,6 +349,7 @@ public abstract class AbstractMarkerAnnotationModel extends AnnotationModel impl
* Removes the marker change listener.
* @see AnnotationModel#disconnected()
*/
+ @Override
protected void disconnected() {
listenToMarkerChanges(false);
uninstallMarkerUpdaters();
@@ -387,9 +389,7 @@ public abstract class AbstractMarkerAnnotationModel extends AnnotationModel impl
addMarkerAnnotation(marker);
}
- /*
- * @see AnnotationModel#removeAnnotations(List, boolean, boolean)
- */
+ @Override
protected void removeAnnotations(List annotations, boolean fireModelChanged, boolean modelInitiated) {
if (annotations != null && annotations.size() > 0) {
@@ -549,6 +549,7 @@ public abstract class AbstractMarkerAnnotationModel extends AnnotationModel impl
* @since 2.0
* @deprecated use <code>updateMarker(IDocument, IMarker, Position)</code> instead. This method will be changed to protected.
*/
+ @Deprecated
public boolean updateMarker(IMarker marker, IDocument document, Position position) throws CoreException {
if (fMarkerUpdaterSpecifications == null)
@@ -690,23 +691,17 @@ public abstract class AbstractMarkerAnnotationModel extends AnnotationModel impl
fireModelChanged();
}
- /*
- * @see org.eclipse.jface.text.source.IPersistableAnnotationModel#commit(org.eclipse.jface.text.IDocument)
- */
+ @Override
public void commit(IDocument document) throws CoreException {
updateMarkers(document);
}
- /*
- * @see org.eclipse.jface.text.source.IPersistableAnnotationModel#revert(org.eclipse.jface.text.IDocument)
- */
+ @Override
public void revert(IDocument document) {
resetMarkers();
}
- /*
- * @see org.eclipse.jface.text.source.IPersistableAnnotationModel#reinitialize(org.eclipse.jface.text.IDocument)
- */
+ @Override
public void reinitialize(IDocument document) {
resetMarkers();
}
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/AddMarkerAction.java b/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/AddMarkerAction.java
index ea168a54e..6df61f5fc 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/AddMarkerAction.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/AddMarkerAction.java
@@ -118,9 +118,7 @@ public class AddMarkerAction extends TextEditorAction {
return fPrefix;
}
- /*
- * @see IAction#run()
- */
+ @Override
public void run() {
IResource resource= getResource();
if (resource == null)
@@ -136,6 +134,7 @@ public class AddMarkerAction extends TextEditorAction {
final Shell shell= getTextEditor().getSite().getShell();
IAdaptable context= new IAdaptable() {
+ @Override
public Object getAdapter(Class adapter) {
if (adapter == Shell.class)
return shell;
@@ -155,9 +154,7 @@ public class AddMarkerAction extends TextEditorAction {
}
}
- /*
- * @see TextEditorAction#update()
- */
+ @Override
public void update() {
setEnabled(getResource() != null);
}
@@ -178,6 +175,7 @@ public class AddMarkerAction extends TextEditorAction {
String title= getString(fBundle, fPrefix + "dialog.title", fPrefix + "dialog.title"); //$NON-NLS-2$ //$NON-NLS-1$
String message= getString(fBundle, fPrefix + "dialog.message", fPrefix + "dialog.message"); //$NON-NLS-2$ //$NON-NLS-1$
IInputValidator inputValidator= new IInputValidator() {
+ @Override
public String isValid(String newText) {
return (newText == null || newText.trim().length() == 0) ? " " : null; //$NON-NLS-1$
}
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/AddTaskAction.java b/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/AddTaskAction.java
index 32324ec18..78acf6a90 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/AddTaskAction.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/AddTaskAction.java
@@ -43,9 +43,7 @@ public class AddTaskAction extends AddMarkerAction {
super(bundle, prefix, editor, IMarker.TASK, false);
}
- /*
- * @see IAction#run()
- */
+ @Override
public void run() {
IResource resource= getResource();
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/BasicMarkerUpdater.java b/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/BasicMarkerUpdater.java
index a665a1c41..d0844e89d 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/BasicMarkerUpdater.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/BasicMarkerUpdater.java
@@ -36,23 +36,17 @@ public final class BasicMarkerUpdater implements IMarkerUpdater {
super();
}
- /*
- * @see IMarkerUpdater#getAttribute()
- */
+ @Override
public String[] getAttribute() {
return ATTRIBUTES;
}
- /*
- * @see IMarkerUpdater#getMarkerType()
- */
+ @Override
public String getMarkerType() {
return null;
}
- /*
- * @see IMarkerUpdater#updateMarker(IMarker, IDocument, Position)
- */
+ @Override
public boolean updateMarker(IMarker marker, IDocument document, Position position) {
if (position == null)
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/BookmarkRulerAction.java b/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/BookmarkRulerAction.java
index 72352e177..64ec3907b 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/BookmarkRulerAction.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/BookmarkRulerAction.java
@@ -24,9 +24,7 @@ import org.eclipse.jface.text.source.IVerticalRulerInfo;
*/
public class BookmarkRulerAction extends AbstractRulerActionDelegate {
- /*
- * @see AbstractRulerActionDelegate#createAction(ITextEditor, IVerticalRulerInfo)
- */
+ @Override
protected IAction createAction(ITextEditor editor, IVerticalRulerInfo rulerInfo) {
return new MarkerRulerAction(TextEditorMessages.getBundleForConstructedKeys(), "Editor.ManageBookmarks.", editor, rulerInfo, IMarker.BOOKMARK, true); //$NON-NLS-1$
}
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/ChainedPreferenceStore.java b/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/ChainedPreferenceStore.java
index d08d6ebe0..5b616c2c2 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/ChainedPreferenceStore.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/ChainedPreferenceStore.java
@@ -61,9 +61,7 @@ public class ChainedPreferenceStore implements IPreferenceStore {
setPreferenceStore(preferenceStore);
}
- /*
- * @see org.eclipse.jface.util.IPropertyChangeListener#propertyChange(org.eclipse.jface.util.PropertyChangeEvent)
- */
+ @Override
public void propertyChange(PropertyChangeEvent event) {
IPreferenceStore childPreferenceStore= getPreferenceStore();
handlePropertyChangeEvent(childPreferenceStore, event);
@@ -119,9 +117,7 @@ public class ChainedPreferenceStore implements IPreferenceStore {
}
}
- /*
- * @see org.eclipse.jface.preference.IPreferenceStore#addPropertyChangeListener(org.eclipse.jface.util.IPropertyChangeListener)
- */
+ @Override
public void addPropertyChangeListener(IPropertyChangeListener listener) {
if (fClientListeners.size() == 0) {
registerChildListeners();
@@ -129,9 +125,7 @@ public class ChainedPreferenceStore implements IPreferenceStore {
fClientListeners.add(listener);
}
- /*
- * @see org.eclipse.jface.preference.IPreferenceStore#removePropertyChangeListener(org.eclipse.jface.util.IPropertyChangeListener)
- */
+ @Override
public void removePropertyChangeListener(IPropertyChangeListener listener) {
fClientListeners.remove(listener);
if (fClientListeners.size() == 0) {
@@ -139,16 +133,12 @@ public class ChainedPreferenceStore implements IPreferenceStore {
}
}
- /*
- * @see org.eclipse.jface.preference.IPreferenceStore#contains(java.lang.String)
- */
+ @Override
public boolean contains(String name) {
return getVisibleStore(name) != null;
}
- /*
- * @see org.eclipse.jface.preference.IPreferenceStore#firePropertyChangeEvent(java.lang.String, java.lang.Object, java.lang.Object)
- */
+ @Override
public void firePropertyChangeEvent(String name, Object oldValue, Object newValue) {
firePropertyChangeEvent(new PropertyChangeEvent(this, name, oldValue, newValue));
}
@@ -164,9 +154,7 @@ public class ChainedPreferenceStore implements IPreferenceStore {
((IPropertyChangeListener) listeners[i]).propertyChange(event);
}
- /*
- * @see org.eclipse.jface.preference.IPreferenceStore#getBoolean(java.lang.String)
- */
+ @Override
public boolean getBoolean(String name) {
IPreferenceStore visibleStore= getVisibleStore(name);
if (visibleStore != null)
@@ -174,9 +162,7 @@ public class ChainedPreferenceStore implements IPreferenceStore {
return BOOLEAN_DEFAULT_DEFAULT;
}
- /*
- * @see org.eclipse.jface.preference.IPreferenceStore#getDefaultBoolean(java.lang.String)
- */
+ @Override
public boolean getDefaultBoolean(String name) {
IPreferenceStore visibleStore= getVisibleStore(name);
if (visibleStore != null)
@@ -184,9 +170,7 @@ public class ChainedPreferenceStore implements IPreferenceStore {
return BOOLEAN_DEFAULT_DEFAULT;
}
- /*
- * @see org.eclipse.jface.preference.IPreferenceStore#getDefaultDouble(java.lang.String)
- */
+ @Override
public double getDefaultDouble(String name) {
IPreferenceStore visibleStore= getVisibleStore(name);
if (visibleStore != null)
@@ -194,9 +178,7 @@ public class ChainedPreferenceStore implements IPreferenceStore {
return DOUBLE_DEFAULT_DEFAULT;
}
- /*
- * @see org.eclipse.jface.preference.IPreferenceStore#getDefaultFloat(java.lang.String)
- */
+ @Override
public float getDefaultFloat(String name) {
IPreferenceStore visibleStore= getVisibleStore(name);
if (visibleStore != null)
@@ -204,9 +186,7 @@ public class ChainedPreferenceStore implements IPreferenceStore {
return FLOAT_DEFAULT_DEFAULT;
}
- /*
- * @see org.eclipse.jface.preference.IPreferenceStore#getDefaultInt(java.lang.String)
- */
+ @Override
public int getDefaultInt(String name) {
IPreferenceStore visibleStore= getVisibleStore(name);
if (visibleStore != null)
@@ -214,9 +194,7 @@ public class ChainedPreferenceStore implements IPreferenceStore {
return INT_DEFAULT_DEFAULT;
}
- /*
- * @see org.eclipse.jface.preference.IPreferenceStore#getDefaultLong(java.lang.String)
- */
+ @Override
public long getDefaultLong(String name) {
IPreferenceStore visibleStore= getVisibleStore(name);
if (visibleStore != null)
@@ -224,9 +202,7 @@ public class ChainedPreferenceStore implements IPreferenceStore {
return LONG_DEFAULT_DEFAULT;
}
- /*
- * @see org.eclipse.jface.preference.IPreferenceStore#getDefaultString(java.lang.String)
- */
+ @Override
public String getDefaultString(String name) {
IPreferenceStore visibleStore= getVisibleStore(name);
if (visibleStore != null)
@@ -234,9 +210,7 @@ public class ChainedPreferenceStore implements IPreferenceStore {
return STRING_DEFAULT_DEFAULT;
}
- /*
- * @see org.eclipse.jface.preference.IPreferenceStore#getDouble(java.lang.String)
- */
+ @Override
public double getDouble(String name) {
IPreferenceStore visibleStore= getVisibleStore(name);
if (visibleStore != null)
@@ -244,9 +218,7 @@ public class ChainedPreferenceStore implements IPreferenceStore {
return DOUBLE_DEFAULT_DEFAULT;
}
- /*
- * @see org.eclipse.jface.preference.IPreferenceStore#getFloat(java.lang.String)
- */
+ @Override
public float getFloat(String name) {
IPreferenceStore visibleStore= getVisibleStore(name);
if (visibleStore != null)
@@ -254,9 +226,7 @@ public class ChainedPreferenceStore implements IPreferenceStore {
return FLOAT_DEFAULT_DEFAULT;
}
- /*
- * @see org.eclipse.jface.preference.IPreferenceStore#getInt(java.lang.String)
- */
+ @Override
public int getInt(String name) {
IPreferenceStore visibleStore= getVisibleStore(name);
if (visibleStore != null)
@@ -264,9 +234,7 @@ public class ChainedPreferenceStore implements IPreferenceStore {
return INT_DEFAULT_DEFAULT;
}
- /*
- * @see org.eclipse.jface.preference.IPreferenceStore#getLong(java.lang.String)
- */
+ @Override
public long getLong(String name) {
IPreferenceStore visibleStore= getVisibleStore(name);
if (visibleStore != null)
@@ -274,9 +242,7 @@ public class ChainedPreferenceStore implements IPreferenceStore {
return LONG_DEFAULT_DEFAULT;
}
- /*
- * @see org.eclipse.jface.preference.IPreferenceStore#getString(java.lang.String)
- */
+ @Override
public String getString(String name) {
IPreferenceStore visibleStore= getVisibleStore(name);
if (visibleStore != null)
@@ -284,9 +250,7 @@ public class ChainedPreferenceStore implements IPreferenceStore {
return STRING_DEFAULT_DEFAULT;
}
- /*
- * @see org.eclipse.jface.preference.IPreferenceStore#isDefault(java.lang.String)
- */
+ @Override
public boolean isDefault(String name) {
IPreferenceStore visibleStore= getVisibleStore(name);
if (visibleStore != null)
@@ -294,107 +258,77 @@ public class ChainedPreferenceStore implements IPreferenceStore {
return false;
}
- /*
- * @see org.eclipse.jface.preference.IPreferenceStore#needsSaving()
- */
+ @Override
public boolean needsSaving() {
throw new UnsupportedOperationException();
}
- /*
- * @see org.eclipse.jface.preference.IPreferenceStore#putValue(java.lang.String, java.lang.String)
- */
+ @Override
public void putValue(String name, String value) {
throw new UnsupportedOperationException();
}
- /*
- * @see org.eclipse.jface.preference.IPreferenceStore#setDefault(java.lang.String, double)
- */
+ @Override
public void setDefault(String name, double value) {
throw new UnsupportedOperationException();
}
- /*
- * @see org.eclipse.jface.preference.IPreferenceStore#setDefault(java.lang.String, float)
- */
+ @Override
public void setDefault(String name, float value) {
throw new UnsupportedOperationException();
}
- /*
- * @see org.eclipse.jface.preference.IPreferenceStore#setDefault(java.lang.String, int)
- */
+ @Override
public void setDefault(String name, int value) {
throw new UnsupportedOperationException();
}
- /*
- * @see org.eclipse.jface.preference.IPreferenceStore#setDefault(java.lang.String, long)
- */
+ @Override
public void setDefault(String name, long value) {
throw new UnsupportedOperationException();
}
- /*
- * @see org.eclipse.jface.preference.IPreferenceStore#setDefault(java.lang.String, java.lang.String)
- */
+ @Override
public void setDefault(String name, String defaultObject) {
throw new UnsupportedOperationException();
}
- /*
- * @see org.eclipse.jface.preference.IPreferenceStore#setDefault(java.lang.String, boolean)
- */
+ @Override
public void setDefault(String name, boolean value) {
throw new UnsupportedOperationException();
}
- /*
- * @see org.eclipse.jface.preference.IPreferenceStore#setToDefault(java.lang.String)
- */
+ @Override
public void setToDefault(String name) {
throw new UnsupportedOperationException();
}
- /*
- * @see org.eclipse.jface.preference.IPreferenceStore#setValue(java.lang.String, double)
- */
+ @Override
public void setValue(String name, double value) {
throw new UnsupportedOperationException();
}
- /*
- * @see org.eclipse.jface.preference.IPreferenceStore#setValue(java.lang.String, float)
- */
+ @Override
public void setValue(String name, float value) {
throw new UnsupportedOperationException();
}
- /*
- * @see org.eclipse.jface.preference.IPreferenceStore#setValue(java.lang.String, int)
- */
+ @Override
public void setValue(String name, int value) {
throw new UnsupportedOperationException();
}
- /*
- * @see org.eclipse.jface.preference.IPreferenceStore#setValue(java.lang.String, long)
- */
+ @Override
public void setValue(String name, long value) {
throw new UnsupportedOperationException();
}
- /*
- * @see org.eclipse.jface.preference.IPreferenceStore#setValue(java.lang.String, java.lang.String)
- */
+ @Override
public void setValue(String name, String value) {
throw new UnsupportedOperationException();
}
- /*
- * @see org.eclipse.jface.preference.IPreferenceStore#setValue(java.lang.String, boolean)
- */
+ @Override
public void setValue(String name, boolean value) {
throw new UnsupportedOperationException();
}
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/ChangeEncodingAction.java b/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/ChangeEncodingAction.java
index c61fd20d2..020bf34d9 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/ChangeEncodingAction.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/ChangeEncodingAction.java
@@ -89,9 +89,7 @@ public class ChangeEncodingAction extends TextEditorAction {
fDialogTitle= getString(bundle, key, null);
}
- /*
- * @see org.eclipse.jface.action.Action#run()
- */
+ @Override
public void run() {
final IResource resource= getResource();
final Shell parentShell= getTextEditor().getSite().getShell();
@@ -105,17 +103,13 @@ public class ChangeEncodingAction extends TextEditorAction {
private AbstractEncodingFieldEditor fEncodingEditor;
private IPreferenceStore store= null;
- /*
- * @see org.eclipse.jface.window.Window#configureShell(org.eclipse.swt.widgets.Shell)
- */
+ @Override
protected void configureShell(Shell newShell) {
super.configureShell(newShell);
newShell.setText(fDialogTitle);
}
- /*
- * @see org.eclipse.jface.dialogs.Dialog#createDialogArea(org.eclipse.swt.widgets.Composite)
- */
+ @Override
protected Control createDialogArea(Composite parent) {
Composite composite= (Composite)super.createDialogArea(parent);
@@ -132,6 +126,7 @@ public class ChangeEncodingAction extends TextEditorAction {
composite.setFont(parent.getFont());
DialogPage page= new MessageDialogPage(composite) {
+ @Override
public void setErrorMessage(String newMessage) {
super.setErrorMessage(newMessage);
setButtonEnabledState(IDialogConstants.OK_ID, newMessage == null);
@@ -169,17 +164,13 @@ public class ChangeEncodingAction extends TextEditorAction {
return composite;
}
- /*
- * @see org.eclipse.jface.dialogs.Dialog#createButtonsForButtonBar(org.eclipse.swt.widgets.Composite)
- */
+ @Override
protected void createButtonsForButtonBar(Composite parent) {
createButton(parent, APPLY_ID, TextEditorMessages.ChangeEncodingAction_button_apply_label, false);
super.createButtonsForButtonBar(parent);
}
- /*
- * @see org.eclipse.jface.dialogs.Dialog#buttonPressed(int)
- */
+ @Override
protected void buttonPressed(int buttonId) {
if (buttonId == APPLY_ID)
apply();
@@ -187,9 +178,7 @@ public class ChangeEncodingAction extends TextEditorAction {
super.buttonPressed(buttonId);
}
- /*
- * @see org.eclipse.jface.dialogs.Dialog#okPressed()
- */
+ @Override
protected void okPressed() {
apply();
super.okPressed();
@@ -207,9 +196,7 @@ public class ChangeEncodingAction extends TextEditorAction {
dialog.open();
}
- /*
- * @see org.eclipse.ui.texteditor.IUpdate#update()
- */
+ @Override
public void update() {
setEnabled((getResource() != null || getEncodingSupport() != null) && !getTextEditor().isDirty());
}
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/DefaultMarkerAnnotationAccess.java b/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/DefaultMarkerAnnotationAccess.java
index 7f036f569..d180e03c4 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/DefaultMarkerAnnotationAccess.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/DefaultMarkerAnnotationAccess.java
@@ -56,6 +56,7 @@ public class DefaultMarkerAnnotationAccess implements IAnnotationAccess, IAnnota
*
* @deprecated As of 3.0, replaced by Annotation.TYPE_UNKNOWN
*/
+ @Deprecated
public static final String UNKNOWN= Annotation.TYPE_UNKNOWN;
/**
@@ -116,6 +117,7 @@ public class DefaultMarkerAnnotationAccess implements IAnnotationAccess, IAnnota
*
* @deprecated As of 3.0, no replacement
*/
+ @Deprecated
protected MarkerAnnotationPreferences fMarkerAnnotationPreferences;
/**
@@ -132,6 +134,7 @@ public class DefaultMarkerAnnotationAccess implements IAnnotationAccess, IAnnota
* @deprecated As of 3.0, replaced by
* {@link org.eclipse.ui.texteditor.DefaultMarkerAnnotationAccess#DefaultMarkerAnnotationAccess()}
*/
+ @Deprecated
public DefaultMarkerAnnotationAccess(MarkerAnnotationPreferences markerAnnotationPreferences) {
fMarkerAnnotationPreferences= markerAnnotationPreferences;
}
@@ -146,10 +149,7 @@ public class DefaultMarkerAnnotationAccess implements IAnnotationAccess, IAnnota
public DefaultMarkerAnnotationAccess() {
}
- /*
- * @see org.eclipse.jface.text.source.IAnnotationAccessExtension2#setQuickAssistAssistant(org.eclipse.jface.text.quickassist.IQuickAssistAssistant)
- * @since 3.2
- */
+ @Override
public void setQuickAssistAssistant(IQuickAssistAssistant assistant) {
fQuickAssistAssistant= assistant;
}
@@ -183,6 +183,8 @@ public class DefaultMarkerAnnotationAccess implements IAnnotationAccess, IAnnota
* @deprecated use <code>Annotation.getType()</code>
*/
+ @Deprecated
+ @Override
public Object getType(Annotation annotation) {
return annotation.getType();
}
@@ -192,6 +194,8 @@ public class DefaultMarkerAnnotationAccess implements IAnnotationAccess, IAnnota
*
* @deprecated assumed to always return <code>true</code>
*/
+ @Deprecated
+ @Override
public boolean isMultiLine(Annotation annotation) {
return true;
}
@@ -201,6 +205,8 @@ public class DefaultMarkerAnnotationAccess implements IAnnotationAccess, IAnnota
*
* @deprecated assumed to always return <code>true</code>
*/
+ @Deprecated
+ @Override
public boolean isTemporary(Annotation annotation) {
return !annotation.isPersistent();
}
@@ -209,15 +215,13 @@ public class DefaultMarkerAnnotationAccess implements IAnnotationAccess, IAnnota
* @see org.eclipse.jface.text.source.IAnnotationAccessExtension#getLabel(org.eclipse.jface.text.source.Annotation)
* @since 3.0
*/
+ @Override
public String getTypeLabel(Annotation annotation) {
AnnotationPreference preference= getAnnotationPreference(annotation);
return preference != null ? preference.getPreferenceLabel() : null;
}
- /*
- * @see org.eclipse.jface.text.source.IAnnotationAccessExtension#getLayer(org.eclipse.jface.text.source.Annotation)
- * @since 3.0
- */
+ @Override
public int getLayer(Annotation annotation) {
if (annotation instanceof IAnnotationPresentation) {
IAnnotationPresentation presentation= (IAnnotationPresentation) annotation;
@@ -245,10 +249,7 @@ public class DefaultMarkerAnnotationAccess implements IAnnotationAccess, IAnnota
return IAnnotationAccessExtension.DEFAULT_LAYER;
}
- /*
- * @see org.eclipse.jface.text.source.IAnnotationAccessExtension#paint(org.eclipse.jface.text.source.Annotation, org.eclipse.swt.graphics.GC, org.eclipse.swt.widgets.Canvas, org.eclipse.swt.graphics.Rectangle)
- * @since 3.0
- */
+ @Override
public void paint(Annotation annotation, GC gc, Canvas canvas, Rectangle bounds) {
if (annotation instanceof IAnnotationPresentation) {
@@ -282,10 +283,7 @@ public class DefaultMarkerAnnotationAccess implements IAnnotationAccess, IAnnota
}
}
- /*
- * @see org.eclipse.jface.text.source.IAnnotationAccessExtension#isPaintable(org.eclipse.jface.text.source.Annotation)
- * @since 3.0
- */
+ @Override
public boolean isPaintable(Annotation annotation) {
if (annotation instanceof IAnnotationPresentation)
return true;
@@ -300,17 +298,13 @@ public class DefaultMarkerAnnotationAccess implements IAnnotationAccess, IAnnota
return image != null;
}
- /*
- * @see org.eclipse.jface.text.source.IAnnotationAccessExtension#isSubtype(java.lang.Object, java.lang.Object)
- */
+ @Override
public boolean isSubtype(Object annotationType, Object potentialSupertype) {
AnnotationTypeHierarchy hierarchy= getAnnotationTypeHierarchy();
return hierarchy.isSubtype(potentialSupertype.toString(), annotationType.toString());
}
- /*
- * @see org.eclipse.jface.text.source.IAnnotationAccessExtension#getSupertypes(java.lang.Object)
- */
+ @Override
public Object[] getSupertypes(Object annotationType) {
AnnotationTypeHierarchy hierarchy= getAnnotationTypeHierarchy();
AnnotationType type= hierarchy.getAnnotationType(annotationType.toString());
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/ImageUtilities.java b/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/ImageUtilities.java
index e095f811c..40b4127a8 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/ImageUtilities.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/ImageUtilities.java
@@ -22,6 +22,7 @@ import org.eclipse.swt.widgets.Canvas;
* @noinstantiate This class is not intended to be instantiated by clients.
* @noextend This class is not intended to be subclassed by clients.
*/
+@Deprecated
public class ImageUtilities {
/**
@@ -35,6 +36,7 @@ public class ImageUtilities {
* @param valign the vertical alignment of the image to be drawn
* @deprecated As of 3.0, replaced by {@link org.eclipse.jface.text.source.ImageUtilities#drawImage(Image, GC, Canvas, Rectangle, int, int)}
*/
+ @Deprecated
public static void drawImage(Image image, GC gc, Canvas canvas, Rectangle r, int halign, int valign) {
org.eclipse.jface.text.source.ImageUtilities.drawImage(image, gc, canvas, r, halign, valign);
}
@@ -49,6 +51,7 @@ public class ImageUtilities {
* @param align the alignment of the image to be drawn
* @deprecated As of 3.0, replaced by {@link org.eclipse.jface.text.source.ImageUtilities#drawImage(Image, GC, Canvas, Rectangle, int)}
*/
+ @Deprecated
public static void drawImage(Image image, GC gc, Canvas canvas, Rectangle r, int align) {
org.eclipse.jface.text.source.ImageUtilities.drawImage(image, gc, canvas, r, align);
}
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/MarkerAnnotation.java b/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/MarkerAnnotation.java
index 3a90c7c03..92271a50a 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/MarkerAnnotation.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/MarkerAnnotation.java
@@ -53,6 +53,7 @@ public class MarkerAnnotation extends SimpleMarkerAnnotation implements IQuickFi
* @deprecated As of 3.0, replaced by {@link IAnnotationAccessExtension}
*/
+ @Deprecated
public final static int PROBLEM_LAYER= 5;
/** Internal image registry. */
@@ -69,6 +70,7 @@ public class MarkerAnnotation extends SimpleMarkerAnnotation implements IQuickFi
* annotation with a visible presentation should implement
* {@link org.eclipse.jface.text.source.IAnnotationPresentation}
*/
+ @Deprecated
protected static Image getImage(Display display, ImageDescriptor descriptor) {
Map map= getImageRegistry(display);
Image image= (Image) map.get(descriptor);
@@ -89,10 +91,12 @@ public class MarkerAnnotation extends SimpleMarkerAnnotation implements IQuickFi
* annotation with a visible presentation should implement
* {@link org.eclipse.jface.text.source.IAnnotationPresentation}
*/
+ @Deprecated
protected static Map getImageRegistry(Display display) {
if (fgImageRegistry == null) {
fgImageRegistry= new HashMap();
display.disposeExec(new Runnable() {
+ @Override
public void run() {
if (fgImageRegistry != null) {
Map map= fgImageRegistry;
@@ -159,6 +163,7 @@ public class MarkerAnnotation extends SimpleMarkerAnnotation implements IQuickFi
* annotation with a visible presentation should implement
* {@link org.eclipse.jface.text.source.IAnnotationPresentation}
*/
+ @Deprecated
protected void setImage(Image image) {
fImage= image;
}
@@ -171,6 +176,7 @@ public class MarkerAnnotation extends SimpleMarkerAnnotation implements IQuickFi
* annotation with a visible presentation should implement
* {@link org.eclipse.jface.text.source.IAnnotationPresentation}
*/
+ @Deprecated
protected void initialize() {
IMarker marker= getMarker();
String name= getUnknownImageName(marker);
@@ -206,6 +212,7 @@ public class MarkerAnnotation extends SimpleMarkerAnnotation implements IQuickFi
* @deprecated As of 3.0, replaced by {@link org.eclipse.jface.text.source.IAnnotationAccessExtension#getLayer(org.eclipse.jface.text.source.Annotation)}
* @since 3.0
*/
+ @Deprecated
public int getLayer() {
if (fPresentationLayer != -1)
// Backward compatibility
@@ -228,6 +235,7 @@ public class MarkerAnnotation extends SimpleMarkerAnnotation implements IQuickFi
*
* @since 3.0
*/
+ @Deprecated
protected void setLayer(int layer) {
fPresentationLayer= layer;
}
@@ -245,6 +253,7 @@ public class MarkerAnnotation extends SimpleMarkerAnnotation implements IQuickFi
* @deprecated As of 3.0 replaced by {@link org.eclipse.jface.text.source.IAnnotationAccessExtension#paint(org.eclipse.jface.text.source.Annotation, GC, Canvas, Rectangle)}
* @since 3.0
*/
+ @Deprecated
public void paint(GC gc, Canvas canvas, Rectangle r) {
Image image= getImage(canvas.getDisplay());
if (image != null)
@@ -255,6 +264,7 @@ public class MarkerAnnotation extends SimpleMarkerAnnotation implements IQuickFi
* Informs this annotation about changes applied to its underlying marker
* and adapts to those changes.
*/
+ @Override
public void update() {
super.update();
initialize();
@@ -271,6 +281,7 @@ public class MarkerAnnotation extends SimpleMarkerAnnotation implements IQuickFi
* annotation with a visible presentation should implement
* {@link org.eclipse.jface.text.source.IAnnotationPresentation}
*/
+ @Deprecated
protected String getUnknownImageName(IMarker marker) {
return null;
}
@@ -286,6 +297,7 @@ public class MarkerAnnotation extends SimpleMarkerAnnotation implements IQuickFi
* annotation with a visible presentation should implement
* {@link org.eclipse.jface.text.source.IAnnotationPresentation}
*/
+ @Deprecated
protected Image getImage(String name) {
if (name != null)
return PlatformUI.getWorkbench().getSharedImages().getImage(name);
@@ -303,6 +315,7 @@ public class MarkerAnnotation extends SimpleMarkerAnnotation implements IQuickFi
* annotation with a visible presentation should implement
* {@link org.eclipse.jface.text.source.IAnnotationPresentation}
*/
+ @Deprecated
protected Image getImage(Display display) {
if (fImage == null) {
@@ -328,6 +341,7 @@ public class MarkerAnnotation extends SimpleMarkerAnnotation implements IQuickFi
*
* @since 3.4
*/
+ @Override
public void setQuickFixable(boolean state) {
fIsQuickFixable= state;
fIsQuickFixableStateSet= true;
@@ -338,6 +352,7 @@ public class MarkerAnnotation extends SimpleMarkerAnnotation implements IQuickFi
*
* @since 3.4
*/
+ @Override
public boolean isQuickFixableStateSet() {
return fIsQuickFixableStateSet;
}
@@ -347,6 +362,7 @@ public class MarkerAnnotation extends SimpleMarkerAnnotation implements IQuickFi
*
* @since 3.4
*/
+ @Override
public boolean isQuickFixable() {
Assert.isTrue(isQuickFixableStateSet());
return fIsQuickFixable;
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/MarkerAnnotationPreferences.java b/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/MarkerAnnotationPreferences.java
index 2480849d8..17b7e5a3d 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/MarkerAnnotationPreferences.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/MarkerAnnotationPreferences.java
@@ -191,6 +191,7 @@ public class MarkerAnnotationPreferences {
}
private static final class AccessChecker extends SecurityManager {
+ @Override
public Class[] getClassContext() {
return super.getClassContext();
}
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 a59f471fc..16538f92e 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
@@ -132,6 +132,7 @@ public class MarkerRulerAction extends ResourceAction implements IUpdate {
* @param askForLabel <code>true</code> if the user should be asked for a label
* @deprecated use <code>MarkerRulerAction(ResourceBundle, String, ITextEditor, IVerticalRulerInfo, String, boolean)</code> instead
*/
+ @Deprecated
public MarkerRulerAction(ResourceBundle bundle, String prefix, IVerticalRuler ruler, ITextEditor editor, String markerType, boolean askForLabel) {
this(bundle, prefix, editor, ruler, markerType, askForLabel);
}
@@ -152,6 +153,7 @@ public class MarkerRulerAction extends ResourceAction implements IUpdate {
* @return this action's vertical ruler
* @deprecated use <code>getVerticalRulerInfo</code> instead
*/
+ @Deprecated
protected IVerticalRuler getVerticalRuler() {
if (fRuler instanceof IVerticalRuler)
return (IVerticalRuler) fRuler;
@@ -186,9 +188,7 @@ public class MarkerRulerAction extends ResourceAction implements IUpdate {
return fPrefix;
}
- /*
- * @see IUpdate#update()
- */
+ @Override
public void update() {
//bug 38745
IDocument document= getDocument();
@@ -232,9 +232,7 @@ public class MarkerRulerAction extends ResourceAction implements IUpdate {
return marker != null && marker.exists() && marker.getAttribute(IMarker.USER_EDITABLE, true);
}
- /*
- * @see Action#run()
- */
+ @Override
public void run() {
if (fMarkers.isEmpty())
addMarker();
@@ -403,6 +401,7 @@ public class MarkerRulerAction extends ResourceAction implements IUpdate {
String title= getString(fBundle, fPrefix + "add.dialog.title", fPrefix + "add.dialog.title"); //$NON-NLS-2$ //$NON-NLS-1$
String message= getString(fBundle, fPrefix + "add.dialog.message", fPrefix + "add.dialog.message"); //$NON-NLS-2$ //$NON-NLS-1$
IInputValidator inputValidator= new IInputValidator() {
+ @Override
public String isValid(String newText) {
return (newText == null || newText.trim().length() == 0) ? " " : null; //$NON-NLS-1$
}
@@ -504,6 +503,7 @@ public class MarkerRulerAction extends ResourceAction implements IUpdate {
private void execute(IUndoableOperation operation) {
final Shell shell= getTextEditor().getSite().getShell();
IAdaptable context= new IAdaptable() {
+ @Override
public Object getAdapter(Class adapter) {
if (adapter == Shell.class)
return shell;
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/MarkerRulerInfoAction.java b/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/MarkerRulerInfoAction.java
index c3ff0319e..3c764cbe7 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/MarkerRulerInfoAction.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/MarkerRulerInfoAction.java
@@ -19,6 +19,7 @@ import org.eclipse.jface.text.source.IVerticalRulerInfo;
* @deprecated use {@link org.eclipse.ui.texteditor.MarkerRulerAction} instead
* @since 2.0
*/
+@Deprecated
public class MarkerRulerInfoAction extends MarkerRulerAction {
/**
@@ -33,6 +34,7 @@ public class MarkerRulerInfoAction extends MarkerRulerAction {
* @param askForLabel <code>true</code> if the user should be asked for a label when a new marker is created
* @deprecated use super class constructor instead
*/
+ @Deprecated
public MarkerRulerInfoAction(ResourceBundle bundle, String prefix, IVerticalRulerInfo ruler, ITextEditor editor, String markerType, boolean askForLabel) {
super(bundle, prefix, editor, ruler, markerType, askForLabel);
}
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/MarkerUtilities.java b/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/MarkerUtilities.java
index 6f397a2f6..c02d4371b 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/MarkerUtilities.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/MarkerUtilities.java
@@ -390,6 +390,7 @@ public final class MarkerUtilities {
public static void createMarker(final IResource resource, final Map attributes, final String markerType) throws CoreException {
IWorkspaceRunnable r= new IWorkspaceRunnable() {
+ @Override
public void run(IProgressMonitor monitor) throws CoreException {
IMarker marker= resource.createMarker(markerType);
marker.setAttributes(attributes);
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/MessageDialogPage.java b/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/MessageDialogPage.java
index b8dcfd5bc..9cb00d858 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/MessageDialogPage.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/MessageDialogPage.java
@@ -35,6 +35,7 @@ class MessageDialogPage extends DialogPage {
createControl(parent);
}
+ @Override
public void createControl(Composite parent) {
Composite composite1= new Composite(parent, SWT.NONE);
composite1.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
@@ -50,11 +51,13 @@ class MessageDialogPage extends DialogPage {
Dialog.applyDialogFont(composite1);
}
+ @Override
public void setMessage(String newMessage,int newType) {
super.setMessage(newMessage, newType);
fMessageRegion.updateText(newMessage, newType);
}
+ @Override
public void setErrorMessage(String newMessage) {
super.setErrorMessage(newMessage);
fMessageRegion.updateText(newMessage, IMessageProvider.ERROR);
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/ReadOnlyAnnotationPreference.java b/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/ReadOnlyAnnotationPreference.java
index f55cd499c..1e1ec97cc 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/ReadOnlyAnnotationPreference.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/ReadOnlyAnnotationPreference.java
@@ -31,18 +31,21 @@ class ReadOnlyAnnotationPreference extends AnnotationPreference {
private boolean fIsReadOnly;
+ @Override
public void merge(AnnotationPreference preference) {
if (fIsReadOnly)
throw new UnsupportedOperationException();
super.merge(preference);
}
+ @Override
public void setAnnotationImageProvider(IAnnotationImageProvider provider) {
if (fIsReadOnly)
throw new UnsupportedOperationException();
super.setAnnotationImageProvider(provider);
}
+ @Override
public void setAnnotationImageProviderData(IConfigurationElement configurationElement, String annotationImageProviderAttribute) {
if (fIsReadOnly)
throw new UnsupportedOperationException();
@@ -50,186 +53,217 @@ class ReadOnlyAnnotationPreference extends AnnotationPreference {
annotationImageProviderAttribute);
}
+ @Override
public void setAnnotationType(Object annotationType) {
if (fIsReadOnly)
throw new UnsupportedOperationException();
super.setAnnotationType(annotationType);
}
+ @Override
public void setColorPreferenceKey(String colorKey) {
if (fIsReadOnly)
throw new UnsupportedOperationException();
super.setColorPreferenceKey(colorKey);
}
+ @Override
public void setColorPreferenceValue(RGB colorValue) {
if (fIsReadOnly)
throw new UnsupportedOperationException();
super.setColorPreferenceValue(colorValue);
}
+ @Override
public void setContributesToHeader(boolean contributesToHeader) {
if (fIsReadOnly)
throw new UnsupportedOperationException();
super.setContributesToHeader(contributesToHeader);
}
+ @Override
public void setHighlightPreferenceKey(String highlightKey) {
if (fIsReadOnly)
throw new UnsupportedOperationException();
super.setHighlightPreferenceKey(highlightKey);
}
+ @Override
public void setHighlightPreferenceValue(boolean highlightValue) {
if (fIsReadOnly)
throw new UnsupportedOperationException();
super.setHighlightPreferenceValue(highlightValue);
}
+ @Override
public void setImageDescriptor(ImageDescriptor descriptor) {
if (fIsReadOnly)
throw new UnsupportedOperationException();
super.setImageDescriptor(descriptor);
}
+ @Override
public void setIncludeOnPreferencePage(boolean includeOnPreferencePage) {
if (fIsReadOnly)
throw new UnsupportedOperationException();
super.setIncludeOnPreferencePage(includeOnPreferencePage);
}
+ @Override
public void setIsGoToNextNavigationTarget(boolean isGoToNextNavigationTarget) {
if (fIsReadOnly)
throw new UnsupportedOperationException();
super.setIsGoToNextNavigationTarget(isGoToNextNavigationTarget);
}
+ @Override
public void setIsGoToNextNavigationTargetKey(String isGoToNextNavigationTargetKey) {
if (fIsReadOnly)
throw new UnsupportedOperationException();
super.setIsGoToNextNavigationTargetKey(isGoToNextNavigationTargetKey);
}
+ @Override
public void setIsGoToPreviousNavigationTarget(boolean isGoToPreviousNavigationTarget) {
if (fIsReadOnly)
throw new UnsupportedOperationException();
super.setIsGoToPreviousNavigationTarget(isGoToPreviousNavigationTarget);
}
+ @Override
public void setIsGoToPreviousNavigationTargetKey(String isGoToPreviousNavigationTargetKey) {
if (fIsReadOnly)
throw new UnsupportedOperationException();
super.setIsGoToPreviousNavigationTargetKey(isGoToPreviousNavigationTargetKey);
}
+ @Override
public void setMarkerType(String markerType) {
if (fIsReadOnly)
throw new UnsupportedOperationException();
super.setMarkerType(markerType);
}
+ @Override
public void setOverviewRulerPreferenceKey(String overviewRulerKey) {
if (fIsReadOnly)
throw new UnsupportedOperationException();
super.setOverviewRulerPreferenceKey(overviewRulerKey);
}
+ @Override
public void setOverviewRulerPreferenceValue(boolean overviewRulerValue) {
if (fIsReadOnly)
throw new UnsupportedOperationException();
super.setOverviewRulerPreferenceValue(overviewRulerValue);
}
+ @Override
public void setPreferenceLabel(String label) {
if (fIsReadOnly)
throw new UnsupportedOperationException();
super.setPreferenceLabel(label);
}
+ @Override
public void setPresentationLayer(int presentationLayer) {
if (fIsReadOnly)
throw new UnsupportedOperationException();
super.setPresentationLayer(presentationLayer);
}
+ @Override
public void setQuickFixImageDescriptor(ImageDescriptor descriptor) {
if (fIsReadOnly)
throw new UnsupportedOperationException();
super.setQuickFixImageDescriptor(descriptor);
}
+ @Override
public void setSeverity(int severity) {
if (fIsReadOnly)
throw new UnsupportedOperationException();
super.setSeverity(severity);
}
+ @Override
public void setShowInNextPrevDropdownToolbarAction(boolean showInNextPrevDropdownToolbarAction) {
if (fIsReadOnly)
throw new UnsupportedOperationException();
super.setShowInNextPrevDropdownToolbarAction(showInNextPrevDropdownToolbarAction);
}
+ @Override
public void setShowInNextPrevDropdownToolbarActionKey(String showInNextPrevDropdownToolbarActionKey) {
if (fIsReadOnly)
throw new UnsupportedOperationException();
super.setShowInNextPrevDropdownToolbarActionKey(showInNextPrevDropdownToolbarActionKey);
}
+ @Override
public void setSymbolicImageName(String symbolicImageName) {
if (fIsReadOnly)
throw new UnsupportedOperationException();
super.setSymbolicImageName(symbolicImageName);
}
+ @Override
public void setTextPreferenceKey(String textKey) {
if (fIsReadOnly)
throw new UnsupportedOperationException();
super.setTextPreferenceKey(textKey);
}
+ @Override
public void setTextPreferenceValue(boolean textValue) {
if (fIsReadOnly)
throw new UnsupportedOperationException();
super.setTextPreferenceValue(textValue);
}
+ @Override
public void setTextStylePreferenceKey(String key) {
if (fIsReadOnly)
throw new UnsupportedOperationException();
super.setTextStylePreferenceKey(key);
}
+ @Override
public void setTextStyleValue(String value) {
if (fIsReadOnly)
throw new UnsupportedOperationException();
super.setTextStyleValue(value);
}
+ @Override
protected void setValue(Object attribute, boolean value) {
if (fIsReadOnly)
throw new UnsupportedOperationException();
super.setValue(attribute, value);
}
+ @Override
protected void setValue(Object attribute, int value) {
if (fIsReadOnly)
throw new UnsupportedOperationException();
super.setValue(attribute, value);
}
+ @Override
protected void setValue(Object attribute, Object value) {
if (fIsReadOnly)
throw new UnsupportedOperationException();
super.setValue(attribute, value);
}
+ @Override
public void setVerticalRulerPreferenceKey(String verticalRulerKey) {
if (fIsReadOnly)
throw new UnsupportedOperationException();
super.setVerticalRulerPreferenceKey(verticalRulerKey);
}
+ @Override
public void setVerticalRulerPreferenceValue(boolean verticalRulerValue) {
if (fIsReadOnly)
throw new UnsupportedOperationException();
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/ResourceMarkerAnnotationModel.java b/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/ResourceMarkerAnnotationModel.java
index 3cf258bd2..819ee7a70 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/ResourceMarkerAnnotationModel.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/ResourceMarkerAnnotationModel.java
@@ -45,9 +45,7 @@ public class ResourceMarkerAnnotationModel extends AbstractMarkerAnnotationModel
* Internal resource change listener.
*/
class ResourceChangeListener implements IResourceChangeListener {
- /*
- * @see IResourceChangeListener#resourceChanged(org.eclipse.core.resources.IResourceChangeEvent)
- */
+ @Override
public void resourceChanged(IResourceChangeEvent e) {
IResourceDelta delta= e.getDelta();
if (delta != null && fResource != null) {
@@ -78,9 +76,7 @@ public class ResourceMarkerAnnotationModel extends AbstractMarkerAnnotationModel
fWorkspace= resource.getWorkspace();
}
- /*
- * @see AbstractMarkerAnnotationModel#isAcceptable(IMarker)
- */
+ @Override
protected boolean isAcceptable(IMarker marker) {
return marker != null && fResource.equals(marker.getResource());
}
@@ -170,9 +166,7 @@ public class ResourceMarkerAnnotationModel extends AbstractMarkerAnnotationModel
addMarkerAnnotation((IMarker)iter.next());
}
- /*
- * @see AbstractMarkerAnnotationModel#listenToMarkerChanges(boolean)
- */
+ @Override
protected void listenToMarkerChanges(boolean listen) {
if (listen)
fWorkspace.addResourceChangeListener(fResourceChangeListener);
@@ -180,11 +174,10 @@ public class ResourceMarkerAnnotationModel extends AbstractMarkerAnnotationModel
fWorkspace.removeResourceChangeListener(fResourceChangeListener);
}
- /*
- * @see AbstractMarkerAnnotationModel#deleteMarkers(IMarker[])
- */
+ @Override
protected void deleteMarkers(final IMarker[] markers) throws CoreException {
fWorkspace.run(new IWorkspaceRunnable() {
+ @Override
public void run(IProgressMonitor monitor) throws CoreException {
for (int i= 0; i < markers.length; ++i) {
markers[i].delete();
@@ -193,9 +186,7 @@ public class ResourceMarkerAnnotationModel extends AbstractMarkerAnnotationModel
}, null, IWorkspace.AVOID_UPDATE, null);
}
- /*
- * @see AbstractMarkerAnnotationModel#retrieveMarkers()
- */
+ @Override
protected IMarker[] retrieveMarkers() throws CoreException {
return fResource.findMarkers(IMarker.MARKER, true, IResource.DEPTH_ZERO);
}
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/ResourceMarkerAnnotationModelFactory.java b/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/ResourceMarkerAnnotationModelFactory.java
index c1b4e78cb..c012fa39b 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/ResourceMarkerAnnotationModelFactory.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/ResourceMarkerAnnotationModelFactory.java
@@ -27,9 +27,7 @@ import org.eclipse.jface.text.source.IAnnotationModel;
*/
public class ResourceMarkerAnnotationModelFactory implements IAnnotationModelFactory {
- /*
- * @see org.eclipse.core.filebuffers.IAnnotationModelFactory#createAnnotationModel(org.eclipse.core.runtime.IPath)
- */
+ @Override
public IAnnotationModel createAnnotationModel(IPath location) {
IFile file= FileBuffers.getWorkspaceFileAtLocation(location);
if (file != null)
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/RevisionHoverInformationControlCreator.java b/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/RevisionHoverInformationControlCreator.java
index f5baea48d..dfbd0277b 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/RevisionHoverInformationControlCreator.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/RevisionHoverInformationControlCreator.java
@@ -79,6 +79,8 @@ class RevisionHoverInformationControlCreator extends AbstractReusableInformation
*
* @deprecated use {@link #setInput(Object)}
*/
+ @Deprecated
+ @Override
public void setInformation(String content) {
content= addCSSToHTMLFragment(content);
super.setInformation(content);
@@ -113,9 +115,7 @@ class RevisionHoverInformationControlCreator extends AbstractReusableInformation
fIsFocusable= isFocusable;
}
- /*
- * @see org.eclipse.ui.texteditor.AbstractReusableInformationControlCreator#canReuse(org.eclipse.jface.text.IInformationControl)
- */
+ @Override
public boolean canReuse(IInformationControl control) {
if (!super.canReuse(control))
return false;
@@ -126,9 +126,7 @@ class RevisionHoverInformationControlCreator extends AbstractReusableInformation
return true;
}
- /*
- * @see org.eclipse.jface.internal.text.revisions.AbstractReusableInformationControlCreator#doCreateInformationControl(org.eclipse.swt.widgets.Shell)
- */
+ @Override
protected IInformationControl doCreateInformationControl(Shell parent) {
if (BrowserInformationControl.isAvailable(parent)) {
if (fIsFocusable)
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/SelectMarkerRulerAction.java b/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/SelectMarkerRulerAction.java
index 945773fb1..eb8fc635b 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/SelectMarkerRulerAction.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/SelectMarkerRulerAction.java
@@ -101,20 +101,17 @@ public class SelectMarkerRulerAction extends ResourceAction implements IUpdate {
* @param editor the editor
* @deprecated As of 3.0, replaced by {@link #SelectMarkerRulerAction(ResourceBundle, String, ITextEditor, IVerticalRulerInfo)}
*/
+ @Deprecated
public SelectMarkerRulerAction(ResourceBundle bundle, String prefix, IVerticalRuler ruler, ITextEditor editor) {
this(bundle, prefix, editor, ruler);
}
- /*
- * @see IUpdate#update()
- */
+ @Override
public void update() {
setEnabled(hasMarkers());
}
- /*
- * @see Action#run()
- */
+ @Override
public void run() {
IMarker marker= chooseMarker(getMarkers());
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/SelectMarkerRulerInfoAction.java b/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/SelectMarkerRulerInfoAction.java
index 9d5bbc837..93b12992a 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/SelectMarkerRulerInfoAction.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/SelectMarkerRulerInfoAction.java
@@ -19,6 +19,7 @@ import org.eclipse.jface.text.source.IVerticalRulerInfo;
* @deprecated As of 2.1, replaced by {@link org.eclipse.ui.texteditor.SelectMarkerRulerAction}
* @since 2.0
*/
+@Deprecated
public class SelectMarkerRulerInfoAction extends SelectMarkerRulerAction {
/**
@@ -31,6 +32,7 @@ public class SelectMarkerRulerInfoAction extends SelectMarkerRulerAction {
* @param editor the editor
* @deprecated As of 2.1 replaced by {@link org.eclipse.ui.texteditor.SelectMarkerRulerAction#SelectMarkerRulerAction(ResourceBundle, String, ITextEditor, IVerticalRulerInfo)}
*/
+ @Deprecated
public SelectMarkerRulerInfoAction(ResourceBundle bundle, String prefix, IVerticalRulerInfo ruler, ITextEditor editor) {
super(bundle, prefix, editor, ruler);
}
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/SelectRulerAction.java b/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/SelectRulerAction.java
index c580ccff2..07c6a9dde 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/SelectRulerAction.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/SelectRulerAction.java
@@ -22,9 +22,7 @@ import org.eclipse.jface.text.source.IVerticalRulerInfo;
*/
public class SelectRulerAction extends AbstractRulerActionDelegate {
- /*
- * @see AbstractRulerActionDelegate#createAction(ITextEditor, IVerticalRulerInfo)
- */
+ @Override
protected IAction createAction(ITextEditor editor, IVerticalRulerInfo rulerInfo) {
return new SelectMarkerRulerAction(TextEditorMessages.getBundleForConstructedKeys(), "Editor.SelectMarker.", editor, rulerInfo); //$NON-NLS-1$
}
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/SimpleMarkerAnnotation.java b/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/SimpleMarkerAnnotation.java
index 43925cec9..5db64bc5c 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/SimpleMarkerAnnotation.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/SimpleMarkerAnnotation.java
@@ -67,15 +67,14 @@ public class SimpleMarkerAnnotation extends Annotation {
*
* @see Object#equals(java.lang.Object)
*/
+ @Override
public boolean equals(Object o) {
if (o != null && o.getClass() == getClass())
return fMarker.equals(((SimpleMarkerAnnotation) o).fMarker);
return false;
}
- /*
- * @see Object#hashCode()
- */
+ @Override
public int hashCode() {
return fMarker.hashCode();
}
@@ -102,9 +101,7 @@ public class SimpleMarkerAnnotation extends Annotation {
setType(annotationType);
}
- /*
- * @see org.eclipse.jface.text.source.Annotation#getText()
- */
+ @Override
public String getText() {
return MarkerUtilities.getMessage(fMarker);
}
diff --git a/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/TaskRulerAction.java b/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/TaskRulerAction.java
index e77bef4f3..21b7e103e 100644
--- a/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/TaskRulerAction.java
+++ b/org.eclipse.ui.editors/src/org/eclipse/ui/texteditor/TaskRulerAction.java
@@ -54,9 +54,7 @@ public class TaskRulerAction extends AbstractRulerActionDelegate {
super(bundle, prefix, editor, ruler, IMarker.TASK, false);
}
- /*
- * @see MarkerRulerAction#addMarker()
- */
+ @Override
protected void addMarker() {
IResource resource= getResource();
if (resource == null)
@@ -69,9 +67,7 @@ public class TaskRulerAction extends AbstractRulerActionDelegate {
}
}
- /*
- * @see AbstractRulerActionDelegate#createAction(ITextEditor, IVerticalRulerInfo)
- */
+ @Override
protected IAction createAction(ITextEditor editor, IVerticalRulerInfo rulerInfo) {
return new TaskMarkerRulerAction(TextEditorMessages.getBundleForConstructedKeys(), "Editor.ManageTasks.", editor, rulerInfo); //$NON-NLS-1$
}

Back to the top