diff options
author | Nikita Nemkin | 2018-02-21 14:54:35 +0000 |
---|---|---|
committer | Lars Vogel | 2018-05-02 07:10:07 +0000 |
commit | 4c7c704b33bb950ecf2425b4f12b3e83ad4ca02a (patch) | |
tree | 9e26792b49c00479eba66d70fa6f198daef67f79 /bundles | |
parent | ecd6aa1e7eca55f023f03ca244bf7e5f42912fd1 (diff) | |
download | eclipse.platform.swt-4c7c704b33bb950ecf2425b4f12b3e83ad4ca02a.tar.gz eclipse.platform.swt-4c7c704b33bb950ecf2425b4f12b3e83ad4ca02a.tar.xz eclipse.platform.swt-4c7c704b33bb950ecf2425b4f12b3e83ad4ca02a.zip |
Bug 533559 - [Win32] Move TASKBARBUTTONCREATED handler
TASKBARBUTTONCREATED is sent to top level windows, process it
in Shell.windowProc.
Bug 305335 provides a test snippet.
Change-Id: Ie4ba53cbee5964a216e19e1f84151960e1df9bfa
Signed-off-by: Nikita Nemkin <nikita@nemkin.ru>
Diffstat (limited to 'bundles')
-rw-r--r-- | bundles/org.eclipse.swt/Eclipse SWT/win32/org/eclipse/swt/widgets/Display.java | 12 | ||||
-rw-r--r-- | bundles/org.eclipse.swt/Eclipse SWT/win32/org/eclipse/swt/widgets/Shell.java | 12 |
2 files changed, 12 insertions, 12 deletions
diff --git a/bundles/org.eclipse.swt/Eclipse SWT/win32/org/eclipse/swt/widgets/Display.java b/bundles/org.eclipse.swt/Eclipse SWT/win32/org/eclipse/swt/widgets/Display.java index d3de3e489c..d621b05f68 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT/win32/org/eclipse/swt/widgets/Display.java +++ b/bundles/org.eclipse.swt/Eclipse SWT/win32/org/eclipse/swt/widgets/Display.java @@ -4771,18 +4771,6 @@ void wakeThread () { } long /*int*/ windowProc (long /*int*/ hwnd, long /*int*/ msg, long /*int*/ wParam, long /*int*/ lParam) { - if ((int)/*64*/msg == TASKBARBUTTONCREATED) { - if (taskBar != null) { - TaskItem [] items = taskBar.items; - for (int i=0; i<items.length; i++) { - TaskItem item = items [i]; - if (item != null && item.shell != null && item.shell.handle == hwnd) { - item.recreate (); - break; - } - } - } - } if (lastControl != null && lastHwnd == hwnd) { return lastControl.windowProc (hwnd, (int)/*64*/msg, wParam, lParam); } 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 c5da1593d1..6bcc71c7b7 100644 --- 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 @@ -2144,6 +2144,18 @@ long /*int*/ windowProc (long /*int*/ hwnd, int msg, long /*int*/ wParam, long / } return callWindowProc (hwnd, msg, wParam, lParam); } + if (hwnd == handle) { + if ((int)/*64*/msg == Display.TASKBARBUTTONCREATED) { + if (display.taskBar != null) { + for (TaskItem item : display.taskBar.items) { + if (item != null && item.shell == this) { + item.recreate (); + break; + } + } + } + } + } return super.windowProc (hwnd, msg, wParam, lParam); } |