ModuleMenu Class Reference

List of all members.

Public Member Functions

 __construct ()
 setBackPath ($backPath)
 getLoadedModules ()
 saveMenuState ($params, &$ajaxObj)
 render ($wrapInUl=true)
 renderAjax ($params=array(), TYPO3AJAX &$ajaxObj=null)
 renderSubModules ($modules, $menuState=false)
 getRawModuleData ()
 getGotoModuleJavascript ()
 renderLogoutButton ()
 setLinkModules ($linkModules)
 getFsMod ()

Protected Member Functions

 getCollapsedStates ()
 getModuleIcon ($moduleKey)
 getModuleIconAbsolute ($iconFilename)
 getModuleIconRelative ($iconFilename)
 getNavigationFramePrefix ($moduleData, $subModuleData=array())
 appendQuestionmarkToLink ($link)

Protected Attributes

 $moduleLoader
 $backPath
 $linkModules
 $loadedModules
 $fsMod

Detailed Description

Definition at line 40 of file class.modulemenu.php.


Constructor & Destructor Documentation

ModuleMenu::__construct (  ) 

constructor, initializes several variables

Returns:
void

Definition at line 59 of file class.modulemenu.php.

References $GLOBALS, and t3lib_div::makeInstance().


Member Function Documentation

ModuleMenu::appendQuestionmarkToLink ( link  )  [protected]

Appends a '?' if there is none in the string already

Parameters:
string Link URL
Returns:
string link URl appended with ? if there wasn't one

Definition at line 499 of file class.modulemenu.php.

Referenced by getGotoModuleJavascript(), and getNavigationFramePrefix().

ModuleMenu::getCollapsedStates (  )  [protected]

loads the collapse states for the main modules from user's configuration (uc)

Returns:
array collapse states

Definition at line 92 of file class.modulemenu.php.

References $GLOBALS.

ModuleMenu::getFsMod (  ) 

gets the frameset (leftover) helper

Returns:
array array of javascript snippets

Definition at line 541 of file class.modulemenu.php.

ModuleMenu::getGotoModuleJavascript (  ) 

generates javascript code to switch between modules

Returns:
string javascript code snippet to switch modules

Definition at line 397 of file class.modulemenu.php.

References $GLOBALS, appendQuestionmarkToLink(), getRawModuleData(), and t3lib_div::resolveBackPath().

Referenced by renderAjax().

ModuleMenu::getLoadedModules (  ) 

returns the loaded modules

Returns:
array array of loaded modules

Definition at line 107 of file class.modulemenu.php.

ModuleMenu::getModuleIcon ( moduleKey  )  [protected]

gets the module icon and its size

Parameters:
string module key
Returns:
array icon data array with 'filename', 'size', and 'html'

Definition at line 306 of file class.modulemenu.php.

References $GLOBALS, getModuleIconAbsolute(), and getModuleIconRelative().

Referenced by getRawModuleData().

ModuleMenu::getModuleIconAbsolute ( iconFilename  )  [protected]

Returns the filename readable for the script from PATH_typo3. That means absolute names are just returned while relative names are prepended with the path pointing back to typo3/ dir

Parameters:
string icon filename
Returns:
string icon filename with absolute path
See also:
getModuleIconRelative()

Definition at line 330 of file class.modulemenu.php.

References t3lib_div::isAbsPath().

Referenced by getModuleIcon().

ModuleMenu::getModuleIconRelative ( iconFilename  )  [protected]

Returns relative path to the icon filename for use in img-tags

Parameters:
string icon filename
Returns:
string icon filename with relative path
See also:
getModuleIconAbsolute()

Definition at line 346 of file class.modulemenu.php.

References t3lib_div::isAbsPath().

Referenced by getModuleIcon().

ModuleMenu::getNavigationFramePrefix ( moduleData,
subModuleData = array() 
) [protected]

Returns a prefix used to call the navigation frame with parameters which then will call the scripts defined in the modules info array.

Parameters:
array module data array
array submodule data array
Returns:
string result URL string

Definition at line 361 of file class.modulemenu.php.

References $GLOBALS, appendQuestionmarkToLink(), and t3lib_div::resolveBackPath().

Referenced by getRawModuleData().

ModuleMenu::getRawModuleData (  ) 

gets the raw module data

Returns:
array multi dimension array with module data

Definition at line 221 of file class.modulemenu.php.

References $GLOBALS, getModuleIcon(), getNavigationFramePrefix(), and t3lib_div::resolveBackPath().

Referenced by getGotoModuleJavascript(), and render().

ModuleMenu::render ( wrapInUl = true  ) 

renders the backend menu as unordered list

Parameters:
boolean optional parameter used to switch wrapping the menu in ul tags off for AJAX calls
Returns:
string menu html code to use in the backend

Definition at line 132 of file class.modulemenu.php.

References $GLOBALS, getRawModuleData(), and renderSubModules().

Referenced by renderAjax().

ModuleMenu::renderAjax ( params = array(),
TYPO3AJAX &$  ajaxObj = null 
)

renders the backend menu as unordered list as an AJAX response without the wrapping ul tags

Parameters:
array array of parameters from the AJAX interface, currently unused
TYPO3AJAX object of type TYPO3AJAX
Returns:
void

Definition at line 167 of file class.modulemenu.php.

References $ajaxObj, getGotoModuleJavascript(), and render().

ModuleMenu::renderLogoutButton (  ) 

renders the logout button form

Returns:
string html code snippet displaying the logout button

Definition at line 512 of file class.modulemenu.php.

References $GLOBALS.

ModuleMenu::renderSubModules ( modules,
menuState = false 
)

renders submodules

Parameters:
array array of (sub)module data
boolean collapse state of menu item, defaults to false
Returns:
string (sub)module html code

Definition at line 188 of file class.modulemenu.php.

References $GLOBALS.

Referenced by render().

ModuleMenu::saveMenuState ( params,
&$  ajaxObj 
)

saves the menu's toggle state in the backend user's uc

Parameters:
array array of parameters from the AJAX interface, currently unused
TYPO3AJAX object of type TYPO3AJAX
Returns:
void

Definition at line 118 of file class.modulemenu.php.

References $GLOBALS, and t3lib_div::_POST().

ModuleMenu::setBackPath ( backPath  ) 

sets the path back to /typo3/

Parameters:
string path back to /typo3/
Returns:
void

Definition at line 79 of file class.modulemenu.php.

References $backPath.

ModuleMenu::setLinkModules ( linkModules  ) 

turns linking of modules on or off

Parameters:
boolean status for linking modules with a-tags, set to false to turn lining off

Definition at line 528 of file class.modulemenu.php.

References $linkModules.


Member Data Documentation

ModuleMenu::$backPath [protected]

Definition at line 49 of file class.modulemenu.php.

Referenced by setBackPath().

ModuleMenu::$fsMod [protected]

Definition at line 52 of file class.modulemenu.php.

ModuleMenu::$linkModules [protected]

Definition at line 50 of file class.modulemenu.php.

Referenced by setLinkModules().

ModuleMenu::$loadedModules [protected]

Definition at line 51 of file class.modulemenu.php.

ModuleMenu::$moduleLoader [protected]

Definition at line 47 of file class.modulemenu.php.


The documentation for this class was generated from the following file:
Generated on Sat Nov 29 04:23:31 2008 for TYPO3 API by  doxygen 1.4.7