From c16986be7f5f4df21bfc85a93a2c35f38c86bf12 Mon Sep 17 00:00:00 2001 From: alecpl Date: Wed, 17 Mar 2010 18:21:07 +0000 Subject: - use popupmenu style for attachments upload form - move .popupmenu style definition to common.css --- program/js/app.js | 6 +++--- program/steps/mail/compose.inc | 2 +- skins/default/common.css | 21 ++++++++++++++++++++- skins/default/mail.css | 26 -------------------------- skins/default/templates/compose.html | 2 +- 5 files changed, 25 insertions(+), 32 deletions(-) diff --git a/program/js/app.js b/program/js/app.js index 7aca3d8de..87ee76c8f 100644 --- a/program/js/app.js +++ b/program/js/app.js @@ -2832,7 +2832,7 @@ function rcube_webmail() { if (!this.gui_objects.uploadbox) return false; - + var elm, list; if (elm = this.gui_objects.uploadbox) { @@ -2842,8 +2842,8 @@ function rcube_webmail() elm.style.top = (pos.top + list.offsetHeight + 10) + 'px'; elm.style.left = pos.left + 'px'; } - - elm.style.visibility = a ? 'visible' : 'hidden'; + + $(elm).toggle(); } // clear upload form diff --git a/program/steps/mail/compose.inc b/program/steps/mail/compose.inc index a5b0a340e..a8b2fa5f2 100644 --- a/program/steps/mail/compose.inc +++ b/program/steps/mail/compose.inc @@ -901,7 +901,7 @@ function rcmail_compose_attachment_form($attrib) html::div(null, rcmail_compose_attachment_field(array('size' => $attrib[attachmentfieldsize]))) . html::div('hint', rcube_label(array('name' => 'maxuploadsize', 'vars' => array('size' => $max_filesize)))) . html::div('buttons', - $button->show(rcube_label('close'), array('class' => 'button', 'onclick' => "document.getElementById('$attrib[id]').style.visibility='hidden'")) . ' ' . + $button->show(rcube_label('close'), array('class' => 'button', 'onclick' => "$('#$attrib[id]').hide()")) . ' ' . $button->show(rcube_label('upload'), array('class' => 'button mainaction', 'onclick' => JS_OBJECT_NAME . ".command('send-attachment', this.form)")) ) ) diff --git a/skins/default/common.css b/skins/default/common.css index 44bb4f5b9..5977087f3 100644 --- a/skins/default/common.css +++ b/skins/default/common.css @@ -330,6 +330,25 @@ img padding-right: 10px; } +.popupmenu +{ + position: absolute; + top: 32px; + left: 90px; + width: auto; + display: none; + background-color: #fff; + background-color: rgba(255, 255, 255, 0.95); + border: 1px solid #999; + padding: 4px; + z-index: 240; + border-radius: 3px; + -moz-border-radius: 3px; + -webkit-border-radius: 3px; + -moz-box-shadow: 1px 1px 12px #999; + -webkit-box-shadow: #999 1px 1px 12px; +} + /***** common table settings ******/ @@ -532,7 +551,7 @@ a.rcmContactAddress:hover opacity: 0.8; } - + /***** onclick menu list *****/ ul.toolbarmenu diff --git a/skins/default/mail.css b/skins/default/mail.css index 7d1cb33d4..6b105acc2 100644 --- a/skins/default/mail.css +++ b/skins/default/mail.css @@ -164,25 +164,6 @@ padding-left: 2px; } -.popupmenu -{ - position: absolute; - top: 32px; - left: 90px; - width: auto; - display: none; - background-color: #fff; - background-color: rgba(255, 255, 255, 0.95); - border: 1px solid #999; - padding: 4px; - z-index: 240; - border-radius: 3px; - -moz-border-radius: 3px; - -webkit-border-radius: 3px; - -moz-box-shadow: 1px 1px 12px #999; - -webkit-box-shadow: #999 1px 1px 12px; -} - #searchmenu { width: 160px; @@ -1304,14 +1285,7 @@ div.message-htmlpart div.rcmBody #attachment-form { - position: absolute; - top: 150px; - left: 20px; - z-index: 200; padding: 6px; - visibility: hidden; - border: 1px solid #CCCCCC; - background-color: #F9F9F9; } #attachment-form div diff --git a/skins/default/templates/compose.html b/skins/default/templates/compose.html index 661ec4d07..3b9cd4003 100644 --- a/skins/default/templates/compose.html +++ b/skins/default/templates/compose.html @@ -101,7 +101,7 @@ - + -- cgit v1.2.3