Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEric Williams2019-04-15 09:36:25 -0400
committerEric Williams2019-04-15 09:36:37 -0400
commit9304fe94fda6a01723eca1806e3ff9b70dc5e406 (patch)
tree39e00262753f9074fc59c5feb0de7426f19f5078
parent44ae0603eb815357cbc63a475955dc0268f4623d (diff)
downloadeclipse.platform.swt-9304fe94fda6a01723eca1806e3ff9b70dc5e406.tar.gz
eclipse.platform.swt-9304fe94fda6a01723eca1806e3ff9b70dc5e406.tar.xz
eclipse.platform.swt-9304fe94fda6a01723eca1806e3ff9b70dc5e406.zip
Revert "Bug 466511: Replace dropdown menu custom drawing with png"
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common/org/eclipse/swt/custom/CTabFolderRenderer.java15
1 files changed, 2 insertions, 13 deletions
diff --git a/bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common/org/eclipse/swt/custom/CTabFolderRenderer.java b/bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common/org/eclipse/swt/custom/CTabFolderRenderer.java
index a4e66d1cea..2fa60dcea8 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common/org/eclipse/swt/custom/CTabFolderRenderer.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common/org/eclipse/swt/custom/CTabFolderRenderer.java
@@ -51,7 +51,6 @@ public class CTabFolderRenderer {
Color selectedOuterColor = null;
Color selectedInnerColor = null;
Color tabAreaColor = null;
- Color minMaxBorderColor = null;
/*
* Border color that was used in computing the cached anti-alias Colors.
* We have to recompute the colors if the border color changes
@@ -550,10 +549,6 @@ public class CTabFolderRenderer {
chevronFont.dispose();
chevronFont = null;
}
- if (minMaxBorderColor != null) {
- minMaxBorderColor.dispose();
- minMaxBorderColor = null;
- }
}
void disposeAntialiasColors() {
@@ -605,12 +600,6 @@ public class CTabFolderRenderer {
* @since 3.6
*/
protected void draw (int part, int state, Rectangle bounds, GC gc) {
- if (minMaxBorderColor == null) {
- // this color has to be identical to the colors used in the PNG files of
- // the view drop down menu located in
- // org.eclipse.e4.ui.workbench.renderers.swt/icons/full/elcl16/view_menu.png
- minMaxBorderColor = new Color (gc.getDevice(), 170, 170, 170);
- }
switch (part) {
case PART_BACKGROUND:
this.drawBackground(gc, bounds, state);
@@ -1133,7 +1122,7 @@ public class CTabFolderRenderer {
int x = maxRect.x + (maxRect.width - 10)/2;
int y = maxRect.y + 3;
- gc.setForeground(minMaxBorderColor);
+ gc.setForeground(display.getSystemColor(BUTTON_BORDER));
gc.setBackground(display.getSystemColor(BUTTON_FILL));
switch (maxImageState & (SWT.HOT | SWT.SELECTED)) {
@@ -1193,7 +1182,7 @@ public class CTabFolderRenderer {
int x = minRect.x + (minRect.width - 10)/2;
int y = minRect.y + 3;
- gc.setForeground(minMaxBorderColor);
+ gc.setForeground(display.getSystemColor(BUTTON_BORDER));
gc.setBackground(display.getSystemColor(BUTTON_FILL));
switch (minImageState & (SWT.HOT | SWT.SELECTED)) {

Back to the top