/**
* Code to run on init.
- *
- * @param Horde_Core_Prefs_Ui $ui The UI object.
*/
- static public function sourceInit($ui)
+ static public function sourceInit()
{
Horde::addScriptFile('sourceselect.js', 'horde');
}
* will contain a list of arrays; each subarray contains the source name
* and the list of selected values (JSON encoded).
*
- * @param Horde_Core_Prefs_Ui $ui The UI object.
- * @param array $data Data items:
+ * @param array $data Data items:
* <pre>
* 'mainlabel' - (string) Main label.
* 'selectlabel' - (array) Selected label.
*
* @return string HTML UI code.
*/
- static public function source($ui, $data = array())
+ static public function source($data)
{
$t = $GLOBALS['injector']->createInstance('Horde_Template');
/**
* Code to run on init for addressbook selection.
- *
- * @param Horde_Core_Prefs_Ui $ui The UI object.
*/
- static public function addressbooksInit($ui)
+ static public function addressbooksInit()
{
- self::sourceInit($ui);
+ self::sourceInit();
Horde::addScriptFile('addressbooksprefs.js', 'horde');
}
* search_fields contains a hash containing sources as keys and an array
* of search fields as the value.
*
- * @param Horde_Core_Prefs_Ui $ui The UI object.
- *
* @return string HTML UI code.
*/
- static public function addressbooks($ui)
+ static public function addressbooks()
{
global $prefs, $registry;
}
if (!empty($selected) || !empty($unselected)) {
- $out = Horde_Core_Prefs_Ui_Widgets::source($ui, array(
+ $out = Horde_Core_Prefs_Ui_Widgets::source(array(
'mainlabel' => _("Choose the order of address books to search when expanding addresses."),
'selectlabel' => _("Selected address books:"),
'sources' => array(array(
switch ($ui->group) {
case 'display':
if (!$prefs->isLocked('columns')) {
- Horde_Core_Prefs_Ui_Widgets::sourceInit($ui);
+ Horde_Core_Prefs_Ui_Widgets::sourceInit();
}
break;
}
);
}
- return Horde_Core_Prefs_Ui_Widgets::source($ui, array(
+ return Horde_Core_Prefs_Ui_Widgets::source(array(
'mainlabel' => _("Choose which address books to display, and in what order:"),
'selectlabel' => _("These addressbooks will display in this order:"),
'sourcelabel' => _("Select a backend:"),
case 'addressbooks':
if (!$prefs->isLocked('sourceselect')) {
- Horde_Core_Prefs_Ui_Widgets::addressbooksInit($ui);
+ Horde_Core_Prefs_Ui_Widgets::addressbooksInit();
}
if (!$prefs->isLocked('add_source')) {
return $this->_sound();
case 'sourceselect':
- return Horde_Core_Prefs_Ui_Widgets::addressbooks($ui);
+ return Horde_Core_Prefs_Ui_Widgets::addressbooks();
case 'spamselect':
return $this->_spam();
switch ($ui->group) {
case 'addressbooks':
- Horde_Core_Prefs_Ui_Widgets::sourceInit($ui);
+ Horde_Core_Prefs_Ui_Widgets::sourceInit();
if (!$prefs->isLocked('default_dir')) {
$out = array();
$selected[$val] = $GLOBALS['cfgSources'][$val]['title'];
}
- return Horde_Core_Prefs_Ui_Widgets::source($ui, array(
+ return Horde_Core_Prefs_Ui_Widgets::source(array(
'mainlabel' => _("Choose which address books to display, and in what order:"),
'selected' => $selected,
'selectlabel' => _("These addressbooks will display in this order:"),