- Fix action when toggling prefer_html option state

pull/1/head
alecpl 13 years ago
parent 2498155abe
commit e01e798517

@ -5587,7 +5587,7 @@ function rcube_webmail()
this.toggle_prefer_html = function(checkbox) this.toggle_prefer_html = function(checkbox)
{ {
$('#rcmfd_addrbook_show_images').prop('disabled', !checkbox.checked); $('#rcmfd_show_images').prop('disabled', !checkbox.checked).val(0);
}; };
this.toggle_preview_pane = function(checkbox) this.toggle_preview_pane = function(checkbox)

@ -437,14 +437,15 @@ function rcmail_user_prefs($current=null)
if (!isset($no_override['show_images'])) { if (!isset($no_override['show_images'])) {
$field_id = 'rcmfd_show_images'; $field_id = 'rcmfd_show_images';
$input_show_images = new html_select(array('name' => '_show_images', 'id' => $field_id)); $input_show_images = new html_select(array('name' => '_show_images', 'id' => $field_id,
'disabled' => !$config['prefer_html']));
$input_show_images->add(rcube_label('never'), 0); $input_show_images->add(rcube_label('never'), 0);
$input_show_images->add(rcube_label('fromknownsenders'), 1); $input_show_images->add(rcube_label('fromknownsenders'), 1);
$input_show_images->add(rcube_label('always'), 2); $input_show_images->add(rcube_label('always'), 2);
$blocks['main']['options']['show_images'] = array( $blocks['main']['options']['show_images'] = array(
'title' => html::label($field_id, Q(rcube_label('showremoteimages'))), 'title' => html::label($field_id, Q(rcube_label('showremoteimages'))),
'content' => $input_show_images->show($config['show_images']), 'content' => $input_show_images->show($config['prefer_html'] ? $config['show_images'] : 0),
); );
} }

Loading…
Cancel
Save