com.jogamp.newt.impl.awt
Class AWTWindow

java.lang.Object
  extended by com.jogamp.newt.Window
      extended by com.jogamp.newt.impl.awt.AWTWindow
All Implemented Interfaces:
NativeWindow, SurfaceUpdatedListener

public class AWTWindow
extends Window

An implementation of the Newt Window class built using the AWT. This is provided for convenience of porting to platforms supporting Java SE.


Field Summary
 
Fields inherited from class com.jogamp.newt.Window
caps, ClickTimeout, config, DEBUG_IMPLEMENTATION, DEBUG_KEY_EVENT, DEBUG_MOUSE_EVENT, DEBUG_WINDOW_EVENT, fullscreen, height, parentNativeWindow, parentWindowHandle, screen, title, undecorated, visible, width, windowHandle, windowLock, x, y
 
Fields inherited from interface javax.media.nativewindow.NativeWindow
LOCK_SUCCESS, LOCK_SURFACE_CHANGED, LOCK_SURFACE_NOT_READY, LOCK_SURFACE_UNLOCKED
 
Constructor Summary
AWTWindow()
           
AWTWindow(Container container)
           
 
Method Summary
protected  void closeNative()
           
protected  void createNativeImpl()
          Create native windowHandle, ie creates a new native invisible window.
protected  void enqueueKeyEvent(int eventType, int modifiers, int keyCode, char keyChar)
           
protected  void enqueueMouseEvent(int eventType, int modifiers, int x, int y, int button, int rotation)
           
protected  void enqueueWindowEvent(int eventType)
           
static Class[] getCustomConstructorArgumentTypes()
           
 Insets getInsets()
          Returns the insets for this native window (the difference between the size of the toplevel window with the decorations and the client area).
 Object getWrappedWindow()
          If this Window actually wraps one from another toolkit such as the AWT, this will return a non-null value.
 boolean hasDeviceChanged()
          If the implementation is capable of detecting a device change return true and clear the status/reason of the change.
protected  boolean setFullscreenImpl(boolean fullscreen, int x, int y, int w, int h)
           
protected  void setPositionImpl(int x, int y)
           
protected  void setSizeImpl(int width, int height)
           
protected  void setTitleImpl(String title)
           
protected  void setVisibleImpl(boolean visible)
           
 
Methods inherited from class com.jogamp.newt.Window
addChild, addKeyListener, addKeyListener, addMouseListener, addMouseListener, addPaintListener, addPaintListener, addSurfaceUpdatedListener, addSurfaceUpdatedListener, addWindowListener, addWindowListener, create, create, destroy, destroy, getDisplayHandle, getGraphicsConfiguration, getHeight, getInnerWindow, getKeyListener, getKeyListeners, getLockedStack, getMouseListener, getMouseListeners, getPaintListener, getParentNativeWindow, getRequestedCapabilities, getScreen, getScreenIndex, getSurfaceHandle, getSurfaceLockOwner, getSurfaceUpdatedListener, getSurfaceUpdatedListeners, getThreadName, getTitle, getWidth, getWindowHandle, getWindowListener, getWindowListeners, getWindowLock, getX, getY, invalidate, invalidate, isDestroyed, isFullscreen, isNativeWindowValid, isSurfaceLocked, isUndecorated, isUndecorated, isVisible, lockSurface, removeAllSurfaceUpdatedListener, removeChild, removeKeyListener, removeMouseListener, removePaintListener, removeSurfaceUpdatedListener, removeWindowListener, reparentWindow, reparentWindowImpl, requestFocus, requestFocusImpl, runOnEDTIfAvail, sendEvent, sendKeyEvent, sendMouseEvent, sendPaintEvent, sendPaintEvent, sendWindowEvent, setFullscreen, setHandleDestroyNotify, setPosition, setSize, setTitle, setUndecorated, setVisible, shouldNotCallThis, surfaceSwap, surfaceUpdated, toHexString, toHexString, toString, unlockSurface, windowDestroyed, windowDestroyNotify, windowIsLocked, windowLock, windowUnlock
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

AWTWindow

public AWTWindow()

AWTWindow

public AWTWindow(Container container)
Method Detail

getCustomConstructorArgumentTypes

public static Class[] getCustomConstructorArgumentTypes()

setTitleImpl

protected void setTitleImpl(String title)
Overrides:
setTitleImpl in class Window

createNativeImpl

protected void createNativeImpl()
Description copied from class: Window
Create native windowHandle, ie creates a new native invisible window.

Specified by:
createNativeImpl in class Window

closeNative

protected void closeNative()
Specified by:
closeNative in class Window

hasDeviceChanged

public boolean hasDeviceChanged()
Description copied from class: Window
If the implementation is capable of detecting a device change return true and clear the status/reason of the change.

Overrides:
hasDeviceChanged in class Window

setVisibleImpl

protected void setVisibleImpl(boolean visible)
Specified by:
setVisibleImpl in class Window

setSizeImpl

protected void setSizeImpl(int width,
                           int height)
Specified by:
setSizeImpl in class Window

getInsets

public Insets getInsets()
Description copied from class: Window
Returns the insets for this native window (the difference between the size of the toplevel window with the decorations and the client area).

Overrides:
getInsets in class Window
Returns:
insets for this platform window

setPositionImpl

protected void setPositionImpl(int x,
                               int y)
Specified by:
setPositionImpl in class Window

setFullscreenImpl

protected boolean setFullscreenImpl(boolean fullscreen,
                                    int x,
                                    int y,
                                    int w,
                                    int h)
Specified by:
setFullscreenImpl in class Window

getWrappedWindow

public Object getWrappedWindow()
Description copied from class: Window
If this Window actually wraps one from another toolkit such as the AWT, this will return a non-null value.

Overrides:
getWrappedWindow in class Window

enqueueWindowEvent

protected void enqueueWindowEvent(int eventType)
Overrides:
enqueueWindowEvent in class Window

enqueueKeyEvent

protected void enqueueKeyEvent(int eventType,
                               int modifiers,
                               int keyCode,
                               char keyChar)
Overrides:
enqueueKeyEvent in class Window

enqueueMouseEvent

protected void enqueueMouseEvent(int eventType,
                                 int modifiers,
                                 int x,
                                 int y,
                                 int button,
                                 int rotation)
Overrides:
enqueueMouseEvent in class Window


Copyright 2010 JogAmp Community.