2 Copyright (C) 2017, The AROS Development Team. All rights reserved.
9 #include <utility/tagitem.h>
11 #include "gfx_intern.h"
13 OOP_Object
*GFXHW__Root__New(OOP_Class
*cl
, OOP_Object
*o
, struct pRoot_New
*msg
)
15 D(bug("[HWGfx] csd @ 0x%p\n", CSD(cl
));)
17 if (!CSD(cl
)->gfxhwinstance
)
19 struct TagItem new_tags
[] =
21 {aHW_ClassName
, (IPTR
)"Display Hardware"},
24 struct pRoot_New new_msg
=
30 D(bug("[HWGfx] Instantiating...\n");)
31 CSD(cl
)->gfxhwinstance
= (OOP_Object
*)OOP_DoSuperMethod(cl
, o
, &new_msg
.mID
);
34 D(bug("[HWGfx] returning 0x%p\n", CSD(cl
)->gfxhwinstance
);)
36 return CSD(cl
)->gfxhwinstance
;
39 VOID
GFXHW__Root__Dispose(OOP_Class
*cl
, OOP_Object
*o
, OOP_Msg msg
)
41 /* We are singleton. Cannot dispose. */