|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.eclipse.ercp.swt.mobile.Screen
Instances of this class represent display screens available for application use.
MobileDevice,
MobileDeviceListener| Field Summary | |
static int |
LANDSCAPE
indicates text is normally written across the longest width |
static int |
PORTRAIT
indicates text is normally written across the shortest width |
static int |
PRIMARY
one primary screen may be active at a time |
static int |
SECONDARY
multiple secondary screens may be simultaneously active |
static int |
STATUS
sub type of secondary screen that shows minimal content for notification purposes |
| Method Summary | |
void |
addEventListener(ScreenListener listener)
Adds the listener to the collection of listeners that will be notified when screen events occur by sending it one of the messages defined in the ScreenListener interface. |
Rectangle |
getBounds()
Returns the bounds of the screen. |
int |
getColorDepth()
Returns the color depth of the screen in bits per pixel. |
int |
getLocation()
Returns the location of the screen device. |
int |
getOrientation()
Returns the screen orientation. |
int |
getUsage()
Returns the usage type of the screen. |
boolean |
isActive()
Returns whether the screen is currently active. |
boolean |
isTouchScreen()
Returns whether the screen has touch screen capability. |
void |
removeEventListener(ScreenListener listener)
Removes the listener from the collection of listeners that will be notified when screen events occur. |
void |
setOrientation(int orientation)
Sets the screen orientation if supported on this device. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
public static final int PRIMARY
public static final int SECONDARY
public static final int STATUS
public static final int PORTRAIT
public static final int LANDSCAPE
| Method Detail |
public void addEventListener(ScreenListener listener)
screenActivated is called when a screen becomes active. That
is, the screen is powered and contents are visible to the user.
screenDeactivated is called when a screen is no longer
active.
listener - instance called when screen events occur
java.lang.IllegalArgumentException - SWTException - SWTError - ScreenListener,
removeEventListener(org.eclipse.ercp.swt.mobile.ScreenListener)public Rectangle getBounds()
SWTException - SWTError - public int getColorDepth()
SWTException - SWTError - public int getLocation()
LOCAL,
INTERNAL,
EXTERNAL, or
REMOTE
SWTException - SWTError - MobileDevice.LOCAL,
MobileDevice.INTERNAL,
MobileDevice.EXTERNAL,
MobileDevice.REMOTEpublic int getOrientation()
SWTException - SWTError - PORTRAIT,
LANDSCAPE,
setOrientation(int)public int getUsage()
SWTException - SWTError - PRIMARY,
SECONDARY,
STATUSpublic boolean isActive()
SWTException - SWTError - public boolean isTouchScreen()
SWTException - SWTError - public void removeEventListener(ScreenListener listener)
listener - instance called when screen events occur
java.lang.IllegalArgumentException - SWTException - SWTError - ScreenListener,
addEventListener(org.eclipse.ercp.swt.mobile.ScreenListener)public void setOrientation(int orientation)
orientation - the caller's preferred orientation. Must be one of PORTRAIT and
LANDSCAPE.
java.lang.IllegalArgumentException - SWTException - PORTRAIT,
LANDSCAPE,
getOrientation()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||