diff options
author | Michael Rennie | 2007-01-04 19:42:03 +0000 |
---|---|---|
committer | Michael Rennie | 2007-01-04 19:42:03 +0000 |
commit | a8cf0277a9d6135f136593a5687f128fa20b91e6 (patch) | |
tree | 4b8b5b06702bfa653b472688f3b22bb8c6b0f064 /org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/launchConfigurations/LaunchConfigurationViewer.java | |
parent | 03542716b3286041bf91175fa2e0bb5f34509984 (diff) | |
download | eclipse.platform.debug-a8cf0277a9d6135f136593a5687f128fa20b91e6.tar.gz eclipse.platform.debug-a8cf0277a9d6135f136593a5687f128fa20b91e6.tar.xz eclipse.platform.debug-a8cf0277a9d6135f136593a5687f128fa20b91e6.zip |
filter label update for 167667
[launching] No visual clue configurations are filtered from dialog
Diffstat (limited to 'org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/launchConfigurations/LaunchConfigurationViewer.java')
-rw-r--r-- | org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/launchConfigurations/LaunchConfigurationViewer.java | 24 |
1 files changed, 21 insertions, 3 deletions
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/launchConfigurations/LaunchConfigurationViewer.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/launchConfigurations/LaunchConfigurationViewer.java index 60829f79b..7a553ce2d 100644 --- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/launchConfigurations/LaunchConfigurationViewer.java +++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/launchConfigurations/LaunchConfigurationViewer.java @@ -20,6 +20,7 @@ import org.eclipse.jface.viewers.TreeViewer; import org.eclipse.swt.widgets.Composite; import org.eclipse.swt.widgets.Tree; import org.eclipse.swt.widgets.TreeItem; +import org.eclipse.swt.widgets.Widget; /** * This class allow the notion of the viewer to be abstracted from the launch configuration view, as well as allowing the over-riding of @@ -80,11 +81,14 @@ public class LaunchConfigurationViewer extends TreeViewer { //pick best child, or default to parent index = selectIndex(pitem.getItemCount(), indices[1]); if(index > -1) { - o = pitem.getItem(index); + o = pitem.getItem(index).getData(); } else { if(pitem.getItemCount() > 0) { o = pitem.getItem((indices[1]-1 > -1 ? indices[1]-1 : 0)).getData(); + if(o == null) { + o = pitem.getData(); + } } } } @@ -120,14 +124,28 @@ public class LaunchConfigurationViewer extends TreeViewer { * Returns the total count of all of the children that <i>could</i> be visible at * the time the input was set to the viewer * @return the total number of elements - * - * @since 3.3 */ protected int getTotalChildCount() { return fTotalCount; } /** + * @see org.eclipse.jface.viewers.AbstractTreeViewer#remove(java.lang.Object) + */ + public void remove(Object elementsOrTreePaths) { + super.remove(elementsOrTreePaths); + fTotalCount--; + } + + /** + * @see org.eclipse.jface.viewers.TreeViewer#internalAdd(org.eclipse.swt.widgets.Widget, java.lang.Object, java.lang.Object[]) + */ + protected void internalAdd(Widget widget, Object parentElement, Object[] childElements) { + super.internalAdd(widget, parentElement, childElements); + fTotalCount++; + } + + /** * @see org.eclipse.jface.viewers.AbstractTreeViewer#inputChanged(java.lang.Object, java.lang.Object) */ protected void inputChanged(Object input, Object oldInput) { |