|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Object | +--waba.sys.Settings
this class provides some preferences from PalmOS config and other Vm settings. All settings are read-only, unless otherwise specified. Changing their values may cause the VM to crash.
| Field Summary | |
static boolean |
actionOnRelease
When actionOnRelease is true (default), the IKeys.ACTION is dispatched when the user does a quick-press, and a IKeys.MENU is dispatched when the user holds the action for at least one second. |
static java.lang.String |
appCreatorId
Application creator ID. |
static java.lang.String |
appPath
The path from where the application is running from. |
static java.lang.String |
appSecretKey
Application defined secret key. |
static java.lang.String |
appSettings
Application defined settings. |
static byte[] |
appSettingsBin
Application defined settings, stored as a byte array. |
static java.lang.String |
dataPath
Specifies the directory where pdbs should be read/written. |
static byte |
DATE_DMY
Constant used in dateFormat: day month year |
static byte |
DATE_MDY
Constant used in dateFormat: month day year |
static byte |
DATE_YMD
Constant used in dateFormat: year month day |
static byte |
dateFormat
Can be one of the following constants: DATE_MDY, DATE_DMY, DATE_YMD; where m = month, d = day and y = year |
static char |
dateSeparator
The date char separator. |
static boolean |
daylightSavings
Returns true if the device is in daylight savings mode. |
static char |
decimalSeparator
The decimal separator for numbers |
static java.lang.String |
deviceId
Returns a device id that can be used to identify the device's name. |
static byte |
Flat
Defines a FLAT user interface style, like the ones used in Pocket PC 2003. |
static boolean |
is24Hour
True if the time format is 24 hour format or if it is the AM/PM format |
static boolean |
isColor
READ-ONLY variable that represents if the device supports color. |
static boolean |
isHighColor
Returns true if this device supports high or true color (or, in othe words, is not palletized). |
static boolean |
keyboardFocusTraversable
Defines if the arrow keys will be used to change the focus using the keyboard. |
static boolean |
keypadOnly
Returns true if this device has a keypad only (many SmartPhones have keypads only). |
static int |
maxColors
READ-ONLY variable that returns the number of colors supported by the device. |
static boolean |
onDevice
READ-ONLY variable that defines if were being runned in a handheld device or in a desktop computer. |
static byte |
PalmOS
Defines a PalmOS user interface style. |
static boolean |
penless
Deprecated. Use Settings.keyboardFocusTraversable instead. |
static java.lang.String |
platform
READ-ONLY variable that returns the current platform name. |
static java.lang.String |
romSerialNumber
Returns the ROM serial number for this device. |
static int |
romVersion
READ-ONLY variable that returns the ROM version of the device, like 0x02000000 or 0x03010000. |
static int |
screenHeight
READ-ONLY variable that represents the device's screen height |
static int |
screenWidth
READ-ONLY variable that represents the device's screen width |
static boolean |
showSecrets
Returns false if the PDA has a password and the user choosen to hide the secret records (via the Apps/Security/Current Privacy). |
static char |
thousandsSeparator
The thousands separator for numbers |
static char |
timeSeparator
The time char separator |
static int |
timeZone
Returns the timezone used for this device. |
static byte |
uiStyle
The uiStyle used to define the user interface style. |
static boolean |
useExceptions
Set this property to true to be able to use exceptions in the waba.* packages instead of checking for error codes of calling methods. |
static java.lang.String |
userName
READ-ONLY variable that returns the username of the user running the Virtual Machine. |
static int |
version
The version of the SuperWaba Virtual Machine. |
static java.lang.String |
versionStr
Returns the version in a string form, like "2.0b4r8" |
static boolean |
virtualKeyboard
True if this handheld has a virtual keyboard |
static byte |
Vista
Defines a Windows Vista user interface style. |
static byte |
weekStart
The week day start. 0 = sunday, 6 = saturday |
static byte |
WinCE
Defines a Windows CE user interface style. |
| Method Summary | |
static void |
setUIStyle(byte style)
Changes the user interface style to the given one. |
| Methods inherited from class java.lang.Object |
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
| Field Detail |
public static byte dateFormat
public static char dateSeparator
public static byte weekStart
public static boolean is24Hour
public static char timeSeparator
public static char thousandsSeparator
public static char decimalSeparator
public static int screenWidth
public static int screenHeight
public static boolean isColor
public static int maxColors
public static boolean onDevice
public static int romVersion
public static java.lang.String platform
public static java.lang.String userName
public static byte[] appSettingsBin
if (Settings.appSettingsBin == null)
{
add(new Label("empty"),CENTER,CENTER);
ByteArrayStream bas = new ByteArrayStream(100);
DataStream ds = new DataStream(bas);
ds.writeDouble(1234.567);
Settings.appSettingsBin = bas.getCopy();
}
else
{
ByteArrayStream bas = new ByteArrayStream(Settings.appSettingsBin);
DataStream ds = new DataStream(bas);
double d = ds.readDouble();
add(new Label("d = "+Convert.toString(d,3)),CENTER,CENTER);
Settings.appSettingsBin = null;
}
public static java.lang.String appSettings
public static java.lang.String appSecretKey
In Windows CE, the key is stored in the registry.
public static java.lang.String appCreatorId
public static byte uiStyle
public static int version
public static java.lang.String versionStr
public static final byte WinCE
public static final byte PalmOS
public static final byte Flat
public static final byte Vista
public static final byte DATE_MDY
public static final byte DATE_DMY
public static final byte DATE_YMD
public static boolean daylightSavings
public static int timeZone
public static boolean virtualKeyboard
public static java.lang.String dataPath
/dataPath commandline parameter.
null (unless the library is also in the dataPath).
public static java.lang.String romSerialNumber
null if unavailable, such as in
Windows CE 2.11 devices, Palm OS < 3.0, and even some Palm OS 5 devices,
like Treo 6xx.
Note: this was correctly tested; you can ensure that your Palm OS device has or not a serial number pressing App/Info/Version: the serial number will appear in the top; if nothing appears, it means that the device doesn't has a serial number. If it appears but nothing is returned from here, it means that the device has a non-standard function that retrieves the serial number, and thus we don't support it.
public static boolean showSecrets
public static boolean isHighColor
public static boolean penless
public static boolean keypadOnly
public static boolean keyboardFocusTraversable
public static java.lang.String deviceId
null.public static boolean useExceptions
public static java.lang.String appPath
dataPathpublic static boolean actionOnRelease
| Method Detail |
public static void setUIStyle(byte style)
public class Foo extends MainWindow
{
public Foo()
{
super("Hi bar",TAB_ONLY_BORDER);
waba.sys.Settings.setUIStyle(waba.sys.Settings.FLAT);
style - Can be PalmOS, WinCE or Flat. If PalmOS, uses a white background.
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||