forked from extern/egroupware
display: control attachmentdiv and displayareadiv class by code, to hide attachmentarea, when no attachments are present
This commit is contained in:
parent
fe217e5458
commit
4354a02fbd
@ -1151,21 +1151,21 @@ class mail_compose
|
||||
// if no filemanager -> no vfsFileSelector
|
||||
if (!$GLOBALS['egw_info']['user']['apps']['filemanager'])
|
||||
{
|
||||
$content['vfsNotAvailable'] = "mail-index_quotaDisplayNone";
|
||||
$content['vfsNotAvailable'] = "mail_DisplayNone";
|
||||
}
|
||||
// if no infolog -> no save as infolog
|
||||
if (!$GLOBALS['egw_info']['user']['apps']['infolog'])
|
||||
{
|
||||
$content['noInfologAvailable'] = "mail-index_quotaDisplayNone";
|
||||
$content['noInfologAvailable'] = "mail_DisplayNone";
|
||||
}
|
||||
// if no tracker -> no save as tracker
|
||||
if (!$GLOBALS['egw_info']['user']['apps']['tracker'])
|
||||
{
|
||||
$content['noTrackerAvailable'] = "mail-index_quotaDisplayNone";
|
||||
$content['noTrackerAvailable'] = "mail_DisplayNone";
|
||||
}
|
||||
if (!$GLOBALS['egw_info']['user']['apps']['infolog'] && !$GLOBALS['egw_info']['user']['apps']['tracker'])
|
||||
{
|
||||
$content['noSaveAsAvailable'] = "mail-index_quotaDisplayNone";
|
||||
$content['noSaveAsAvailable'] = "mail_DisplayNone";
|
||||
}
|
||||
// composeID to detect if we have changes to certain content
|
||||
$preserv['composeID'] = $content['composeID'] = $this->composeID;
|
||||
|
@ -251,8 +251,8 @@ class mail_ui
|
||||
$content[self::$nm_index]['quotanotsupported'] = $sel_options[self::$nm_index]['quotanotsupported'] = "";
|
||||
} else {
|
||||
$content[self::$nm_index]['quota'] = $sel_options[self::$nm_index]['quota'] = lang("Quota not provided by server");
|
||||
$content[self::$nm_index]['quotaclass'] = $sel_options[self::$nm_index]['quotaclass'] = "mail-index_quotaDisplayNone";
|
||||
$content[self::$nm_index]['quotanotsupported'] = $sel_options[self::$nm_index]['quotanotsupported'] = "mail-index_quotaDisplayNone";
|
||||
$content[self::$nm_index]['quotaclass'] = $sel_options[self::$nm_index]['quotaclass'] = "mail_DisplayNone";
|
||||
$content[self::$nm_index]['quotanotsupported'] = $sel_options[self::$nm_index]['quotanotsupported'] = "mail_DisplayNone";
|
||||
}
|
||||
|
||||
$sel_options[self::$nm_index]['foldertree'] = $this->getFolderTree(false);
|
||||
@ -1706,6 +1706,8 @@ unset($query['actions']);
|
||||
//_debug_array($attachments);
|
||||
$content['mail_displayattachments'] = $attachmentHTMLBlock;
|
||||
$content['mail_id']=$rowID;
|
||||
$content['mailDisplayContainerClass']=(count($attachments)?"mailDisplayContainer mailDisplayContainerFixedHeight":"mailDisplayContainer mailDisplayContainerFullHeight");
|
||||
$content['mailDisplayAttachmentsClass']=(count($attachments)?"mailDisplayAttachments":"mail_DisplayNone");
|
||||
//_debug_array($content);
|
||||
$readonlys = $preserv = $content;
|
||||
$etpl->exec('mail.mail_ui.displayMessage',$content,$sel_options,$readonlys,$preserv,2);
|
||||
@ -2432,7 +2434,7 @@ blockquote[type=cite] {
|
||||
color: blue;
|
||||
}
|
||||
</style>
|
||||
<div style="height:100%;width:100%; background-color:white; padding:0px; margin:0px;">
|
||||
<div class="mailDisplayBody">
|
||||
<table width="100%" style="table-layout:fixed"><tr><td class="td_display">';
|
||||
|
||||
$EndBody = '</td></tr></table></div>';
|
||||
|
@ -293,6 +293,9 @@ pre {
|
||||
width:200px !important;
|
||||
z-index:99;
|
||||
}
|
||||
.mail_DisplayNone {
|
||||
display: none !important;
|
||||
}
|
||||
.mail-index_quotaDisplayNone {
|
||||
display: none !important;
|
||||
}
|
||||
@ -384,8 +387,8 @@ input[type=button] {
|
||||
padding: 0px;
|
||||
height: 16px !important;
|
||||
}
|
||||
#mail-display_toolbar {
|
||||
padding: 0px;
|
||||
#mail-compose_toolbar > button {
|
||||
padding: .2em .4em;
|
||||
}
|
||||
#mail-display_toolbar > button > span {
|
||||
padding: .2em .4em;
|
||||
@ -421,7 +424,7 @@ input[type=button] {
|
||||
}
|
||||
#mail-index_previewAttachmentArea {
|
||||
background-color:#efefdf;
|
||||
max-height: 10%;
|
||||
max-height: 3em;
|
||||
max-width: 50%;
|
||||
position: absolute;
|
||||
overflow:scroll;
|
||||
@ -453,15 +456,26 @@ input[type=button] {
|
||||
overflow-y: auto;
|
||||
border: 1px solid silver;
|
||||
top: 120px;
|
||||
bottom: 100px;
|
||||
}
|
||||
.mailDisplayContainerFixedHeight {
|
||||
bottom: 123px;
|
||||
}
|
||||
.mailDisplayContainerFullHeight {
|
||||
bottom: .1em;
|
||||
}
|
||||
.mailDisplayBody {
|
||||
height:100%;
|
||||
width:100%;
|
||||
background-color:white;
|
||||
padding:0px;
|
||||
margin:0px;
|
||||
}
|
||||
.mailDisplayAttachments {
|
||||
background-color:#efefdf;
|
||||
max-height: 10%;
|
||||
height: 121px;
|
||||
position: fixed;
|
||||
bottom: 26px;
|
||||
bottom: .1em;
|
||||
border: 1px solid red;
|
||||
border-bottom: 0px;
|
||||
opacity: 1;
|
||||
-moz-opacity:1:
|
||||
filter: Alpha(opacity=100);
|
||||
|
@ -33,15 +33,12 @@
|
||||
<description value="Subject"/>
|
||||
<description align="left" id="mail_displaysubject" readonly="true"/>
|
||||
</hbox>
|
||||
<hbox class="mail_displayicons">
|
||||
<html id="mail_displayicons"/>
|
||||
</hbox>
|
||||
</vbox>
|
||||
<vbox class="mailDisplay" width="100%">
|
||||
<box class="mailDisplayContainer">
|
||||
<box class="$cont[mailDisplayContainerClass]">
|
||||
<html id="mail_displaybody"/>
|
||||
</box>
|
||||
<box class="mailDisplayAttachments">
|
||||
<box class="$cont[mailDisplayAttachmentsClass]">
|
||||
<html id="mail_displayattachments"/>
|
||||
</box>
|
||||
</vbox>
|
||||
|
Loading…
Reference in New Issue
Block a user