KoolMoves AS3 API Documentation | All Packages | All Classes | Index | Frames No Frames |
Class DateChooser

Package | km.components
Class | public class DateChooser
Inheritance | DateChooser UIComponent flash.display.Sprite

The DateChooser component class.

Example

    import km.components.*;

    var dc:DateChooser = new DateChooser();
    dc.duotone = [0x402000,0xfff8f0];
    dc.move(20,20);
    addChild(dc);

Public Properties
Hide Inherited Public Properties
Show Inherited Public Properties

| Property | Defined by
--- | --- | ---
|  | duotone : Array The duotone property can be used to convert the colors of the component into duotone. | UIComponent
|  | enabled : Boolean Specifies if the component is enabled. If a component is disabled, it will be turned into grayscale and become partly transparent. | UIComponent
|  | firstDayOfWeek : int [write-only] Sets the first day of a week (0 = Sunday, 1 = Monday). | DateChooser
|  | onChange : Function onChange handler. | DateChooser
|  | selectedDay : int [read-only] | DateChooser
|  | selectedMonth : int [read-only] | DateChooser
|  | selectedWeekday : int [read-only] The selected day of the week. The range of this value is 0 - 6 (0 = Sunday, 6 = Saturday). | DateChooser
|  | selectedYear : int [read-only] | DateChooser
|  | size : int [write-only] Sets the component size (0 = small, 1 = normal, 2 = large). | DateChooser
|  | toolTip : String Text to use as toolTip when ToolTip is enabled. | UIComponent
|  | x : Number | UIComponent
|  | y : Number | UIComponent

Public Methods
Hide Inherited Public Methods
Show Inherited Public Methods

| Method | Defined by
--- | --- | ---
|  | DateChooser() | DateChooser
|  | addHighlight(year:int, month:int, day:int, style:int = 0):void Add a highlight. style is optional and can be 0, 1 or 2. | DateChooser
|  | move(x:int, y:int, animationMode:int = 0, animationFrames:int = 12, easeInOut:Boolean = false):void Moves the component to the specified coordinates. | UIComponent
|  | removeAll():void Remove all highlights. | DateChooser
|  | setProperties(o:Object):void Sets a number of properties at once. | UIComponent
|  | setSelectedDate(year:int, month:int, day:int):void | DateChooser
|  | showMonth(year:int, month:int = 1):void Sets the month to be shown. | DateChooser

Events
Hide Inherited Events
Show Inherited Events

| Event | Summary | Defined by
--- | --- | --- | ---
|  | animationComplete | The animationComplete event is broadcasted when an animated move is completed. | UIComponent
|  | change | The change event is broadcasted when a new date is selected. It's also possible to use the onChange handler. | DateChooser

Property detail

firstDayOfWeek | property

`firstDayOfWeek:int` [write-only]

Sets the first day of a week (0 = Sunday, 1 = Monday).

Implementation
`public function set firstDayOfWeek(value:int):void`

onChange | property |

`public var onChange:Function`

onChange handler.

selectedDay | property |

`selectedDay:int` [read-only]

Implementation
`public function get selectedDay():int`

selectedMonth | property |

`selectedMonth:int` [read-only]

Implementation
`public function get selectedMonth():int`

selectedWeekday | property |

`selectedWeekday:int` [read-only]

The selected day of the week.
The range of this value is 0 - 6 (0 = Sunday, 6 = Saturday).

Implementation
`public function get selectedWeekday():int`

selectedYear | property |

`selectedYear:int` [read-only]

Implementation
`public function get selectedYear():int`

size | property |

`size:int` [write-only]

Sets the component size (0 = small, 1 = normal, 2 = large).

Implementation
`public function set size(value:int):void`
Constructor detail

DateChooser | () | constructor

`public function DateChooser()`
Method detail

addHighlight | () | method

`public function addHighlight(year:int, month:int, day:int, style:int = 0):void`

Add a highlight.
style is optional and can be 0, 1 or 2.

Parameters

| `year:int`
| `month:int`
| `day:int`
| `style:int` (default = `0`)``

removeAll | () | method |

`public function removeAll():void`

Remove all highlights.

setSelectedDate | () | method |

`public function setSelectedDate(year:int, month:int, day:int):void`

Parameters

| `year:int`
| `month:int`
| `day:int`

showMonth | () | method |

`public function showMonth(year:int, month:int = 1):void`

Sets the month to be shown.

Parameters

| `year:int`
| `month:int` (default = `1`)``

Event detail

change | event

Event object type: `flash.events.Event`

The change event is broadcasted when a new date is selected.
It's also possible to use the onChange handler.

Last update : 04/05/2008