Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Rennie2008-12-16 14:44:50 +0000
committerMichael Rennie2008-12-16 14:44:50 +0000
commitdf4c38839f95b6178fa292dc4f7749204caf354d (patch)
tree81b505607eeca115cbed0438e187d58bd548e4ba /org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/launchConfigurations/LaunchConfigurationTabGroupViewer.java
parente9d015432ab39a3816f35b336e640e489030d576 (diff)
downloadeclipse.platform.debug-df4c38839f95b6178fa292dc4f7749204caf354d.tar.gz
eclipse.platform.debug-df4c38839f95b6178fa292dc4f7749204caf354d.tar.xz
eclipse.platform.debug-df4c38839f95b6178fa292dc4f7749204caf354d.zip
Bug 256569 Possibly broken code in LaunchConfigurationTabGroupViewer.setSelection(ISelection, boolean)
Diffstat (limited to 'org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/launchConfigurations/LaunchConfigurationTabGroupViewer.java')
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/launchConfigurations/LaunchConfigurationTabGroupViewer.java54
1 files changed, 8 insertions, 46 deletions
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/launchConfigurations/LaunchConfigurationTabGroupViewer.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/launchConfigurations/LaunchConfigurationTabGroupViewer.java
index ad98d93da..ac0045551 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/launchConfigurations/LaunchConfigurationTabGroupViewer.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/launchConfigurations/LaunchConfigurationTabGroupViewer.java
@@ -41,10 +41,6 @@ import org.eclipse.jface.dialogs.IDialogConstants;
import org.eclipse.jface.operation.IRunnableWithProgress;
import org.eclipse.jface.resource.ColorRegistry;
import org.eclipse.jface.resource.JFaceResources;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.jface.viewers.Viewer;
import org.eclipse.swt.SWT;
import org.eclipse.swt.custom.BusyIndicator;
import org.eclipse.swt.custom.CTabFolder;
@@ -76,7 +72,7 @@ import com.ibm.icu.text.MessageFormat;
* A viewer that displays tabs for a launch configuration, with apply and revert
* buttons.
*/
-public class LaunchConfigurationTabGroupViewer extends Viewer {
+public class LaunchConfigurationTabGroupViewer {
/**
* Containing launch dialog
@@ -432,14 +428,7 @@ public class LaunchConfigurationTabGroupViewer extends Viewer {
protected Button getRevertButton() {
return fRevertButton;
}
-
- /**
- * Sets the tab folder
- */
- protected CTabFolder getTabFolder() {
- return fTabFolder;
- }
-
+
/**
* Sets the current name
*/
@@ -465,24 +454,20 @@ public class LaunchConfigurationTabGroupViewer extends Viewer {
/**
* Returns the shell this viewer is contained in.
*/
- protected Shell getShell() {
+ private Shell getShell() {
return getControl().getShell();
}
/**
- * @see org.eclipse.jface.viewers.IInputProvider#getInput()
+ * Returns the current input to the viewer. Input will
+ * be one of {@link ILaunchConfiguration} or {@link ILaunchConfigurationType}
+ *
+ * @return returns the current input
*/
public Object getInput() {
return fInput;
}
- /**
- * @see org.eclipse.jface.viewers.ISelectionProvider#getSelection()
- */
- public ISelection getSelection() {
- return new StructuredSelection(fWorkingCopy);
- }
-
/* (non-Javadoc)
* @see org.eclipse.jface.viewers.Viewer#refresh()
*/
@@ -908,30 +893,7 @@ public class LaunchConfigurationTabGroupViewer extends Viewer {
// Otherwise return the tab group
return (ILaunchConfigurationTabGroup)finalArray[0];
}
-
- /**
- * @see org.eclipse.jface.viewers.Viewer#setSelection(org.eclipse.jface.viewers.ISelection, boolean)
- */
- public void setSelection(ISelection selection, boolean reveal) {
- if (getWorkingCopy() != null) {
- if (selection instanceof IStructuredSelection) {
- IStructuredSelection structuredSelection = (IStructuredSelection)selection;
- Object object = structuredSelection.getFirstElement();
- if (object instanceof ILaunchConfigurationTab) {
- ILaunchConfigurationTab[] tabs = getTabs();
- for (int i = 0; i < tabs.length; i++) {
- if (tabs[i].equals(object)) {
- fCurrentTabIndex = i;
- fTabFolder.setSelection(i);
- }
- return;
- }
- }
- }
- }
-
- }
-
+
/**
* Returns the tabs currently being displayed, or
* <code>null</code> if none.

Back to the top