| Package | com.rubenswieringa.book |
| Class | public class PageManager |
| Inheritance | PageManager mx.containers.Canvas |
| Subclasses | Book |
See also
| Property | Defined by | ||
|---|---|---|---|
| currentPage : int [write-only]
Index of the current left-hand page (-1 if the Book is unopened).
| PageManager | ||
| openAt : int
Index of the Page at which the Book is opened at startup, can only be set once, and only at startup.
| PageManager | ||
| pages : ArrayCollection [write-only]
Array of all respective Pages in this Book instance.
| PageManager | ||
| Method | Defined by | ||
|---|---|---|---|
|
Constructor.
| PageManager | ||
|
addChild(child:DisplayObject):DisplayObject
Adds a child Page instance to this PageManager instance.
| PageManager | ||
|
addChildAt(child:DisplayObject, index:int):DisplayObject
Adds a child Page instance to this PageManager instance at the index position specified.
| PageManager | ||
|
contains(child:DisplayObject):Boolean
Determines whether the specified display object is a child of the PageManager instance or the instance itself.
| PageManager | ||
|
getChildByName(name:String):DisplayObject
Returns the child display object that exists with the specified name.
| PageManager | ||
|
getChildIndex(child:DisplayObject):int
Returns the index position of a child Page instance.
| PageManager | ||
|
getChildren():Array
Returns an Array of Page objects consisting of the content children of the container.
| PageManager | ||
|
getObjectsUnderPoint(point:Point):Array
Returns an array of objects that lie under the specified point and are children (or grandchildren, and so on) of this PageManager instance.
| PageManager | ||
|
owns(child:DisplayObject):Boolean
Returns true if the chain of owner properties points from child to this PageManager.
| PageManager | ||
|
removeAllChildren():void
Removes all children (Page instances) from the child list of this container.
| PageManager | ||
|
removeChild(child:DisplayObject):DisplayObject
Removes a child Page from the child list of this Container.
| PageManager | ||
|
removeChildAt(index:int):DisplayObject
Removes a child Page from the child list of this Container at the specified index.
| PageManager | ||
|
setChildIndex(child:DisplayObject, newIndex:int):void
Changes the position of an existing child in the PageManager container.
| PageManager | ||
|
swapChildren(child1:DisplayObject, child2:DisplayObject):void
Swaps the position of two Page instances in the PageManager.
| PageManager | ||
|
swapChildrenAt(index1:int, index2:int):void
Swaps the position of two Page instances in the PageManager at the specified indexes.
| PageManager | ||
| Event | Summary | Defined by | ||
|---|---|---|---|---|
| Dispatched when a page is added to or removed from the PageManager. | PageManager | |||
| currentPage | property |
currentPage:int [write-only]Index of the current left-hand page (-1 if the Book is unopened).
This property can be used as the source for data binding.
Implementation public function set currentPage(value:int):void
| openAt | property |
openAt:int [read-write]Index of the Page at which the Book is opened at startup, can only be set once, and only at startup.
The default value is -1.
public function get openAt():int
public function set openAt(value:int):void
| pages | property |
pages:ArrayCollection [write-only]Array of all respective Pages in this Book instance.
This property can be used as the source for data binding.
Implementation public function set pages(value:ArrayCollection):void
| PageManager | () | constructor |
public function PageManager()Constructor.
| addChild | () | method |
public override function addChild(child:DisplayObject):DisplayObjectAdds a child Page instance to this PageManager instance. Regardless of this method's signiature, the child parameter must always be an instance of the Page class.
Parameterschild:DisplayObject — The Page instance to add as a child of this PageManager instance.
|
DisplayObject — The Page instance that you pass in the child parameter.
|
— Gets thrown when the child parameter is not an instance of the Page class.
|
See also
| addChildAt | () | method |
public override function addChildAt(child:DisplayObject, index:int):DisplayObjectAdds a child Page instance to this PageManager instance at the index position specified.
Parameterschild:DisplayObject — The Page instance to add as a child of this PageManager instance.
|
|
index:int — The index position to which the child is added.
|
DisplayObject — The Page instance that you pass in the child parameter.
|
— Gets thrown when the child parameter is not an instance of the Page class.
|
See also
| contains | () | method |
public override function contains(child:DisplayObject):BooleanDetermines whether the specified display object is a child of the PageManager instance or the instance itself.
Parameterschild:DisplayObject — The child object to test.
|
Boolean — true if the child object is a child of the PageManager or the container itself; otherwise false.
|
| getChildByName | () | method |
public override function getChildByName(name:String):DisplayObjectReturns the child display object that exists with the specified name.
Parametersname:String — The name of the child to return.
|
DisplayObject — The child Page with the specified name as a DisplayObject. You may want to cast the return value of this method back to a Page.
|
| getChildIndex | () | method |
public override function getChildIndex(child:DisplayObject):intReturns the index position of a child Page instance.
Parameterschild:DisplayObject — The Page instance to identify.
|
int — The index position of the child Page to identify.
|
| getChildren | () | method |
public override function getChildren():ArrayReturns an Array of Page objects consisting of the content children of the container. Note that this method returns the source property of the pages property.
ReturnsArray — Array of Page objects consisting of the content children of the container.
|
See also
| getObjectsUnderPoint | () | method |
public override function getObjectsUnderPoint(point:Point):ArrayReturns an array of objects that lie under the specified point and are children (or grandchildren, and so on) of this PageManager instance.
Parameterspoint:Point — The point under which to look.
|
Array — An array of objects that lie under the specified point and are children (or grandchildren, and so on) of this PageManager instance.
|
| owns | () | method |
public override function owns(child:DisplayObject):BooleanReturns true if the chain of owner properties points from child to this PageManager.
Parameterschild:DisplayObject — A UIComponent.
|
Boolean — true if the child is parented or owned by this PageManager.
|
| removeAllChildren | () | method |
public override function removeAllChildren():voidRemoves all children (Page instances) from the child list of this container.
| removeChild | () | method |
public override function removeChild(child:DisplayObject):DisplayObjectRemoves a child Page from the child list of this Container.
Parameterschild:DisplayObject — The Page instance to remove.
|
DisplayObject — The removed child.
|
— Gets thrown when the child parameter is not an instance of the Page class.
|
|
— Gets thrown when the child parameter is not a child of this PageManager.
|
See also
| removeChildAt | () | method |
public override function removeChildAt(index:int):DisplayObjectRemoves a child Page from the child list of this Container at the specified index.
Parametersindex:int — The child index of the Page to remove.
|
DisplayObject — The removed child.
|
— Gets thrown when the supplied index is out of bounds.
|
See also
| setChildIndex | () | method |
public override function setChildIndex(child:DisplayObject, newIndex:int):voidChanges the position of an existing child in the PageManager container.
Parameterschild:DisplayObject — The child Page instance for which you want to change the index number.
|
|
newIndex:int — The resulting index number for the child display object.
|
— Gets thrown when the child parameter is not an instance of the Page class.
|
|
— Gets thrown when the child parameter is not a child of this PageManager.
|
See also
| swapChildren | () | method |
public override function swapChildren(child1:DisplayObject, child2:DisplayObject):voidSwaps the position of two Page instances in the PageManager.
Parameterschild1:DisplayObject — The first child object.
|
|
child2:DisplayObject — The second child object.
|
— Gets thrown when the child parameter is not an instance of the Page class.
|
|
— Gets thrown when the child parameter is not a child of this PageManager.
|
See also
| swapChildrenAt | () | method |
public override function swapChildrenAt(index1:int, index2:int):voidSwaps the position of two Page instances in the PageManager at the specified indexes.
Parametersindex1:int — The index position of the first child object.
|
|
index2:int — The index position of the second child object.
|
| contentChanged | event |
com.rubenswieringa.book.BookEvent
Dispatched when a page is added to or removed from the PageManager.
See also