diff options
author | Pawel Piech | 2011-04-29 23:08:23 +0000 |
---|---|---|
committer | Pawel Piech | 2011-04-29 23:08:23 +0000 |
commit | 0b1f6c8f4ac80b041f209a0438e01745035f1653 (patch) | |
tree | 15b5972bf1bed55415f04fbfd3aeeaf7acf02444 | |
parent | c4608152ed8db2f2c79c0fd130a9eeaad9fc9687 (diff) | |
download | eclipse.platform.debug-0b1f6c8f4ac80b041f209a0438e01745035f1653.tar.gz eclipse.platform.debug-0b1f6c8f4ac80b041f209a0438e01745035f1653.tar.xz eclipse.platform.debug-0b1f6c8f4ac80b041f209a0438e01745035f1653.zip |
Bug 335536 - [beadcrumb] Debug breadcrumb does not activate until view is resized to 0 height
-rw-r--r-- | org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/launch/LaunchView.java | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/launch/LaunchView.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/launch/LaunchView.java index 94d4cd462..4180d3c88 100644 --- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/launch/LaunchView.java +++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/launch/LaunchView.java @@ -156,6 +156,8 @@ public class LaunchView extends AbstractDebugView implements ISelectionChangedLi private static final String RESTART = "restart"; //$NON-NLS-1$ + private static final int BREADCRUMB_TRIGGER_HEIGHT_DEFAULT = 30; // pixels + private static final int BREADCRUMB_TRIGGER_RANGE = 5; // pixels private static final int BREADCRUMB_STICKY_RANGE = 20; // pixels @@ -753,6 +755,11 @@ public class LaunchView extends AbstractDebugView implements ISelectionChangedLi */ private void autoSelectViewPage(Composite parent) { int breadcrumbHeight = fBreadcrumbPage.getHeight(); + // Breadcrumb may report size 0 if it hasn't been shown yet. + // Bug 335536. + if (breadcrumbHeight == 0) { + breadcrumbHeight = BREADCRUMB_TRIGGER_HEIGHT_DEFAULT; + } if (parent.getClientArea().height < breadcrumbHeight + BREADCRUMB_TRIGGER_RANGE) { showBreadcrumbPage(); } |