PhpExt : Menu [ class tree ] [ index ] [ all elements ]

Class: PhpExt_Menu_BaseItem

Source Location: /PhpExt/Menu/BaseItem.php

Class PhpExt_Menu_BaseItem

Class Overview

The base class for all items that render into menus. BaseItem provides default rendering, activated state management and base configuration options shared by all menu components.

Located in /PhpExt/Menu/BaseItem.php [line 29]

PhpExt_Object
   |
   --PhpExt_Observable
      |
      --PhpExt_Component
         |
         --PhpExt_Menu_BaseItem

Properties

Methods

[ Top ]
Descendants
Child Class Description
PhpExt_Menu_Adapter A base utility class that adapts a non-menu component so that it can be wrapped by a menu item and added to a menu. It provides basic rendering, activation management and enable/disable logic required to work in menus.
PhpExt_Menu_Item A base class for all menu items that require menu-related functionality (like sub-menus) and are not static display items.
PhpExt_Menu_Separator Adds a separator bar to a menu, used to divide logical groups of menu items.
PhpExt_Menu_TextItem Adds a static text string to a menu, usually used as either a heading or group separator.

[ Top ]
Inherited Properties, Constants, and Methods
Inherited Properties Inherited Methods Inherited Constants

Inherited From PhpExt_Component

PhpExt_Component::$_layoutData
PhpExt_Component::$_ownerCollection
PhpExt_Component::$_plugins
PhpExt_Component::$_xType

Inherited From PhpExt_Observable

PhpExt_Observable::$_listeners

Inherited From PhpExt_Object

PhpExt_Object::$_extClassName
PhpExt_Object::$_extConfigProperties
PhpExt_Object::$_validExtConfigProperties
PhpExt_Object::$_varName

Inherited From PhpExt_Component

PhpExt_Component::__construct()
** Overrides ***
PhpExt_Component::getAllowDomMove()
Whether the component can move the Dom node when rendering (defaults to true).
PhpExt_Component::getApplyTo()
The id of the node, a DOM node or an existing Element corresponding to a DIV that is already present in the document that specifies some structural markup for this component. When applyTo is used, constituent parts of the component can also be specified by id or CSS class name within the main element, and the component being created may attempt to create its subcomponents from that markup if applicable. Using this config, a call to render() is not required. If applyTo is specified, any value passed for renderTo will be ignored and the target element's parent node will automatically be used as the component's container.
PhpExt_Component::getAutoShow()
True if the component should check for hidden classes (e.g. 'x-hidden' or 'x-hide-display') and remove them on render (defaults to false).
PhpExt_Component::getConfigParams()
PhpExt_Component::getContainerCssClass()
An optional extra CSS class that will be added to this component's container (defaults to ''). This can be useful for adding customized styles to the container or any of its children using standard CSS rules.
PhpExt_Component::getCssClass()
An optional extra CSS class that will be added to this component's Element (defaults to ''). This can be useful for adding customized styles to the component or any of its children using standard CSS rules.
PhpExt_Component::getCssStyle()
A custom style specification to be applied to this component's Element.
PhpExt_Component::getDisabledCssClass()
CSS class added to the component when it is disabled (defaults to "x-item-disabled").
PhpExt_Component::getEl()
The DOM element to which this component show be rendered to. This should be used instead of renderTo or applyTo if using lazy render.
PhpExt_Component::getHideMode()
How this component should hidden. Supported values are
  1. PhpExt_Component::HIDE_MODE_VISIBILITY
(css visibility),
  1. PhpExt_Component::HIDE_MODE_OFFSETS
(negative offset position) and
  1. PhpExt_Component::HIDE_MODE_DISPLAY
(css display) - defaults to
  1. PhpExt_Component::HIDE_MODE_DISPLAY
.
PhpExt_Component::getHideParent()
True to hide and show the component's container when hide/show is called on the component, false to hide and show the component itself (defaults to false). For example, this can be used as a shortcut for a hide button on a window by setting hide:true on the button when adding it to its parent container.
PhpExt_Component::getId()
The unique id of this component (defaults to an auto-assigned id).
PhpExt_Component::getLayoutData()
PhpExt_Component::getOwnerCollection()
PhpExt_Component::getPlugins()
An object or array of objects that will provide custom functionality for this component. The only requirement for a valid plugin is that it contain an init method that accepts a reference of type Ext.Component. When a component is created, if any plugins are available, the component will call the init method on each plugin, passing a reference to itself. Each plugin can then call methods or respond to events on the component as needed to provide its functionality.
PhpExt_Component::getRenderTo()
The id of the node, a DOM node or an existing Element that will be the container to render this component into. Using this config, a call to render() is not required.
PhpExt_Component::render()
** Ext Object Methods ***
PhpExt_Component::setAllowDomMove()
Whether the component can move the Dom node when rendering (defaults to true).
PhpExt_Component::setApplyTo()
The id of the node, a DOM node or an existing Element corresponding to a DIV that is already present in the document that specifies some structural markup for this component. When applyTo is used, constituent parts of the component can also be specified by id or CSS class name within the main element, and the component being created may attempt to create its subcomponents from that markup if applicable. Using this config, a call to render() is not required. If applyTo is specified, any value passed for renderTo will be ignored and the target element's parent node will automatically be used as the component's container.
PhpExt_Component::setAutoShow()
True if the component should check for hidden classes (e.g. 'x-hidden' or 'x-hide-display') and remove them on render (defaults to false).
PhpExt_Component::setContainerCssClass()
An optional extra CSS class that will be added to this component's container (defaults to ''). This can be useful for adding customized styles to the container or any of its children using standard CSS rules.
PhpExt_Component::setCssClass()
An optional extra CSS class that will be added to this component's Element (defaults to ''). This can be useful for adding customized styles to the component or any of its children using standard CSS rules.
PhpExt_Component::setCssStyle()
A custom style specification to be applied to this component's Element.
PhpExt_Component::setDisabledCssClass()
CSS class added to the component when it is disabled (defaults to "x-item-disabled").
PhpExt_Component::setEl()
The DOM element to which this component show be rendered to. This should be used instead of renderTo or applyTo if using lazy render.
PhpExt_Component::setExtClassInfo()
PhpExt_Component::setHideMode()
How this component should hidden. Supported values are
  1. PhpExt_Component::HIDE_MODE_VISIBILITY
(css visibility),
  1. PhpExt_Component::HIDE_MODE_OFFSETS
(negative offset position) and
  1. PhpExt_Component::HIDE_MODE_DISPLAY
(css display) - defaults to
  1. PhpExt_Component::HIDE_MODE_DISPLAY
.
PhpExt_Component::setHideParent()
True to hide and show the component's container when hide/show is called on the component, false to hide and show the component itself (defaults to false). For example, this can be used as a shortcut for a hide button on a window by setting hide:true on the button when adding it to its parent container.
PhpExt_Component::setId()
The unique id of this component (defaults to an auto-assigned id).
PhpExt_Component::setLayoutData()
Layout specific properties for the corresponding layout of the container.
PhpExt_Component::setOwnerCollection()
PhpExt_Component::setRenderTo()
The id of the node, a DOM node or an existing Element that will be the container to render this component into. Using this config, a call to render() is not required.

Inherited From PhpExt_Observable

PhpExt_Observable::__construct()
PhpExt_Observable::attachListener()
Adds a PhpExt_Listener to the specified $eventName. This lintener will execute when the Javascript object fires that event.
PhpExt_Observable::getConfigParams()
PhpExt_Observable::getListeners()

Inherited From PhpExt_Object

PhpExt_Object::__construct()
PhpExt_Object::addValidConfigProperties()
PhpExt_Object::createMethodSignature()
PhpExt_Object::getConfigParams()
PhpExt_Object::getExtConfigProperty()
PhpExt_Object::getJavascript()
PhpExt_Object::getMethodInvokeStm()
PhpExt_Object::isExtObject()
PhpExt_Object::paramToString()
PhpExt_Object::setExtClassInfo()
PhpExt_Object::setExtConfigProperty()
PhpExt_Object::__get()
PhpExt_Object::__set()

Inherited From PhpExt_Component

PhpExt_Component::HIDE_MODE_DISPLAY
PhpExt_Component::HIDE_MODE_OFFSETS
PhpExt_Component::HIDE_MODE_VISIBILITY

[ Top ]
Method Summary
PhpExt_Menu_BaseItem   __construct()  
PhpExt_Menu_Menu   addCheckItem()   Helper function to quick add a checkitem
PhpExt_Menu_Menu   addSeparator()   Helper function to quick add a separator
PhpExt_Menu_Menu   addSubItem()   Helper function to quick add an item
PhpExt_Menu_Menu   addTextItem()   Helper function to quick add a textitem
string   getActiveCssClass()   The CSS class to use when the item becomes activated (defaults to "x-menu-item-active")
boolean   getCanActivate()   True if this item can be visually activated (defaults to false)
void   getConfigParams()  
PhpExt_Handler|PhpExt_JavascriptStm   getHandler()   A function that will handle the click event of this menu item (defaults to undefined)
integer   getHideDelay()   Length of time in milliseconds to wait before hiding after a click (defaults to 100)
boolean   getHideOnClick()   True to hide the containing menu after this item is clicked (defaults to true)
PhpExt_Menu_BaseItemCollection   getItems()   An array of items to be added to this menu. See add for a list of valid item types.
PhpExt_JavascriptStm   getScope()   The scope in which the handler function will be called.
PhpExt_Menu_BaseItem   setActiveCssClass()   The CSS class to use when the item becomes activated (defaults to "x-menu-item-active")
PhpExt_Menu_BaseItem   setCanActivate()   True if this item can be visually activated (defaults to false)
PhpExt_Menu_BaseItem   setHandler()   A function that will handle the click event of this menu item (defaults to undefined)
PhpExt_Menu_BaseItem   setHideDelay()   Length of time in milliseconds to wait before hiding after a click (defaults to 100)
PhpExt_Menu_BaseItem   setHideOnClick()   True to hide the containing menu after this item is clicked (defaults to true)
PhpExt_Menu_BaseItem   setScope()   The scope in which the handler function will be called.

[ Top ]
Properties
PhpExt_Menu_BaseItemCollection   $_items [line 143]
API Tags:
Access:  protected


[ Top ]
Methods
addCheckItem  [line 163]

  PhpExt_Menu_Menu addCheckItem( $key, $text, [ $handler = null]  )

Helper function to quick add a checkitem

Parameters:
   $key: 
   $text: 
   $handler: 

API Tags:
Access:  public


[ Top ]
addSeparator  [line 155]

  PhpExt_Menu_Menu addSeparator( $key  )

Helper function to quick add a separator

Parameters:
   $key: 

API Tags:
Access:  public


[ Top ]
addSubItem  [line 179]

  PhpExt_Menu_Menu addSubItem( $key, PhpExt_Menu_BaseItem $item  )

Helper function to quick add an item

Parameters:
   $key: 
PhpExt_Menu_BaseItem   $item: 

API Tags:
Access:  public


[ Top ]
addTextItem  [line 171]

  PhpExt_Menu_Menu addTextItem( $key, $text, [ $handler = null]  )

Helper function to quick add a textitem

Parameters:
   $key: 
   $text: 
   $handler: 

API Tags:
Access:  public


[ Top ]
getActiveCssClass  [line 45]

  string getActiveCssClass( )

The CSS class to use when the item becomes activated (defaults to "x-menu-item-active")


API Tags:
Access:  public


[ Top ]
getCanActivate  [line 63]

  boolean getCanActivate( )

True if this item can be visually activated (defaults to false)


API Tags:
Access:  public


Redefined in descendants as:

[ Top ]
getConfigParams  [line 202]

  void getConfigParams( [ $lazy = false]  )

Parameters:
   $lazy: 

API Tags:
Access:  protected


Redefinition of:
PhpExt_Component::getConfigParams()

[ Top ]
getHandler  [line 81]

A function that will handle the click event of this menu item (defaults to undefined)


API Tags:
Access:  public


[ Top ]
getHideDelay  [line 99]

  integer getHideDelay( )

Length of time in milliseconds to wait before hiding after a click (defaults to 100)


API Tags:
Access:  public


[ Top ]
getHideOnClick  [line 117]

  boolean getHideOnClick( )

True to hide the containing menu after this item is clicked (defaults to true)


API Tags:
Access:  public


Redefined in descendants as:

[ Top ]
getItems  [line 148]

An array of items to be added to this menu. See add for a list of valid item types.


API Tags:
Access:  public


[ Top ]
getScope  [line 135]

  PhpExt_JavascriptStm getScope( )

The scope in which the handler function will be called.


API Tags:
Access:  public


[ Top ]
setActiveCssClass  [line 37]

  PhpExt_Menu_BaseItem setActiveCssClass( string $value  )

The CSS class to use when the item becomes activated (defaults to "x-menu-item-active")

Parameters:
string   $value: 

API Tags:
Access:  public


[ Top ]
setCanActivate  [line 55]

  PhpExt_Menu_BaseItem setCanActivate( boolean $value  )

True if this item can be visually activated (defaults to false)

Parameters:
boolean   $value: 

API Tags:
Access:  public


Redefined in descendants as:

[ Top ]
setHandler  [line 73]

A function that will handle the click event of this menu item (defaults to undefined)

Parameters:
PhpExt_Handler|PhpExt_JavascriptStm   $value: 

API Tags:
Access:  public


[ Top ]
setHideDelay  [line 91]

  PhpExt_Menu_BaseItem setHideDelay( integer $value  )

Length of time in milliseconds to wait before hiding after a click (defaults to 100)

Parameters:
integer   $value: 

API Tags:
Access:  public


[ Top ]
setHideOnClick  [line 109]

  PhpExt_Menu_BaseItem setHideOnClick( boolean $value  )

True to hide the containing menu after this item is clicked (defaults to true)

Parameters:
boolean   $value: 

API Tags:
Access:  public


Redefined in descendants as:

[ Top ]
setScope  [line 127]

  PhpExt_Menu_BaseItem setScope( PhpExt_JavascriptStm $value  )

The scope in which the handler function will be called.

Parameters:
PhpExt_JavascriptStm   $value: 

API Tags:
Access:  public


[ Top ]

Documentation generated on Fri, 08 Aug 2008 15:50:15 -0500 by phpDocumentor 1.4.0