Mercurial > dwindows
changeset 1035:31dc5b4f6cfc
Ok... better fix for the OS/2 spinbutton issue
This one actually works.
author | bsmith@81767d24-ef19-dc11-ae90-00e081727c95 |
---|---|
date | Thu, 26 May 2011 06:08:14 +0000 |
parents | af2c93f78ae9 |
children | c2013f1ef354 |
files | os2/dw.c |
diffstat | 1 files changed, 3 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/os2/dw.c Thu May 26 03:24:06 2011 +0000 +++ b/os2/dw.c Thu May 26 06:08:14 2011 +0000 @@ -5344,6 +5344,7 @@ WinSetWindowPtr(entry, QWP_USER, blah); dw_window_set_font(tmp, DefaultFont); dw_window_set_color(entry, DW_CLR_BLACK, DW_CLR_WHITE); + dw_window_set_data(tmp, "_dw_entry", (void *)entry); return tmp; } @@ -5767,7 +5768,7 @@ */ void API dw_window_set_text(HWND handle, char *text) { - HWND entryfield = WinWindowFromID(handle, 1703); + HWND entryfield = (HWND)dw_window_get_data(handle, "_dw_entry"); WinSetWindowText(entryfield ? entryfield : handle, text); } @@ -5780,7 +5781,7 @@ */ char * API dw_window_get_text(HWND handle) { - HWND entryfield = WinWindowFromID(handle, 1703); + HWND entryfield = (HWND)dw_window_get_data(handle, "_dw_entry"); int len = WinQueryWindowTextLength(entryfield ? entryfield : handle); char *tempbuf = calloc(1, len + 2);