danger.ui
Class DateTimeEditor
java.lang.Object
|
+--danger.app.Listener
|
+--danger.ui.View
|
+--danger.ui.Container
|
+--danger.ui.Control
|
+--danger.ui.DateTimeEditor
- public class DateTimeEditor
- extends Control
| Methods inherited from class danger.ui.Control |
drawFocusBox, drawIdleBox, drawIdleBox, getEvent, getEventListener, getEventType, getHasBorder, getString, getTitle, getValue, sendEvent, setEvent, setEvent, setEvent, setEvent, setEvent, setEventListener, setHasBorder, setTitle, setValue |
| Methods inherited from class danger.ui.Container |
addChild, addChild, addChildAt, advanceFocus, childCount, childIsOnScreen, eventKeyHeld, eventKeyRepeat, eventPeriodicPulse, eventShortcut, eventWidgetHeld, getBottomChild, getChildAt, getChildIndex, getChildWithID, getDescendantWithID, getFirstChild, getFirstFocusableChild, getFocusedChild, getLastChild, getLastFocusableChild, hideAllChildren, loseFocus, moveChildToIndex, paintChildren, reflowChildren, removeAllChildren, removeChild, reverseFocus, setFocusedChild, setFocusedChild, setWindow, showAllChildren, snapToChildren, takeFocus |
| Methods inherited from class danger.ui.View |
clear, copyStyle, getAcceptFocus, getBackgroundColor, getBottom, getBounds, getBounds, getFrame, getFrame, getHeight, getInterestingRect, getInterestingRect, getLeft, getOrigin, getOrigin, getOriginX, getOriginY, getParent, getRight, getSibling, getStyle, getStyleColor, getStyleFont, getTop, getWidth, getWindow, globalToLocal, hide, invalidate, invalidate, invalidate, isEnabled, isFocusable, isFocused, isOnScreen, isTransparent, isVisible, keepRectInView, localToGlobal, localToGlobal, localToWindow, moveBy, offsetOrigin, offsetOrigin, onAddedToParent, onDecoded, onPeriodicPulse, onRemovedFromParent, onStyleChanged, onWindowPaint, receiveEventInternal, resetOrigin, sendEventToWindow, setAcceptFocus, setBackgroundColor, setBottom, setDebugBounds, setEnabled, setFrame, setHeight, setKeyedValue, setLeft, setOrigin, setOrigin, setPosition, setRight, setStyle, setStyleColor, setStyleFont, setStyleFrameColor, setTop, setTransparent, setVisible, setWidth, shouldDropEvent, show, styleIsDefault, willFocusWithin, windowToLocal |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
mDate
protected danger.internal.Date mDate
mMaxDate
protected danger.internal.Date mMaxDate
mMinDate
protected danger.internal.Date mMinDate
mFormat
protected int mFormat
mLastKeyTime
protected int mLastKeyTime
mKeyString
protected java.lang.String mKeyString
mKeyInputAlarm
protected Alarm mKeyInputAlarm
mMonthTextView
protected StaticText mMonthTextView
mDayTextView
protected StaticText mDayTextView
mYearTextView
protected StaticText mYearTextView
mHourTextView
protected StaticText mHourTextView
mMinuteTextView
protected StaticText mMinuteTextView
mAMPMTextView
protected StaticText mAMPMTextView
mCommaTextView
protected StaticText mCommaTextView
kFormat_None
public static final int kFormat_None
kFormat_DateShort
public static final int kFormat_DateShort
kFormat_DateMedium
public static final int kFormat_DateMedium
kFormat_DateLong
public static final int kFormat_DateLong
kFormat_TimeLong
public static final int kFormat_TimeLong
STD_HEIGHT
protected static final int STD_HEIGHT
STD_WIDTH
protected static final int STD_WIDTH
DateTimeEditor
public DateTimeEditor()
DateTimeEditor
public DateTimeEditor(danger.internal.Date inDate)
DateTimeEditor
public DateTimeEditor(danger.internal.Date inDate,
int inFormat)
setDate
public void setDate(danger.internal.Date inDate)
setFormat
public void setFormat(int inFormat)
getDate
public danger.internal.Date getDate()
enforceLimitsAndUpdate
public void enforceLimitsAndUpdate()
enable
public void enable()
- Overrides:
enable in class Container
disable
public void disable()
- Overrides:
disable in class Container
layoutDate
protected void layoutDate()
layoutTime
protected void layoutTime()
reflowDateLayout
protected void reflowDateLayout(int inAmount)
update
protected void update()
setSize
public void setSize(int inWidth,
int inHeight)
- Overrides:
setSize in class View
receiveEvent
public boolean receiveEvent(Event e)
- Description copied from class:
Listener
- Entry point for event processing.
Default behaviour is to do nothing and return false.
Normally this method is called from a Dispatcher when it
discovers an Event in its queue that is targetted at this
Listener.
- Overrides:
receiveEvent in class Container
adjustPickerWindow
protected void adjustPickerWindow(PickerWindow pw,
View inAlignView)
showMonthPicker
protected void showMonthPicker()
showDayPicker
protected void showDayPicker()
showYearPicker
protected void showYearPicker()
showHourPicker
protected void showHourPicker()
showMinutePicker
protected void showMinutePicker()
showAMPMPicker
protected void showAMPMPicker()
getMonthString
protected java.lang.String getMonthString()
getMonthString
protected java.lang.String getMonthString(int inMonth)
paint
public void paint(Pen p)
- Description copied from class:
View
- Draw the contents of this View. This method is called by the graphics
system when the View needs to be repainted. A Pen will be provided which
is appropriately clipped and translated for drawing on this View.
- Overrides:
paint in class Container
drawBackground
protected final void drawBackground(Pen p,
Rect inRect)
eventKeyUp
public boolean eventKeyUp(char c,
Event event)
- Description copied from class:
Container
- Processes key releases directed at this container.
- Overrides:
eventKeyUp in class Container
- Following copied from class:
danger.ui.Container
- Parameters:
c - the character being released.
eventKeyDown
public boolean eventKeyDown(char c,
Event event)
- Overrides:
eventKeyDown in class Container
eventWidgetUp
public boolean eventWidgetUp(int widget,
Event event)
- Description copied from class:
Container
- Handle the release of a device widget
- Overrides:
eventWidgetUp in class Container
- Following copied from class:
danger.ui.Container
- Parameters:
inWidget - the widget that went down- Returns:
- whether or not the event was consumed
eventWidgetDown
public boolean eventWidgetDown(int widget,
Event event)
- Description copied from class:
Container
- Handle the pressing of a device widget
- Overrides:
eventWidgetDown in class Container
- Following copied from class:
danger.ui.Container
- Parameters:
inWidget - the widget that went up- Returns:
- whether or not the event was consumed
max
public final void max(danger.internal.Date inMaxDate)
min
public final void min(danger.internal.Date inMinDate)
limitToUnixEpoch
public final void limitToUnixEpoch()
limitToDangerEpoch
public final void limitToDangerEpoch()
enforceMinLimit
protected final void enforceMinLimit()
enforceMaxLimit
protected final void enforceMaxLimit()
Danger Confidential. Copyright © 2000-2003, Danger Inc.