mirror of
https://github.com/EGroupware/egroupware.git
synced 2025-02-02 11:29:58 +01:00
Use preference to set size of description lines
This commit is contained in:
parent
792d922743
commit
d57893988e
@ -386,6 +386,15 @@ class calendar_hooks
|
||||
'admin' => False,
|
||||
'forced' => 'user',
|
||||
),
|
||||
'limit_des_lines' => array(
|
||||
'type' => 'input',
|
||||
'size' => 5,
|
||||
'label' => 'Limit number of description lines in list view (default 5, 0 for no limit)',
|
||||
'name' => 'limit_des_lines',
|
||||
'help' => 'How many describtion lines should be directly visible. Further lines are available via a scrollbar.',
|
||||
'xmlrpc' => True,
|
||||
'admin' => False
|
||||
),
|
||||
'default_private' => array(
|
||||
'type' => 'check',
|
||||
'label' => 'Set new events to private',
|
||||
|
@ -176,6 +176,13 @@ class calendar_uilist extends calendar_ui
|
||||
if($key == 'G') continue;
|
||||
$sel_options['action'][lang('Change your participant status')]['status-'.$key] = $value;
|
||||
}
|
||||
// add scrollbar to long describtion, if user choose so in his prefs
|
||||
if ($this->prefs['limit_des_lines'] > 0 || (string)$this->prefs['limit_des_lines'] == '')
|
||||
{
|
||||
$content['css'] .= '<style type="text/css">@media screen { .listDescription { max-height: '.
|
||||
(($this->prefs['limit_des_lines'] ? $this->prefs['limit_des_lines'] : 5) * 1.35). // dono why em is not real lines
|
||||
'em; overflow: auto; }}</style>';
|
||||
}
|
||||
unset($sel_options['action'][lang('Change your participant status')]['G']);
|
||||
$GLOBALS['egw_info']['flags']['java_script'] .= $this->get_javascript();
|
||||
|
||||
|
File diff suppressed because one or more lines are too long
Loading…
Reference in New Issue
Block a user