# HG changeset patch
# User Frank Benoit
# Date 1202115920 -3600
# Node ID 0f25be5cbe6feddc9f0bf247134b0ef0eb63ab36
# Parent 0405e18fec7f83cb43b62fc616ee91e30df730f9
Added aliases and overrides from generated file, remaining widgets. Thanks torhu for doing this job.
diff -r 0405e18fec7f -r 0f25be5cbe6f dwt/widgets/Canvas.d
--- a/dwt/widgets/Canvas.d Sun Feb 03 15:48:14 2008 -0800
+++ b/dwt/widgets/Canvas.d Mon Feb 04 10:05:20 2008 +0100
@@ -125,7 +125,7 @@
return caret;
}
-void releaseChildren (bool destroy) {
+override void releaseChildren (bool destroy) {
if (caret !is null) {
caret.release (false);
caret = null;
@@ -288,7 +288,7 @@
}
}
-public void setFont (Font font) {
+override public void setFont (Font font) {
checkWidget ();
if (caret !is null) caret.setFont (font);
super.setFont (font);
@@ -307,7 +307,7 @@
return super.windowProc (hwnd, msg, wParam, lParam);
}
-LRESULT WM_IME_COMPOSITION (int wParam, int lParam) {
+override LRESULT WM_IME_COMPOSITION (int wParam, int lParam) {
LRESULT result = super.WM_IME_COMPOSITION (wParam, lParam);
/*
* Bug in Windows. On Korean Windows XP, the IME window
@@ -340,7 +340,7 @@
return result;
}
-LRESULT WM_INPUTLANGCHANGE (int wParam, int lParam) {
+override LRESULT WM_INPUTLANGCHANGE (int wParam, int lParam) {
LRESULT result = super.WM_INPUTLANGCHANGE (wParam, lParam);
if (caret !is null && caret.isFocusCaret ()) {
caret.setIMEFont ();
@@ -349,25 +349,25 @@
return result;
}
-LRESULT WM_KILLFOCUS (int wParam, int lParam) {
+override LRESULT WM_KILLFOCUS (int wParam, int lParam) {
LRESULT result = super.WM_KILLFOCUS (wParam, lParam);
if (caret !is null) caret.killFocus ();
return result;
}
-LRESULT WM_SETFOCUS (int wParam, int lParam) {
+override LRESULT WM_SETFOCUS (int wParam, int lParam) {
LRESULT result = super.WM_SETFOCUS (wParam, lParam);
if (caret !is null) caret.setFocus ();
return result;
}
-LRESULT WM_SIZE (int wParam, int lParam) {
+override LRESULT WM_SIZE (int wParam, int lParam) {
LRESULT result = super.WM_SIZE (wParam, lParam);
if (caret !is null && caret.isFocusCaret ()) caret.resizeIME ();
return result;
}
-LRESULT WM_WINDOWPOSCHANGED (int wParam, int lParam) {
+override LRESULT WM_WINDOWPOSCHANGED (int wParam, int lParam) {
LRESULT result = super.WM_WINDOWPOSCHANGED (wParam, lParam);
if (result !is LRESULT.NULL) return result;
/*
@@ -382,7 +382,7 @@
return result;
}
-LRESULT WM_WINDOWPOSCHANGING (int wParam, int lParam) {
+override LRESULT WM_WINDOWPOSCHANGING (int wParam, int lParam) {
LRESULT result = super.WM_WINDOWPOSCHANGING (wParam, lParam);
if (result !is LRESULT.NULL) return result;
/*
diff -r 0405e18fec7f -r 0f25be5cbe6f dwt/widgets/Caret.d
--- a/dwt/widgets/Caret.d Sun Feb 03 15:48:14 2008 -0800
+++ b/dwt/widgets/Caret.d Mon Feb 04 10:05:20 2008 +0100
@@ -290,12 +290,12 @@
OS.ImmReleaseContext (hwnd, hIMC);
}
-void releaseParent () {
+override void releaseParent () {
super.releaseParent ();
if (this is parent.getCaret ()) parent.setCaret (null);
}
-void releaseWidget () {
+override void releaseWidget () {
super.releaseWidget ();
parent = null;
image = null;
diff -r 0405e18fec7f -r 0f25be5cbe6f dwt/widgets/Combo.d
--- a/dwt/widgets/Combo.d Sun Feb 03 15:48:14 2008 -0800
+++ b/dwt/widgets/Combo.d Mon Feb 04 10:05:20 2008 +0100
@@ -70,7 +70,12 @@
public class Combo : Composite {
+ alias Composite.computeSize computeSize;
+ alias Composite.dragDetect dragDetect;
alias Composite.sendKeyEvent sendKeyEvent;
+ alias Composite.setBackgroundImage setBackgroundImage;
+ alias Composite.setBounds setBounds;
+ alias Composite.setToolTipText setToolTipText;
alias extern(Windows) int function( HWND, uint, uint, int ) TWindowProc;
private static Combo pThis;
@@ -336,11 +341,11 @@
return OS.CallNextHookEx (cbtHook, nCode, wParam, lParam);
}
-bool checkHandle (HWND hwnd) {
+override bool checkHandle (HWND hwnd) {
return hwnd is handle || hwnd is OS.GetDlgItem (handle, CBID_EDIT) || hwnd is OS.GetDlgItem (handle, CBID_LIST);
}
-protected void checkSubclass () {
+override protected void checkSubclass () {
if (!isValidSubclass ()) error (DWT.ERROR_INVALID_SUBCLASS);
}
@@ -394,7 +399,7 @@
OS.SendMessage (handle, OS.CB_SETEDITSEL, 0, -1);
}
-public Point computeSize (int wHint, int hHint, bool changed) {
+override public Point computeSize (int wHint, int hHint, bool changed) {
checkWidget ();
int width = 0, height = 0;
if (wHint is DWT.DEFAULT) {
@@ -491,7 +496,7 @@
OS.SendMessage (handle, OS.WM_COPY, 0, 0);
}
-void createHandle () {
+override void createHandle () {
/*
* Feature in Windows. When the selection changes in a combo box,
* Windows draws the selection, even when the combo box does not
@@ -562,11 +567,11 @@
OS.SendMessage (handle, OS.WM_CUT, 0, 0);
}
-int defaultBackground () {
+override int defaultBackground () {
return OS.GetSysColor (OS.COLOR_WINDOW);
}
-void deregister () {
+override void deregister () {
super.deregister ();
auto hwndText = OS.GetDlgItem (handle, CBID_EDIT);
if (hwndText !is null) display.removeControl (hwndText);
@@ -616,7 +621,7 @@
// widget could be disposed at this point
}
-bool dragDetect (HWND hwnd, int x, int y, bool filter, bool [] detect, bool [] consume) {
+override bool dragDetect (HWND hwnd, int x, int y, bool filter, bool [] detect, bool [] consume) {
if (filter && (style & DWT.READ_ONLY) is 0) {
auto hwndText = OS.GetDlgItem (handle, CBID_EDIT);
if (hwndText !is null) {
@@ -754,7 +759,7 @@
return true;
}
-char[] getNameText () {
+override char[] getNameText () {
return getText ();
}
@@ -912,7 +917,7 @@
return visibleCount;
}
-bool hasFocus () {
+override bool hasFocus () {
auto hwndFocus = OS.GetFocus ();
if (hwndFocus is handle) return true;
if (hwndFocus is null) return false;
@@ -1027,7 +1032,7 @@
OS.SendMessage (handle, OS.WM_PASTE, 0, 0);
}
-void register () {
+override void register () {
super.register ();
auto hwndText = OS.GetDlgItem (handle, CBID_EDIT);
if (hwndText !is null) display.addControl (hwndText, this);
@@ -1286,7 +1291,7 @@
eventTable.unhook (DWT.Verify, listener);
}
-bool sendKeyEvent (int type, int msg, int wParam, int lParam, Event event) {
+override bool sendKeyEvent (int type, int msg, int wParam, int lParam, Event event) {
if (!super.sendKeyEvent (type, msg, wParam, lParam, event)) {
return false;
}
@@ -1396,7 +1401,7 @@
}
}
-void setBackgroundImage (HBITMAP hBitmap) {
+override void setBackgroundImage (HBITMAP hBitmap) {
super.setBackgroundImage (hBitmap);
auto hwndText = OS.GetDlgItem (handle, CBID_EDIT);
if (hwndText !is null) OS.InvalidateRect (hwndText, null, true);
@@ -1404,7 +1409,7 @@
if (hwndList !is null) OS.InvalidateRect (hwndList, null, true);
}
-void setBackgroundPixel (int pixel) {
+override void setBackgroundPixel (int pixel) {
super.setBackgroundPixel (pixel);
auto hwndText = OS.GetDlgItem (handle, CBID_EDIT);
if (hwndText !is null) OS.InvalidateRect (hwndText, null, true);
@@ -1412,7 +1417,7 @@
if (hwndList !is null) OS.InvalidateRect (hwndList, null, true);
}
-void setBounds (int x, int y, int width, int height, int flags) {
+override void setBounds (int x, int y, int width, int height, int flags) {
/*
* Feature in Windows. If the combo box has the CBS_DROPDOWN
* or CBS_DROPDOWNLIST style, Windows uses the height that the
@@ -1459,13 +1464,13 @@
}
}
-public void setFont (Font font) {
+override public void setFont (Font font) {
checkWidget ();
super.setFont (font);
if ((style & DWT.H_SCROLL) !is 0) setScrollWidth ();
}
-void setForegroundPixel (int pixel) {
+override void setForegroundPixel (int pixel) {
super.setForegroundPixel (pixel);
auto hwndText = OS.GetDlgItem (handle, CBID_EDIT);
if (hwndText !is null) OS.InvalidateRect (hwndText, null, true);
@@ -1834,7 +1839,7 @@
OS.SendMessage (handle, OS.CB_LIMITTEXT, limit, 0);
}
-void setToolTipText (Shell shell, char[] string) {
+override void setToolTipText (Shell shell, char[] string) {
auto hwndText = OS.GetDlgItem (handle, CBID_EDIT);
auto hwndList = OS.GetDlgItem (handle, CBID_LIST);
if (hwndText !is null) shell.setToolTipText (hwndText, string);
@@ -1872,7 +1877,7 @@
}
}
-void subclass () {
+override void subclass () {
super.subclass ();
auto newProc = display.windowProc;
auto hwndText = OS.GetDlgItem (handle, CBID_EDIT);
@@ -1885,7 +1890,7 @@
}
}
-bool translateTraversal (MSG* msg) {
+override bool translateTraversal (MSG* msg) {
/*
* When the combo box is dropped down, allow return
* to select an item in the list and escape to close
@@ -1903,7 +1908,7 @@
return super.translateTraversal (msg);
}
-bool traverseEscape () {
+override bool traverseEscape () {
if ((style & DWT.DROP_DOWN) !is 0) {
if (OS.SendMessage (handle, OS.CB_GETDROPPEDSTATE, 0, 0) !is 0) {
OS.SendMessage (handle, OS.CB_SHOWDROPDOWN, 0, 0);
@@ -1913,7 +1918,7 @@
return super.traverseEscape ();
}
-bool traverseReturn () {
+override bool traverseReturn () {
if ((style & DWT.DROP_DOWN) !is 0) {
if (OS.SendMessage (handle, OS.CB_GETDROPPEDSTATE, 0, 0) !is 0) {
OS.SendMessage (handle, OS.CB_SHOWDROPDOWN, 0, 0);
@@ -1923,7 +1928,7 @@
return super.traverseReturn ();
}
-void unsubclass () {
+override void unsubclass () {
super.unsubclass ();
auto hwndText = OS.GetDlgItem (handle, CBID_EDIT);
if (hwndText !is null && EditProc !is null) {
@@ -1978,22 +1983,22 @@
return mbcsPos;
}
-int widgetExtStyle () {
+override int widgetExtStyle () {
return super.widgetExtStyle () & ~OS.WS_EX_NOINHERITLAYOUT;
}
-int widgetStyle () {
+override int widgetStyle () {
int bits = super.widgetStyle () | OS.CBS_AUTOHSCROLL | OS.CBS_NOINTEGRALHEIGHT | OS.WS_HSCROLL |OS.WS_VSCROLL;
if ((style & DWT.SIMPLE) !is 0) return bits | OS.CBS_SIMPLE;
if ((style & DWT.READ_ONLY) !is 0) return bits | OS.CBS_DROPDOWNLIST;
return bits | OS.CBS_DROPDOWN;
}
-char[] windowClass () {
+override char[] windowClass () {
return TCHARzToStr( ComboClass );
}
-int windowProc () {
+override int windowProc () {
return cast(int) ComboProc;
}
@@ -2084,16 +2089,16 @@
return super.windowProc (hwnd, msg, wParam, lParam);
}
-LRESULT WM_CTLCOLOR (int wParam, int lParam) {
+override LRESULT WM_CTLCOLOR (int wParam, int lParam) {
return wmColorChild (wParam, lParam);
}
-LRESULT WM_GETDLGCODE (int wParam, int lParam) {
+override LRESULT WM_GETDLGCODE (int wParam, int lParam) {
int code = callWindowProc (handle, OS.WM_GETDLGCODE, wParam, lParam);
return cast( LRESULT )(code | OS.DLGC_WANTARROWS);
}
-LRESULT WM_KILLFOCUS (int wParam, int lParam) {
+override LRESULT WM_KILLFOCUS (int wParam, int lParam) {
/*
* Bug in Windows. When a combo box that is read only
* is disposed in CBN_KILLFOCUS, Windows segment faults.
@@ -2113,7 +2118,7 @@
return LRESULT.NULL;
}
-LRESULT WM_LBUTTONDOWN (int wParam, int lParam) {
+override LRESULT WM_LBUTTONDOWN (int wParam, int lParam) {
/*
* Feature in Windows. When an editable combo box is dropped
* down and the text in the entry field partially matches an
@@ -2136,7 +2141,7 @@
return result;
}
-LRESULT WM_SETFOCUS (int wParam, int lParam) {
+override LRESULT WM_SETFOCUS (int wParam, int lParam) {
/*
* Return NULL - Focus notification is
* done by WM_COMMAND with CBN_SETFOCUS.
@@ -2144,7 +2149,7 @@
return LRESULT.NULL;
}
-LRESULT WM_SIZE (int wParam, int lParam) {
+override LRESULT WM_SIZE (int wParam, int lParam) {
/*
* Bug in Windows. If the combo box has the CBS_SIMPLE style,
* the list portion of the combo box is not redrawn when the
@@ -2218,7 +2223,7 @@
return result;
}
-LRESULT wmChar (HWND hwnd, int wParam, int lParam) {
+override LRESULT wmChar (HWND hwnd, int wParam, int lParam) {
if (ignoreCharacter) return LRESULT.NULL;
LRESULT result = super.wmChar (hwnd, wParam, lParam);
if (result !is LRESULT.NULL) return result;
@@ -2324,7 +2329,7 @@
return LRESULT.NULL;
}
-LRESULT wmCommandChild (int wParam, int lParam) {
+override LRESULT wmCommandChild (int wParam, int lParam) {
int code = wParam >> 16;
switch (code) {
case OS.CBN_EDITCHANGE:
@@ -2389,7 +2394,7 @@
return super.wmCommandChild (wParam, lParam);
}
-LRESULT wmIMEChar (HWND hwnd, int wParam, int lParam) {
+override LRESULT wmIMEChar (HWND hwnd, int wParam, int lParam) {
/* Process a DBCS character */
Display display = this.display;
@@ -2423,7 +2428,7 @@
return cast( LRESULT )(result);
}
-LRESULT wmKeyDown (HWND hwnd, int wParam, int lParam) {
+override LRESULT wmKeyDown (HWND hwnd, int wParam, int lParam) {
if (ignoreCharacter) return LRESULT.NULL;
LRESULT result = super.wmKeyDown (hwnd, wParam, lParam);
if (result !is LRESULT.NULL) return result;
@@ -2438,7 +2443,7 @@
return result;
}
-LRESULT wmSysKeyDown (HWND hwnd, int wParam, int lParam) {
+override LRESULT wmSysKeyDown (HWND hwnd, int wParam, int lParam) {
/*
* Feature in Windows. When an editable combo box is dropped
* down using Alt+Down and the text in the entry field partially
diff -r 0405e18fec7f -r 0f25be5cbe6f dwt/widgets/Composite.d
--- a/dwt/widgets/Composite.d Sun Feb 03 15:48:14 2008 -0800
+++ b/dwt/widgets/Composite.d Mon Feb 04 10:05:20 2008 +0100
@@ -66,6 +66,10 @@
*/
public class Composite : Scrollable {
+
+ alias Scrollable.computeSize computeSize;
+ alias Scrollable.translateMnemonic translateMnemonic;
+
Layout layout_;
HFONT font;
WINDOWPOS* [] lpwp;
@@ -201,17 +205,17 @@
}
}
-void checkBuffered () {
+override void checkBuffered () {
if (OS.IsWinCE || (state & CANVAS) is 0) {
super.checkBuffered ();
}
}
-protected void checkSubclass () {
+override protected void checkSubclass () {
/* Do nothing - Subclassing is allowed */
}
-Control [] computeTabList () {
+override Control [] computeTabList () {
Control result [] = super.computeTabList ();
if (result.length is 0) return result;
Control [] list = tabList !is null ? _getTabList () : _getChildren ();
@@ -228,7 +232,7 @@
return result;
}
-public Point computeSize (int wHint, int hHint, bool changed) {
+override public Point computeSize (int wHint, int hHint, bool changed) {
checkWidget ();
Point size;
if (layout_ !is null) {
@@ -250,7 +254,7 @@
return new Point (trim.width, trim.height);
}
-void createHandle () {
+override void createHandle () {
super.createHandle ();
state |= CANVAS;
if ((style & (DWT.H_SCROLL | DWT.V_SCROLL)) is 0) {
@@ -262,7 +266,7 @@
return layoutCount > 0 ? this : parent.findDeferredControl ();
}
-Menu [] findMenus (Control control) {
+override Menu [] findMenus (Control control) {
if (control is this) return new Menu [0];
Menu result [] = super.findMenus (control);
Control [] children = _getChildren ();
@@ -279,7 +283,7 @@
return result;
}
-void fixChildren (Shell newShell, Shell oldShell, Decorations newDecorations, Decorations oldDecorations, Menu [] menus) {
+override void fixChildren (Shell newShell, Shell oldShell, Decorations newDecorations, Decorations oldDecorations, Menu [] menus) {
super.fixChildren (newShell, oldShell, newDecorations, oldDecorations, menus);
Control [] children = _getChildren ();
for (int i=0; iERROR_THREAD_INVALID_ACCESS - if not called from the thread that created the receiver
*
*/
-public Menu getMenu () {
+override public Menu getMenu () {
checkWidget ();
return menu;
}
@@ -1744,7 +1744,7 @@
return getVisible () && parent.isVisible ();
}
-void mapEvent (HWND hwnd, Event event) {
+override void mapEvent (HWND hwnd, Event event) {
if (hwnd !is handle) {
POINT point;
point.x = event.x;
@@ -1882,7 +1882,7 @@
return Accessible.internal_new_Accessible (this);
}
-GC new_GC (GCData data) {
+override GC new_GC (GCData data) {
return GC.win32_new (this, data);
}
@@ -2032,17 +2032,17 @@
display.addControl (handle, this);
}
-void releaseHandle () {
+override void releaseHandle () {
super.releaseHandle ();
handle = null;
parent = null;
}
-void releaseParent () {
+override void releaseParent () {
parent.removeControl (this);
}
-void releaseWidget () {
+override void releaseWidget () {
super.releaseWidget ();
if (OS.IsDBLocale) {
OS.ImmAssociateContext (handle, null);
@@ -2374,7 +2374,7 @@
if (handle !is topHandle_) OS.ShowWindow (handle, visible ? OS.SW_SHOW : OS.SW_HIDE);
}
-bool sendFocusEvent (int type) {
+override bool sendFocusEvent (int type) {
Shell shell = getShell ();
/*
diff -r 0405e18fec7f -r 0f25be5cbe6f dwt/widgets/CoolBar.d
--- a/dwt/widgets/CoolBar.d Sun Feb 03 15:48:14 2008 -0800
+++ b/dwt/widgets/CoolBar.d Mon Feb 04 10:05:20 2008 +0100
@@ -54,6 +54,9 @@
public class CoolBar : Composite {
+ alias Composite.computeSize computeSize;
+ alias Composite.windowProc windowProc;
+
CoolItem [] items;
CoolItem [] originalItems;
bool locked;
@@ -124,7 +127,7 @@
}
}
-LRESULT callWindowProc (HWND hwnd, int msg, int wParam, int lParam) {
+override LRESULT callWindowProc (HWND hwnd, int msg, int wParam, int lParam) {
if (handle is null) return LRESULT.NULL;
return cast(LRESULT) OS.CallWindowProc (ReBarProc, hwnd, msg, wParam, lParam);
}
@@ -141,11 +144,11 @@
return style & ~(DWT.H_SCROLL | DWT.V_SCROLL);
}
-protected void checkSubclass () {
+override protected void checkSubclass () {
if (!isValidSubclass ()) error (DWT.ERROR_INVALID_SUBCLASS);
}
-public Point computeSize (int wHint, int hHint, bool changed) {
+override public Point computeSize (int wHint, int hHint, bool changed) {
checkWidget ();
int width = 0, height = 0;
int border = getBorderWidth ();
@@ -214,7 +217,7 @@
return new Point (width, height);
}
-void createHandle () {
+override void createHandle () {
super.createHandle ();
state &= ~(CANVAS | THEME_BACKGROUND);
@@ -302,7 +305,7 @@
originalItems = newOriginals;
}
-void createWidget () {
+override void createWidget () {
super.createWidget ();
items = new CoolItem [4];
originalItems = new CoolItem [0];
@@ -374,7 +377,7 @@
originalItems = newOriginals;
}
-void drawThemeBackground (HDC hDC, HWND hwnd, RECT* rect) {
+override void drawThemeBackground (HDC hDC, HWND hwnd, RECT* rect) {
if (OS.COMCTL32_MAJOR >= 6 && OS.IsAppThemed ()) {
if (background is -1 && (style & DWT.FLAT) !is 0) {
Control control = findBackgroundControl ();
@@ -393,7 +396,7 @@
OS.SetWindowOrgEx (hDC, lpPoint.x, lpPoint.y, null);
}
-Control findThemeControl () {
+override Control findThemeControl () {
if ((style & DWT.FLAT) !is 0) return this;
return background is -1 && backgroundImage is null ? this : super.findThemeControl ();
}
@@ -710,7 +713,7 @@
OS.SendMessage (handle, OS.RB_SETBANDINFO, index, &rbBand);
}
-void releaseChildren (bool destroy) {
+override void releaseChildren (bool destroy) {
if (items !is null) {
for (int i=0; iERROR_DEVICE_DISPOSED - if the receiver has been disposed
*
*/
-public Rectangle getBounds () {
+override public Rectangle getBounds () {
checkDevice ();
if (OS.GetSystemMetrics (OS.SM_CMONITORS) < 2) {
int width = OS.GetSystemMetrics (OS.SM_CXSCREEN);
@@ -1470,7 +1470,7 @@
*
* @see #getBounds
*/
-public Rectangle getClientArea () {
+override public Rectangle getClientArea () {
checkDevice ();
if (OS.GetSystemMetrics (OS.SM_CMONITORS) < 2) {
RECT rect;
@@ -2211,7 +2211,7 @@
*
* @see DWT
*/
-public Color getSystemColor (int id) {
+override public Color getSystemColor (int id) {
checkDevice ();
int pixel = 0x00000000;
switch (id) {
@@ -2318,7 +2318,7 @@
* ERROR_DEVICE_DISPOSED - if the receiver has been disposed
*
*/
-public Font getSystemFont () {
+override public Font getSystemFont () {
checkDevice ();
if (systemFont !is null) return systemFont;
HFONT hFont;
@@ -2468,7 +2468,7 @@
* ERROR_NO_HANDLES if a handle could not be obtained for gc creation
*
*/
-public HDC internal_new_GC (GCData data) {
+override public HDC internal_new_GC (GCData data) {
if (isDisposed()) DWT.error(DWT.ERROR_DEVICE_DISPOSED);
auto hDC = OS.GetDC (null);
if (hDC is null) DWT.error (DWT.ERROR_NO_HANDLES);
@@ -2494,7 +2494,7 @@
*
* @see #create
*/
-protected void init () {
+override protected void init () {
super.init ();
/* Create the callbacks */
@@ -2597,7 +2597,7 @@
* @param hDC the platform specific GC handle
* @param data the platform specific GC data
*/
-public void internal_dispose_GC (HDC hDC, GCData data) {
+override public void internal_dispose_GC (HDC hDC, GCData data) {
OS.ReleaseDC (null, hDC);
}
@@ -3438,7 +3438,7 @@
* @see Device#dispose
* @see #destroy
*/
-protected void release () {
+override protected void release () {
sendEvent (DWT.Dispose, new Event ());
Shell [] shells = getShells ();
for (int i=0; i
*/
public class Label : Control {
+
+ alias Control.computeSize computeSize;
+ alias Control.windowProc windowProc;
+
char[] text = "";
Image image;
static const int MARGIN = 4;
@@ -105,7 +109,7 @@
super (parent, checkStyle (style));
}
-LRESULT callWindowProc (HWND hwnd, int msg, int wParam, int lParam) {
+override LRESULT callWindowProc (HWND hwnd, int msg, int wParam, int lParam) {
if (handle is null) return LRESULT.NULL;
return cast(LRESULT) OS.CallWindowProc (LabelProc, hwnd, msg, wParam, lParam);
}
@@ -119,7 +123,7 @@
return checkBits (style, DWT.LEFT, DWT.CENTER, DWT.RIGHT, 0, 0, 0);
}
-public Point computeSize (int wHint, int hHint, bool changed) {
+override public Point computeSize (int wHint, int hHint, bool changed) {
checkWidget ();
int width = 0, height = 0, border = getBorderWidth ();
if ((style & DWT.SEPARATOR) !is 0) {
@@ -188,7 +192,7 @@
return new Point (width, height);
}
-void createHandle () {
+override void createHandle () {
super.createHandle ();
state |= THEME_BACKGROUND;
}
@@ -232,7 +236,7 @@
return image;
}
-char[] getNameText () {
+override char[] getNameText () {
return getText ();
}
@@ -254,7 +258,7 @@
return text;
}
-bool mnemonicHit (wchar key) {
+override bool mnemonicHit (wchar key) {
Composite control = this.parent;
while (control !is null) {
Control [] children = control._getChildren ();
@@ -272,13 +276,13 @@
return false;
}
-bool mnemonicMatch (wchar key) {
+override bool mnemonicMatch (wchar key) {
wchar mnemonic = findMnemonic (getText ());
if (mnemonic is '\0') return false;
return CharacterToUpper (key) is CharacterToUpper (mnemonic);
}
-void releaseWidget () {
+override void releaseWidget () {
super.releaseWidget ();
text = null;
image = null;
@@ -417,13 +421,13 @@
}
}
-int widgetExtStyle () {
+override int widgetExtStyle () {
int bits = super.widgetExtStyle () & ~OS.WS_EX_CLIENTEDGE;
if ((style & DWT.BORDER) !is 0) return bits | OS.WS_EX_STATICEDGE;
return bits;
}
-int widgetStyle () {
+override int widgetStyle () {
int bits = super.widgetStyle () | OS.SS_NOTIFY;
if ((style & DWT.SEPARATOR) !is 0) return bits | OS.SS_OWNERDRAW;
if (OS.WIN32_VERSION >= OS.VERSION (5, 0)) {
@@ -435,15 +439,15 @@
return bits | OS.SS_LEFTNOWORDWRAP;
}
-char[] windowClass () {
+override char[] windowClass () {
return TCHARsToStr( LabelClass );
}
-int windowProc () {
+override int windowProc () {
return cast(int) LabelProc;
}
-LRESULT WM_ERASEBKGND (int wParam, int lParam) {
+override LRESULT WM_ERASEBKGND (int wParam, int lParam) {
LRESULT result = super.WM_ERASEBKGND (wParam, lParam);
if (result !is LRESULT.NULL) return result;
int bits = OS.GetWindowLong (handle, OS.GWL_STYLE);
@@ -467,7 +471,7 @@
return result;
}
-LRESULT WM_SIZE (int wParam, int lParam) {
+override LRESULT WM_SIZE (int wParam, int lParam) {
LRESULT result = super.WM_SIZE (wParam, lParam);
if (isDisposed ()) return result;
if ((style & DWT.SEPARATOR) !is 0) {
@@ -493,7 +497,7 @@
return result;
}
-LRESULT WM_UPDATEUISTATE (int wParam, int lParam) {
+override LRESULT WM_UPDATEUISTATE (int wParam, int lParam) {
LRESULT result = super.WM_UPDATEUISTATE (wParam, lParam);
/*
* Feature in Windows. When WM_UPDATEUISTATE is sent to
@@ -519,7 +523,7 @@
return result;
}
-LRESULT wmColorChild (int wParam, int lParam) {
+override LRESULT wmColorChild (int wParam, int lParam) {
/*
* Bug in Windows. For some reason, the HBRUSH that
* is returned from WM_CTRLCOLOR is misaligned when
@@ -541,7 +545,7 @@
return result;
}
-LRESULT WM_PAINT (int wParam, int lParam) {
+override LRESULT WM_PAINT (int wParam, int lParam) {
if (OS.IsWinCE) {
bool drawImage = image !is null;
bool drawSeparator = (style & DWT.SEPARATOR) !is 0 && (style & DWT.SHADOW_NONE) is 0;
@@ -605,7 +609,7 @@
return super.WM_PAINT(wParam, lParam);
}
-LRESULT wmDrawChild (int wParam, int lParam) {
+override LRESULT wmDrawChild (int wParam, int lParam) {
DRAWITEMSTRUCT* struct_ = cast(DRAWITEMSTRUCT*)lParam;
drawBackground (struct_.hDC);
if ((style & DWT.SEPARATOR) !is 0) {
diff -r 0405e18fec7f -r 0f25be5cbe6f dwt/widgets/Link.d
--- a/dwt/widgets/Link.d Sun Feb 03 15:48:14 2008 -0800
+++ b/dwt/widgets/Link.d Mon Feb 04 10:05:20 2008 +0100
@@ -61,6 +61,10 @@
* @since 3.1
*/
public class Link : Control {
+
+ alias Control.computeSize computeSize;
+ alias Control.windowProc windowProc;
+
char[] text;
TextLayout layout;
Color linkColor, disabledColor;
@@ -147,13 +151,13 @@
addListener (DWT.DefaultSelection, typedListener);
}
-LRESULT callWindowProc (HWND hwnd, int msg, int wParam, int lParam) {
+override LRESULT callWindowProc (HWND hwnd, int msg, int wParam, int lParam) {
if (handle is null) return LRESULT.NULL;
if (LinkProc !is null) return cast(LRESULT) OS.CallWindowProc (LinkProc, hwnd, msg, wParam, lParam);
return cast(LRESULT) OS.DefWindowProc (hwnd, msg, wParam, lParam);
}
-public Point computeSize (int wHint, int hHint, bool changed) {
+override public Point computeSize (int wHint, int hHint, bool changed) {
checkWidget ();
if (wHint !is DWT.DEFAULT && wHint < 0) wHint = 0;
if (hHint !is DWT.DEFAULT && hHint < 0) hHint = 0;
@@ -198,7 +202,7 @@
return new Point (width, height);
}
-void createHandle () {
+override void createHandle () {
super.createHandle ();
state |= THEME_BACKGROUND;
if (OS.COMCTL32_MAJOR < 6) {
@@ -217,7 +221,7 @@
}
}
-void createWidget () {
+override void createWidget () {
super.createWidget ();
text = "";
if (OS.COMCTL32_MAJOR < 6) {
@@ -259,7 +263,7 @@
}
}
-void enableWidget (bool enabled) {
+override void enableWidget (bool enabled) {
if (OS.COMCTL32_MAJOR >= 6) {
LITEM item;
item.mask = OS.LIF_ITEMINDEX | OS.LIF_STATE;
@@ -335,7 +339,7 @@
});
}
-char[] getNameText () {
+override char[] getNameText () {
return getText ();
}
@@ -533,7 +537,7 @@
return mnemonic;
}
-void releaseWidget () {
+override void releaseWidget () {
super.releaseWidget ();
if (layout !is null) layout.dispose ();
layout = null;
@@ -642,20 +646,20 @@
}
}
-int widgetStyle () {
+override int widgetStyle () {
int bits = super.widgetStyle ();
return bits | OS.WS_TABSTOP;
}
-char[] windowClass () {
+override char[] windowClass () {
return OS.COMCTL32_MAJOR >= 6 ? TCHARsToStr(LinkClass) : display.windowClass();
}
-int windowProc () {
+override int windowProc () {
return LinkProc !is null ? cast(int)LinkProc : display.windowProc();
}
-LRESULT WM_CHAR (int wParam, int lParam) {
+override LRESULT WM_CHAR (int wParam, int lParam) {
LRESULT result = super.WM_CHAR (wParam, lParam);
if (result !is LRESULT.NULL) return result;
if (OS.COMCTL32_MAJOR < 6) {
@@ -701,7 +705,7 @@
return result;
}
-LRESULT WM_GETDLGCODE (int wParam, int lParam) {
+override LRESULT WM_GETDLGCODE (int wParam, int lParam) {
LRESULT result = super.WM_GETDLGCODE (wParam, lParam);
if (result !is LRESULT.NULL) return result;
int index, count, code = 0;
@@ -735,7 +739,7 @@
return result;
}
-LRESULT WM_GETFONT (int wParam, int lParam) {
+override LRESULT WM_GETFONT (int wParam, int lParam) {
LRESULT result = super.WM_GETFONT (wParam, lParam);
if (result !is LRESULT.NULL) return result;
int code = callWindowProc (handle, OS.WM_GETFONT, wParam, lParam);
@@ -744,7 +748,7 @@
return cast(LRESULT) (font);
}
-LRESULT WM_KEYDOWN (int wParam, int lParam) {
+override LRESULT WM_KEYDOWN (int wParam, int lParam) {
LRESULT result = super.WM_KEYDOWN (wParam, lParam);
if (result !is LRESULT.NULL) return result;
if (OS.COMCTL32_MAJOR >= 6) {
@@ -764,13 +768,13 @@
return result;
}
-LRESULT WM_KILLFOCUS (int wParam, int lParam) {
+override LRESULT WM_KILLFOCUS (int wParam, int lParam) {
LRESULT result = super.WM_KILLFOCUS (wParam, lParam);
if (OS.COMCTL32_MAJOR < 6) redraw ();
return result;
}
-LRESULT WM_LBUTTONDOWN (int wParam, int lParam) {
+override LRESULT WM_LBUTTONDOWN (int wParam, int lParam) {
LRESULT result = super.WM_LBUTTONDOWN (wParam, lParam);
if (result is LRESULT.ZERO) return result;
if (OS.COMCTL32_MAJOR < 6) {
@@ -808,7 +812,7 @@
return result;
}
-LRESULT WM_LBUTTONUP (int wParam, int lParam) {
+override LRESULT WM_LBUTTONUP (int wParam, int lParam) {
LRESULT result = super.WM_LBUTTONUP (wParam, lParam);
if (result is LRESULT.ZERO) return result;
if (OS.COMCTL32_MAJOR < 6) {
@@ -830,7 +834,7 @@
return result;
}
-LRESULT WM_MOUSEMOVE (int wParam, int lParam) {
+override LRESULT WM_MOUSEMOVE (int wParam, int lParam) {
LRESULT result = super.WM_MOUSEMOVE (wParam, lParam);
if (OS.COMCTL32_MAJOR < 6) {
int x = lParam & 0xFFFF;
@@ -865,7 +869,7 @@
return result;
}
-LRESULT WM_PAINT (int wParam, int lParam) {
+override LRESULT WM_PAINT (int wParam, int lParam) {
if (OS.COMCTL32_MAJOR >= 6) {
return super.WM_PAINT (wParam, lParam);
}
@@ -887,7 +891,7 @@
return LRESULT.ZERO;
}
-LRESULT WM_PRINTCLIENT (int wParam, int lParam) {
+override LRESULT WM_PRINTCLIENT (int wParam, int lParam) {
LRESULT result = super.WM_PRINTCLIENT (wParam, lParam);
if (OS.COMCTL32_MAJOR < 6) {
RECT rect;
@@ -902,13 +906,13 @@
return result;
}
-LRESULT WM_SETFOCUS (int wParam, int lParam) {
+override LRESULT WM_SETFOCUS (int wParam, int lParam) {
LRESULT result = super.WM_SETFOCUS (wParam, lParam);
if (OS.COMCTL32_MAJOR < 6) redraw ();
return result;
}
-LRESULT WM_SETFONT (int wParam, int lParam) {
+override LRESULT WM_SETFONT (int wParam, int lParam) {
if (OS.COMCTL32_MAJOR < 6) {
layout.setFont (Font.win32_new (display, cast(HANDLE)wParam));
}
@@ -917,7 +921,7 @@
return super.WM_SETFONT (wParam, lParam);
}
-LRESULT WM_SIZE (int wParam, int lParam) {
+override LRESULT WM_SIZE (int wParam, int lParam) {
LRESULT result = super.WM_SIZE (wParam, lParam);
if (OS.COMCTL32_MAJOR < 6) {
RECT rect;
@@ -928,7 +932,7 @@
return result;
}
-LRESULT wmColorChild (int wParam, int lParam) {
+override LRESULT wmColorChild (int wParam, int lParam) {
LRESULT result = super.wmColorChild (wParam, lParam);
/*
* Feature in Windows. When a SysLink is disabled, it does
@@ -949,7 +953,7 @@
return result;
}
-LRESULT wmNotifyChild (NMHDR* hdr, int wParam, int lParam) {
+override LRESULT wmNotifyChild (NMHDR* hdr, int wParam, int lParam) {
if (OS.COMCTL32_MAJOR >= 6) {
switch (hdr.code) {
case OS.NM_RETURN:
diff -r 0405e18fec7f -r 0f25be5cbe6f dwt/widgets/List.d
--- a/dwt/widgets/List.d Sun Feb 03 15:48:14 2008 -0800
+++ b/dwt/widgets/List.d Mon Feb 04 10:05:20 2008 +0100
@@ -48,6 +48,10 @@
*/
public class List extends Scrollable {
+
+ alias Scrollable.computeSize computeSize;
+ alias Scrollable.windowProc windowProc;
+
static final int INSET = 3;
static final int ListProc;
static final TCHAR ListClass = new TCHAR (0, "LISTBOX", true);
@@ -186,7 +190,7 @@
addListener (DWT.DefaultSelection,typedListener);
}
-int callWindowProc (int hwnd, int msg, int wParam, int lParam) {
+override int callWindowProc (int hwnd, int msg, int wParam, int lParam) {
if (handle is 0) return 0;
return OS.CallWindowProc (ListProc, hwnd, msg, wParam, lParam);
}
@@ -195,7 +199,7 @@
return checkBits (style, DWT.SINGLE, DWT.MULTI, 0, 0, 0, 0);
}
-public Point computeSize (int wHint, int hHint, bool changed) {
+override public Point computeSize (int wHint, int hHint, bool changed) {
checkWidget ();
int width = 0, height = 0;
if (wHint is DWT.DEFAULT) {
@@ -250,7 +254,7 @@
return new Point (width, height);
}
-int defaultBackground () {
+override int defaultBackground () {
return OS.GetSysColor (OS.COLOR_WINDOW);
}
@@ -1130,7 +1134,7 @@
OS.SendMessage (handle, OS.LB_SETCARETINDEX, index, 0);
}
-public void setFont (Font font) {
+override public void setFont (Font font) {
checkWidget ();
super.setFont (font);
if ((style & DWT.H_SCROLL) !is 0) setScrollWidth ();
@@ -1492,7 +1496,7 @@
OS.SendMessage (handle, OS.LB_SETTOPINDEX, newTop, 0);
}
-int widgetStyle () {
+override int widgetStyle () {
int bits = super.widgetStyle () | OS.LBS_NOTIFY | OS.LBS_NOINTEGRALHEIGHT;
if ((style & DWT.SINGLE) !is 0) return bits;
if ((style & DWT.MULTI) !is 0) {
@@ -1502,15 +1506,15 @@
return bits;
}
-TCHAR windowClass () {
+override TCHAR windowClass () {
return ListClass;
}
-int windowProc () {
+override int windowProc () {
return ListProc;
}
-LRESULT WM_SIZE (int wParam, int lParam) {
+override LRESULT WM_SIZE (int wParam, int lParam) {
/*
* Bug in Windows. If the top index is changed while the
* list is being resized, Windows does not redraw properly
@@ -1538,7 +1542,7 @@
return result;
}
-LRESULT wmCommandChild (int wParam, int lParam) {
+override LRESULT wmCommandChild (int wParam, int lParam) {
int code = wParam >> 16;
switch (code) {
case OS.LBN_SELCHANGE:
diff -r 0405e18fec7f -r 0f25be5cbe6f dwt/widgets/Menu.d
--- a/dwt/widgets/Menu.d Sun Feb 03 15:48:14 2008 -0800
+++ b/dwt/widgets/Menu.d Mon Feb 04 10:05:20 2008 +0100
@@ -603,7 +603,7 @@
redraw ();
}
-void destroyWidget () {
+override void destroyWidget () {
int hMenu = handle, hCB = hwndCB;
releaseHandle ();
if (OS.IsWinCE && hCB !is 0) {
@@ -897,7 +897,7 @@
return OS.GetMenuItemCount (handle);
}
-String getNameText () {
+override String getNameText () {
String result = "";
MenuItem [] items = getItems ();
int length = items.length;
@@ -1131,12 +1131,12 @@
}
}
-void releaseHandle () {
+override void releaseHandle () {
super.releaseHandle ();
handle = hwndCB = 0;
}
-void releaseChildren (bool destroy) {
+override void releaseChildren (bool destroy) {
MenuItem [] items = getItems ();
for (int i=0; iERROR_THREAD_INVALID_ACCESS - if not called from the thread that created the receiver
*
*/
-public Menu getMenu () {
+override public Menu getMenu () {
checkWidget ();
return menu;
}
-String getNameText () {
+override String getNameText () {
if ((style & DWT.SEPARATOR) !is 0) return "|";
return super.getNameText ();
}
@@ -523,7 +523,7 @@
return getEnabled () && parent.isEnabled ();
}
-void releaseChildren (bool destroy) {
+override void releaseChildren (bool destroy) {
if (menu !is null) {
menu.release (false);
menu = null;
@@ -531,7 +531,7 @@
super.releaseChildren (destroy);
}
-void releaseHandle () {
+override void releaseHandle () {
super.releaseHandle ();
parent = null;
id = -1;
@@ -542,13 +542,13 @@
menu = null;
}
-void releaseParent () {
+override void releaseParent () {
super.releaseParent ();
if (menu !is null) menu.dispose ();
menu = null;
}
-void releaseWidget () {
+override void releaseWidget () {
super.releaseWidget ();
if (hBitmap !is 0) OS.DeleteObject (hBitmap);
hBitmap = 0;
@@ -744,7 +744,7 @@
* ERROR_THREAD_INVALID_ACCESS - if not called from the thread that created the receiver
*
*/
-public void setImage (Image image) {
+override public void setImage (Image image) {
checkWidget ();
if ((style & DWT.SEPARATOR) !is 0) return;
super.setImage (image);
@@ -1037,7 +1037,7 @@
*
* @see #setAccelerator
*/
-public void setText (String string) {
+override public void setText (String string) {
checkWidget ();
if (string is null) error (DWT.ERROR_NULL_ARGUMENT);
if ((style & DWT.SEPARATOR) !is 0) return;
diff -r 0405e18fec7f -r 0f25be5cbe6f dwt/widgets/ProgressBar.d
--- a/dwt/widgets/ProgressBar.d Sun Feb 03 15:48:14 2008 -0800
+++ b/dwt/widgets/ProgressBar.d Mon Feb 04 10:05:20 2008 +0100
@@ -41,6 +41,10 @@
*
*/
public class ProgressBar extends Control {
+
+ alias Control.computeSize computeSize;
+ alias Control.windowProc windowProc;
+
static final int DELAY = 100;
static final int TIMER_ID = 100;
static final int MINIMUM_WIDTH = 100;
@@ -114,7 +118,7 @@
super (parent, checkStyle (style));
}
-int callWindowProc (int hwnd, int msg, int wParam, int lParam) {
+override int callWindowProc (int hwnd, int msg, int wParam, int lParam) {
if (handle is 0) return 0;
return OS.CallWindowProc (ProgressBarProc, hwnd, msg, wParam, lParam);
}
@@ -124,7 +128,7 @@
return checkBits (style, DWT.HORIZONTAL, DWT.VERTICAL, 0, 0, 0, 0);
}
-public Point computeSize (int wHint, int hHint, bool changed) {
+override public Point computeSize (int wHint, int hHint, bool changed) {
checkWidget ();
int border = getBorderWidth ();
int width = border * 2, height = border * 2;
@@ -140,12 +144,12 @@
return new Point (width, height);
}
-void createHandle () {
+override void createHandle () {
super.createHandle ();
startTimer ();
}
-int defaultForeground () {
+override int defaultForeground () {
return OS.GetSysColor (OS.COLOR_HIGHLIGHT);
}
@@ -194,7 +198,7 @@
return OS.SendMessage (handle, OS.PBM_GETPOS, 0, 0);
}
-void releaseWidget () {
+override void releaseWidget () {
super.releaseWidget ();
stopTimer ();
}
@@ -221,12 +225,12 @@
}
}
-void setBackgroundPixel (int pixel) {
+override void setBackgroundPixel (int pixel) {
if (pixel is -1) pixel = OS.CLR_DEFAULT;
OS.SendMessage (handle, OS.PBM_SETBKCOLOR, 0, pixel);
}
-void setForegroundPixel (int pixel) {
+override void setForegroundPixel (int pixel) {
if (pixel is -1) pixel = OS.CLR_DEFAULT;
OS.SendMessage (handle, OS.PBM_SETBARCOLOR, 0, pixel);
}
@@ -290,7 +294,7 @@
OS.SendMessage (handle, OS.PBM_SETPOS, value, 0);
}
-int widgetStyle () {
+override int widgetStyle () {
int bits = super.widgetStyle ();
if ((style & DWT.SMOOTH) !is 0) bits |= OS.PBS_SMOOTH;
if ((style & DWT.VERTICAL) !is 0) bits |= OS.PBS_VERTICAL;
@@ -298,15 +302,15 @@
return bits;
}
-TCHAR windowClass () {
+override TCHAR windowClass () {
return ProgressBarClass;
}
-int windowProc () {
+override int windowProc () {
return ProgressBarProc;
}
-LRESULT WM_GETDLGCODE (int wParam, int lParam) {
+override LRESULT WM_GETDLGCODE (int wParam, int lParam) {
LRESULT result = super.WM_GETDLGCODE (wParam, lParam);
if (result !is null) return result;
/*
@@ -321,7 +325,7 @@
return new LRESULT (OS.DLGC_STATIC);
}
-LRESULT WM_SIZE (int wParam, int lParam) {
+override LRESULT WM_SIZE (int wParam, int lParam) {
LRESULT result = super.WM_SIZE (wParam, lParam);
if (result !is null) return result;
/*
@@ -357,7 +361,7 @@
return result;
}
-LRESULT WM_TIMER (int wParam, int lParam) {
+override LRESULT WM_TIMER (int wParam, int lParam) {
LRESULT result = super.WM_TIMER (wParam, lParam);
if (result !is null) return result;
if ((style & DWT.INDETERMINATE) !is 0) {
diff -r 0405e18fec7f -r 0f25be5cbe6f dwt/widgets/Sash.d
--- a/dwt/widgets/Sash.d Sun Feb 03 15:48:14 2008 -0800
+++ b/dwt/widgets/Sash.d Mon Feb 04 10:05:20 2008 +0100
@@ -43,6 +43,10 @@
*
*/
public class Sash extends Control {
+
+ alias Control.computeSize computeSize;
+ alias Control.windowProc windowProc;
+
bool dragging;
int startX, startY, lastX, lastY;
final static int INCREMENT = 1;
@@ -114,12 +118,12 @@
addListener (DWT.DefaultSelection,typedListener);
}
-int callWindowProc (int hwnd, int msg, int wParam, int lParam) {
+override int callWindowProc (int hwnd, int msg, int wParam, int lParam) {
if (handle is 0) return 0;
return OS.DefWindowProc (hwnd, msg, wParam, lParam);
}
-void createHandle () {
+override void createHandle () {
super.createHandle ();
state |= THEME_BACKGROUND;
}
@@ -128,7 +132,7 @@
return checkBits (style, DWT.HORIZONTAL, DWT.VERTICAL, 0, 0, 0, 0);
}
-public Point computeSize (int wHint, int hHint, bool changed) {
+override public Point computeSize (int wHint, int hHint, bool changed) {
checkWidget ();
int border = getBorderWidth ();
int width = border * 2, height = border * 2;
@@ -182,21 +186,21 @@
eventTable.unhook (DWT.DefaultSelection,listener);
}
-TCHAR windowClass () {
+override TCHAR windowClass () {
return display.windowClass;
}
-int windowProc () {
+override int windowProc () {
return display.windowProc;
}
-LRESULT WM_ERASEBKGND (int wParam, int lParam) {
+override LRESULT WM_ERASEBKGND (int wParam, int lParam) {
super.WM_ERASEBKGND (wParam, lParam);
drawBackground (wParam);
return LRESULT.ONE;
}
-LRESULT WM_KEYDOWN (int wParam, int lParam) {
+override LRESULT WM_KEYDOWN (int wParam, int lParam) {
LRESULT result = super.WM_KEYDOWN (wParam, lParam);
if (result !is null) return result;
switch (wParam) {
@@ -262,11 +266,11 @@
return result;
}
-LRESULT WM_GETDLGCODE (int wParam, int lParam) {
+override LRESULT WM_GETDLGCODE (int wParam, int lParam) {
return new LRESULT (OS.DLGC_STATIC);
}
-LRESULT WM_LBUTTONDOWN (int wParam, int lParam) {
+override LRESULT WM_LBUTTONDOWN (int wParam, int lParam) {
LRESULT result = super.WM_LBUTTONDOWN (wParam, lParam);
if (result is LRESULT.ZERO) return result;
@@ -320,7 +324,7 @@
return result;
}
-LRESULT WM_LBUTTONUP (int wParam, int lParam) {
+override LRESULT WM_LBUTTONUP (int wParam, int lParam) {
LRESULT result = super.WM_LBUTTONUP (wParam, lParam);
if (result is LRESULT.ZERO) return result;
@@ -350,7 +354,7 @@
return result;
}
-LRESULT WM_MOUSEMOVE (int wParam, int lParam) {
+override LRESULT WM_MOUSEMOVE (int wParam, int lParam) {
LRESULT result = super.WM_MOUSEMOVE (wParam, lParam);
if (result !is null) return result;
if (!dragging || (wParam & OS.MK_LBUTTON) is 0) return result;
@@ -406,7 +410,7 @@
return result;
}
-LRESULT WM_SETCURSOR (int wParam, int lParam) {
+override LRESULT WM_SETCURSOR (int wParam, int lParam) {
LRESULT result = super.WM_SETCURSOR (wParam, lParam);
if (result !is null) return result;
int hitTest = lParam & 0xFFFF;
diff -r 0405e18fec7f -r 0f25be5cbe6f dwt/widgets/Scale.d
--- a/dwt/widgets/Scale.d Sun Feb 03 15:48:14 2008 -0800
+++ b/dwt/widgets/Scale.d Mon Feb 04 10:05:20 2008 +0100
@@ -47,6 +47,11 @@
*/
public class Scale extends Control {
+
+ alias Control.computeSize computeSize;
+ alias Control.setBackgroundImage setBackgroundImage;
+ alias Control.windowProc windowProc;
+
bool ignoreResize;
static final int TrackBarProc;
static final TCHAR TrackBarClass = new TCHAR (0, OS.TRACKBAR_CLASS, true);
@@ -148,7 +153,7 @@
addListener (DWT.DefaultSelection,typedListener);
}
-int callWindowProc (int hwnd, int msg, int wParam, int lParam) {
+override int callWindowProc (int hwnd, int msg, int wParam, int lParam) {
if (handle is 0) return 0;
return OS.CallWindowProc (TrackBarProc, hwnd, msg, wParam, lParam);
}
@@ -157,7 +162,7 @@
return checkBits (style, DWT.HORIZONTAL, DWT.VERTICAL, 0, 0, 0, 0);
}
-public Point computeSize (int wHint, int hHint, bool changed) {
+override public Point computeSize (int wHint, int hHint, bool changed) {
checkWidget ();
int border = getBorderWidth ();
int width = border * 2, height = border * 2;
@@ -177,7 +182,7 @@
return new Point (width, height);
}
-void createHandle () {
+override void createHandle () {
super.createHandle ();
state |= THEME_BACKGROUND | DRAW_BACKGROUND;
OS.SendMessage (handle, OS.TBM_SETRANGEMAX, 0, 100);
@@ -185,7 +190,7 @@
OS.SendMessage (handle, OS.TBM_SETTICFREQ, 10, 0);
}
-int defaultForeground () {
+override int defaultForeground () {
return OS.GetSysColor (OS.COLOR_BTNFACE);
}
@@ -293,7 +298,7 @@
eventTable.unhook (DWT.DefaultSelection,listener);
}
-void setBackgroundImage (int hImage) {
+override void setBackgroundImage (int hImage) {
super.setBackgroundImage (hImage);
/*
* Bug in Windows. Changing the background color of the Scale
@@ -306,7 +311,7 @@
ignoreResize = false;
}
-void setBackgroundPixel (int pixel) {
+override void setBackgroundPixel (int pixel) {
super.setBackgroundPixel (pixel);
/*
* Bug in Windows. Changing the background color of the Scale
@@ -422,21 +427,21 @@
OS.SendMessage (handle, OS.TBM_SETPOS, 1, value);
}
-int widgetStyle () {
+override int widgetStyle () {
int bits = super.widgetStyle () | OS.WS_TABSTOP | OS.TBS_BOTH | OS.TBS_AUTOTICKS;
if ((style & DWT.HORIZONTAL) !is 0) return bits | OS.TBS_HORZ | OS.TBS_DOWNISLEFT;
return bits | OS.TBS_VERT;
}
-TCHAR windowClass () {
+override TCHAR windowClass () {
return TrackBarClass;
}
-int windowProc () {
+override int windowProc () {
return TrackBarProc;
}
-LRESULT WM_PAINT (int wParam, int lParam) {
+override LRESULT WM_PAINT (int wParam, int lParam) {
/*
* Bug in Windows. For some reason, when WM_CTLCOLORSTATIC
* is used to implement transparency and returns a NULL brush,
@@ -468,12 +473,12 @@
return super.WM_PAINT (wParam, lParam);
}
-LRESULT WM_SIZE (int wParam, int lParam) {
+override LRESULT WM_SIZE (int wParam, int lParam) {
if (ignoreResize) return null;
return super.WM_SIZE (wParam, lParam);
}
-LRESULT wmScrollChild (int wParam, int lParam) {
+override LRESULT wmScrollChild (int wParam, int lParam) {
/* Do nothing when scrolling is ending */
int code = wParam & 0xFFFF;
diff -r 0405e18fec7f -r 0f25be5cbe6f dwt/widgets/ScrollBar.d
--- a/dwt/widgets/ScrollBar.d Sun Feb 03 15:48:14 2008 -0800
+++ b/dwt/widgets/ScrollBar.d Mon Feb 04 10:05:20 2008 +0100
@@ -197,7 +197,7 @@
*/
}
-void destroyWidget () {
+override void destroyWidget () {
int hwnd = hwndScrollBar (), type = scrollBarType ();
if (OS.IsWinCE) {
SCROLLINFO info = new SCROLLINFO ();
@@ -482,12 +482,12 @@
return getVisible () && parent.isVisible ();
}
-void releaseHandle () {
+override void releaseHandle () {
super.releaseHandle ();
parent = null;
}
-void releaseParent () {
+override void releaseParent () {
super.releaseParent ();
if (parent.horizontalBar is this) parent.horizontalBar = null;
if (parent.verticalBar is this) parent.verticalBar = null;
diff -r 0405e18fec7f -r 0f25be5cbe6f dwt/widgets/Scrollable.d
--- a/dwt/widgets/Scrollable.d Sun Feb 03 15:48:14 2008 -0800
+++ b/dwt/widgets/Scrollable.d Mon Feb 04 10:05:20 2008 +0100
@@ -137,7 +137,7 @@
return bar;
}
-void createWidget () {
+override void createWidget () {
super.createWidget ();
if ((style & DWT.H_SCROLL) !is 0) horizontalBar = createScrollBar (DWT.H_SCROLL);
if ((style & DWT.V_SCROLL) !is 0) verticalBar = createScrollBar (DWT.V_SCROLL);
@@ -207,7 +207,7 @@
return verticalBar;
}
-void releaseChildren (bool destroy) {
+override void releaseChildren (bool destroy) {
if (horizontalBar !is null) {
horizontalBar.release (false);
horizontalBar = null;
@@ -223,7 +223,7 @@
return handle;
}
-int widgetExtStyle () {
+override int widgetExtStyle () {
return super.widgetExtStyle ();
/*
* This code is intentionally commented. In future,
@@ -237,7 +237,7 @@
// return super.widgetExtStyle ();
}
-int widgetStyle () {
+override int widgetStyle () {
int bits = super.widgetStyle () | OS.WS_TABSTOP;
if ((style & DWT.H_SCROLL) !is 0) bits |= OS.WS_HSCROLL;
if ((style & DWT.V_SCROLL) !is 0) bits |= OS.WS_VSCROLL;
diff -r 0405e18fec7f -r 0f25be5cbe6f dwt/widgets/Shell.d
--- a/dwt/widgets/Shell.d Sun Feb 03 15:48:14 2008 -0800
+++ b/dwt/widgets/Shell.d Mon Feb 04 10:05:20 2008 +0100
@@ -126,6 +126,11 @@
* @see DWT
*/
public class Shell : Decorations {
+
+ alias Decorations.setBounds setBounds;
+ alias Decorations.setParent setParent;
+ alias Decorations.setToolTipText setToolTipText;
+
Menu activeMenu;
ToolTip [] toolTips;
HIMC hIMC;
@@ -529,7 +534,7 @@
OS.SetWindowLong (balloonTipHandle_, OS.GWL_WNDPROC, display.windowProc);
}
-void createHandle () {
+override void createHandle () {
bool embedded = handle !is null && (state & FOREIGN_HANDLE) is 0;
/*
@@ -637,7 +642,7 @@
OS.SetWindowLong (toolTipHandle_, OS.GWL_WNDPROC, display.windowProc);
}
-void deregister () {
+override void deregister () {
super.deregister ();
if (toolTipHandle_ !is null) display.removeControl (toolTipHandle_);
if (balloonTipHandle_ !is null) display.removeControl (balloonTipHandle_);
@@ -657,12 +662,12 @@
toolTip.id = -1;
}
-void destroyWidget () {
+override void destroyWidget () {
fixActiveShell ();
super.destroyWidget ();
}
-public void dispose () {
+override public void dispose () {
/*
* This code is intentionally commented. On some
* platforms, the owner window is repainted right
@@ -681,7 +686,7 @@
// if (oldDisplay !is null) oldDisplay.update ();
}
-void enableWidget (bool enabled) {
+override void enableWidget (bool enabled) {
if (enabled) {
state &= ~DISABLED;
} else {
@@ -694,7 +699,7 @@
}
}
-HBRUSH findBrush (int value, int lbStyle) {
+override HBRUSH findBrush (int value, int lbStyle) {
if (lbStyle is OS.BS_SOLID) {
for (int i=0; i 0 ? this : null;
}
-public bool isEnabled () {
+override public bool isEnabled () {
checkWidget ();
return getEnabled ();
}
-public bool isVisible () {
+override public bool isVisible () {
checkWidget ();
return getVisible ();
}
@@ -1125,7 +1130,7 @@
if (!restoreFocus () && !traverseGroup (true)) setFocus ();
}
-void register () {
+override void register () {
super.register ();
if (toolTipHandle_ !is null) display.addControl (toolTipHandle_, this);
if (balloonTipHandle_ !is null) display.addControl (balloonTipHandle_, this);
@@ -1140,7 +1145,7 @@
brushes = null;
}
-void releaseChildren (bool destroy) {
+override void releaseChildren (bool destroy) {
Shell [] shells = getShells ();
for (int i=0; i> 16;
@@ -1159,7 +1166,7 @@
return result;
}
-LRESULT wmChar (int hwnd, int wParam, int lParam) {
+override LRESULT wmChar (int hwnd, int wParam, int lParam) {
LRESULT result = super.wmChar (hwnd, wParam, lParam);
if (result !is null) return result;
/*
@@ -1245,7 +1252,7 @@
return null;
}
-LRESULT wmCommandChild (int wParam, int lParam) {
+override LRESULT wmCommandChild (int wParam, int lParam) {
int code = wParam >> 16;
switch (code) {
case OS.EN_CHANGE:
@@ -1267,7 +1274,7 @@
return super.wmCommandChild (wParam, lParam);
}
-LRESULT wmKeyDown (int hwnd, int wParam, int lParam) {
+override LRESULT wmKeyDown (int hwnd, int wParam, int lParam) {
LRESULT result = super.wmKeyDown (hwnd, wParam, lParam);
if (result !is null) return result;
@@ -1310,7 +1317,7 @@
return result;
}
-LRESULT wmKillFocus (int hwnd, int wParam, int lParam) {
+override LRESULT wmKillFocus (int hwnd, int wParam, int lParam) {
int value = getSelectionText ();
if (value is -1) {
if (OS.IsWinCE) {
@@ -1323,7 +1330,7 @@
return super.wmKillFocus (hwnd, wParam, lParam);
}
-LRESULT wmNotifyChild (NMHDR hdr, int wParam, int lParam) {
+override LRESULT wmNotifyChild (NMHDR hdr, int wParam, int lParam) {
switch (hdr.code) {
case OS.UDN_DELTAPOS:
NMUPDOWN lpnmud = new NMUPDOWN ();
@@ -1352,7 +1359,7 @@
return super.wmNotifyChild (hdr, wParam, lParam);
}
-LRESULT wmScrollChild (int wParam, int lParam) {
+override LRESULT wmScrollChild (int wParam, int lParam) {
int code = wParam & 0xFFFF;
switch (code) {
case OS.SB_THUMBPOSITION:
diff -r 0405e18fec7f -r 0f25be5cbe6f dwt/widgets/TabFolder.d
--- a/dwt/widgets/TabFolder.d Sun Feb 03 15:48:14 2008 -0800
+++ b/dwt/widgets/TabFolder.d Mon Feb 04 10:05:20 2008 +0100
@@ -60,6 +60,10 @@
*
*/
public class TabFolder extends Composite {
+
+ alias Composite.computeSize computeSize;
+ alias Composite.windowProc windowProc;
+
TabItem [] items;
ImageList imageList;
static final int TabFolderProc;
@@ -171,7 +175,7 @@
addListener(DWT.DefaultSelection,typedListener);
}
-int callWindowProc (int hwnd, int msg, int wParam, int lParam) {
+override int callWindowProc (int hwnd, int msg, int wParam, int lParam) {
if (handle is 0) return 0;
return OS.CallWindowProc (TabFolderProc, hwnd, msg, wParam, lParam);
}
@@ -196,11 +200,11 @@
return style & ~(DWT.H_SCROLL | DWT.V_SCROLL);
}
-protected void checkSubclass () {
+override protected void checkSubclass () {
if (!isValidSubclass ()) error (DWT.ERROR_INVALID_SUBCLASS);
}
-public Point computeSize (int wHint, int hHint, bool changed) {
+override public Point computeSize (int wHint, int hHint, bool changed) {
checkWidget ();
Point size = super.computeSize (wHint, hHint, changed);
RECT insetRect = new RECT (), itemRect = new RECT ();
@@ -221,7 +225,7 @@
return size;
}
-public Rectangle computeTrim (int x, int y, int width, int height) {
+override public Rectangle computeTrim (int x, int y, int width, int height) {
checkWidget ();
RECT rect = new RECT ();
OS.SetRect (rect, x, y, x + width, y + height);
@@ -262,7 +266,7 @@
}
}
-void createHandle () {
+override void createHandle () {
super.createHandle ();
state &= ~(CANVAS | THEME_BACKGROUND);
@@ -282,7 +286,7 @@
OS.SendMessage (hwndToolTip, OS.TTM_SETMAXTIPWIDTH, 0, 0x7FFF);
}
-void createWidget () {
+override void createWidget () {
super.createWidget ();
items = new TabItem [4];
}
@@ -314,7 +318,7 @@
}
}
-void drawThemeBackground (int hDC, int hwnd, RECT rect) {
+override void drawThemeBackground (int hDC, int hwnd, RECT rect) {
RECT rect2 = new RECT ();
OS.GetClientRect (handle, rect2);
OS.MapWindowPoints (handle, hwnd, rect2, 2);
@@ -323,12 +327,12 @@
}
}
-Control findThemeControl () {
+override Control findThemeControl () {
/* It is not possible to change the background of this control */
return this;
}
-public Rectangle getClientArea () {
+override public Rectangle getClientArea () {
checkWidget ();
forceResize ();
RECT rect = new RECT ();
@@ -485,7 +489,7 @@
return -1;
}
-Point minimumSize (int wHint, int hHint, bool flushCache) {
+override Point minimumSize (int wHint, int hHint, bool flushCache) {
Control [] children = _getChildren ();
int width = 0, height = 0;
for (int i=0; i
*
*/
-public void setText (String string) {
+override public void setText (String string) {
checkWidget();
if (string is null) error (DWT.ERROR_NULL_ARGUMENT);
if (string.equals (text)) return;
diff -r 0405e18fec7f -r 0f25be5cbe6f dwt/widgets/Table.d
--- a/dwt/widgets/Table.d Sun Feb 03 15:48:14 2008 -0800
+++ b/dwt/widgets/Table.d Mon Feb 04 10:05:20 2008 +0100
@@ -101,6 +101,13 @@
*/
public class Table extends Composite {
+
+ alias Composite.computeSize computeSize;
+ alias Composite.setBackgroundImage setBackgroundImage;
+ alias Composite.setBounds setBounds;
+ alias Composite.sort sort;
+ alias Composite.update update;
+
TableItem [] items;
TableColumn [] columns;
int columnCount, customCount;
@@ -165,7 +172,7 @@
super (parent, checkStyle (style));
}
-void _addListener (int eventType, Listener listener) {
+override void _addListener (int eventType, Listener listener) {
super._addListener (eventType, listener);
switch (eventType) {
case DWT.MeasureItem:
@@ -221,7 +228,7 @@
addListener (DWT.DefaultSelection,typedListener);
}
-int callWindowProc (int hwnd, int msg, int wParam, int lParam) {
+override int callWindowProc (int hwnd, int msg, int wParam, int lParam) {
return callWindowProc (hwnd, msg, wParam, lParam, false);
}
@@ -825,7 +832,7 @@
return new LRESULT (code);
}
-void checkBuffered () {
+override void checkBuffered () {
super.checkBuffered ();
if (OS.COMCTL32_MAJOR >= 6) style |= DWT.DOUBLE_BUFFERED;
if ((style & DWT.VIRTUAL) !is 0) style |= DWT.DOUBLE_BUFFERED;
@@ -857,12 +864,12 @@
return true;
}
-bool checkHandle (int hwnd) {
+override bool checkHandle (int hwnd) {
if (hwnd is handle) return true;
return hwnd is OS.SendMessage (handle, OS.LVM_GETHEADER, 0, 0);
}
-protected void checkSubclass () {
+override protected void checkSubclass () {
if (!isValidSubclass ()) error (DWT.ERROR_INVALID_SUBCLASS);
}
@@ -1125,7 +1132,7 @@
}
}
-public Point computeSize (int wHint, int hHint, bool changed) {
+override public Point computeSize (int wHint, int hHint, bool changed) {
checkWidget ();
if (fixScrollWidth) setScrollWidth (null, true);
//This code is intentionally commented
@@ -1186,7 +1193,7 @@
return new Point (width, height);
}
-void createHandle () {
+override void createHandle () {
super.createHandle ();
state &= ~(CANVAS | THEME_BACKGROUND);
@@ -1515,18 +1522,18 @@
if (count is 0) setScrollWidth (item, false);
}
-void createWidget () {
+override void createWidget () {
super.createWidget ();
itemHeight = hotIndex = -1;
items = new TableItem [4];
columns = new TableColumn [4];
}
-int defaultBackground () {
+override int defaultBackground () {
return OS.GetSysColor (OS.COLOR_WINDOW);
}
-void deregister () {
+override void deregister () {
super.deregister ();
int hwndHeader = OS.SendMessage (handle, OS.LVM_GETHEADER, 0, 0);
if (hwndHeader !is 0) display.removeControl (hwndHeader);
@@ -2629,13 +2636,13 @@
return (result !is 0) && ((lvItem.state & OS.LVIS_SELECTED) !is 0);
}
-void register () {
+override void register () {
super.register ();
int hwndHeader = OS.SendMessage (handle, OS.LVM_GETHEADER, 0, 0);
if (hwndHeader !is 0) display.addControl (hwndHeader, this);
}
-void releaseChildren (bool destroy) {
+override void releaseChildren (bool destroy) {
if (items !is null) {
int itemCount = OS.SendMessage (handle, OS.LVM_GETITEMCOUNT, 0, 0);
/*
@@ -2681,7 +2688,7 @@
super.releaseChildren (destroy);
}
-void releaseWidget () {
+override void releaseWidget () {
super.releaseWidget ();
customDraw = false;
currentItem = null;
@@ -3483,12 +3490,12 @@
OS.RestoreDC (hDC, nSavedDC);
}
-void setBackgroundImage (int hBitmap) {
+override void setBackgroundImage (int hBitmap) {
super.setBackgroundImage (hBitmap);
if (!customDraw) setBackgroundTransparent (hBitmap !is 0);
}
-void setBackgroundPixel (int newPixel) {
+override void setBackgroundPixel (int newPixel) {
if (!customDraw) {
if (findImageControl () !is null) return;
if (newPixel is -1) newPixel = defaultBackground ();
@@ -3588,7 +3595,7 @@
}
}
-void setBounds (int x, int y, int width, int height, int flags, bool defer) {
+override void setBounds (int x, int y, int width, int height, int flags, bool defer) {
/*
* Bug in Windows. If the table column widths are adjusted
* in WM_SIZE or WM_POSITIONCHANGED using LVM_SETCOLUMNWIDTH
@@ -3857,7 +3864,7 @@
OS.SendMessage (handle, OS.LVM_SETSELECTIONMARK, 0, index);
}
-public void setFont (Font font) {
+override public void setFont (Font font) {
checkWidget ();
/*
* Bug in Windows. Making any change to an item that
@@ -3897,7 +3904,7 @@
OS.InvalidateRect (hwndHeader, null, true);
}
-void setForegroundPixel (int pixel) {
+override void setForegroundPixel (int pixel) {
/*
* The Windows table control uses CLR_DEFAULT to indicate
* that it is using the default foreground color. This
@@ -4126,7 +4133,7 @@
}
}
-public void setRedraw (bool redraw) {
+override public void setRedraw (bool redraw) {
checkWidget ();
/*
* Feature in Windows. When WM_SETREDRAW is used to turn
@@ -4852,7 +4859,7 @@
// redraw ();
}
-void subclass () {
+override void subclass () {
super.subclass ();
if (HeaderProc !is 0) {
int hwndHeader = OS.SendMessage (handle, OS.LVM_GETHEADER, 0, 0);
@@ -4860,7 +4867,7 @@
}
}
-String toolTipText (NMTTDISPINFO hdr) {
+override String toolTipText (NMTTDISPINFO hdr) {
int hwndToolTip = OS.SendMessage (handle, OS.LVM_GETTOOLTIPS, 0, 0);
if (hwndToolTip is hdr.hwndFrom && toolTipText !is null) return ""; //$NON-NLS-1$
if (headerToolTipHandle is hdr.hwndFrom) {
@@ -4872,7 +4879,7 @@
return super.toolTipText (hdr);
}
-void unsubclass () {
+override void unsubclass () {
super.unsubclass ();
if (HeaderProc !is 0) {
int hwndHeader = OS.SendMessage (handle, OS.LVM_GETHEADER, 0, 0);
@@ -4880,7 +4887,7 @@
}
}
-void update (bool all) {
+override void update (bool all) {
// checkWidget ();
/*
* When there are many columns in a table, scrolling performance
@@ -4929,7 +4936,7 @@
}
}
-void updateImages () {
+override void updateImages () {
if (sortColumn !is null && !sortColumn.isDisposed ()) {
if (OS.COMCTL32_MAJOR < 6) {
switch (sortDirection) {
@@ -4952,7 +4959,7 @@
OS.SendMessage (handle, OS.LVM_SETEXTENDEDLISTVIEWSTYLE, OS.LVS_EX_HEADERDRAGDROP, newBits);
}
-int widgetStyle () {
+override int widgetStyle () {
int bits = super.widgetStyle () | OS.LVS_SHAREIMAGELISTS;
if ((style & DWT.HIDE_SELECTION) is 0) bits |= OS.LVS_SHOWSELALWAYS;
if ((style & DWT.SINGLE) !is 0) bits |= OS.LVS_SINGLESEL;
@@ -4967,15 +4974,15 @@
return bits;
}
-TCHAR windowClass () {
+override TCHAR windowClass () {
return TableClass;
}
-int windowProc () {
+override int windowProc () {
return TableProc;
}
-int windowProc (int hwnd, int msg, int wParam, int lParam) {
+override int windowProc (int hwnd, int msg, int wParam, int lParam) {
if (handle is 0) return 0;
if (hwnd !is handle) {
switch (msg) {
@@ -5061,7 +5068,7 @@
return super.windowProc (hwnd, msg, wParam, lParam);
}
-LRESULT WM_CHAR (int wParam, int lParam) {
+override LRESULT WM_CHAR (int wParam, int lParam) {
LRESULT result = super.WM_CHAR (wParam, lParam);
if (result !is null) return result;
switch (wParam) {
@@ -5103,7 +5110,7 @@
return result;
}
-LRESULT WM_CONTEXTMENU (int wParam, int lParam) {
+override LRESULT WM_CONTEXTMENU (int wParam, int lParam) {
/*
* Feature in Windows. For some reason, when the right
* mouse button is pressed over an item, Windows sends
@@ -5120,7 +5127,7 @@
return super.WM_CONTEXTMENU (wParam, lParam);
}
-LRESULT WM_ERASEBKGND (int wParam, int lParam) {
+override LRESULT WM_ERASEBKGND (int wParam, int lParam) {
LRESULT result = super.WM_ERASEBKGND (wParam, lParam);
if (findImageControl () !is null) return LRESULT.ONE;
if (OS.COMCTL32_MAJOR < 6) {
@@ -5132,7 +5139,7 @@
return result;
}
-LRESULT WM_GETOBJECT (int wParam, int lParam) {
+override LRESULT WM_GETOBJECT (int wParam, int lParam) {
/*
* Ensure that there is an accessible object created for this
* control because support for checked item accessibility is
@@ -5144,7 +5151,7 @@
return super.WM_GETOBJECT (wParam, lParam);
}
-LRESULT WM_KEYDOWN (int wParam, int lParam) {
+override LRESULT WM_KEYDOWN (int wParam, int lParam) {
LRESULT result = super.WM_KEYDOWN (wParam, lParam);
if (result !is null) return result;
switch (wParam) {
@@ -5212,7 +5219,7 @@
return result;
}
-LRESULT WM_KILLFOCUS (int wParam, int lParam) {
+override LRESULT WM_KILLFOCUS (int wParam, int lParam) {
LRESULT result = super.WM_KILLFOCUS (wParam, lParam);
/*
* Bug in Windows. When focus is lost, Windows does not
@@ -5226,7 +5233,7 @@
return result;
}
-LRESULT WM_LBUTTONDBLCLK (int wParam, int lParam) {
+override LRESULT WM_LBUTTONDBLCLK (int wParam, int lParam) {
/*
* Feature in Windows. When the user selects outside of
@@ -5274,7 +5281,7 @@
return LRESULT.ZERO;
}
-LRESULT WM_LBUTTONDOWN (int wParam, int lParam) {
+override LRESULT WM_LBUTTONDOWN (int wParam, int lParam) {
/*
* Feature in Windows. For some reason, capturing
* the mouse after processing the mouse event for the
@@ -5310,7 +5317,7 @@
return result;
}
-LRESULT WM_MOUSEHOVER (int wParam, int lParam) {
+override LRESULT WM_MOUSEHOVER (int wParam, int lParam) {
/*
* Feature in Windows. Despite the fact that hot
* tracking is not enabled, the hot tracking code
@@ -5325,7 +5332,7 @@
return LRESULT.ZERO;
}
-LRESULT WM_PAINT (int wParam, int lParam) {
+override LRESULT WM_PAINT (int wParam, int lParam) {
if (!ignoreShrink) {
/* Resize the item array to match the item count */
int count = OS.SendMessage (handle, OS.LVM_GETITEMCOUNT, 0, 0);
@@ -5399,7 +5406,7 @@
return super.WM_PAINT (wParam, lParam);
}
-LRESULT WM_RBUTTONDBLCLK (int wParam, int lParam) {
+override LRESULT WM_RBUTTONDBLCLK (int wParam, int lParam) {
/*
* Feature in Windows. When the user selects outside of
* a table item, Windows deselects all the items, even
@@ -5423,7 +5430,7 @@
return LRESULT.ZERO;
}
-LRESULT WM_RBUTTONDOWN (int wParam, int lParam) {
+override LRESULT WM_RBUTTONDOWN (int wParam, int lParam) {
/*
* Feature in Windows. For some reason, capturing
* the mouse after processing the mouse event for the
@@ -5434,7 +5441,7 @@
return sendMouseDownEvent (DWT.MouseDown, 3, OS.WM_RBUTTONDOWN, wParam, lParam);
}
-LRESULT WM_SETFOCUS (int wParam, int lParam) {
+override LRESULT WM_SETFOCUS (int wParam, int lParam) {
LRESULT result = super.WM_SETFOCUS (wParam, lParam);
/*
* Bug in Windows. When focus is gained after the
@@ -5469,7 +5476,7 @@
return result;
}
-LRESULT WM_SETFONT (int wParam, int lParam) {
+override LRESULT WM_SETFONT (int wParam, int lParam) {
LRESULT result = super.WM_SETFONT (wParam, lParam);
if (result !is null) return result;
@@ -5493,7 +5500,7 @@
return result;
}
-LRESULT WM_SIZE (int wParam, int lParam) {
+override LRESULT WM_SIZE (int wParam, int lParam) {
if (ignoreResize) return null;
if (hooks (DWT.EraseItem) || hooks (DWT.PaintItem)) {
OS.InvalidateRect (handle, null, true);
@@ -5505,7 +5512,7 @@
return super.WM_SIZE (wParam, lParam);
}
-LRESULT WM_SYSCOLORCHANGE (int wParam, int lParam) {
+override LRESULT WM_SYSCOLORCHANGE (int wParam, int lParam) {
LRESULT result = super.WM_SYSCOLORCHANGE (wParam, lParam);
if (result !is null) return result;
if (findBackgroundControl () is null) {
@@ -5518,7 +5525,7 @@
return result;
}
-LRESULT WM_HSCROLL (int wParam, int lParam) {
+override LRESULT WM_HSCROLL (int wParam, int lParam) {
/*
* Bug in Windows. When a table that is drawing grid lines
* is slowly scrolled horizontally to the left, the table does
@@ -5583,7 +5590,7 @@
return result;
}
-LRESULT WM_VSCROLL (int wParam, int lParam) {
+override LRESULT WM_VSCROLL (int wParam, int lParam) {
/*
* When there are many columns in a table, scrolling performance
* can be improved by temporarily unsubclassing the window proc
@@ -5651,7 +5658,7 @@
return result;
}
-LRESULT wmMeasureChild (int wParam, int lParam) {
+override LRESULT wmMeasureChild (int wParam, int lParam) {
MEASUREITEMSTRUCT struct = new MEASUREITEMSTRUCT ();
OS.MoveMemory (struct, lParam, MEASUREITEMSTRUCT.sizeof);
if (itemHeight is -1) {
@@ -5665,7 +5672,7 @@
return null;
}
-LRESULT wmNotify (NMHDR hdr, int wParam, int lParam) {
+override LRESULT wmNotify (NMHDR hdr, int wParam, int lParam) {
int hwndHeader = OS.SendMessage (handle, OS.LVM_GETHEADER, 0, 0);
if (hdr.hwndFrom is hwndHeader) {
/*
@@ -5855,7 +5862,7 @@
return result;
}
-LRESULT wmNotifyChild (NMHDR hdr, int wParam, int lParam) {
+override LRESULT wmNotifyChild (NMHDR hdr, int wParam, int lParam) {
switch (hdr.code) {
case OS.LVN_ODFINDITEMA:
case OS.LVN_ODFINDITEMW: {
diff -r 0405e18fec7f -r 0f25be5cbe6f dwt/widgets/TableColumn.d
--- a/dwt/widgets/TableColumn.d Sun Feb 03 15:48:14 2008 -0800
+++ b/dwt/widgets/TableColumn.d Mon Feb 04 10:05:20 2008 +0100
@@ -197,11 +197,11 @@
return checkBits (style, DWT.LEFT, DWT.CENTER, DWT.RIGHT, 0, 0, 0);
}
-protected void checkSubclass () {
+override protected void checkSubclass () {
if (!isValidSubclass ()) error (DWT.ERROR_INVALID_SUBCLASS);
}
-void destroyWidget () {
+override void destroyWidget () {
parent.destroyItem (this);
releaseHandle ();
}
@@ -226,7 +226,7 @@
return DWT.LEFT;
}
-String getNameText () {
+override String getNameText () {
return getText ();
}
@@ -481,12 +481,12 @@
}
}
-void releaseHandle () {
+override void releaseHandle () {
super.releaseHandle ();
parent = null;
}
-void releaseParent () {
+override void releaseParent () {
super.releaseParent ();
if (parent.sortColumn is this) {
parent.sortColumn = null;
@@ -592,7 +592,7 @@
}
}
-public void setImage (Image image) {
+override public void setImage (Image image) {
checkWidget();
if (image !is null && image.isDisposed ()) {
error (DWT.ERROR_INVALID_ARGUMENT);
@@ -772,7 +772,7 @@
}
}
-public void setText (String string) {
+override public void setText (String string) {
checkWidget ();
if (string is null) error (DWT.ERROR_NULL_ARGUMENT);
if (string.equals (text)) return;
diff -r 0405e18fec7f -r 0f25be5cbe6f dwt/widgets/TableItem.d
--- a/dwt/widgets/TableItem.d Sun Feb 03 15:48:14 2008 -0800
+++ b/dwt/widgets/TableItem.d Mon Feb 04 10:05:20 2008 +0100
@@ -134,7 +134,7 @@
return control;
}
-protected void checkSubclass () {
+override protected void checkSubclass () {
if (!isValidSubclass ()) error (DWT.ERROR_INVALID_SUBCLASS);
}
@@ -150,7 +150,7 @@
if ((parent.style & DWT.VIRTUAL) !is 0) cached = false;
}
-void destroyWidget () {
+override void destroyWidget () {
parent.destroyItem (this);
releaseHandle ();
}
@@ -531,7 +531,7 @@
return grayed;
}
-public Image getImage () {
+override public Image getImage () {
checkWidget();
if (!parent.checkData (this, true)) error (DWT.ERROR_WIDGET_DISPOSED);
return super.getImage ();
@@ -599,7 +599,7 @@
return imageIndent;
}
-String getNameText () {
+override String getNameText () {
if ((parent.style & DWT.VIRTUAL) !is 0) {
if (!cached) return "*virtual*"; //$NON-NLS-1$
}
@@ -621,7 +621,7 @@
return parent;
}
-public String getText () {
+override public String getText () {
checkWidget();
if (!parent.checkData (this, true)) error (DWT.ERROR_WIDGET_DISPOSED);
return super.getText ();
@@ -702,12 +702,12 @@
OS.InvalidateRect (hwnd, rect, true);
}
-void releaseHandle () {
+override void releaseHandle () {
super.releaseHandle ();
parent = null;
}
-void releaseWidget () {
+override void releaseWidget () {
super.releaseWidget ();
strings = null;
images = null;
@@ -1054,7 +1054,7 @@
* ERROR_THREAD_INVALID_ACCESS - if not called from the thread that created the receiver
*
*/
-public void setImage (Image [] images) {
+override public void setImage (Image [] images) {
checkWidget();
if (images is null) error (DWT.ERROR_NULL_ARGUMENT);
for (int i=0; iERROR_THREAD_INVALID_ACCESS - if not called from the thread that created the receiver
*
*/
-public void setText (String [] strings) {
+override public void setText (String [] strings) {
checkWidget();
if (strings is null) error (DWT.ERROR_NULL_ARGUMENT);
for (int i=0; i
*/
public class Text extends Scrollable {
+
+ alias Scrollable.computeSize computeSize;
+ alias Scrollable.dragDetect dragDetect;
+ alias Scrollable.sendKeyEvent sendKeyEvent;
+ alias Scrollable.setBounds setBounds;
+
int tabs, oldStart, oldEnd;
bool doubleClick, ignoreModify, ignoreVerify, ignoreCharacter;
String message;
@@ -148,12 +154,12 @@
super (parent, checkStyle (style));
}
-int callWindowProc (int hwnd, int msg, int wParam, int lParam) {
+override int callWindowProc (int hwnd, int msg, int wParam, int lParam) {
if (handle is 0) return 0;
return OS.CallWindowProc (EditProc, hwnd, msg, wParam, lParam);
}
-void createHandle () {
+override void createHandle () {
super.createHandle ();
OS.SendMessage (handle, OS.EM_LIMITTEXT, 0, 0);
if ((style & DWT.READ_ONLY) !is 0) {
@@ -341,7 +347,7 @@
}
}
-public Point computeSize (int wHint, int hHint, bool changed) {
+override public Point computeSize (int wHint, int hHint, bool changed) {
checkWidget ();
int height = 0, width = 0;
if (wHint is DWT.DEFAULT || hHint is DWT.DEFAULT) {
@@ -395,7 +401,7 @@
return new Point (trim.width, trim.height);
}
-public Rectangle computeTrim (int x, int y, int width, int height) {
+override public Rectangle computeTrim (int x, int y, int width, int height) {
checkWidget ();
Rectangle rect = super.computeTrim (x, y, width, height);
/*
@@ -433,7 +439,7 @@
OS.SendMessage (handle, OS.WM_COPY, 0, 0);
}
-void createWidget () {
+override void createWidget () {
super.createWidget ();
message = "";
doubleClick = true;
@@ -459,12 +465,12 @@
OS.SendMessage (handle, OS.WM_CUT, 0, 0);
}
-int defaultBackground () {
+override int defaultBackground () {
int bits = OS.GetWindowLong (handle, OS.GWL_STYLE);
return OS.GetSysColor ((bits & OS.ES_READONLY) !is 0 ? OS.COLOR_3DFACE : OS.COLOR_WINDOW);
}
-bool dragDetect (int hwnd, int x, int y, bool filter, bool [] detect, bool [] consume) {
+override bool dragDetect (int hwnd, int x, int y, bool filter, bool [] detect, bool [] consume) {
if (filter) {
int [] start = new int [1], end = new int [1];
OS.SendMessage (handle, OS.EM_GETSEL, start, end);
@@ -536,7 +542,7 @@
OS.SetWindowLong (handle, OS.GWL_STYLE, bits2);
}
-public int getBorderWidth () {
+override public int getBorderWidth () {
checkWidget ();
/*
* Feature in Windows 2000 and XP. Despite the fact that WS_BORDER
@@ -1224,7 +1230,7 @@
OS.SendMessage (handle, OS.WM_PASTE, 0, 0);
}
-void releaseWidget () {
+override void releaseWidget () {
super.releaseWidget ();
message = null;
}
@@ -1315,7 +1321,7 @@
OS.SendMessage (handle, OS.EM_SETSEL, 0, -1);
}
-bool sendKeyEvent (int type, int msg, int wParam, int lParam, Event event) {
+override bool sendKeyEvent (int type, int msg, int wParam, int lParam, Event event) {
if (!super.sendKeyEvent (type, msg, wParam, lParam, event)) {
return false;
}
@@ -1429,7 +1435,7 @@
return false;
}
-void setBounds (int x, int y, int width, int height, int flags) {
+override void setBounds (int x, int y, int width, int height, int flags) {
/*
* Feature in Windows. When the caret is moved,
* the text widget scrolls to show the new location.
@@ -1464,7 +1470,7 @@
super.setBounds (x, y, width, height, flags);
}
-void setDefaultFont () {
+override void setDefaultFont () {
super.setDefaultFont ();
setMargins ();
}
@@ -1545,7 +1551,7 @@
OS.SendMessage (handle, OS.EM_SETREADONLY, editable ? 0 : 1, 0);
}
-public void setFont (Font font) {
+override public void setFont (Font font) {
checkWidget ();
super.setFont (font);
setTabStops (tabs);
@@ -1705,7 +1711,7 @@
OS.SendMessage (handle, OS.EM_SCROLLCARET, 0, 0);
}
-public void setRedraw (bool redraw) {
+override public void setRedraw (bool redraw) {
checkWidget ();
super.setRedraw (redraw);
/*
@@ -1978,7 +1984,7 @@
return mbcsTotal;
}
-int widgetStyle () {
+override int widgetStyle () {
int bits = super.widgetStyle () | OS.ES_AUTOHSCROLL;
if ((style & DWT.PASSWORD) !is 0) bits |= OS.ES_PASSWORD;
if ((style & DWT.CENTER) !is 0) bits |= OS.ES_CENTER;
@@ -2008,15 +2014,15 @@
return bits;
}
-TCHAR windowClass () {
+override TCHAR windowClass () {
return EditClass;
}
-int windowProc () {
+override int windowProc () {
return EditProc;
}
-int windowProc (int hwnd, int msg, int wParam, int lParam) {
+override int windowProc (int hwnd, int msg, int wParam, int lParam) {
if (msg is OS.EM_UNDO) {
int bits = OS.GetWindowLong (handle, OS.GWL_STYLE);
if ((bits & OS.ES_MULTILINE) is 0) {
@@ -2033,7 +2039,7 @@
return super.windowProc (hwnd, msg, wParam, lParam);
}
-LRESULT WM_CHAR (int wParam, int lParam) {
+override LRESULT WM_CHAR (int wParam, int lParam) {
if (ignoreCharacter) return null;
LRESULT result = super.WM_CHAR (wParam, lParam);
if (result !is null) return result;
@@ -2071,19 +2077,19 @@
return result;
}
-LRESULT WM_CLEAR (int wParam, int lParam) {
+override LRESULT WM_CLEAR (int wParam, int lParam) {
LRESULT result = super.WM_CLEAR (wParam, lParam);
if (result !is null) return result;
return wmClipboard (OS.WM_CLEAR, wParam, lParam);
}
-LRESULT WM_CUT (int wParam, int lParam) {
+override LRESULT WM_CUT (int wParam, int lParam) {
LRESULT result = super.WM_CUT (wParam, lParam);
if (result !is null) return result;
return wmClipboard (OS.WM_CUT, wParam, lParam);
}
-LRESULT WM_ERASEBKGND (int wParam, int lParam) {
+override LRESULT WM_ERASEBKGND (int wParam, int lParam) {
LRESULT result = super.WM_ERASEBKGND (wParam, lParam);
if ((style & DWT.READ_ONLY) !is 0) {
if ((style & (DWT.BORDER | DWT.H_SCROLL | DWT.V_SCROLL)) is 0) {
@@ -2109,7 +2115,7 @@
return result;
}
-LRESULT WM_GETDLGCODE (int wParam, int lParam) {
+override LRESULT WM_GETDLGCODE (int wParam, int lParam) {
LRESULT result = super.WM_GETDLGCODE (wParam, lParam);
if (result !is null) return result;
@@ -2142,7 +2148,7 @@
return null;
}
-LRESULT WM_IME_CHAR (int wParam, int lParam) {
+override LRESULT WM_IME_CHAR (int wParam, int lParam) {
/* Process a DBCS character */
Display display = this.display;
@@ -2176,7 +2182,7 @@
return new LRESULT (result);
}
-LRESULT WM_LBUTTONDBLCLK (int wParam, int lParam) {
+override LRESULT WM_LBUTTONDBLCLK (int wParam, int lParam) {
/*
* Prevent Windows from processing WM_LBUTTONDBLCLK
* when double clicking behavior is disabled by not
@@ -2214,7 +2220,7 @@
return result;
}
-LRESULT WM_LBUTTONDOWN (int wParam, int lParam) {
+override LRESULT WM_LBUTTONDOWN (int wParam, int lParam) {
if (OS.IsPPC) {
LRESULT result = null;
Display display = this.display;
@@ -2258,13 +2264,13 @@
return super.WM_LBUTTONDOWN (wParam, lParam);
}
-LRESULT WM_PASTE (int wParam, int lParam) {
+override LRESULT WM_PASTE (int wParam, int lParam) {
LRESULT result = super.WM_PASTE (wParam, lParam);
if (result !is null) return result;
return wmClipboard (OS.WM_PASTE, wParam, lParam);
}
-LRESULT WM_UNDO (int wParam, int lParam) {
+override LRESULT WM_UNDO (int wParam, int lParam) {
LRESULT result = super.WM_UNDO (wParam, lParam);
if (result !is null) return result;
return wmClipboard (OS.WM_UNDO, wParam, lParam);
@@ -2346,7 +2352,7 @@
return null;
}
-LRESULT wmColorChild (int wParam, int lParam) {
+override LRESULT wmColorChild (int wParam, int lParam) {
if ((style & DWT.READ_ONLY) !is 0) {
if ((style & (DWT.BORDER | DWT.H_SCROLL | DWT.V_SCROLL)) is 0) {
int bits = OS.GetWindowLong (handle, OS.GWL_STYLE);
@@ -2371,7 +2377,7 @@
return super.wmColorChild (wParam, lParam);
}
-LRESULT wmCommandChild (int wParam, int lParam) {
+override LRESULT wmCommandChild (int wParam, int lParam) {
int code = wParam >> 16;
switch (code) {
case OS.EN_CHANGE:
diff -r 0405e18fec7f -r 0f25be5cbe6f dwt/widgets/ToolBar.d
--- a/dwt/widgets/ToolBar.d Sun Feb 03 15:48:14 2008 -0800
+++ b/dwt/widgets/ToolBar.d Mon Feb 04 10:05:20 2008 +0100
@@ -60,6 +60,12 @@
*
*/
public class ToolBar extends Composite {
+
+ alias Composite.computeSize computeSize;
+ alias Composite.setBackgroundImage setBackgroundImage;
+ alias Composite.setBounds setBounds;
+ alias Composite.windowProc windowProc;
+
int lastFocusId;
ToolItem [] items;
bool ignoreResize, ignoreMouse;
@@ -153,7 +159,7 @@
}
}
-int callWindowProc (int hwnd, int msg, int wParam, int lParam) {
+override int callWindowProc (int hwnd, int msg, int wParam, int lParam) {
if (handle is 0) return 0;
/*
* Bug in Windows. For some reason, during the processing
@@ -190,16 +196,16 @@
return style & ~(DWT.H_SCROLL | DWT.V_SCROLL);
}
-void checkBuffered () {
+override void checkBuffered () {
super.checkBuffered ();
if (OS.COMCTL32_MAJOR >= 6) style |= DWT.DOUBLE_BUFFERED;
}
-protected void checkSubclass () {
+override protected void checkSubclass () {
if (!isValidSubclass ()) error (DWT.ERROR_INVALID_SUBCLASS);
}
-public Point computeSize (int wHint, int hHint, bool changed) {
+override public Point computeSize (int wHint, int hHint, bool changed) {
checkWidget ();
int width = 0, height = 0;
if ((style & DWT.VERTICAL) !is 0) {
@@ -261,7 +267,7 @@
return new Point (width, height);
}
-public Rectangle computeTrim (int x, int y, int width, int height) {
+override public Rectangle computeTrim (int x, int y, int width, int height) {
checkWidget ();
Rectangle trim = super.computeTrim (x, y, width, height);
int bits = OS.GetWindowLong (handle, OS.GWL_STYLE);
@@ -269,7 +275,7 @@
return trim;
}
-void createHandle () {
+override void createHandle () {
super.createHandle ();
state &= ~CANVAS;
@@ -369,13 +375,13 @@
layoutItems ();
}
-void createWidget () {
+override void createWidget () {
super.createWidget ();
items = new ToolItem [4];
lastFocusId = -1;
}
-int defaultBackground () {
+override int defaultBackground () {
if (OS.IsWinCE) return OS.GetSysColor (OS.COLOR_BTNFACE);
return super.defaultBackground ();
}
@@ -425,7 +431,7 @@
layoutItems ();
}
-void enableWidget (bool enabled) {
+override void enableWidget (bool enabled) {
super.enableWidget (enabled);
/*
* Bug in Windows. When a tool item with the style
@@ -687,7 +693,7 @@
}
}
-bool mnemonicHit (char ch) {
+override bool mnemonicHit (char ch) {
int key = Display.wcsToMbcs (ch);
int [] id = new int [1];
if (OS.SendMessage (handle, OS.TB_MAPACCELERATOR, key, id) is 0) {
@@ -701,7 +707,7 @@
return true;
}
-bool mnemonicMatch (char ch) {
+override bool mnemonicMatch (char ch) {
int key = Display.wcsToMbcs (ch);
int [] id = new int [1];
if (OS.SendMessage (handle, OS.TB_MAPACCELERATOR, key, id) is 0) {
@@ -718,7 +724,7 @@
return findMnemonic (items [id [0]].text) !is '\0';
}
-void releaseChildren (bool destroy) {
+override void releaseChildren (bool destroy) {
if (items !is null) {
for (int i=0; i= 6 && OS.IsAppThemed ()) bits |= OS.TBSTYLE_TRANSPARENT;
if ((style & DWT.SHADOW_OUT) is 0) bits |= OS.CCS_NODIVIDER;
@@ -1029,15 +1035,15 @@
return bits;
}
-TCHAR windowClass () {
+override TCHAR windowClass () {
return ToolBarClass;
}
-int windowProc () {
+override int windowProc () {
return ToolBarProc;
}
-LRESULT WM_CAPTURECHANGED (int wParam, int lParam) {
+override LRESULT WM_CAPTURECHANGED (int wParam, int lParam) {
LRESULT result = super.WM_CAPTURECHANGED (wParam, lParam);
if (result !is null) return result;
/*
@@ -1058,7 +1064,7 @@
return result;
}
-LRESULT WM_CHAR (int wParam, int lParam) {
+override LRESULT WM_CHAR (int wParam, int lParam) {
LRESULT result = super.WM_CHAR (wParam, lParam);
if (result !is null) return result;
switch (wParam) {
@@ -1076,7 +1082,7 @@
return result;
}
-LRESULT WM_COMMAND (int wParam, int lParam) {
+override LRESULT WM_COMMAND (int wParam, int lParam) {
/*
* Feature in Windows. When the toolbar window
* proc processes WM_COMMAND, it forwards this
@@ -1100,7 +1106,7 @@
return LRESULT.ZERO;
}
-LRESULT WM_ERASEBKGND (int wParam, int lParam) {
+override LRESULT WM_ERASEBKGND (int wParam, int lParam) {
LRESULT result = super.WM_ERASEBKGND (wParam, lParam);
/*
* Bug in Windows. For some reason, NM_CUSTOMDRAW with
@@ -1117,7 +1123,7 @@
return result;
}
-LRESULT WM_GETDLGCODE (int wParam, int lParam) {
+override LRESULT WM_GETDLGCODE (int wParam, int lParam) {
LRESULT result = super.WM_GETDLGCODE (wParam, lParam);
/*
* Return DLGC_BUTTON so that mnemonics will be
@@ -1128,7 +1134,7 @@
return new LRESULT (OS.DLGC_BUTTON);
}
-LRESULT WM_KEYDOWN (int wParam, int lParam) {
+override LRESULT WM_KEYDOWN (int wParam, int lParam) {
LRESULT result = super.WM_KEYDOWN (wParam, lParam);
if (result !is null) return result;
switch (wParam) {
@@ -1143,7 +1149,7 @@
return result;
}
-LRESULT WM_KILLFOCUS (int wParam, int lParam) {
+override LRESULT WM_KILLFOCUS (int wParam, int lParam) {
int index = OS.SendMessage (handle, OS.TB_GETHOTITEM, 0, 0);
TBBUTTON lpButton = new TBBUTTON ();
int code = OS.SendMessage (handle, OS.TB_GETBUTTON, index, lpButton);
@@ -1151,17 +1157,17 @@
return super.WM_KILLFOCUS (wParam, lParam);
}
-LRESULT WM_LBUTTONDOWN (int wParam, int lParam) {
+override LRESULT WM_LBUTTONDOWN (int wParam, int lParam) {
if (ignoreMouse) return null;
return super.WM_LBUTTONDOWN (wParam, lParam);
}
-LRESULT WM_LBUTTONUP (int wParam, int lParam) {
+override LRESULT WM_LBUTTONUP (int wParam, int lParam) {
if (ignoreMouse) return null;
return super.WM_LBUTTONUP (wParam, lParam);
}
-LRESULT WM_MOUSELEAVE (int wParam, int lParam) {
+override LRESULT WM_MOUSELEAVE (int wParam, int lParam) {
LRESULT result = super.WM_MOUSELEAVE (wParam, lParam);
if (result !is null) return result;
/*
@@ -1189,7 +1195,7 @@
return result;
}
-LRESULT WM_NOTIFY (int wParam, int lParam) {
+override LRESULT WM_NOTIFY (int wParam, int lParam) {
/*
* Feature in Windows. When the toolbar window
* proc processes WM_NOTIFY, it forwards this
@@ -1213,7 +1219,7 @@
return LRESULT.ZERO;
}
-LRESULT WM_SETFOCUS (int wParam, int lParam) {
+override LRESULT WM_SETFOCUS (int wParam, int lParam) {
LRESULT result = super.WM_SETFOCUS (wParam, lParam);
if (lastFocusId !is -1 && handle is OS.GetFocus ()) {
int index = OS.SendMessage (handle, OS.TB_COMMANDTOINDEX, lastFocusId, 0);
@@ -1222,7 +1228,7 @@
return result;
}
-LRESULT WM_SIZE (int wParam, int lParam) {
+override LRESULT WM_SIZE (int wParam, int lParam) {
if (ignoreResize) {
int code = callWindowProc (handle, OS.WM_SIZE, wParam, lParam);
if (code is 0) return LRESULT.ZERO;
@@ -1264,7 +1270,7 @@
return result;
}
-LRESULT WM_WINDOWPOSCHANGING (int wParam, int lParam) {
+override LRESULT WM_WINDOWPOSCHANGING (int wParam, int lParam) {
LRESULT result = super.WM_WINDOWPOSCHANGING (wParam, lParam);
if (result !is null) return result;
if (ignoreResize) return result;
@@ -1306,13 +1312,13 @@
return result;
}
-LRESULT wmCommandChild (int wParam, int lParam) {
+override LRESULT wmCommandChild (int wParam, int lParam) {
ToolItem child = items [wParam & 0xFFFF];
if (child is null) return null;
return child.wmCommandChild (wParam, lParam);
}
-LRESULT wmNotifyChild (NMHDR hdr, int wParam, int lParam) {
+override LRESULT wmNotifyChild (NMHDR hdr, int wParam, int lParam) {
switch (hdr.code) {
case OS.TBN_DROPDOWN:
NMTOOLBAR lpnmtb = new NMTOOLBAR ();
diff -r 0405e18fec7f -r 0f25be5cbe6f dwt/widgets/ToolItem.d
--- a/dwt/widgets/ToolItem.d Sun Feb 03 15:48:14 2008 -0800
+++ b/dwt/widgets/ToolItem.d Mon Feb 04 10:05:20 2008 +0100
@@ -175,7 +175,7 @@
return checkBits (style, DWT.PUSH, DWT.CHECK, DWT.RADIO, DWT.SEPARATOR, DWT.DROP_DOWN, 0);
}
-protected void checkSubclass () {
+override protected void checkSubclass () {
if (!isValidSubclass ()) error (DWT.ERROR_INVALID_SUBCLASS);
}
@@ -206,7 +206,7 @@
}
}
-void destroyWidget () {
+override void destroyWidget () {
parent.destroyItem (this);
releaseHandle ();
}
@@ -406,7 +406,7 @@
return getEnabled () && parent.isEnabled ();
}
-void releaseWidget () {
+override void releaseWidget () {
super.releaseWidget ();
releaseImages ();
control = null;
@@ -416,7 +416,7 @@
disabledImage2 = null;
}
-void releaseHandle () {
+override void releaseHandle () {
super.releaseHandle ();
parent = null;
id = -1;
@@ -677,7 +677,7 @@
updateImages (getEnabled () && parent.getEnabled ());
}
-public void setImage (Image image) {
+override public void setImage (Image image) {
checkWidget();
if ((style & DWT.SEPARATOR) !is 0) return;
if (image !is null && image.isDisposed()) error(DWT.ERROR_INVALID_ARGUMENT);
@@ -770,7 +770,7 @@
* ERROR_THREAD_INVALID_ACCESS - if not called from the thread that created the receiver
*
*/
-public void setText (String string) {
+override public void setText (String string) {
checkWidget();
if (string is null) error (DWT.ERROR_NULL_ARGUMENT);
if ((style & DWT.SEPARATOR) !is 0) return;
diff -r 0405e18fec7f -r 0f25be5cbe6f dwt/widgets/ToolTip.d
--- a/dwt/widgets/ToolTip.d Sun Feb 03 15:48:14 2008 -0800
+++ b/dwt/widgets/ToolTip.d Mon Feb 04 10:05:20 2008 +0100
@@ -136,7 +136,7 @@
addListener (DWT.DefaultSelection,typedListener);
}
-void destroyWidget () {
+override void destroyWidget () {
if (parent !is null) parent.destroyToolTip (this);
releaseHandle ();
}
@@ -261,14 +261,14 @@
return getVisible ();
}
-void releaseHandle () {
+override void releaseHandle () {
super.releaseHandle ();
parent = null;
item = null;
id = -1;
}
-void releaseWidget () {
+override void releaseWidget () {
super.releaseWidget ();
if (item is null) {
if (autoHide) {
diff -r 0405e18fec7f -r 0f25be5cbe6f dwt/widgets/Tracker.d
--- a/dwt/widgets/Tracker.d Sun Feb 03 15:48:14 2008 -0800
+++ b/dwt/widgets/Tracker.d Mon Feb 04 10:05:20 2008 +0100
@@ -599,7 +599,7 @@
return !cancelled;
}
-void releaseWidget () {
+override void releaseWidget () {
super.releaseWidget ();
parent = null;
rectangles = proportions = null;
@@ -905,7 +905,7 @@
}
}
-LRESULT wmKeyDown (int hwnd, int wParam, int lParam) {
+override LRESULT wmKeyDown (int hwnd, int wParam, int lParam) {
LRESULT result = super.wmKeyDown (hwnd, wParam, lParam);
if (result !is null) return result;
bool isMirrored = parent !is null && (parent.style & DWT.MIRRORED) !is 0;
@@ -1039,7 +1039,7 @@
return result;
}
-LRESULT wmSysKeyDown (int hwnd, int wParam, int lParam) {
+override LRESULT wmSysKeyDown (int hwnd, int wParam, int lParam) {
LRESULT result = super.wmSysKeyDown (hwnd, wParam, lParam);
if (result !is null) return result;
cancelled = true;
diff -r 0405e18fec7f -r 0f25be5cbe6f dwt/widgets/Tray.d
--- a/dwt/widgets/Tray.d Sun Feb 03 15:48:14 2008 -0800
+++ b/dwt/widgets/Tray.d Mon Feb 04 10:05:20 2008 +0100
@@ -131,7 +131,7 @@
return result;
}
-void releaseChildren (bool destroy) {
+override void releaseChildren (bool destroy) {
if (items !is null) {
for (int i=0; iERROR_THREAD_INVALID_ACCESS - if not called from the thread that created the receiver
*
*/
-public void setImage (Image image) {
+override public void setImage (Image image) {
checkWidget ();
if (image !is null && image.isDisposed ()) error (DWT.ERROR_INVALID_ARGUMENT);
super.setImage (image);
diff -r 0405e18fec7f -r 0f25be5cbe6f dwt/widgets/Tree.d
--- a/dwt/widgets/Tree.d Sun Feb 03 15:48:14 2008 -0800
+++ b/dwt/widgets/Tree.d Mon Feb 04 10:05:20 2008 +0100
@@ -110,6 +110,13 @@
*
*/
public class Tree extends Composite {
+
+ alias Composite.computeSize computeSize;
+ alias Composite.setBackgroundImage setBackgroundImage;
+ alias Composite.setBounds setBounds;
+ alias Composite.setCursor setCursor;
+ alias Composite.sort sort;
+
TreeItem [] items;
TreeColumn [] columns;
ImageList imageList, headerImageList;
@@ -192,7 +199,7 @@
return checkBits (style, DWT.SINGLE, DWT.MULTI, 0, 0, 0, 0);
}
-void _addListener (int eventType, Listener listener) {
+override void _addListener (int eventType, Listener listener) {
super._addListener (eventType, listener);
switch (eventType) {
case DWT.DragDetect: {
@@ -258,7 +265,7 @@
return id !is -1 ? items [id] : new TreeItem (this, DWT.NONE, -1, -1, hItem);
}
-void _setBackgroundPixel (int newPixel) {
+override void _setBackgroundPixel (int newPixel) {
int oldPixel = OS.SendMessage (handle, OS.TVM_GETBKCOLOR, 0, 0);
if (oldPixel !is newPixel) {
/*
@@ -358,7 +365,7 @@
addListener (DWT.Collapse, typedListener);
}
-int borderHandle () {
+override int borderHandle () {
return hwndParent !is 0 ? hwndParent : handle;
}
@@ -1484,7 +1491,7 @@
return new LRESULT (OS.CDRF_NOTIFYITEMDRAW | OS.CDRF_NOTIFYPOSTPAINT);
}
-int callWindowProc (int hwnd, int msg, int wParam, int lParam) {
+override int callWindowProc (int hwnd, int msg, int wParam, int lParam) {
if (handle is 0) return 0;
if (hwndParent !is 0 && hwnd is hwndParent) {
return OS.DefWindowProc (hwnd, msg, wParam, lParam);
@@ -1644,7 +1651,7 @@
return code;
}
-void checkBuffered () {
+override void checkBuffered () {
super.checkBuffered ();
if ((style & DWT.VIRTUAL) !is 0) {
style |= DWT.DOUBLE_BUFFERED;
@@ -1682,7 +1689,7 @@
return true;
}
-bool checkHandle (int hwnd) {
+override bool checkHandle (int hwnd) {
return hwnd is handle || (hwndParent !is 0 && hwnd is hwndParent) || (hwndHeader !is 0 && hwnd is hwndHeader);
}
@@ -1707,7 +1714,7 @@
return hParent is 0;
}
-protected void checkSubclass () {
+override protected void checkSubclass () {
if (!isValidSubclass ()) error (DWT.ERROR_INVALID_SUBCLASS);
}
@@ -1804,7 +1811,7 @@
return sortDirection is DWT.UP ? text1.compareTo (text2) : text2.compareTo (text1);
}
-public Point computeSize (int wHint, int hHint, bool changed) {
+override public Point computeSize (int wHint, int hHint, bool changed) {
checkWidget ();
int width = 0, height = 0;
if (hwndHeader !is 0) {
@@ -1854,7 +1861,7 @@
return new Point (width, height);
}
-void createHandle () {
+override void createHandle () {
super.createHandle ();
state &= ~(CANVAS | THEME_BACKGROUND);
@@ -2308,18 +2315,18 @@
createItemToolTips ();
}
-void createWidget () {
+override void createWidget () {
super.createWidget ();
items = new TreeItem [4];
columns = new TreeColumn [4];
itemCount = -1;
}
-int defaultBackground () {
+override int defaultBackground () {
return OS.GetSysColor (OS.COLOR_WINDOW);
}
-void deregister () {
+override void deregister () {
super.deregister ();
if (hwndParent !is 0) display.removeControl (hwndParent);
if (hwndHeader !is 0) display.removeControl (hwndHeader);
@@ -2606,7 +2613,7 @@
updateScrollBar ();
}
-void enableDrag (bool enabled) {
+override void enableDrag (bool enabled) {
int bits = OS.GetWindowLong (handle, OS.GWL_STYLE);
if (enabled && hooks (DWT.DragDetect)) {
bits &= ~OS.TVS_DISABLEDRAGDROP;
@@ -2616,7 +2623,7 @@
OS.SetWindowLong (handle, OS.GWL_STYLE, bits);
}
-void enableWidget (bool enabled) {
+override void enableWidget (bool enabled) {
super.enableWidget (enabled);
/*
* Feature in Windows. When a tree is given a background color
@@ -2706,7 +2713,7 @@
return -1;
}
-Widget findItem (int hItem) {
+override Widget findItem (int hItem) {
return _getItem (hItem);
}
@@ -3696,7 +3703,7 @@
}
}
-void register () {
+override void register () {
super.register ();
if (hwndParent !is 0) display.addControl (hwndParent, this);
if (hwndHeader !is 0) display.addControl (hwndHeader, this);
@@ -3727,12 +3734,12 @@
}
}
-void releaseHandle () {
+override void releaseHandle () {
super.releaseHandle ();
hwndParent = hwndHeader = 0;
}
-void releaseChildren (bool destroy) {
+override void releaseChildren (bool destroy) {
if (items !is null) {
for (int i=0; i= OS.VERSION (6, 0)) {
bits |= OS.TVS_TRACKSELECT;
@@ -5241,15 +5248,15 @@
return bits | OS.TVS_DISABLEDRAGDROP;
}
-TCHAR windowClass () {
+override TCHAR windowClass () {
return TreeClass;
}
-int windowProc () {
+override int windowProc () {
return TreeProc;
}
-int windowProc (int hwnd, int msg, int wParam, int lParam) {
+override int windowProc (int hwnd, int msg, int wParam, int lParam) {
if (hwndHeader !is 0 && hwnd is hwndHeader) {
switch (msg) {
/* This code is intentionally commented */
@@ -5410,7 +5417,7 @@
return super.windowProc (hwnd, msg, wParam, lParam);
}
-LRESULT WM_CHAR (int wParam, int lParam) {
+override LRESULT WM_CHAR (int wParam, int lParam) {
LRESULT result = super.WM_CHAR (wParam, lParam);
if (result !is null) return result;
/*
@@ -5496,14 +5503,14 @@
return result;
}
-LRESULT WM_ERASEBKGND (int wParam, int lParam) {
+override LRESULT WM_ERASEBKGND (int wParam, int lParam) {
LRESULT result = super.WM_ERASEBKGND (wParam, lParam);
if ((style & DWT.DOUBLE_BUFFERED) !is 0) return LRESULT.ONE;
if (findImageControl () !is null) return LRESULT.ONE;
return result;
}
-LRESULT WM_GETOBJECT (int wParam, int lParam) {
+override LRESULT WM_GETOBJECT (int wParam, int lParam) {
/*
* Ensure that there is an accessible object created for this
* control because support for checked item and tree column
@@ -5516,7 +5523,7 @@
return super.WM_GETOBJECT (wParam, lParam);
}
-LRESULT WM_KEYDOWN (int wParam, int lParam) {
+override LRESULT WM_KEYDOWN (int wParam, int lParam) {
LRESULT result = super.WM_KEYDOWN (wParam, lParam);
if (result !is null) return result;
switch (wParam) {
@@ -5694,7 +5701,7 @@
return result;
}
-LRESULT WM_KILLFOCUS (int wParam, int lParam) {
+override LRESULT WM_KILLFOCUS (int wParam, int lParam) {
/*
* Bug in Windows. When a tree item that has an image
* with alpha is expanded or collapsed, the area where
@@ -5724,7 +5731,7 @@
return super.WM_KILLFOCUS (wParam, lParam);
}
-LRESULT WM_LBUTTONDBLCLK (int wParam, int lParam) {
+override LRESULT WM_LBUTTONDBLCLK (int wParam, int lParam) {
TVHITTESTINFO lpht = new TVHITTESTINFO ();
lpht.x = (short) (lParam & 0xFFFF);
lpht.y = (short) (lParam >> 16);
@@ -5785,7 +5792,7 @@
return result;
}
-LRESULT WM_LBUTTONDOWN (int wParam, int lParam) {
+override LRESULT WM_LBUTTONDOWN (int wParam, int lParam) {
/*
* In a multi-select tree, if the user is collapsing a subtree that
* contains selected items, clear the selection from these items and
@@ -6144,7 +6151,7 @@
return new LRESULT (code);
}
-LRESULT WM_MOUSEMOVE (int wParam, int lParam) {
+override LRESULT WM_MOUSEMOVE (int wParam, int lParam) {
Display display = this.display;
LRESULT result = super.WM_MOUSEMOVE (wParam, lParam);
if (result !is null) return result;
@@ -6210,12 +6217,12 @@
return result;
}
-LRESULT WM_MOVE (int wParam, int lParam) {
+override LRESULT WM_MOVE (int wParam, int lParam) {
if (ignoreResize) return null;
return super.WM_MOVE (wParam, lParam);
}
-LRESULT WM_RBUTTONDOWN (int wParam, int lParam) {
+override LRESULT WM_RBUTTONDOWN (int wParam, int lParam) {
/*
* Feature in Windows. The receiver uses WM_RBUTTONDOWN
* to initiate a drag/drop operation depending on how the
@@ -6276,7 +6283,7 @@
return LRESULT.ZERO;
}
-LRESULT WM_PAINT (int wParam, int lParam) {
+override LRESULT WM_PAINT (int wParam, int lParam) {
if (shrink && !ignoreShrink) {
/* Resize the item array to fit the last item */
int count = items.length - 1;
@@ -6357,7 +6364,7 @@
return super.WM_PAINT (wParam, lParam);
}
-LRESULT WM_PRINTCLIENT (int wParam, int lParam) {
+override LRESULT WM_PRINTCLIENT (int wParam, int lParam) {
LRESULT result = super.WM_PRINTCLIENT (wParam, lParam);
if (result !is null) return result;
/*
@@ -6376,7 +6383,7 @@
return new LRESULT (code);
}
-LRESULT WM_SETFOCUS (int wParam, int lParam) {
+override LRESULT WM_SETFOCUS (int wParam, int lParam) {
/*
* Bug in Windows. When a tree item that has an image
* with alpha is expanded or collapsed, the area where
@@ -6406,7 +6413,7 @@
return super.WM_SETFOCUS (wParam, lParam);
}
-LRESULT WM_SETFONT (int wParam, int lParam) {
+override LRESULT WM_SETFONT (int wParam, int lParam) {
LRESULT result = super.WM_SETFONT (wParam, lParam);
if (result !is null) return result;
if (hwndHeader !is 0) {
@@ -6429,7 +6436,7 @@
return result;
}
-LRESULT WM_SETREDRAW (int wParam, int lParam) {
+override LRESULT WM_SETREDRAW (int wParam, int lParam) {
LRESULT result = super.WM_SETREDRAW (wParam, lParam);
if (result !is null) return result;
/*
@@ -6450,7 +6457,7 @@
return result;
}
-LRESULT WM_SIZE (int wParam, int lParam) {
+override LRESULT WM_SIZE (int wParam, int lParam) {
/*
* Bug in Windows. When TVS_NOHSCROLL is set when the
* size of the tree is zero, the scroll bar is shown the
@@ -6479,7 +6486,7 @@
return super.WM_SIZE (wParam, lParam);
}
-LRESULT WM_SYSCOLORCHANGE (int wParam, int lParam) {
+override LRESULT WM_SYSCOLORCHANGE (int wParam, int lParam) {
LRESULT result = super.WM_SYSCOLORCHANGE (wParam, lParam);
if (result !is null) return result;
/*
@@ -6495,7 +6502,7 @@
return result;
}
-LRESULT wmColorChild (int wParam, int lParam) {
+override LRESULT wmColorChild (int wParam, int lParam) {
if (findImageControl () !is null) {
if (OS.COMCTL32_MAJOR < 6) {
return super.wmColorChild (wParam, lParam);
@@ -6512,7 +6519,7 @@
return null;
}
-LRESULT wmNotify (NMHDR hdr, int wParam, int lParam) {
+override LRESULT wmNotify (NMHDR hdr, int wParam, int lParam) {
if (hdr.hwndFrom is itemToolTipHandle && hwndHeader !is 0) {
if (!OS.IsWinCE) {
switch (hdr.code) {
@@ -6782,7 +6789,7 @@
return super.wmNotify (hdr, wParam, lParam);
}
-LRESULT wmNotifyChild (NMHDR hdr, int wParam, int lParam) {
+override LRESULT wmNotifyChild (NMHDR hdr, int wParam, int lParam) {
switch (hdr.code) {
case OS.TVN_GETDISPINFOA:
case OS.TVN_GETDISPINFOW: {
diff -r 0405e18fec7f -r 0f25be5cbe6f dwt/widgets/TreeColumn.d
--- a/dwt/widgets/TreeColumn.d Sun Feb 03 15:48:14 2008 -0800
+++ b/dwt/widgets/TreeColumn.d Mon Feb 04 10:05:20 2008 +0100
@@ -200,11 +200,11 @@
return checkBits (style, DWT.LEFT, DWT.CENTER, DWT.RIGHT, 0, 0, 0);
}
-protected void checkSubclass () {
+override protected void checkSubclass () {
if (!isValidSubclass ()) error (DWT.ERROR_INVALID_SUBCLASS);
}
-void destroyWidget () {
+override void destroyWidget () {
parent.destroyItem (this);
releaseHandle ();
}
@@ -254,7 +254,7 @@
return moveable;
}
-String getNameText () {
+override String getNameText () {
return getText ();
}
@@ -426,12 +426,12 @@
setWidth (Math.max (headerWidth, columnWidth + gridWidth));
}
-void releaseHandle () {
+override void releaseHandle () {
super.releaseHandle ();
parent = null;
}
-void releaseParent () {
+override void releaseParent () {
super.releaseParent ();
if (parent.sortColumn is this) {
parent.sortColumn = null;
@@ -529,7 +529,7 @@
}
}
-public void setImage (Image image) {
+override public void setImage (Image image) {
checkWidget();
if (image !is null && image.isDisposed ()) {
error (DWT.ERROR_INVALID_ARGUMENT);
@@ -665,7 +665,7 @@
}
}
-public void setText (String string) {
+override public void setText (String string) {
checkWidget ();
if (string is null) error (DWT.ERROR_NULL_ARGUMENT);
if (string.equals (text)) return;
diff -r 0405e18fec7f -r 0f25be5cbe6f dwt/widgets/TreeItem.d
--- a/dwt/widgets/TreeItem.d Sun Feb 03 15:48:14 2008 -0800
+++ b/dwt/widgets/TreeItem.d Mon Feb 04 10:05:20 2008 +0100
@@ -241,7 +241,7 @@
return hItem;
}
-protected void checkSubclass () {
+override protected void checkSubclass () {
if (!isValidSubclass ()) error (DWT.ERROR_INVALID_SUBCLASS);
}
@@ -332,7 +332,7 @@
parent.clearAll (hItem, tvItem, all);
}
-void destroyWidget () {
+override void destroyWidget () {
TVITEM tvItem = new TVITEM ();
tvItem.mask = OS.TVIF_HANDLE | OS.TVIF_PARAM;
parent.releaseItem (handle, tvItem, false);
@@ -793,7 +793,7 @@
return parent.getItems (hItem);
}
-public Image getImage () {
+override public Image getImage () {
checkWidget();
if (!parent.checkData (this, true)) error (DWT.ERROR_WIDGET_DISPOSED);
return super.getImage ();
@@ -880,7 +880,7 @@
return hItem !is 0 ? parent._getItem (hItem) : null;
}
-public String getText () {
+override public String getText () {
checkWidget();
if (!parent.checkData (this, true)) error (DWT.ERROR_WIDGET_DISPOSED);
return super.getText ();
@@ -1006,7 +1006,7 @@
OS.InvalidateRect (hwnd, rect, true);
}
-void releaseChildren (bool destroy) {
+override void releaseChildren (bool destroy) {
if (destroy) {
TVITEM tvItem = new TVITEM ();
tvItem.mask = OS.TVIF_HANDLE | OS.TVIF_PARAM;
@@ -1015,13 +1015,13 @@
super.releaseChildren (destroy);
}
-void releaseHandle () {
+override void releaseHandle () {
super.releaseHandle ();
handle = 0;
parent = null;
}
-void releaseWidget () {
+override void releaseWidget () {
super.releaseWidget ();
strings = null;
images = null;
@@ -1726,7 +1726,7 @@
}
}
-public void setImage (Image image) {
+override public void setImage (Image image) {
checkWidget ();
setImage (0, image);
}
@@ -1766,7 +1766,7 @@
*
* @since 3.1
*/
-public void setText (String [] strings) {
+override public void setText (String [] strings) {
checkWidget();
if (strings is null) error (DWT.ERROR_NULL_ARGUMENT);
for (int i=0; i