summaryrefslogtreecommitdiff
path: root/skins/larry/ui.js
diff options
context:
space:
mode:
Diffstat (limited to 'skins/larry/ui.js')
-rw-r--r--skins/larry/ui.js20
1 files changed, 15 insertions, 5 deletions
diff --git a/skins/larry/ui.js b/skins/larry/ui.js
index 42d5237ea..da4f2300e 100644
--- a/skins/larry/ui.js
+++ b/skins/larry/ui.js
@@ -21,7 +21,6 @@ function rcube_mail_ui()
dragmessagemenu: { sticky:1 },
groupmenu: { above:1 },
mailboxmenu: { above:1 },
- composeoptionsmenu: { editable:1, overlap:1 },
spellmenu: { callback: spellmenu },
// toggle: #1486823, #1486930
'attachment-form': { editable:1, above:1, toggle:!bw.ie&&!bw.linux },
@@ -90,13 +89,17 @@ function rcube_mail_ui()
show_header_row(fields[f], true);
}
- $('#composeoptionstoggle').parent().click(function(){
- $('#composeoptionstoggle').toggleClass('enabled');
+ $('#composeoptionstoggle').click(function(){
+ $('#composeoptionstoggle').toggleClass('remove');
$('#composeoptions').toggle();
layout_composeview();
return false;
}).css('cursor', 'pointer');
+ // toggle compose options if opened in new window and they were visible before
+ if (window.opener && opener.rcmail && opener.rcmail.env.action == 'compose' && $('#composeoptionstoggle', opener.document).hasClass('remove'))
+ $('#composeoptionstoggle').click();
+
new rcube_splitter({ id:'composesplitterv', p1:'#composeview-left', p2:'#composeview-right',
orientation:'v', relative:true, start:248, min:170, size:12, render:layout_composeview }).init();
}
@@ -354,9 +357,14 @@ function rcube_mail_ui()
var body = $('#composebody'),
form = $('#compose-content'),
bottom = $('#composeview-bottom'),
- w, h;
+ w, h, bh, ovflw, btns = 0,
+ minheight = 300,
- bottom.css('height', (form.height() - bottom.position().top) + 'px');
+ bh = (form.height() - bottom.position().top);
+ ovflw = minheight - bh;
+ btns = ovflw > -100 ? 0 : 40;
+ bottom.css('height', Math.max(minheight, bh) + 'px');
+ form.css('overflow', ovflw > 0 ? 'auto' : 'hidden');
w = body.parent().width() - 5;
h = body.parent().height() - 16;
@@ -365,6 +373,8 @@ function rcube_mail_ui()
$('#composebody_tbl').width((w+8)+'px').height('').css('margin-top', '1px');
$('#composebody_ifr').width((w+8)+'px').height((h-40)+'px');
$('#googie_edit_layer').height(h+'px');
+// $('#composebodycontainer')[(btns ? 'addClass' : 'removeClass')]('buttons');
+// $('#composeformbuttons')[(btns ? 'show' : 'hide')]();
var abooks = $('#directorylist');
$('#compose-contacts .scroller').css('top', abooks.position().top + abooks.outerHeight());