Added kernel module for starting the usb stack at boot time. It's not activated thoug...
[cake.git] / rom / intuition / lendmenus.c
blob9e53ef033841ac1a2d5a6f0a7d812b055e078299
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 "intuition_intern.h"
9 /*****************************************************************************
11 NAME */
12 #include <proto/intuition.h>
14 AROS_LH2(void, LendMenus,
16 /* SYNOPSIS */
17 AROS_LHA(struct Window *, fromwindow, A0),
18 AROS_LHA(struct Window *, towindow, A1),
20 /* LOCATION */
21 struct IntuitionBase *, IntuitionBase, 134, Intuition)
23 /* FUNCTION
24 This function 'lends' the menus of one window to another.
25 This makes the menu events (eg. menu button press) take place
26 in another window's menu (ie. the other window's strip and screen).
27 This function is used to unify two windows on different attached
28 screens. (Eg. a painting program with an attached palette screen
29 can open the menu on the main screen if the menu button is
30 pressed on the palette screen.
32 INPUTS
33 fromwindow - This window's menu events will go to another window.
34 towindow - This is the window that will react on the menu actions
35 of the other window. If NULL 'lending' will be turned off.
37 RESULT
38 None.
40 NOTES
42 EXAMPLE
44 BUGS
46 SEE ALSO
47 SetMenuStrip(), ClearMenuStrip()
49 INTERNALS
51 HISTORY
53 *****************************************************************************/
55 AROS_LIBFUNC_INIT
57 ASSERT_VALID_PTR(fromwindow);
58 ASSERT_VALID_PTR_OR_NULL(towindow);
60 DEBUG_LENDMENUS(dprintf("LendMenus(Window 0x%lx ToWindow 0x%lx)\n",fromwindow,towindow));
62 IntuitionBase = IntuitionBase; /* shut up the compiler */
64 SANITY_CHECK(fromwindow);
66 ((struct IntWindow *)fromwindow)->menulendwindow = towindow;
68 AROS_LIBFUNC_EXIT
69 } /* LendMenus */