2 Copyright © 1995-2013, The AROS Development Team. All rights reserved.
3 Copyright © 2001-2003, The MorphOS Development Team. All Rights Reserved.
8 #include "intuition_intern.h"
10 /*****************************************************************************
13 #include <proto/intuition.h>
15 AROS_LH1(struct Screen
*, GetDefaultPubScreen
,
18 AROS_LHA(UBYTE
*, nameBuffer
, A0
),
21 struct IntuitionBase
*, IntuitionBase
, 97, Intuition
)
24 Returns the name of the current default public screen. This will be
25 "Workbench" if there is no default public screen.
28 nameBuffer - A buffer of length MAXPUBSCREENNAME
34 Only Public Screen Manager utilities want to use this function
35 since it is easy to open a window on the default public screen
36 without specifying a name.
43 SetDefaultPubScreen(), OpenWindow()
47 *****************************************************************************/
51 struct Screen
*defscreen
;
54 DEBUG_GETDEFAULTPUBSCREEN(dprintf("GetDefaultPubScreen(%s)\n",nameBuffer
));
58 defscreen
= GetPrivIBase(IntuitionBase
)->DefaultPubScreen
;
62 name
= GetPrivScreen(defscreen
)->pubScrNode
->psn_Node
.ln_Name
;
71 strcpy(nameBuffer
, name
);
74 UnlockPubScreenList();
79 } /* GetDefaultPubScreen */