grub2: bring back build of aros-side grub2 tools
[AROS.git] / rom / intuition / windowaction.c
blob3e4cb7d4994c6fb94e49f8ac1871b678d48440ca
1 /*
2 Copyright 2003-2013, The AROS Development Team. All rights reserved.
3 Copyright 2001-2003, The MorphOS Development Team. All Rights Reserved.
4 $Id$
5 */
7 #include <utility/tagitem.h>
8 #include <intuition/extensions.h>
10 #include "intuition_intern.h"
11 #include "inputhandler_support.h"
13 /*****************************************************************************
15 NAME */
16 #include <proto/intuition.h>
18 AROS_LH3(void, WindowAction,
20 /* SYNOPSIS */
21 AROS_LHA(struct Window *, window, A0),
22 AROS_LHA(ULONG, action, D0),
23 AROS_LHA(struct TagItem *, tags, A1),
25 /* LOCATION */
26 struct IntuitionBase *, IntuitionBase, 157, Intuition)
28 /* FUNCTION
29 Perform an asynchronous action on a window that is not controlled
30 by the caller task.
32 This function is safe even when the window is destroyed by the owner
33 during the call.
35 INPUTS
36 window - a window to act upon
37 action - a requested action code
38 tags - additional parameters, depending on the action
40 Currently defined actions are:
42 WAC_SENDIDCMPCLOSE - send an IDCMP_CLOSEWINDOW message.
44 RESULT
45 None.
47 NOTES
48 This function is compatible with MorphOS.
50 The requested action is executed asynchronously; the function actually
51 returns before it is complete.
53 EXAMPLE
55 BUGS
56 At the moment only WAC_SENDIDCMPCLOSE action is implemented.
58 SEE ALSO
60 INTERNALS
62 *****************************************************************************/
64 AROS_LIBFUNC_INIT
66 /* TODO: Write intuition/WindowAction() */
68 switch (action)
70 case WAC_SENDIDCMPCLOSE:
71 ih_fire_intuimessage(window, IDCMP_CLOSEWINDOW, 0, 0, IntuitionBase);
72 break;
74 default:
75 aros_print_not_implemented ("WindowAction");
76 break;
79 AROS_LIBFUNC_EXIT
80 } /* WindowAction */