diff options
author | Felipe Heidrich | 2006-07-27 22:14:19 +0000 |
---|---|---|
committer | Felipe Heidrich | 2006-07-27 22:14:19 +0000 |
commit | c6a55e682932cf2d9c5de5959d835ce856901679 (patch) | |
tree | 69da375f724668a1ee47035bc4f3116f2fc81929 /bundles | |
parent | a84b31d5b33dc25b49cb488d9000ba1334601a03 (diff) | |
download | eclipse.platform.swt-c6a55e682932cf2d9c5de5959d835ce856901679.tar.gz eclipse.platform.swt-c6a55e682932cf2d9c5de5959d835ce856901679.tar.xz eclipse.platform.swt-c6a55e682932cf2d9c5de5959d835ce856901679.zip |
151137 - thumb doesn't work for tree with column
Diffstat (limited to 'bundles')
-rwxr-xr-x | bundles/org.eclipse.swt/Eclipse SWT/win32/org/eclipse/swt/widgets/Tree.java | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/bundles/org.eclipse.swt/Eclipse SWT/win32/org/eclipse/swt/widgets/Tree.java b/bundles/org.eclipse.swt/Eclipse SWT/win32/org/eclipse/swt/widgets/Tree.java index e7f3609845..9b79a25f5e 100755 --- a/bundles/org.eclipse.swt/Eclipse SWT/win32/org/eclipse/swt/widgets/Tree.java +++ b/bundles/org.eclipse.swt/Eclipse SWT/win32/org/eclipse/swt/widgets/Tree.java @@ -4756,6 +4756,19 @@ int windowProc (int hwnd, int msg, int wParam, int lParam) { info.cbSize = SCROLLINFO.sizeof; info.fMask = OS.SIF_ALL; OS.GetScrollInfo (hwndParent, OS.SB_VERT, info); + /* + * Update the nPos field to match the nTrackPos field + * so that the tree scrolls when the scroll bar of the + * parent is dragged. + * + * NOTE: For some reason, this code is only necessary + * on Windows Vista. + */ + if (!OS.IsWinCE && OS.WIN32_VERSION >= OS.VERSION (6, 0)) { + if ((wParam & 0xFFFF) == OS.SB_THUMBTRACK) { + info.nPos = info.nTrackPos; + } + } OS.SetScrollInfo (handle, OS.SB_VERT, info, true); int code = OS.SendMessage (handle, OS.WM_VSCROLL, wParam, lParam); OS.GetScrollInfo (handle, OS.SB_VERT, info); |