Download
Getting Started
Members
Projects
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
More
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
Toggle navigation
Bugzilla – Attachment 12921 Details for
Bug 60768
CBanner at top does vertical sizing based on left components
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
Log In
[x]
|
Terms of Use
|
Copyright Agent
Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read
this important communication.
[patch]
Fix for UI Workbench
patch_60768_UIWorkbench.txt (text/plain), 2.81 KB, created by
Hanna Farah
on 2004-06-30 13:50:33 EDT
(
hide
)
Description:
Fix for UI Workbench
Filename:
MIME Type:
Creator:
Hanna Farah
Created:
2004-06-30 13:50:33 EDT
Size:
2.81 KB
patch
obsolete
>Index: Eclipse UI/org/eclipse/ui/internal/PerspectiveSwitcher.java >=================================================================== >RCS file: /home/eclipse/org.eclipse.ui.workbench/Eclipse UI/org/eclipse/ui/internal/PerspectiveSwitcher.java,v >retrieving revision 1.17 >diff -u -r1.17 PerspectiveSwitcher.java >--- Eclipse UI/org/eclipse/ui/internal/PerspectiveSwitcher.java 29 Jun 2004 17:53:27 -0000 1.17 >+++ Eclipse UI/org/eclipse/ui/internal/PerspectiveSwitcher.java 30 Jun 2004 17:43:31 -0000 >@@ -345,7 +345,6 @@ > } > perspectiveBar.update(true); > setCoolItemSize(coolItem); >- > } > } > }; >@@ -422,12 +421,6 @@ > return; > > int rowHeight = toolbar.getItem(0).getBounds().height; >- >- // This gets the height of the tallest item. >- for (int i = 1; i < perspectiveBar.getControl().getItemCount(); i++) { >- rowHeight = Math.max(rowHeight, perspectiveBar.getControl().getItem(i).getBounds().height); >- } >- > Rectangle area = perspectiveCoolBar.getClientArea(); > int rows = rowHeight <= 0 ? 1 : (int)Math.max(1, Math.floor(area.height / rowHeight)); > if (rows == 1 || (toolbar.getStyle() & SWT.WRAP) == 0 || currentLocation == TOP_LEFT) { >@@ -674,6 +667,22 @@ > // make sure the selected item is visible > perspectiveBar.arrangeToolbar(); > perspectiveBar.getControl().redraw(); >+ } >+ >+ /** >+ * Updates the height of the CBanner >+ */ >+ public void updateCBannerHeight() { >+ if (topBar == null || perspectiveBar == null || perspectiveBar.getControl() == null) >+ return; >+ // This gets the height of the tallest tool item. >+ int maxRowHeight = 0; >+ ToolItem[] toolItems = perspectiveBar.getControl().getItems(); >+ for (int i = 0; i < toolItems.length; i++) { >+ maxRowHeight = Math.max(maxRowHeight, toolItems[i].getBounds().height); >+ } >+ // This sets the CBanner's minimum height to support large fonts >+ topBar.setMinRightHeight(maxRowHeight); > } > > } >Index: Eclipse UI/org/eclipse/ui/internal/WorkbenchWindow.java >=================================================================== >RCS file: /home/eclipse/org.eclipse.ui.workbench/Eclipse UI/org/eclipse/ui/internal/WorkbenchWindow.java,v >retrieving revision 1.237 >diff -u -r1.237 WorkbenchWindow.java >--- Eclipse UI/org/eclipse/ui/internal/WorkbenchWindow.java 17 Jun 2004 17:56:06 -0000 1.237 >+++ Eclipse UI/org/eclipse/ui/internal/WorkbenchWindow.java 30 Jun 2004 17:43:31 -0000 >@@ -513,8 +513,10 @@ > int result = super.open(); > getWorkbenchImpl().fireWindowOpened(this); > getAdvisor().postWindowOpen(getWindowConfigurer()); >- if (perspectiveSwitcher != null) >- perspectiveSwitcher.updatePerspectiveBar(); >+ if (perspectiveSwitcher != null) { >+ perspectiveSwitcher.updateCBannerHeight(); >+ perspectiveSwitcher.updatePerspectiveBar(); >+ } > return result; > } >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 60768
:
12920
|
12921
|
12968