Top Description Fields Constructors Methods
com.sun.glass.ui.monocle

pack-priv Class DispmanCursor

extends NativeCursor
Class Inheritance
Imports
com.sun.glass.ui.Size

Cursor using dispman API.

Todo

Can we mmap the image and location files?

Field Summary

Modifier and TypeField and Description
private static final int
private static final int
Inherited from com.sun.glass.ui.monocle.NativeCursor:
isVisible

Constructor Summary

AccessConstructor and Description
pack-priv

Method Summary

Modifier and TypeMethod and Description
private native void
_initDispmanCursor(int cursorWidth, int cursorHeight)

private native void
_setImage(byte[] cursorImage)

private native void
_setLocation(int x, int y)

private native void
_setVisible(boolean visible)

pack-priv Size
getBestSize()

Implements abstract com.sun.glass.ui.monocle.NativeCursor.getBestSize.

Returns the preferred size of a native cursor.

pack-priv void
setHotSpot(int
the X offset of the hot spot
hotspotX
,
int
the Y offset of the hot spot.
hotspotY
)

Implements abstract com.sun.glass.ui.monocle.NativeCursor.setHotSpot.

Sets the offset of the cursor's hot spot within the cursor image The hot spot offsets default to 0, 0.

pack-priv void
setImage(byte[]
the cursor image, in BYTE_BGRA_PRE format
cursorImage
)

Implements abstract com.sun.glass.ui.monocle.NativeCursor.setImage.

Sets the cursor image

pack-priv void
setLocation(int
the new X location on the screen
x
,
int
the new Y location on the screen
y
)

Implements abstract com.sun.glass.ui.monocle.NativeCursor.setLocation.

Sets the location of the hot spot of the cursor on the screen

pack-priv void
setVisibility(boolean
the new setting for the cursor's visibility.
visibility
)

Implements abstract com.sun.glass.ui.monocle.NativeCursor.setVisibility.

Sets whether or not the cursor is visible.

pack-priv void
shutdown()

Implements abstract com.sun.glass.ui.monocle.NativeCursor.shutdown.

Performs any necessary shutdown of the cursor infrastructure.

private void
updateImage(boolean always)

Inherited from com.sun.glass.ui.monocle.NativeCursor:
getVisiblity

Field Detail

CURSOR_HEIGHTback to summary
private static final int CURSOR_HEIGHT
CURSOR_WIDTHback to summary
private static final int CURSOR_WIDTH

Constructor Detail

DispmanCursorback to summary
pack-priv DispmanCursor()

Method Detail

_initDispmanCursorback to summary
private native void _initDispmanCursor(int cursorWidth, int cursorHeight)
_setImageback to summary
private native void _setImage(byte[] cursorImage)
_setLocationback to summary
private native void _setLocation(int x, int y)
_setVisibleback to summary
private native void _setVisible(boolean visible)
getBestSizeback to summary
pack-priv Size getBestSize()

Implements abstract com.sun.glass.ui.monocle.NativeCursor.getBestSize.

Doc from com.sun.glass.ui.monocle.NativeCursor.getBestSize.

Returns the preferred size of a native cursor.

Annotations
@Override
setHotSpotback to summary
pack-priv void setHotSpot(int hotspotX, int hotspotY)

Implements abstract com.sun.glass.ui.monocle.NativeCursor.setHotSpot.

Doc from com.sun.glass.ui.monocle.NativeCursor.setHotSpot.

Sets the offset of the cursor's hot spot within the cursor image The hot spot offsets default to 0, 0.

Parameters
hotspotX:int

the X offset of the hot spot

hotspotY:int

the Y offset of the hot spot.

Annotations
@Override
setImageback to summary
pack-priv void setImage(byte[] cursorImage)

Implements abstract com.sun.glass.ui.monocle.NativeCursor.setImage.

Doc from com.sun.glass.ui.monocle.NativeCursor.setImage.

Sets the cursor image

Parameters
cursorImage:byte[]

the cursor image, in BYTE_BGRA_PRE format

Annotations
@Override
setLocationback to summary
pack-priv void setLocation(int x, int y)

Implements abstract com.sun.glass.ui.monocle.NativeCursor.setLocation.

Doc from com.sun.glass.ui.monocle.NativeCursor.setLocation.

Sets the location of the hot spot of the cursor on the screen

Parameters
x:int

the new X location on the screen

y:int

the new Y location on the screen

Annotations
@Override
setVisibilityback to summary
pack-priv void setVisibility(boolean visibility)

Implements abstract com.sun.glass.ui.monocle.NativeCursor.setVisibility.

Doc from com.sun.glass.ui.monocle.NativeCursor.setVisibility.

Sets whether or not the cursor is visible. The implementation should set the isVisible field. On success the isVisible field is set to the visibility parameter.

Parameters
visibility:boolean

the new setting for the cursor's visibility.

Annotations
@Override
shutdownback to summary
pack-priv void shutdown()

Implements abstract com.sun.glass.ui.monocle.NativeCursor.shutdown.

Doc from com.sun.glass.ui.monocle.NativeCursor.shutdown.

Performs any necessary shutdown of the cursor infrastructure. Called only once.

Annotations
@Override
updateImageback to summary
private void updateImage(boolean always)