Extends Zend_Dojo_Form_Element_Editor to implement functionality that allows the user to define extra plugins via the options.
More...
List of all members.
Detailed Description
Extends Zend_Dojo_Form_Element_Editor to implement functionality that allows the user to define extra plugins via the options.
- Copyright:
- 2011-2012 Perforce Software. All rights reserved
- License:
- Please see LICENSE.txt in top-level folder of this distribution.
- Version:
- 2012.2/486814
Member Function Documentation
Content_Form_Element_Editor::addExtraPlugin |
( |
$ |
plugin | ) |
|
Add a single editor extra plugin.
- Parameters:
-
- Returns:
- Zend_Dojo_Form_Element_Editor
{
$plugin = (string) $plugin;
if ($this->hasExtraPlugin($plugin)) {
return $this;
}
$plugins = $this->getExtraPlugins();
$plugins[] = $plugin;
$this->setDijitParam('extraPlugins', $plugins);
return $this;
}
Content_Form_Element_Editor::addExtraPlugins |
( |
array $ |
plugins | ) |
|
Add multiple extra plugins.
- Parameters:
-
array | $plugins | array of plugin names |
- Returns:
- Zend_Dojo_Form_Element_Editor
{
foreach ($plugins as $plugin) {
$this->addExtraPlugin($plugin);
}
return $this;
}
Content_Form_Element_Editor::clearExtraPlugins |
( |
| ) |
|
Clear all extra plugins.
- Returns:
- Zend_Dojo_Form_Element_Editor
{
return $this->removeDijitParam('extraPlugins');
}
Content_Form_Element_Editor::getExtraPlugins |
( |
| ) |
|
Get all extra plugins.
- Returns:
- array
{
if (!$this->hasDijitParam('extraPlugins')) {
return array();
}
return $this->getDijitParam('extraPlugins');
}
Content_Form_Element_Editor::hasExtraPlugin |
( |
$ |
plugin | ) |
|
Is a given extra plugin registered?
- Parameters:
-
- Returns:
- bool
{
$plugins = $this->getExtraPlugins();
return in_array((string) $plugin, $plugins);
}
Content_Form_Element_Editor::removeExtraPlugin |
( |
$ |
plugin | ) |
|
Remove a given extra plugin.
- Parameters:
-
- Returns:
- Zend_Dojo_Form_Element_Editor
{
$plugins = $this->getExtraPlugins();
if (false === ($index = array_search($plugin, $plugins))) {
return $this;
}
unset($plugins[$index]);
$this->setDijitParam('extraPlugins', $plugins);
return $this;
}
Content_Form_Element_Editor::setExtraPlugins |
( |
array $ |
plugins | ) |
|
Overwrite many extra plugins at once.
- Parameters:
-
array | $plugins | array of plugin names |
- Returns:
- Zend_Dojo_Form_Element_Editor
The documentation for this class was generated from the following file:
- forms/elements/Editor.php