2 Copyright © 2002, The AROS Development Team.
8 #include <exec/types.h>
14 #include <intuition/gadgetclass.h>
15 #include <intuition/icclass.h>
16 #include <proto/exec.h>
17 #include <proto/intuition.h>
18 #include <proto/muimaster.h>
19 #include <clib/alib_protos.h>
21 /* the following should go in a single include file which then only
22 ** constits of the public constants and members. Actually this is easiey
25 #include <libraries/mui.h>
28 #include <aros/debug.h>
32 Object
*MakeLabel(STRPTR str
)
34 return (MUI_MakeObject(MUIO_Label
, str
, 0));
41 Object
*a
, *b
, *c
, *d
;
43 app
= ApplicationObject
,
44 SubWindow
, wnd
= WindowObject
,
45 MUIA_Window_Title
, "col",
46 MUIA_Window_Activate
, TRUE
,
47 WindowContents
, d
= HGroup
,
48 GroupFrameT("Background"),
50 Child
, a
= PopimageObject
, End
,
51 Child
, b
= MakeLabel("Window"),
54 Child
, PopimageObject
, End
,
55 Child
, MakeLabel("Requester"),
64 DoMethod(wnd
, MUIM_Notify
, MUIA_Window_CloseRequest
, TRUE
, app
, 2, MUIM_Application_ReturnID
, MUIV_Application_ReturnID_Quit
);
65 set(wnd
, MUIA_Window_Open
, TRUE
);
67 printf("%d[%p] %d[%p] %d[%p] %d\n", _maxwidth(a
), a
, _maxwidth(b
), b
, _maxwidth(c
), c
, _maxwidth(d
));
69 while((LONG
) DoMethod(app
, MUIM_Application_NewInput
, &sigs
) != MUIV_Application_ReturnID_Quit
)
73 sigs
= Wait(sigs
| SIGBREAKF_CTRL_C
| SIGBREAKF_CTRL_D
);
74 if (sigs
& SIGBREAKF_CTRL_C
) break;
78 set(wnd
, MUIA_Window_Open
, FALSE
);
79 MUI_DisposeObject(app
);