2 Copyright © 2003-2011, The AROS Development Team.
8 /* "muizunesupport.h" contains misc includes and
9 init stuff which is not important at the moment. */
11 #include "muizunesupport.h"
19 Object
*BT_21
, *BT_22
, *BT_23
;
20 Object
*BT_31
, *BT_32_33
;
23 /****************************************************************
24 Allocate resources for gui
25 *****************************************************************/
29 app
= ApplicationObject
,
30 MUIA_Application_Title
, (IPTR
) "VHGroup2",
31 MUIA_Application_Version
, (IPTR
) "$VER: VHGroup2 0.1 (14.01.03)",
32 MUIA_Application_Copyright
, (IPTR
) "© 2003-2011, The AROS Development Team",
33 MUIA_Application_Author
, (IPTR
) "The AROS Development Team",
34 MUIA_Application_Description
, (IPTR
) "Layout with VGroup + HGroup 2",
35 MUIA_Application_Base
, (IPTR
) "VHGroup2",
37 SubWindow
, WD_Main
= WindowObject
,
38 MUIA_Window_Title
, (IPTR
) "Layout with VGroup + HGroup 2",
41 Start VGroup of window here. All other GUI objects are childs
45 WindowContents
, VGroup
,
48 Layout: VGroup + HGroup for a more complex layout
50 A group could have any size and can contain any number of
51 GUI objects. This allows more complex layouts.
54 | Button 2.1 | | Button 2.2 | | Button 2.3 |
55 | Button 3.1 | | Button 3.2 - 3.3 |
59 /* Horizontal line 1 */
62 Child
, BT_11_13
= SimpleButton("Button 1.1 - 1.3"),
66 /* Horizontal line 2 */
69 Child
, BT_21
= SimpleButton("Button 2.1"),
70 Child
, BT_22
= SimpleButton("Button 2.2"),
71 Child
, BT_23
= SimpleButton("Button 2.3"),
75 /* Horizontal line 3 */
78 Child
, BT_31
= SimpleButton("Button 3.1"),
79 Child
, BT_32_33
= SimpleButton("Button 3.2 - 3.3"),
84 End
, /* WindowObject */
86 End
; /* ApplicationObject */
90 /* Quit application if the windowclosegadget or the esc key is pressed. */
92 DoMethod(WD_Main
, MUIM_Notify
, MUIA_Window_CloseRequest
, TRUE
,
94 MUIM_Application_ReturnID
, MUIV_Application_ReturnID_Quit
);
100 } /* init_gui(void) */
103 /****************************************************************
104 Deallocates all gui resources
105 *****************************************************************/
107 void deinit_gui(void)
109 if(app
){MUI_DisposeObject(app
);}
110 } /* deinit_gui(void) */
114 /****************************************************************
116 *****************************************************************/
122 while((LONG
) DoMethod(app
, MUIM_Application_NewInput
, &sigs
) != MUIV_Application_ReturnID_Quit
)
126 sigs
= Wait(sigs
| SIGBREAKF_CTRL_C
| SIGBREAKF_CTRL_D
);
127 if(sigs
& SIGBREAKF_CTRL_C
){break;}
128 if(sigs
& SIGBREAKF_CTRL_D
){break;}
134 /****************************************************************
136 *****************************************************************/
138 int main(int argc
, char *argv
[])
144 set(WD_Main
, MUIA_Window_Open
, TRUE
);
146 if(xget(WD_Main
, MUIA_Window_Open
))
151 set(WD_Main
, MUIA_Window_Open
, FALSE
);
160 } /* main(int argc, char *argv[]) */