Mercurial > projects > dwt-win
comparison dwt/widgets/Sash.d @ 213:36f5cb12e1a2
Update to SWT 3.4M7
author | Frank Benoit <benoit@tionex.de> |
---|---|
date | Sat, 17 May 2008 17:34:28 +0200 |
parents | ab60f3309436 |
children | fd9c62a2998e |
comparison
equal
deleted
inserted
replaced
212:ab60f3309436 | 213:36f5cb12e1a2 |
---|---|
279 if (result is LRESULT.ZERO) return result; | 279 if (result is LRESULT.ZERO) return result; |
280 | 280 |
281 /* Compute the banding rectangle */ | 281 /* Compute the banding rectangle */ |
282 auto hwndTrack = parent.handle; | 282 auto hwndTrack = parent.handle; |
283 POINT pt; | 283 POINT pt; |
284 pt.x = cast(short) (lParam & 0xFFFF); | 284 OS.POINTSTOPOINT (pt, lParam); |
285 pt.y = cast(short) (lParam >> 16); | |
286 RECT rect; | 285 RECT rect; |
287 OS.GetWindowRect (handle, &rect); | 286 OS.GetWindowRect (handle, &rect); |
288 OS.MapWindowPoints (handle, null, &pt, 1); | 287 OS.MapWindowPoints (handle, null, &pt, 1); |
289 startX = pt.x - rect.left; | 288 startX = pt.x - rect.left; |
290 startY = pt.y - rect.top; | 289 startY = pt.y - rect.top; |
363 if (result !is null) return result; | 362 if (result !is null) return result; |
364 if (!dragging || (wParam & OS.MK_LBUTTON) is 0) return result; | 363 if (!dragging || (wParam & OS.MK_LBUTTON) is 0) return result; |
365 | 364 |
366 /* Compute the banding rectangle */ | 365 /* Compute the banding rectangle */ |
367 POINT pt; | 366 POINT pt; |
368 pt.x = cast(short) (lParam & 0xFFFF); | 367 OS.POINTSTOPOINT (pt, lParam); |
369 pt.y = cast(short) (lParam >> 16); | |
370 auto hwndTrack = parent.handle; | 368 auto hwndTrack = parent.handle; |
371 OS.MapWindowPoints (handle, hwndTrack, &pt, 1); | 369 OS.MapWindowPoints (handle, hwndTrack, &pt, 1); |
372 RECT rect, clientRect; | 370 RECT rect, clientRect; |
373 OS.GetWindowRect (handle, &rect); | 371 OS.GetWindowRect (handle, &rect); |
374 int width = rect.right - rect.left; | 372 int width = rect.right - rect.left; |
415 } | 413 } |
416 | 414 |
417 override LRESULT WM_SETCURSOR (int wParam, int lParam) { | 415 override LRESULT WM_SETCURSOR (int wParam, int lParam) { |
418 LRESULT result = super.WM_SETCURSOR (wParam, lParam); | 416 LRESULT result = super.WM_SETCURSOR (wParam, lParam); |
419 if (result !is null) return result; | 417 if (result !is null) return result; |
420 int hitTest = lParam & 0xFFFF; | 418 int hitTest = cast(short) OS.LOWORD (lParam); |
421 if (hitTest is OS.HTCLIENT) { | 419 if (hitTest is OS.HTCLIENT) { |
422 HCURSOR hCursor; | 420 HCURSOR hCursor; |
423 if ((style & DWT.HORIZONTAL) !is 0) { | 421 if ((style & DWT.HORIZONTAL) !is 0) { |
424 hCursor = OS.LoadCursor (null, cast(TCHAR*)OS.IDC_SIZENS); | 422 hCursor = OS.LoadCursor (null, cast(TCHAR*)OS.IDC_SIZENS); |
425 } else { | 423 } else { |