changeset 1465:0f9c6f7636db

Menus don't need to be added after packing a box into a window anymore... demonstrate this in the test program and remove comment regarding this.
author bsmith@81767d24-ef19-dc11-ae90-00e081727c95
date Sat, 17 Dec 2011 22:37:36 +0000
parents e325f98a2792
children 65986481a3d8
files dwtest.c
diffstat 1 files changed, 2 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/dwtest.c	Sat Dec 17 13:02:54 2011 +0000
+++ b/dwtest.c	Sat Dec 17 22:37:36 2011 +0000
@@ -1603,15 +1603,14 @@
     mainwindow = dw_window_new( HWND_DESKTOP, "dwindows test", flStyle | DW_FCF_SIZEBORDER | DW_FCF_MINMAX);
     dw_window_set_icon(mainwindow, fileicon);
 
+    menu_add();
+
     notebookbox = dw_box_new( BOXVERT, 5 );
     dw_box_pack_start( mainwindow, notebookbox, 0, 0, TRUE, TRUE, 0);
     
     foldericon = dw_icon_load_from_file( FOLDER_ICON_NAME );
     fileicon = dw_icon_load_from_file( FILE_ICON_NAME  );
     
-    /* MUST pack a box into the mainwindow BEFORE adding menus */
-    menu_add();
-
     notebook = dw_notebook_new( 1, TRUE );
     dw_box_pack_start( notebookbox, notebook, 100, 100, TRUE, TRUE, 0);
     dw_signal_connect(notebook, DW_SIGNAL_SWITCH_PAGE, DW_SIGNAL_FUNC(switch_page_cb), NULL);