2 Copyright (C) 2013, The AROS Development Team.
6 #define MUIMASTER_YES_INLINE_STDARG
8 #include <exec/memory.h>
10 #include <resources/hpet.h>
11 #include <libraries/mui.h>
12 #include <mui/NFloattext_mcc.h>
13 #include <resources/processor.h>
14 #include <utility/tagitem.h>
15 #include <utility/hooks.h>
17 #include <proto/alib.h>
18 #include <proto/aros.h>
19 #include <proto/dos.h>
20 #include <proto/exec.h>
21 #include <proto/hpet.h>
22 #include <proto/kernel.h>
23 #include <proto/muimaster.h>
24 #include <proto/utility.h>
25 #include <proto/intuition.h>
26 #include <proto/processor.h>
35 #include <aros/debug.h>
37 #include <zune/customclasses.h>
40 /*** Instance Data **********************************************************/
41 struct DevicePage_DATA
43 /* Nothing to add here */
47 static Object
*DevicePage__OM_NEW(Class
*cl
, Object
*self
, struct opSet
*msg
)
49 OOP_Object
*device_obj
= (OOP_Object
*)GetTagData(MUIA_PropertyWin_Object
, 0, msg
->ops_AttrList
);
50 IPTR idName
, hwName
, vendorStr
;
52 TEXT productId
[20], vendorId
[20];
54 OOP_GetAttr(device_obj
, aHidd_Name
, &idName
);
55 OOP_GetAttr(device_obj
, aHidd_HardwareName
, &hwName
);
56 OOP_GetAttr(device_obj
, aHidd_ProducerName
, &vendorStr
);
57 OOP_GetAttr(device_obj
, aHidd_Product
, &number
);
58 sprintf(productId
, "0x%04lX", number
);
59 OOP_GetAttr(device_obj
, aHidd_Producer
, &number
);
60 sprintf(vendorId
, "0x%04lX", number
);
62 return (Object
*) DoSuperNewTags
66 Child
, (IPTR
)(ColGroup(2),
67 MUIA_FrameTitle
, __(MSG_GENERAL
),
69 MUIA_Background
, MUII_GroupBack
,
70 Child
, (IPTR
)Label(_(MSG_NAME
)),
71 Child
, (IPTR
)(TextObject
,
73 MUIA_Background
, MUII_TextBack
,
75 MUIA_Text_Contents
, idName
,
77 Child
, (IPTR
)Label(_(MSG_HARDWARE_NAME
)),
78 Child
, (IPTR
)(TextObject
,
80 MUIA_Background
, MUII_TextBack
,
82 MUIA_Text_Contents
, hwName
,
84 Child
, (IPTR
)Label(_(MSG_PRODUCT_ID
)),
85 Child
, (IPTR
)(TextObject
,
87 MUIA_Background
, MUII_TextBack
,
89 MUIA_Text_Contents
, (IPTR
)productId
,
91 Child
, (IPTR
)Label(_(MSG_PRODUCER_NAME
)),
92 Child
, (IPTR
)(TextObject
,
94 MUIA_Background
, MUII_TextBack
,
96 MUIA_Text_Contents
, vendorStr
,
98 Child
, (IPTR
)Label(_(MSG_PRODUCER_ID
)),
99 Child
, (IPTR
)(TextObject
,
101 MUIA_Background
, MUII_TextBack
,
103 MUIA_Text_Contents
, (IPTR
)vendorId
,
111 /*** Setup ******************************************************************/
114 DevicePage
, NULL
, MUIC_Group
, NULL
,
115 OM_NEW
, struct opSet
*