summaryrefslogtreecommitdiff
path: root/skins/larry/ui.js
diff options
context:
space:
mode:
authorThomas Bruederli <thomas@roundcube.net>2012-10-01 17:45:52 +0200
committerThomas Bruederli <thomas@roundcube.net>2012-10-01 17:45:52 +0200
commitc23aad2feb9923cbf9197f4d99f73978a61de832 (patch)
tree790552324ff0c554c2df2452108af244e94cd8ea /skins/larry/ui.js
parentab08544520cc47b8a63be1737d5d6edb02c511b4 (diff)
Revert "Add full headers view in message preview window (#1488538)"
This reverts commit af276f21e5364eb65a56b64c3455bc284ff1e2f2. Conflicts: CHANGELOG skins/larry/mail.css
Diffstat (limited to 'skins/larry/ui.js')
-rw-r--r--skins/larry/ui.js34
1 files changed, 9 insertions, 25 deletions
diff --git a/skins/larry/ui.js b/skins/larry/ui.js
index c221b8681..c01a17cd2 100644
--- a/skins/larry/ui.js
+++ b/skins/larry/ui.js
@@ -74,8 +74,9 @@ function rcube_mail_ui()
if (rcmail.env.action == 'show' || rcmail.env.action == 'preview') {
layout_messageview();
- $('#previewheaderstoggle').click(function(e){ toggle_preview_headers(this); return false; });
- $('#headerstoggleall').click(function(e){ toggle_all_headers(this); return false; });
+ rcmail.addEventListener('aftershow-headers', function() { layout_messageview(); });
+ rcmail.addEventListener('afterhide-headers', function() { layout_messageview(); });
+ $('#previewheaderstoggle').click(function(e){ toggle_preview_headers(this); return false });
}
else if (rcmail.env.action == 'compose') {
rcmail.addEventListener('aftertoggle-editor', function(){ window.setTimeout(function(){ layout_composeview() }, 200); });
@@ -320,6 +321,7 @@ function rcube_mail_ui()
*/
function layout_messageview()
{
+ $('#messagecontent').css('top', ($('#messageheader').outerHeight() + 10) + 'px');
$('#message-objects div a').addClass('button');
if (!$('#attachment-list li').length) {
@@ -512,31 +514,13 @@ function rcube_mail_ui()
{
$('#preview-shortheaders').toggle();
var full = $('#preview-allheaders').toggle(),
- button = $('#previewheaderstoggle');
-
- if (!$('#headerstoggleall').length)
- $('#all-headers').toggle();
+ button = $('a#previewheaderstoggle');
// add toggle button to full headers table
- if (full.is(':visible')) {
- button.attr('href', '#hide').removeClass('add').addClass('remove');
- }
- else {
- button.attr('href', '#details').removeClass('remove').addClass('add');
- }
- }
-
-
- /**
- * Show/hide all message headers
- */
- function toggle_all_headers(button)
- {
- rcmail.command('show-headers', '', button);
- $(button).remove();
- $('#previewheaderstoggle span').css({bottom: '5px'});
-
- return false;
+ if (full.is(':visible'))
+ button.attr('href', '#hide').removeClass('add').addClass('remove')
+ else
+ button.attr('href', '#details').removeClass('remove').addClass('add')
}