|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectewe.ui.ControlBase
ewe.ui.Control
ewe.ui.Container
ewe.ui.Window
ewe.ui.MainWindow
ewe.ui.mApp
| Nested Class Summary |
| Nested classes inherited from class ewe.ui.Window |
Window.TaskBarIconInfo |
| Field Summary | |
static Frame |
appFrame
|
protected boolean |
checkMonochrome
|
static boolean |
counterRotated
Set this to true before calling setupMainWindow() to display the application rotated by 90 degrees anti-clockwise (which puts the controls on the left - when the user rotates it back by 90 degrees clockwise). |
static Font |
guiFont
|
static int |
lastEvent
|
static mApp |
mainApp
|
protected static Method |
mainMethod
|
protected boolean |
monoMode
|
protected Graphics |
myGraphics
|
static String |
platform
|
static String[] |
programArguments
|
static int |
ROTATE_CLOCKWISE
|
static int |
ROTATE_COUNTER_CLOCKWISE
|
static int |
ROTATE_NORMAL
|
static boolean |
rotated
Set this to true before calling setupMainWindow() to display the application rotated by 90 degrees clockwise (which puts the controls on the right - when the user rotates it back by 90 degrees anti-clockwise). |
static Class |
runClass
|
static Object |
runObject
|
static Object |
taskbarIcon
If this is set to a valid icon in the setupMainWindow() method, then the icon will display in the taskbar as long as this application runs. |
static TaskbarWindow |
taskbarWindow
If you set taskbarIcon in the setupMainWindow() method, then this will be set to a TaskbarWindow that will be created. |
static int |
tickTime
|
static VMOptions |
vmOptions
|
protected int |
windowFlagsToClear
|
protected int |
windowFlagsToSet
|
protected boolean |
windowInitiallyVisible
|
protected Rect |
windowRect
|
protected String |
windowTitle
|
| Fields inherited from class ewe.ui.MainWindow |
defaultFont |
| Fields inherited from class ewe.ui.Window |
_controlEvent, _keyEvent, _penEvent, _sipEvent, canDisplay, closeLock, contents, creationData, currentCursor, downPoint, dragAndDropCursor, dragAndDropData, dragAndDropSource, firstDisplay, inEventThread, inFront, lastWindow, wasPainted |
| Fields inherited from class ewe.ui.Container |
closedFocus, cycleFocus, dontAutoScroll, dontFocusOnChildren |
| Fields inherited from class ewe.ui.Control |
_debug, backGround, beforeRemoved, borderColor, borderStyle, borderWidth, children, columns, constraints, DoPaintMethod, dragging, dragResolution, dragTime, exitKeys, fieldTransfer, font, foreGround, haveNativePaint, height, holdDownPause, holdTick, hotKey, image, lastSelected, listeners, maxHeight, maxWidth, menuState, minHeight, minWidth, modifiers, MyClass, name, next, np, parent, penStatus, popupSound, popupSoundClip, preferredHeight, preferredWidth, prev, prompt, promptControl, rows, ss, standardBorder, standardEdge, startDragResolution, tags, tail, text, toolTip, width, x, y |
| Fields inherited from class ewe.ui.ControlBase |
clipItems, clipObject, clipOwner, curPoint, currentPenEvent, debugControl, debugFlag, DidHoldDown, doubleBuffer, doubleClickTime, firstPress, globalDrawFlat, globalEditable, globalEnabled, globalPalmStyle, globalSmallControls, GotPenDown, PenIsOn, pressPoint, TAG_LAST_USER_DATA, TAG_USER_DATA, TAKE_FIRST_PRESS, unnamed, useNativeTextInput |
| Fields inherited from interface ewe.fx.ISurface |
IMAGE_SURFACE, PRINTERJOB_SURFACE, WINDOW_SURFACE |
| Fields inherited from interface ewe.ui.UIConstants |
BDR_DOTTED, BDR_INNER, BDR_NOBORDER, BDR_OUTER, BDR_OUTLINE, BDR_RAISEDINNER, BDR_RAISEDOUTER, BDR_SUNKENINNER, BDR_SUNKENOUTER, BF_BOTTOM, BF_BOTTOMLEFT, BF_BOTTOMRIGHT, BF_BUTTON, BF_DIAGONAL, BF_DIAGONAL_ENDBOTTOMLEFT, BF_DIAGONAL_ENDBOTTOMRIGHT, BF_DIAGONAL_ENDTOPLEFT, BF_DIAGONAL_ENDTOPRIGHT, BF_EXACT, BF_FLAT, BF_LEFT, BF_MIDDLE, BF_MONO, BF_PALM, BF_RECT, BF_RIGHT, BF_SOFT, BF_SQUARE, BF_TOP, BF_TOPLEFT, BF_TOPRIGHT, EDGE_BUMP, EDGE_ETCHED, EDGE_RAISED, EDGE_SUNKEN |
| Fields inherited from interface ewe.ui.CellConstants |
BORDER, BOTTOM, CELLFLAG, CELLMASK, CENTER, CONTROLMASK, DONTCHANGE, DONTFILL, DONTSTRETCH, EAST, FILL, FIXEDSIZE, GROW, HCENTER, HCONTRACT, HEXPAND, HFILL, HGROW, HSHRINK, HSTRETCH, INITIALLY_CLOSED, INITIALLY_MINIMIZED, INITIALLY_PREFERRED_SIZE, INSETS, LEFT, MAXIMUMSIZE, MINIMUMSIZE, NORTH, NORTHEAST, NORTHWEST, PREFERREDSIZE, RECT, RIGHT, SHRINK, SOUTH, SOUTHEAST, SOUTHWEST, SPAN, STRETCH, TEXTSIZE, TOP, VCENTER, VCONTRACT, VEXPAND, VFILL, VGROW, VSHRINK, VSTRETCH, WEST |
| Fields inherited from interface ewe.ui.ControlConstants |
All, AlwaysEnabled, AlwaysRecalculateSizes, ByDeferredMouse, ByDeferredPen, ByFrameChange, ByKeyboard, ByMouse, ByPen, ByRequest, CalculatedSizes, Disabled, DisablePopupMenu, DisplayOnly, Down, DrawFlat, Flag, ForceResize, HasData, Invisible, KeepImage, KeepSIP, Left, MakeMenuAtLeastAsWide, Maximize, Minimize, MouseSensitive, NoFocus, NotAnEditor, NotEditable, PaintDataOnly, PaintOutsideOnly, PenTransparent, PreferredSizeOnly, Right, SendUpKeyEvents, SendUpPenEvents, ShowSIP, ShrinkToNothing, SmallControl, SpecialBackground, TakeControlEvents, TakesKeyFocus, Transparent, Up, WantDrag, WantHoldDown |
| Fields inherited from interface ewe.fx.ImageRefresher |
KEEP_VISIBLE |
| Constructor Summary | |
mApp()
|
|
mApp(boolean dontSetupAtAll)
This is used if the mApp you are creating is not necessarily the only mApp that will be created. If the parameter is true then no application setup will be done. |
|
mApp(Class runClass)
This is used by the system when constructing for a specified run object. |
|
| Method Summary | |
void |
action(FieldTransfer ft,
Editor ed)
This implements the action() method in FieldListener. |
static void |
addFont(Font font,
String name)
Add a Font to the application font library. |
static void |
cancelTimer(int timerId)
|
protected boolean |
canClose()
|
protected boolean |
canExit(int code)
|
void |
changeMonoMode()
Deprecated. |
void |
closeMobileApp(Window targetWindow,
int flags)
This will be called by mobileWindowEvent() if a Close message is sent by the OS and the application is running on a mobile device. |
void |
doPaint(Graphics g,
Rect r)
|
void |
fieldChanged(FieldTransfer ft,
Editor ed)
This implements the fieldChanged() method in FieldListener. |
void |
fieldEvent(FieldTransfer ft,
Editor ed,
Object event)
This implements the fieldEvent() method in FieldListener. |
static Font |
findFont(String name)
Find a font in the application Font library. |
static Font |
findFont(String name,
boolean doDefault)
Find a font in the application Font library. |
static void |
fontsChanged()
Call this method to alert the application that fonts have been changed other than through setFont(). |
protected void |
fullSetup(boolean visible)
|
static Iterator |
getFonts()
Get an Iterator for all the entries in the fonts hashtable. |
Graphics |
getGraphics(boolean newOne)
|
boolean |
isLocked()
|
void |
onEvent(Event ev)
|
void |
onStart()
Called when an application starts. |
static int |
requestTick(TimerProc who,
int milli)
This results in a single call to the ticked() method of the TimerProc, unless cancelTimer() is called first. |
static int |
requestTimer(TimerProc who,
int milli)
This results in regular calls to the ticked() method of the TimerProc until cancelTimer() is called. |
static boolean |
rotateScreen(int type)
|
void |
run()
|
static void |
runApplet(String[] args)
This calls runApplet(String args[],String extraArgs []) with null extraArgs. |
static void |
runApplet(String[] args,
String[] extraArgs)
This is used if the mApp is executed directly by a pure Java interpreter. |
void |
setRect(int x,
int y,
int w,
int h)
|
void |
setRunObject(Object obj)
|
protected void |
setup()
This is called at the end of the fullSetup() method, so by this time the Main Window is created and displayed if it was set to be visible. |
static void |
setupFonts()
This is used by the mApp to setup its font list. |
protected void |
setupMainWindow()
This is called by the system during the constructor to setup this mApp as the application's Main Window. |
void |
show(Frame f,
boolean fullSize)
This is called after setupMainWindow() is called - so by this time the Main Window has already been created and is now visible if it was not set to be invisible. |
void |
showStartMessage()
|
protected void |
sizeToFit(Control what)
|
protected void |
startup()
This is called if this mApp was selected as the class to run for the application. |
void |
tryExit(int code)
|
| Methods inherited from class ewe.ui.MainWindow |
_onTimerTick, _setTimerInterval, addTimer, exit, getFontMetrics, getMainWindow, onExit, removeTimer |
| Methods inherited from class ewe.ui.Container |
_paintChildren, add, addDirectly, containerHasFocus, dismantle, dismantle, doHotKey, findChild, focusFirst, focusFirst, focusOnContainer, focusOnData, getChildren, getChildrenBackwards, getFirstFocus, getNextKeyFocus, gotFocus, lostFocus, remove, removeAll, repaintDataNow, scrollToVisible, takeFocus, takePromptControl |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode |
| Field Detail |
public static mApp mainApp
public static int tickTime
public static int lastEvent
public static Frame appFrame
public static String platform
public static Font guiFont
public static String[] programArguments
public static Object runObject
protected static Method mainMethod
public static Class runClass
public static VMOptions vmOptions
public static boolean rotated
public static boolean counterRotated
public static Object taskbarIcon
The value that you place here must be the result of ewe.fx.Image.toIcon(ewe.fx.Image iconMask). Note that the iconMask must be stored as a monochrome ".bmp" file under Win32/WinCE.
An example is:
taskbarIcon = new ewe.fx.Image("ewe/ewesmall.bmp").toIcon(new ewe.fx.Image("ewe/ewesmallmask.bmp"));
public static TaskbarWindow taskbarWindow
protected boolean windowInitiallyVisible
protected String windowTitle
protected Rect windowRect
protected int windowFlagsToSet
protected int windowFlagsToClear
protected boolean checkMonochrome
public static final int ROTATE_NORMAL
public static final int ROTATE_CLOCKWISE
public static final int ROTATE_COUNTER_CLOCKWISE
protected boolean monoMode
protected Graphics myGraphics
| Constructor Detail |
public mApp(boolean dontSetupAtAll)
public mApp()
public mApp(Class runClass)
| Method Detail |
public void doPaint(Graphics g,
Rect r)
doPaint in class Controlpublic void run()
run in interface Runnableprotected boolean canExit(int code)
public void tryExit(int code)
public final boolean isLocked()
public void setRunObject(Object obj)
protected void fullSetup(boolean visible)
public static boolean rotateScreen(int type)
protected void setupMainWindow()
The Main Window is always present even if it is invisible. When run as an Applet in a web page the application's Main Window is usually shown within the applet area on the page.
Override this method to setup options for the application's Main Window and then call super setupMainWindow() to continue the setup.
protected void sizeToFit(Control what)
public void onStart()
throws Exception
MainWindow
onStart in class MainWindowExceptionprotected void setup()
protected void startup()
public final void showStartMessage()
public void setRect(int x,
int y,
int w,
int h)
setRect in class Control
public void show(Frame f,
boolean fullSize)
public static final int requestTick(TimerProc who,
int milli)
public static final int requestTimer(TimerProc who,
int milli)
public static final void cancelTimer(int timerId)
protected boolean canClose()
public void onEvent(Event ev)
onEvent in interface EventListeneronEvent in class Window
public void closeMobileApp(Window targetWindow,
int flags)
targetWindow - The window that received the CLOSE event.flags - This will have the Window.FLAG_CLOSE_BY_USER bit set if the system knows for
certain that the user pressed a system button to generate the Window.CLOSE event. This is only true
for the 'OK' button under Windows CE. It is not possible to tell the difference between the user pressing
an 'X' button and the system generating a CLOSE message.
public static void fontsChanged()
public static void addFont(Font font,
String name)
font - The Font to add.name - The name of the Font. Important font names include "gui", "system", "fixed", "text", "small" and "big"public static Font findFont(String name)
name - The name of the Font to look for. Important font names include "gui", "system", "fixed", "text", "small" and "big"
public static Font findFont(String name,
boolean doDefault)
name - The name of the Font to look for. Important font names include "gui", "system", "fixed", "text", "small" and "big"doDefault - If this is true and no font is found for the name, the "system" font is returned.
If it is false and no font is found for the name, null will be returned.
public static Iterator getFonts()
public static void setupFonts()
public void changeMonoMode()
public Graphics getGraphics(boolean newOne)
public void action(FieldTransfer ft,
Editor ed)
action in interface FieldListener
public void fieldChanged(FieldTransfer ft,
Editor ed)
fieldChanged in interface FieldListener
public void fieldEvent(FieldTransfer ft,
Editor ed,
Object event)
fieldEvent in interface FieldListenerpublic static void runApplet(String[] args)
public static void runApplet(String[] args,
String[] extraArgs)
public static void main(String args[])
{
runApplet(new String[]{"solitaire/Solitaire"},args);
}
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||