diff options
Diffstat (limited to 'alf/alfbutton.cpp')
| -rw-r--r-- | alf/alfbutton.cpp | 13 |
1 files changed, 2 insertions, 11 deletions
diff --git a/alf/alfbutton.cpp b/alf/alfbutton.cpp index be9a276..67a7236 100644 --- a/alf/alfbutton.cpp +++ b/alf/alfbutton.cpp @@ -485,7 +485,7 @@ ALF__ButtonSubclassProc(HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam, UINT } HWND -ALF_AddButton(HWND win, WORD id, UINT x, UINT y, const TCHAR *text) +ALF_AddButton(HWND win, WORD id, int x, int y, const TCHAR *text) { HWND hwndButton = CreateWindowEx(0, TEXT("BUTTON"), @@ -505,16 +505,7 @@ ALF_AddButton(HWND win, WORD id, UINT x, UINT y, const TCHAR *text) SendMessage(hwndButton, WM_THEMECHANGED, 0, 0); - ALFWidgetLayoutParams p; - ZeroMemory(&p, sizeof(p)); - p.hwnd = hwndButton; - p.x = x; - p.y = y; - p.width = 0; - p.height = 0; - p.flags = ALF_QUERYSIZE | ALF_INHERITFONT; - - ALF_AddWidgetEx(win, &p); + ALF_AddWidget(win, x, y, hwndButton, 0, 0, ALF_LAYOUT_SIZE_QUERY | ALF_LAYOUT_INHERITFONT); return hwndButton; } |
