Updated Sourceforge username and host.
[tangerine.git] / rom / intuition / makescreen.c
blob1fc914788311fdd62dfe5a9a9aa22573dbf2fa58
1 /*
2 Copyright © 1995-2007, The AROS Development Team. All rights reserved.
3 Copyright © 2001-2003, The MorphOS Development Team. All Rights Reserved.
4 $Id$
5 */
7 #include <proto/graphics.h>
8 #include "intuition_intern.h"
10 /*****************************************************************************
12 NAME */
13 #include <proto/intuition.h>
15 AROS_LH1(LONG, MakeScreen,
17 /* SYNOPSIS */
18 AROS_LHA(struct Screen *, screen, A0),
20 /* LOCATION */
21 struct IntuitionBase *, IntuitionBase, 63, Intuition)
23 /* FUNCTION
25 INPUTS
26 Pointer to your custom screen.
28 RESULT
29 Zero for success, non-zero for failure.
31 NOTES
33 EXAMPLE
35 BUGS
37 SEE ALSO
38 RemakeDisplay(), RethinkDisplay(), graphics.library/MakeVPort(),
40 INTERNALS
42 HISTORY
44 *****************************************************************************/
46 AROS_LIBFUNC_INIT
48 LONG failure = TRUE;
49 ULONG ilock = LockIBase(0);
51 if (screen)
53 if ((screen->ViewPort.Modes ^ IntuitionBase->ViewLord.Modes) & LACE)
55 failure = RemakeDisplay();
57 else
59 failure = MakeVPort(&IntuitionBase->ViewLord, &screen->ViewPort);
63 UnlockIBase(ilock);
65 return failure;
67 AROS_LIBFUNC_EXIT
68 } /* MakeScreen */