# HG changeset patch # User bsmith@81767d24-ef19-dc11-ae90-00e081727c95 # Date 1341571888 0 # Node ID d81bebc5c8cc4ffd03e85530765575a751b58bec # Parent 227e13044ce381feb28650d27006935569128d4e Mark and I decided to change dw_box_remove*() to dw_box_unpack*() for consistency. This commit should change all exports and references appropriately. diff -r 227e13044ce3 -r d81bebc5c8cc dw.h --- a/dw.h Sun Jul 01 09:56:49 2012 +0000 +++ b/dw.h Fri Jul 06 10:51:28 2012 +0000 @@ -1464,8 +1464,8 @@ void API dw_box_pack_start(HWND box, HWND item, int width, int height, int hsize, int vsize, int pad); void API dw_box_pack_end(HWND box, HWND item, int width, int height, int hsize, int vsize, int pad); void API dw_box_pack_at_index(HWND box, HWND item, int index, int width, int height, int hsize, int vsize, int pad); -HWND API dw_box_remove_at_index(HWND box, int index); -int API dw_box_remove(HWND handle); +HWND API dw_box_unpack_at_index(HWND box, int index); +int API dw_box_unpack(HWND handle); #if !defined(__OS2__) && !defined(__WIN32__) && !defined(__EMX__) && !defined(__MAC__) int API dw_int_init(DWResources *res, int newthread, int *argc, char **argv[]); #define dw_init(a, b, c) dw_int_init(&_resources, a, &b, &c) diff -r 227e13044ce3 -r d81bebc5c8cc dwtest.c --- a/dwtest.c Sun Jul 01 09:56:49 2012 +0000 +++ b/dwtest.c Fri Jul 06 10:51:28 2012 +0000 @@ -932,7 +932,7 @@ okbutton = dw_button_new("Turn Off Annoying Beep!", 1001L); dw_box_pack_start(buttonbox, okbutton, 130, 30, TRUE, TRUE, 2); - dw_box_remove(cancelbutton); + dw_box_unpack(cancelbutton); dw_box_pack_start(buttonbox, cancelbutton, 130, 30, TRUE, TRUE, 2); dw_window_click_default( mainwindow, cancelbutton ); diff -r 227e13044ce3 -r d81bebc5c8cc gtk/dw.c --- a/gtk/dw.c Sun Jul 01 09:56:49 2012 +0000 +++ b/gtk/dw.c Fri Jul 06 10:51:28 2012 +0000 @@ -10390,7 +10390,7 @@ * Returns: * DW_ERROR_NONE on success and DW_ERROR_GENERAL on failure. */ -int API dw_box_remove(HWND handle) +int API dw_box_unpack(HWND handle) { int _locked_by_me = FALSE, retcode = DW_ERROR_GENERAL; @@ -10456,7 +10456,7 @@ * Returns: * Handle to the removed item on success, 0 on failure or padding. */ -HWND API dw_box_remove_at_index(HWND box, int index) +HWND API dw_box_unpack_at_index(HWND box, int index) { HWND retval = 0; int _locked_by_me = FALSE; diff -r 227e13044ce3 -r d81bebc5c8cc gtk3/dw.c --- a/gtk3/dw.c Sun Jul 01 09:56:49 2012 +0000 +++ b/gtk3/dw.c Fri Jul 06 10:51:28 2012 +0000 @@ -8687,7 +8687,7 @@ * Returns: * DW_ERROR_NONE on success and DW_ERROR_GENERAL on failure. */ -int API dw_box_remove(HWND handle) +int API dw_box_unpack(HWND handle) { int _locked_by_me = FALSE, retcode = DW_ERROR_GENERAL; @@ -8736,7 +8736,7 @@ * Returns: * Handle to the removed item on success, 0 on failure or padding. */ -HWND API dw_box_remove_at_index(HWND box, int index) +HWND API dw_box_unpack_at_index(HWND box, int index) { int _locked_by_me = FALSE; HWND retval = 0; diff -r 227e13044ce3 -r d81bebc5c8cc mac/dw.m --- a/mac/dw.m Sun Jul 01 09:56:49 2012 +0000 +++ b/mac/dw.m Fri Jul 06 10:51:28 2012 +0000 @@ -3913,7 +3913,7 @@ * Returns: * DW_ERROR_NONE on success and DW_ERROR_GENERAL on failure. */ -int API dw_box_remove(HWND handle) +int API dw_box_unpack(HWND handle) { int _locked_by_me = FALSE; DW_LOCAL_POOL_IN; @@ -3999,7 +3999,7 @@ * Returns: * Handle to the removed item on success, 0 on failure or padding. */ -HWND API dw_box_remove_at_index(HWND box, int index) +HWND API dw_box_unpack_at_index(HWND box, int index) { int _locked_by_me = FALSE; DW_LOCAL_POOL_IN; diff -r 227e13044ce3 -r d81bebc5c8cc os2/dw.c --- a/os2/dw.c Sun Jul 01 09:56:49 2012 +0000 +++ b/os2/dw.c Fri Jul 06 10:51:28 2012 +0000 @@ -4979,7 +4979,7 @@ /* If it is a desktop window let WM_DESTROY handle it */ if(parent != desktop) { - dw_box_remove(handle); + dw_box_unpack(handle); _free_window_memory(frame ? frame : handle); } return WinDestroyWindow(frame ? frame : handle); @@ -7793,7 +7793,7 @@ * Returns: * DW_ERROR_NONE on success and DW_ERROR_GENERAL on failure. */ -int API dw_box_remove(HWND handle) +int API dw_box_unpack(HWND handle) { HWND parent = WinQueryWindow(handle, QW_PARENT); @@ -7863,7 +7863,7 @@ * Returns: * Handle to the removed item on success, 0 on failure or padding. */ -HWND API dw_box_remove_at_index(HWND box, int index) +HWND API dw_box_unpack_at_index(HWND box, int index) { Box *thisbox = WinQueryWindowPtr(box, QWP_USER); diff -r 227e13044ce3 -r d81bebc5c8cc os2/dw.def --- a/os2/dw.def Sun Jul 01 09:56:49 2012 +0000 +++ b/os2/dw.def Fri Jul 06 10:51:28 2012 +0000 @@ -33,8 +33,8 @@ dw_mdi_new @46 - dw_box_remove @47 - dw_box_remove_at_index @48 + dw_box_unpack @47 + dw_box_unpack_at_index @48 dw_window_new @50 dw_window_show @51 diff -r 227e13044ce3 -r d81bebc5c8cc os2/dw.lnk --- a/os2/dw.lnk Sun Jul 01 09:56:49 2012 +0000 +++ b/os2/dw.lnk Fri Jul 06 10:51:28 2012 +0000 @@ -28,8 +28,8 @@ export dw_mdi_new.46 -export dw_box_remove.47 -export dw_box_remove_at_index.48 +export dw_box_unpack.47 +export dw_box_unpack_at_index.48 export dw_window_new.50 export dw_window_show.51 diff -r 227e13044ce3 -r d81bebc5c8cc readme.txt --- a/readme.txt Sun Jul 01 09:56:49 2012 +0000 +++ b/readme.txt Fri Jul 06 10:51:28 2012 +0000 @@ -35,7 +35,7 @@ active codepage; Non-Unicode mode will use the default codepage. Added support for Control-Click on Mac for button press events. Added DW_POINTER() macro for casting parameters to (void *). -Added dw_box_remove() and dw_box_remove_at_index() for removing items +Added dw_box_unpack() and dw_box_unpack_at_index() for removing items from boxes without destroying them. Also allows removal of padding. Added GBM (Generalized Bitmap Module) support for OS/2 and eCS for loading Non-OS/2 native file formats. GBM comes with eCS 1.2 and later. diff -r 227e13044ce3 -r d81bebc5c8cc template/dw.c --- a/template/dw.c Sun Jul 01 09:56:49 2012 +0000 +++ b/template/dw.c Fri Jul 06 10:51:28 2012 +0000 @@ -602,7 +602,7 @@ * Returns: * DW_ERROR_NONE on success and DW_ERROR_GENERAL on failure. */ -int API dw_box_remove(HWND handle) +int API dw_box_unpack(HWND handle) { return DW_ERROR_GENERAL; } @@ -615,7 +615,7 @@ * Returns: * Handle to the removed item on success, 0 on failure or padding. */ -HWND API dw_box_remove_at_index(HWND box, int index) +HWND API dw_box_unpack_at_index(HWND box, int index) { return 0; } diff -r 227e13044ce3 -r d81bebc5c8cc win/dw-mingw.def --- a/win/dw-mingw.def Sun Jul 01 09:56:49 2012 +0000 +++ b/win/dw-mingw.def Fri Jul 06 10:51:28 2012 +0000 @@ -32,8 +32,8 @@ dw_mdi_new @46 - dw_box_remove @47 - dw_box_remove_at_index @48 + dw_box_unpack @47 + dw_box_unpack_at_index @48 dw_window_new @50 dw_window_show @51 diff -r 227e13044ce3 -r d81bebc5c8cc win/dw.c --- a/win/dw.c Sun Jul 01 09:56:49 2012 +0000 +++ b/win/dw.c Fri Jul 06 10:51:28 2012 +0000 @@ -4402,7 +4402,7 @@ /* If it is a desktop window let WM_DESTROY handle it */ if(parent != HWND_DESKTOP) { - dw_box_remove(handle); + dw_box_unpack(handle); _free_window_memory(handle, 0); EnumChildWindows(handle, _free_window_memory, 0); } @@ -7187,7 +7187,7 @@ * Returns: * DW_ERROR_NONE on success and DW_ERROR_GENERAL on failure. */ -int API dw_box_remove(HWND handle) +int API dw_box_unpack(HWND handle) { HWND parent = GetParent(handle); @@ -7255,7 +7255,7 @@ * Returns: * Handle to the removed item on success, 0 on failure or padding. */ -HWND API dw_box_remove_at_index(HWND box, int index) +HWND API dw_box_unpack_at_index(HWND box, int index) { Box *thisbox = (Box *)GetWindowLongPtr(box, GWLP_USERDATA); diff -r 227e13044ce3 -r d81bebc5c8cc win/dw.def --- a/win/dw.def Sun Jul 01 09:56:49 2012 +0000 +++ b/win/dw.def Fri Jul 06 10:51:28 2012 +0000 @@ -32,8 +32,8 @@ dw_mdi_new @46 - dw_box_remove @47 - dw_box_remove_at_index @48 + dw_box_unpack @47 + dw_box_unpack_at_index @48 dw_window_new @50 dw_window_show @51