Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSteve Northover2007-01-19 15:48:37 +0000
committerSteve Northover2007-01-19 15:48:37 +0000
commitba5a58793fc78e39453b1cc85e336aea768c9126 (patch)
tree3b613527a9b08f0031f65189707e194e045fd113
parent1e490740d798f6613be3da437070afc86a62358e (diff)
downloadeclipse.platform.swt-ba5a58793fc78e39453b1cc85e336aea768c9126.tar.gz
eclipse.platform.swt-ba5a58793fc78e39453b1cc85e336aea768c9126.tar.xz
eclipse.platform.swt-ba5a58793fc78e39453b1cc85e336aea768c9126.zip
171048 - Resizing on Vista causes black bars to appear (3.2 maintenance stream)
-rwxr-xr-xbundles/org.eclipse.swt/Eclipse SWT/win32/org/eclipse/swt/widgets/Shell.java18
1 files changed, 18 insertions, 0 deletions
diff --git a/bundles/org.eclipse.swt/Eclipse SWT/win32/org/eclipse/swt/widgets/Shell.java b/bundles/org.eclipse.swt/Eclipse SWT/win32/org/eclipse/swt/widgets/Shell.java
index 7e9b9493f8..a5b540b0a8 100755
--- a/bundles/org.eclipse.swt/Eclipse SWT/win32/org/eclipse/swt/widgets/Shell.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT/win32/org/eclipse/swt/widgets/Shell.java
@@ -1776,6 +1776,24 @@ LRESULT WM_DESTROY (int wParam, int lParam) {
return result;
}
+LRESULT WM_ERASEBKGND (int wParam, int lParam) {
+ LRESULT result = super.WM_ERASEBKGND (wParam, lParam);
+ if (result != null) return result;
+ /*
+ * Feature in Windows. When a shell is resized by dragging
+ * the resize handles, Windows temporarily fills in black
+ * rectangles where the new contents of the shell should
+ * draw. The fix is to always draw the background of shells.
+ *
+ * NOTE: This only happens on Vista.
+ */
+ if (!OS.IsWinCE && OS.WIN32_VERSION >= OS.VERSION (6, 0)) {
+ drawBackground (wParam);
+ return LRESULT.ONE;
+ }
+ return result;
+}
+
LRESULT WM_ENTERIDLE (int wParam, int lParam) {
LRESULT result = super.WM_ENTERIDLE (wParam, lParam);
if (result != null) return result;

Back to the top