Skip to content

Commit dc49d74

Browse files
eclipse-platform-botakurtakov
authored andcommitted
Perform clean code of bundles/org.eclipse.ui.workbench
1 parent 1a4d1a8 commit dc49d74

29 files changed

+211
-0
lines changed

bundles/org.eclipse.ui.workbench/eclipseui/org/eclipse/ui/IKeyBindingService.java

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,26 +43,30 @@ public interface IKeyBindingService {
4343
*
4444
* @return the active accelerator scope ids.
4545
*/
46+
@Deprecated
4647
String[] getScopes();
4748

4849
/**
4950
* Registers an action with the key binding service.
5051
*
5152
* @param action the action to be registered with the key binding service.
5253
*/
54+
@Deprecated
5355
void registerAction(IAction action);
5456

5557
/**
5658
* Sets the active accelerator scope ids.
5759
*
5860
* @param scopes the active accelerator scope ids.
5961
*/
62+
@Deprecated
6063
void setScopes(String[] scopes);
6164

6265
/**
6366
* Unregisters an action with the key binding service.
6467
*
6568
* @param action the action to be unregistered with the key binding service.
6669
*/
70+
@Deprecated
6771
void unregisterAction(IAction action);
6872
}

bundles/org.eclipse.ui.workbench/eclipseui/org/eclipse/ui/INestableKeyBindingService.java

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,7 @@ public interface INestableKeyBindingService extends IKeyBindingService {
4646
* case of a <code>null</code> parameter); <code>false</code> if nothing
4747
* changed.
4848
*/
49+
@Deprecated
4950
boolean activateKeyBindingService(IWorkbenchSite nestedSite);
5051

5152
/**
@@ -58,6 +59,7 @@ public interface INestableKeyBindingService extends IKeyBindingService {
5859
* @return The associated service, if any; or a new associated service, if none
5960
* existed previously.
6061
*/
62+
@Deprecated
6163
IKeyBindingService getKeyBindingService(IWorkbenchSite nestedSite);
6264

6365
/**
@@ -70,6 +72,7 @@ public interface INestableKeyBindingService extends IKeyBindingService {
7072
* @return <code>true</code> if the service existed and could be removed;
7173
* <code>false</code> otherwise.
7274
*/
75+
@Deprecated
7376
boolean removeKeyBindingService(IWorkbenchSite nestedSite);
7477

7578
}

bundles/org.eclipse.ui.workbench/eclipseui/org/eclipse/ui/actions/OpenNewPageMenu.java

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,7 @@ public class OpenNewPageMenu extends PerspectiveMenu {
6363
* @param window the window where a new page is created if an item within the
6464
* menu is selected
6565
*/
66+
@Deprecated
6667
public OpenNewPageMenu(IWorkbenchWindow window) {
6768
this(window, null);
6869
}
@@ -74,11 +75,13 @@ public OpenNewPageMenu(IWorkbenchWindow window) {
7475
* menu is selected
7576
* @param input the page input
7677
*/
78+
@Deprecated
7779
public OpenNewPageMenu(IWorkbenchWindow window, IAdaptable input) {
7880
super(window, "Open New Page Menu");//$NON-NLS-1$
7981
this.pageInput = input;
8082
}
8183

84+
@Deprecated
8285
@Override
8386
protected void run(IPerspectiveDescriptor desc) {
8487
// Verify page input.
@@ -102,6 +105,7 @@ protected void run(IPerspectiveDescriptor desc) {
102105
*
103106
* @param input the page input
104107
*/
108+
@Deprecated
105109
public void setPageInput(IAdaptable input) {
106110
pageInput = input;
107111
}

bundles/org.eclipse.ui.workbench/eclipseui/org/eclipse/ui/actions/OpenNewWindowMenu.java

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,7 @@ public class OpenNewWindowMenu extends PerspectiveMenu {
6262
* @param window the window where a new page is created if an item within the
6363
* menu is selected
6464
*/
65+
@Deprecated
6566
public OpenNewWindowMenu(IWorkbenchWindow window) {
6667
this(window, null);
6768
}
@@ -73,6 +74,7 @@ public OpenNewWindowMenu(IWorkbenchWindow window) {
7374
* menu is selected
7475
* @param input the page input
7576
*/
77+
@Deprecated
7678
public OpenNewWindowMenu(IWorkbenchWindow window, IAdaptable input) {
7779
super(window, "Open New Page Menu");//$NON-NLS-1$
7880
this.pageInput = input;
@@ -81,6 +83,7 @@ public OpenNewWindowMenu(IWorkbenchWindow window, IAdaptable input) {
8183
/**
8284
* Opens a new window with a particular perspective and input.
8385
*/
86+
@Deprecated
8487
@Override
8588
protected void run(IPerspectiveDescriptor desc) {
8689
// Verify page input.
@@ -104,6 +107,7 @@ protected void run(IPerspectiveDescriptor desc) {
104107
*
105108
* @param input the page input
106109
*/
110+
@Deprecated
107111
public void setPageInput(IAdaptable input) {
108112
pageInput = input;
109113
}

bundles/org.eclipse.ui.workbench/eclipseui/org/eclipse/ui/actions/OpenPerspectiveMenu.java

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,7 @@ public class OpenPerspectiveMenu extends PerspectiveMenu {
7070
* @param window the window where a new page is created if an item within
7171
* the menu is selected
7272
*/
73+
@Deprecated
7374
public OpenPerspectiveMenu(IMenuManager menuManager, IWorkbenchWindow window) {
7475
this(window);
7576
this.parentMenuManager = menuManager;
@@ -88,6 +89,7 @@ public OpenPerspectiveMenu(IMenuManager menuManager, IWorkbenchWindow window) {
8889
* @param window the window where a new page is created if an item within the
8990
* menu is selected
9091
*/
92+
@Deprecated
9193
public OpenPerspectiveMenu(IWorkbenchWindow window) {
9294
this(window, null);
9395
showActive(true);
@@ -100,6 +102,7 @@ public OpenPerspectiveMenu(IWorkbenchWindow window) {
100102
* menu is selected
101103
* @param input the page input
102104
*/
105+
@Deprecated
103106
public OpenPerspectiveMenu(IWorkbenchWindow window, IAdaptable input) {
104107
super(window, "Open New Page Menu");//$NON-NLS-1$
105108
this.pageInput = input;
@@ -129,6 +132,7 @@ private String openPerspectiveSetting() {
129132
*
130133
* @param desc the selected perspective
131134
*/
135+
@Deprecated
132136
@Override
133137
protected void run(IPerspectiveDescriptor desc) {
134138
openPage(desc);
@@ -140,6 +144,7 @@ protected void run(IPerspectiveDescriptor desc) {
140144
* @param desc the selected perspective
141145
* @param event the event sent along with the selection callback
142146
*/
147+
@Deprecated
143148
@Override
144149
protected void run(IPerspectiveDescriptor desc, SelectionEvent event) {
145150
openPage(desc);
@@ -166,13 +171,15 @@ private void openPage(IPerspectiveDescriptor desc) {
166171
*
167172
* @param input the page input
168173
*/
174+
@Deprecated
169175
public void setPageInput(IAdaptable input) {
170176
pageInput = input;
171177
}
172178

173179
/**
174180
* @param isEnabled true if replace menu item is enabled within its parent menu.
175181
*/
182+
@Deprecated
176183
public void setReplaceEnabled(boolean isEnabled) {
177184
if (replaceEnabled != isEnabled) {
178185
replaceEnabled = isEnabled;

bundles/org.eclipse.ui.workbench/eclipseui/org/eclipse/ui/contexts/ContextEvent.java

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,7 @@ public final class ContextEvent {
6363
* @param nameChanged true, iff the name property changed.
6464
* @param parentIdChanged true, iff the parentId property changed.
6565
*/
66+
@Deprecated
6667
public ContextEvent(IContext context, boolean definedChanged, boolean enabledChanged, boolean nameChanged,
6768
boolean parentIdChanged) {
6869
if (context == null) {
@@ -82,6 +83,7 @@ public ContextEvent(IContext context, boolean definedChanged, boolean enabledCha
8283
* @return the instance of the interface that changed. Guaranteed not to be
8384
* <code>null</code>.
8485
*/
86+
@Deprecated
8587
public IContext getContext() {
8688
return context;
8789
}
@@ -91,6 +93,7 @@ public IContext getContext() {
9193
*
9294
* @return true, iff the defined property changed.
9395
*/
96+
@Deprecated
9497
public boolean hasDefinedChanged() {
9598
return definedChanged;
9699
}
@@ -100,6 +103,7 @@ public boolean hasDefinedChanged() {
100103
*
101104
* @return true, iff the enabled property changed.
102105
*/
106+
@Deprecated
103107
public boolean hasEnabledChanged() {
104108
return enabledChanged;
105109
}
@@ -109,6 +113,7 @@ public boolean hasEnabledChanged() {
109113
*
110114
* @return true, iff the name property changed.
111115
*/
116+
@Deprecated
112117
public boolean hasNameChanged() {
113118
return nameChanged;
114119
}
@@ -118,6 +123,7 @@ public boolean hasNameChanged() {
118123
*
119124
* @return true, iff the parentId property changed.
120125
*/
126+
@Deprecated
121127
public boolean hasParentIdChanged() {
122128
return parentIdChanged;
123129
}

bundles/org.eclipse.ui.workbench/eclipseui/org/eclipse/ui/contexts/ContextException.java

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,7 @@ public abstract class ContextException extends Exception {
4141
*
4242
* @param message the detail message.
4343
*/
44+
@Deprecated
4445
public ContextException(String message) {
4546
super(message);
4647
}
@@ -52,6 +53,7 @@ public ContextException(String message) {
5253
* @param message the detail message.
5354
* @param cause the cause.
5455
*/
56+
@Deprecated
5557
public ContextException(String message, Throwable cause) {
5658
super(message);
5759
// don't pass the cause to super, to allow compilation against JCL Foundation
@@ -65,6 +67,7 @@ public ContextException(String message, Throwable cause) {
6567
* @return the cause or <code>null</code>
6668
* @since 3.1
6769
*/
70+
@Deprecated
6871
@Override
6972
public Throwable getCause() {
7073
return cause;

bundles/org.eclipse.ui.workbench/eclipseui/org/eclipse/ui/contexts/ContextManagerEvent.java

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -90,6 +90,7 @@ public final class ContextManagerEvent {
9090
* enabledContextIdsChanged is
9191
* <code>true</code>.
9292
*/
93+
@Deprecated
9394
public ContextManagerEvent(IContextManager contextManager, boolean definedContextIdsChanged,
9495
boolean enabledContextIdsChanged, Set previouslyDefinedContextIds, Set previouslyEnabledContextIds) {
9596
if (contextManager == null) {
@@ -127,6 +128,7 @@ public ContextManagerEvent(IContextManager contextManager, boolean definedContex
127128
* @return the instance of the interface that changed. Guaranteed not to be
128129
* <code>null</code>.
129130
*/
131+
@Deprecated
130132
public IContextManager getContextManager() {
131133
return contextManager;
132134
}
@@ -141,6 +143,7 @@ public IContextManager getContextManager() {
141143
* <code>false</code> and is guaranteed to not be null if
142144
* haveDefinedContextIdsChanged() is <code>true</code>.
143145
*/
146+
@Deprecated
144147
public Set getPreviouslyDefinedContextIds() {
145148
return previouslyDefinedContextIds;
146149
}
@@ -155,6 +158,7 @@ public Set getPreviouslyDefinedContextIds() {
155158
* <code>false</code> and is guaranteed to not be null if
156159
* haveEnabledContextIdsChanged() is <code>true</code>.
157160
*/
161+
@Deprecated
158162
public Set getPreviouslyEnabledContextIds() {
159163
return previouslyEnabledContextIds;
160164
}
@@ -164,6 +168,7 @@ public Set getPreviouslyEnabledContextIds() {
164168
*
165169
* @return true, iff the definedContextIds property changed.
166170
*/
171+
@Deprecated
167172
public boolean haveDefinedContextIdsChanged() {
168173
return definedContextIdsChanged;
169174
}
@@ -173,6 +178,7 @@ public boolean haveDefinedContextIdsChanged() {
173178
*
174179
* @return true, iff the enabledContextIds property changed.
175180
*/
181+
@Deprecated
176182
public boolean haveEnabledContextIdsChanged() {
177183
return enabledContextIdsChanged;
178184
}

bundles/org.eclipse.ui.workbench/eclipseui/org/eclipse/ui/contexts/EnabledSubmission.java

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -91,6 +91,7 @@ public final class EnabledSubmission implements Comparable {
9191
* @param contextId the identifier of the context to be enabled.
9292
* Must not be <code>null</code>.
9393
*/
94+
@Deprecated
9495
public EnabledSubmission(String activePartId, Shell activeShell, IWorkbenchPartSite activeWorkbenchPartSite,
9596
String contextId) {
9697
if (contextId == null) {
@@ -106,6 +107,7 @@ public EnabledSubmission(String activePartId, Shell activeShell, IWorkbenchPartS
106107
/**
107108
* @see Comparable#compareTo(java.lang.Object)
108109
*/
110+
@Deprecated
109111
@Override
110112
public int compareTo(Object object) {
111113
EnabledSubmission castedObject = (EnabledSubmission) object;
@@ -133,6 +135,7 @@ public int compareTo(Object object) {
133135
* @return the identifier of the part that must be active for this request to be
134136
* considered. May be <code>null</code>.
135137
*/
138+
@Deprecated
136139
public String getActivePartId() {
137140
return activePartId;
138141
}
@@ -143,6 +146,7 @@ public String getActivePartId() {
143146
* @return the shell that must be active for this request to be considered. May
144147
* be <code>null</code>.
145148
*/
149+
@Deprecated
146150
public Shell getActiveShell() {
147151
return activeShell;
148152
}
@@ -154,6 +158,7 @@ public Shell getActiveShell() {
154158
* @return the workbench part site of the part that must be active for this
155159
* request to be considered. May be <code>null</code>.
156160
*/
161+
@Deprecated
157162
public IWorkbenchPartSite getActiveWorkbenchPartSite() {
158163
return activeWorkbenchPartSite;
159164
}
@@ -164,13 +169,15 @@ public IWorkbenchPartSite getActiveWorkbenchPartSite() {
164169
* @return the identifier of the context to be enabled. Guaranteed not to be
165170
* <code>null</code>.
166171
*/
172+
@Deprecated
167173
public String getContextId() {
168174
return contextId;
169175
}
170176

171177
/**
172178
* @see Object#toString()
173179
*/
180+
@Deprecated
174181
@Override
175182
public String toString() {
176183
if (string == null) {

0 commit comments

Comments
 (0)