[Main]
Name=WinRemove
Type=Function
Subtype=ROM Call
Header Files=wingraph.h
Definition=void WinRemove (WINDOW *w, short UpdateScreen);
See Also=WinClose,WinOpen

[ROM Call]
Index=$414
Address Hack=((((unsigned char *)_rom_call_addr(B)+14))+*((signed short *)_rom_call_addr(B)+7))

[Description]
Closes the window pointed to by <I>w</I>, and frees the memory assigned to that window.

[Explanation]
If <I>UpdateScreen</I> is TRUE, the next window in the linked list of windows is activated and the screen is updated.<BR>
If <I>UpdateScreen</I> is FALSE, no window is activated and the screen is not updated.<BR>
In fact, <A HREF="$$LINK(WinClose)">WinClose</A> calls WinRemove with UpdateScreen = TRUE on all AMS versions.<BR>
Virtual windows (the ones with <A HREF="$$LINK(WinFlags)">WF_VIRTUAL</A> flag set) should be closed with:
<PRE>
WinRemove(&w,FALSE);
</PRE>

[References]
In=bascmd.h/cmd_newpic, wingraph.h/WinClose, wingraph.h/WinReOpen
Out=unknown.h/UpdateWindows, alloc.h/HeapFree, graph.h/BitmapPut, graph.h/FontSetSys, graph.h/ScrRect, wingraph.h/DrawWinBorder, wingraph.h/FirstWindow, wingraph.h/WinClr, wingraph.h/WinDeactivate
