AjaxTabbedPanel Class Reference

Inherits er::ajax::AjaxDynamicElement.

Collaboration diagram for AjaxTabbedPanel:

Collaboration graph
[legend]

List of all members.

Public Member Functions

 AjaxTabbedPanel (String name, NSDictionary associations, WOElement template)
void appendToResponse (WOResponse response, WOContext context)
WOActionResults handleRequest (WORequest request, WOContext context)

Protected Member Functions

void addRequiredWebResources (WOResponse response, WOContext context)

Private Member Functions

void findTabs (WODynamicGroup template)

Private Attributes

WOAssociation busyDiv
WOElement content
WOAssociation id
WOAssociation onLoad
WOAssociation onSelect
NSMutableArray tabs = new NSMutableArray()


Detailed Description

This implements the tabs and the main control of a tabbed panel display as an unordered list (UL and LI elements). The tab contents go in AjaxTabbedPanel components contained within this component. The tab contents are loaded on demand so only the selected tab is rendered when the page is displayed. If tabs can take a while to load, a hidden div containing a "working" message can temporarily replace the panel content while it loads.

CSS Classes Used by AjaxTabbedPanel and AjaxTabbedPanelTab

Class Name Used For
ajaxTabbedPanel The UL containing the tabs.
ajaxTabbedPanelTab-selected The LI representing the selected tab and the A element that is the clickable title.
ajaxTabbedPanelTab-unselected The LI representing the selected tab(s) and the A element that is the clickable title.
ajaxTabbedPanelPanes The UL containing the panels (panes).
ajaxTabbedPanelPane-selected The LI representing the selected panel.
ajaxTabbedPanelPane-unselected The LI representing the unselected panel(s). </table

id required, String the id of the UL that wraps the tabs busyDiv optional, String the id of a div that should be shown when a tab is loading onLoad optional, String JavaScript to execute after the whole tabbed panel loads onSelect optional, String JavaScript to execute after a different tab is selected. This will not get called when this is first rendered. Use onLoad if you need that.

Author:
Chuck Hill


Constructor & Destructor Documentation

AjaxTabbedPanel ( String  name,
NSDictionary  associations,
WOElement  template 
)


Member Function Documentation

void addRequiredWebResources ( WOResponse  response,
WOContext  context 
) [protected, virtual]

Override this method to append the needed scripts for this component.

Implements AjaxDynamicElement.

void appendToResponse ( WOResponse  response,
WOContext  context 
)

Creates the tabs and pane control.

Reimplemented from AjaxDynamicElement.

void findTabs ( WODynamicGroup  template  )  [private]

Looks through the child components to locate the AjaxTabbedPanelTabs that are controlled by this panel. Tabs without an explicit id attributed are assigned a calculated one.

Parameters:
template the graph of elements passed to the constructor.

WOActionResults handleRequest ( WORequest  request,
WOContext  context 
) [virtual]

Override this method to return the response for an Ajax request.

Parameters:
request 
context 

Implements AjaxDynamicElement.


Member Data Documentation

WOAssociation busyDiv [private]

WOElement content [private]

WOAssociation id [private]

WOAssociation onLoad [private]

WOAssociation onSelect [private]

NSMutableArray tabs = new NSMutableArray() [private]


The documentation for this class was generated from the following file:

Generated on Sat May 26 06:42:40 2012 for Project Wonder by  doxygen 1.5.8