summaryrefslogtreecommitdiffstats
path: root/bundles/org.eclipse.swt/Eclipse SWT/win32/org/eclipse/swt/widgets/ExpandBar.java
diff options
context:
space:
mode:
authorSteve Northover <steve>2007-02-03 00:27:34 +0000
committerSteve Northover <steve>2007-02-03 00:27:34 +0000
commit43909f2de7482a2b1f3cd58115da240082619bcb (patch)
tree8f95552df91f19011250760056225170c13f8967 /bundles/org.eclipse.swt/Eclipse SWT/win32/org/eclipse/swt/widgets/ExpandBar.java
parent39101717f844dfbf8371d5363156016a525305c4 (diff)
downloadeclipse.platform.swt-43909f2de7482a2b1f3cd58115da240082619bcb.tar.gz
eclipse.platform.swt-43909f2de7482a2b1f3cd58115da240082619bcb.tar.xz
eclipse.platform.swt-43909f2de7482a2b1f3cd58115da240082619bcb.zip
redraw when foreground changed & set default spacing to 4
Diffstat (limited to 'bundles/org.eclipse.swt/Eclipse SWT/win32/org/eclipse/swt/widgets/ExpandBar.java')
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT/win32/org/eclipse/swt/widgets/ExpandBar.java14
1 files changed, 11 insertions, 3 deletions
diff --git a/bundles/org.eclipse.swt/Eclipse SWT/win32/org/eclipse/swt/widgets/ExpandBar.java b/bundles/org.eclipse.swt/Eclipse SWT/win32/org/eclipse/swt/widgets/ExpandBar.java
index 90d955ceaf..fbf0c496a9 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT/win32/org/eclipse/swt/widgets/ExpandBar.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT/win32/org/eclipse/swt/widgets/ExpandBar.java
@@ -43,7 +43,7 @@ public class ExpandBar extends Composite {
ExpandItem[] items;
int itemCount;
ExpandItem focusItem;
- int spacing;
+ int spacing = 4;
int yCurrentScroll;
int hFont;
@@ -466,14 +466,22 @@ public void removeExpandListener (ExpandListener listener) {
eventTable.unhook (SWT.Collapse, listener);
}
+void setBackgroundPixel (int pixel) {
+ super.setBackgroundPixel (pixel);
+ if (!OS.IsWinCE) {
+ int flags = OS.RDW_ERASE | OS.RDW_FRAME | OS.RDW_INVALIDATE | OS.RDW_ALLCHILDREN;
+ OS.RedrawWindow (handle, null, 0, flags);
+ }
+}
+
public void setFont (Font font) {
super.setFont (font);
hFont = font != null ? font.handle : 0;
layoutItems (0, true);
}
-void setBackgroundPixel (int pixel) {
- super.setBackgroundPixel (pixel);
+void setForegroundPixel (int pixel) {
+ super.setForegroundPixel (pixel);
if (!OS.IsWinCE) {
int flags = OS.RDW_ERASE | OS.RDW_FRAME | OS.RDW_INVALIDATE | OS.RDW_ALLCHILDREN;
OS.RedrawWindow (handle, null, 0, flags);