2 Copyright © 2003, 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"
18 Object
*BT_1
, *BT_2
, *BT_3
;
21 /****************************************************************
22 Allocate resources for gui
23 *****************************************************************/
27 app
= ApplicationObject
,
28 MUIA_Application_Title
, (IPTR
) "HGroup",
29 MUIA_Application_Version
, (IPTR
) "$VER: HGroup 0.1 (14.01.03)",
30 MUIA_Application_Copyright
, (IPTR
) "© 2003, The AROS Development Team",
31 MUIA_Application_Author
, (IPTR
) "The AROS Development Team",
32 MUIA_Application_Description
, (IPTR
) "Layout with HGroup",
33 MUIA_Application_Base
, (IPTR
) "HGroup",
35 SubWindow
, WD_Main
= WindowObject
,
36 MUIA_Window_Title
, (IPTR
) "Layout with HGroup",
41 Layout: HGroup - Three buttons in one horizontal line
43 | Button 1 | | Button 2 | | Button 3 |
47 Child
, BT_1
= SimpleButton("Button 1"),
48 Child
, BT_2
= SimpleButton("Button 2"),
49 Child
, BT_3
= SimpleButton("Button 3"),
52 End
, /* WindowObject */
54 End
; /* ApplicationObject */
58 /* Quit application if the windowclosegadget or the esc key is pressed. */
60 DoMethod(WD_Main
, MUIM_Notify
, MUIA_Window_CloseRequest
, TRUE
,
62 MUIM_Application_ReturnID
, MUIV_Application_ReturnID_Quit
);
68 } /* init_gui(void) */
71 /****************************************************************
72 Deallocates all gui resources
73 *****************************************************************/
77 if(app
){MUI_DisposeObject(app
);}
78 } /* deinit_gui(void) */
82 /****************************************************************
84 *****************************************************************/
90 while((LONG
) DoMethod(app
, MUIM_Application_NewInput
, &sigs
) != MUIV_Application_ReturnID_Quit
)
94 sigs
= Wait(sigs
| SIGBREAKF_CTRL_C
| SIGBREAKF_CTRL_D
);
95 if(sigs
& SIGBREAKF_CTRL_C
){break;}
96 if(sigs
& SIGBREAKF_CTRL_D
){break;}
102 /****************************************************************
104 *****************************************************************/
106 int main(int argc
, char *argv
[])
112 set(WD_Main
, MUIA_Window_Open
, TRUE
);
114 if(xget(WD_Main
, MUIA_Window_Open
))
119 set(WD_Main
, MUIA_Window_Open
, FALSE
);
126 } /* main(int argc, char *argv[]) */