PlatformWindow Class Reference#include <platformWindow.h>
Inheritance diagram for PlatformWindow: ![]() Detailed DescriptionAbstract representation of a native OS window.Every windowing system has its own representations and conventions as regards the windows on-screen. In order to provide Torque with means for interfacing with multiple windows, tracking their state, etc. we provide this interface. This interface also allows the app to access the render target for the window it represents, as well as control mode switches, get mode info, and so on.
Constructor & Destructor Documentation
Protected constructor so that the win.
To get rid of a window, just delete it. Make sure the GFXDevice is done with it first!
Member Function Documentation
Get the WindowController associated with this window.
Get the ID that uniquely identifies this window in the context of its window manager.
Reimplemented in MacWindow, and Win32Window. Set the flag that determines whether to suppress a GFXDevice reset.
Return a pointer to the GFX device this window is bound to. A GFX device may use many windows, but a window can only be used by a single GFX device. Implemented in XB360Window, MacWindow, and Win32Window.
Return a pointer to this window's render target. By setting window targets from different windows, we can effect rendering to multiple windows from a single device. Implemented in XB360Window, MacWindow, and Win32Window.
Get our current video mode - if the window has been resized, it will reflect this.
Implemented in MacWindow, and Win32Window.
If we're fullscreen, this function returns us to desktop mode. This will be either the last mode that we had that was not fullscreen, or the equivalent mode, windowed. Implemented in XB360Window, MacWindow, and Win32Window.
Implemented in MacWindow, and Win32Window. Set Idle State (Background). This is called to put a window into idle state, which causes it's rendering priority to be toned down to prefer performance
Get Idle State (Background). This is called to poll the window as to it's idle state.
Restore the window from a Maximized or Minimized state.
Implemented in XB360Window, MacWindow, and Win32Window. Set the Client Area Extent (Resolution) of this window. This does not include the area occupied by a title-bar, menu, borders or other non-client elements. Implemented in MacWindow, and Win32Window.
Resize the window to have some new bounds. This includes the area needed for a title-bar, menu, borders, and other non-client elements. Implemented in XB360Window, MacWindow, and Win32Window.
Get the position and size (fullscreen windows are always at (0,0)).
Implemented in MacWindow, and Win32Window. Set the position of this window. This means that saying setPosition at 0,0 will put the position of the window title-bar (if one exists) at 0,0 and the Client area will be offset from that point by the space needed for the Non-Client area. Implemented in XB360Window, MacWindow, and Win32Window.
Reimplemented in MacWindow, and Win32Window. Resize the window to have a new size (but be in the same position).
Implemented in XB360Window, MacWindow, and Win32Window.
Returns true if the window is instantiated in the OS.
Implemented in XB360Window, MacWindow, and Win32Window.
Set if we want to process key events into appropriate character events as well.
Returns true if keyboard translation is enabled.
Used to disable native OS keyboard accelerators.
Returns true if native OS keyboard accelerators are enabled.
Sets a minimum window size. We'll work with the OS to prevent user from sizing the window to less than this. Setting to (0,0) means user has complete freedom of resize.
Returns the current minimum window size for this window.
Set the cursor position based on logical coordinates from the upper-right corner.
Get the cursor position based on logical coordinates from the upper-right corner.
Set the cursor visibility on this window.
Get the cursor visibility on this window.
Lock the mouse to this window. When this is set, the mouse will always be returned to the center of the client area after every mouse event. The mouse will also be hidden while it is locked. The mouse cannot be moved out of the bounds of the window, but the window may lose focus (for instance by an alt-tab or other event). While the window lacks focus, no mouse events will be reported. Implemented in XB360Window, MacWindow, and Win32Window.
Should the mouse be locked at the next opportunity ? This flag is set to the current state of the mouse lock on a window, to specify the preferred lock status of the mouse in a platform window. This is important for situations where a call is made to setMouseLocked, and the window is not in a state that it can be cleanly locked. Take for example if it was called while the window is in the background, then it is not appropriate to lock the window, but rather the window should query this state at it's next opportunity and lock the mouse if requested. Implemented in XB360Window, MacWindow, and Win32Window.
Implemented in XB360Window, MacWindow, and Win32Window.
Get the platform specific object needed to create or attach an accelerated graohics drawing context on or to the window Win32 D3D and OpenGL typically needs an HWND Mac Cocoa OpenGL typically needs an NSOpenGLView Mac Carbon OpenGL typically needs a WindowRef.
Implemented in MacWindow, and Win32Window.
Reimplemented in MacWindow, and Win32Window.
Friends And Related Function Documentation
Member Data Documentation
Are we enabling IME or other keyboard input translation services, or concerned about raw input?
When Torque GuiText input controls have focus they need to disable native OS keyboard accelerator translation.
Minimum allowed size for this window. When possible, we will communicate this to the OS.
Is Idle?
Cursor Controller for this Window.
An opaque ID used to resolve references to this Window.
Window Mouse/Key input Controller for this Window.
|