public interface PlatformWindow
| Modifier and Type | Method and Description |
|---|---|
void |
applyShape(sun.java2d.pipe.Region shape)
Applies the specified shape to the native component window.
|
boolean |
canDetermineObscurity()
Returns
true if the platform window implementation can
determine if the window has been obscured, false
otherwise. |
void |
createBuffers(int numBuffers,
BufferCapabilities caps)
Creates back buffers for flipping.
|
void |
destroyBuffers()
Destroys the flipping buffers.
|
void |
dispose()
Disposes the underlying platform window and releases all associated
resources.
|
void |
flip(int x1,
int y1,
int x2,
int y2,
BufferCapabilities.FlipContents flipAction)
Flips the (current) backbuffer to the front buffer.
|
Image |
getBackBuffer()
Provides access to the (current) backbuffer as an image.
|
Rectangle |
getBounds()
Returns the bounds of the native window.
|
ColorModel |
getColorModel()
Returns the color model used by the native window.
|
Graphics2D |
getGraphics(Color foreground,
Color background,
Font font)
Returns a Graphics2D object for drawing on this window.
|
GraphicsConfiguration |
getGraphicsConfiguration()
Returns the graphics configuration used by the native window.
|
Insets |
getInsets()
Returns the insets of this native window.
|
Point |
getLocationOnScreen()
Returns the location of the native window on the screen.
|
boolean |
isObscured()
Returns
true if the platform window implementation
determines that it has been obscured, false otherwise. |
boolean |
isReparentSuppored()
Returns
true if reparenting of native windows is supported,
false otherwise. |
boolean |
isRestackSupported()
Returns
true if the native window implementation supports
restacking of the window hierarchy, false otherwise. |
void |
reparent(java.awt.peer.ContainerPeer newContainer)
Reparents this native window to become a child of the specified
container.
|
void |
requestFocus()
Request focus on the window.
|
boolean |
requestFocus(Component lightweightChild,
boolean temporary,
boolean focusedWindowChangeAllowed,
long time,
sun.awt.CausedFocusEvent.Cause cause)
Requests a focus change to this window.
|
void |
restack()
Updates the stacking order of the window hierarchy.
|
void |
setBounds(int x,
int y,
int width,
int height,
int op)
Sets the bounds of this native window.
|
void |
setVisible(boolean b)
Shows or hides this native window.
|
ColorModel getColorModel()
GraphicsConfiguration getGraphicsConfiguration()
Rectangle getBounds()
void dispose()
Graphics2D getGraphics(Color foreground, Color background, Font font)
foreground - the foreground to be setbackground - the background to be setfont - the font to be setvoid setBounds(int x,
int y,
int width,
int height,
int op)
op parameter specifies the actual operation of this
methods, according to the various constants in ComponentPeer.x - y - width - height - op - ComponentPeer.setBounds(int, int, int, int, int)Insets getInsets()
Point getLocationOnScreen()
boolean canDetermineObscurity()
true if the platform window implementation can
determine if the window has been obscured, false
otherwise.true if the platform window implementation can
determine if the window has been obscured, false
otherwiseisObscured()boolean isObscured()
true if the platform window implementation
determines that it has been obscured, false otherwise.
This is only called when canDetermineObscurity() returns
true.true if the platform window implementation
determines that it has been obscured, false
otherwisecanDetermineObscurity()void applyShape(sun.java2d.pipe.Region shape)
shape - the shape to apply to the windowboolean isReparentSuppored()
true if reparenting of native windows is supported,
false otherwise.true if reparenting of native windows is supported,
false otherwisereparent(ContainerPeer)void reparent(java.awt.peer.ContainerPeer newContainer)
isReparentSuppored()
returns true.newContainer - the new container window of this native windowisReparentSuppored()boolean isRestackSupported()
true if the native window implementation supports
restacking of the window hierarchy, false otherwise.true if the native window implementation supports
restacking of the window hierarchy, false otherwisevoid restack()
isRestackSupported() returns true.void setVisible(boolean b)
v - true shows this native window
false hides it.boolean requestFocus(Component lightweightChild, boolean temporary, boolean focusedWindowChangeAllowed, long time, sun.awt.CausedFocusEvent.Cause cause)
lightweightChild - the actual lightweight child that wants focustemporary - true if the focus change should be
temporary, false otherwisefocusedWindowChangeAllowed - true when changing the
focus of the corresponding toplevel window is allowed,
false otherwisetime - the time of the focus change requestcause - the cause of the focus change requesttrue when the focus transfer is guaranteed to be
successful, false otherwisevoid createBuffers(int numBuffers,
BufferCapabilities caps)
throws AWTException
numBuffers - the number of buffers to create for flippingcaps - the required buffer capabilitiesAWTException - if flipping is not supportedvoid destroyBuffers()
void flip(int x1,
int y1,
int x2,
int y2,
BufferCapabilities.FlipContents flipAction)
x1 - the area to flip, left X coordinatey1 - the area to flip, top Y coordinatex2 - the area to flip, right X coordinatey2 - the area to flip, bottom Y coordinateflipAction - the requested flip actionImage getBackBuffer()
void requestFocus()
Copyright © 2012. All Rights Reserved.