2 Copyright © 1995-2003, The AROS Development Team. All rights reserved.
6 #define MUIMASTER_YES_INLINE_STDARG
9 #include <aros/debug.h>
11 #include <exec/types.h>
12 #include <intuition/classes.h>
13 #include <intuition/classusr.h>
14 #include <libraries/mui.h>
15 #include <libraries/desktop.h>
18 #include "desktop_intern.h"
20 #include <proto/dos.h>
21 #include <proto/intuition.h>
22 #include <proto/utility.h>
24 #include "internalwindowopsclass.h"
25 #include "iconcontainerclass.h"
27 #include "desktop_intern_protos.h"
29 IPTR
internalWindowOpsNew(Class
* cl
, Object
* obj
, struct opSet
* msg
)
32 struct InternalWindowOpsClassData
*data
;
33 //struct TagItem *tag;
35 retval
= DoSuperMethodA(cl
, obj
, (Msg
) msg
);
38 obj
= (Object
*) retval
;
39 data
= INST_DATA(cl
, obj
);
45 IPTR
internalWindowOpsSet(Class
* cl
, Object
* obj
, struct opSet
* msg
)
47 struct InternalWindowOpsClassData
*data
;
50 *tstate
= msg
->ops_AttrList
;
52 data
= (struct InternalWindowOpsClassData
*) INST_DATA(cl
, obj
);
54 while ((tag
= NextTagItem(&tstate
)))
63 retval
= DoSuperMethodA(cl
, obj
, (Msg
) msg
);
68 IPTR
internalWindowOpsGet(Class
* cl
, Object
* obj
, struct opGet
* msg
)
71 struct InternalWindowOpsClassData
*data
;
73 data
= (struct InternalWindowOpsClassData
*) INST_DATA(cl
, obj
);
75 switch (msg
->opg_AttrID
)
78 retval
= DoSuperMethodA(cl
, obj
, (Msg
) msg
);
85 IPTR
internalWindowOpsDispose(Class
* cl
, Object
* obj
, Msg msg
)
89 retval
= DoSuperMethodA(cl
, obj
, msg
);
94 IPTR
internalWindowOpsExecute(Class
* cl
, Object
* obj
,
95 struct opExecute
* msg
)
98 struct InternalWindowOpsClassData
*data
;
99 Object
*iconcontainer
= NULL
;
101 data
= (struct InternalWindowOpsClassData
*) INST_DATA(cl
, obj
);
103 GetAttr(MUIA_Window_RootObject
, msg
->target
, (IPTR
*) &iconcontainer
);
105 switch (msg
->operationCode
)
108 case (DOC_WINDOWOP
| 1):
109 // SetAttrs(msg->target, ICA_Open, FALSE, TAG_END);
110 SetAttrs(msg
->target
, MUIA_Window_Open
, FALSE
, TAG_END
);
113 case (DOC_WINDOWOP
| 2):
116 case (DOC_WINDOWOP
| 3):
117 SetAttrs(iconcontainer
, ICA_ViewMode
, ICAVM_LARGE
);
120 case (DOC_WINDOWOP
| 4):
121 SetAttrs(iconcontainer
, ICA_ViewMode
, ICAVM_SMALL
);
124 case (DOC_WINDOWOP
| 5):
125 SetAttrs(iconcontainer
, ICA_ViewMode
, ICAVM_DETAIL
);
132 BOOPSI_DISPATCHER(IPTR
, internalWindowOpsDispatcher
, cl
, obj
, msg
)
136 switch (msg
->MethodID
)
139 retval
= internalWindowOpsNew(cl
, obj
, (struct opSet
*) msg
);
142 retval
= internalWindowOpsSet(cl
, obj
, (struct opSet
*) msg
);
145 retval
= internalWindowOpsGet(cl
, obj
, (struct opGet
*) msg
);
148 retval
= internalWindowOpsDispose(cl
, obj
, msg
);
152 internalWindowOpsExecute(cl
, obj
, (struct opExecute
*) msg
);
155 retval
= DoSuperMethodA(cl
, obj
, msg
);
161 BOOPSI_DISPATCHER_END