mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-12-22 06:30:59 +01:00
Fix broken dock/undocking mail preview on 3pane views
This commit is contained in:
parent
23dadd0559
commit
99b667da6c
@ -1019,6 +1019,16 @@ app.classes.mail = AppJS.extend(
|
||||
var splitter = this.et2.getWidgetById('mailSplitter');
|
||||
// return if there's no splitter we maybe in mobile mode
|
||||
if (typeof splitter == 'undefined' || splitter == null) return;
|
||||
let dock = function(){
|
||||
splitter.style.setProperty('--max','100%');
|
||||
splitter.dock();
|
||||
};
|
||||
let undock = function ()
|
||||
{
|
||||
splitter.style.setProperty('--max','70%');
|
||||
splitter.undock();
|
||||
};
|
||||
|
||||
if(splitter.isDocked())
|
||||
{
|
||||
this.mail_previewAreaActive = false;
|
||||
@ -1027,15 +1037,15 @@ app.classes.mail = AppJS.extend(
|
||||
//Dock the splitter always if we are browsing with mobile
|
||||
if (_value==true)
|
||||
{
|
||||
if (this.mail_previewAreaActive) splitter.dock();
|
||||
if (this.mail_previewAreaActive) dock();
|
||||
this.mail_previewAreaActive = false;
|
||||
}
|
||||
else
|
||||
{
|
||||
if (!this.mail_previewAreaActive)
|
||||
{
|
||||
splitter.undock();
|
||||
window.setTimeout(function(){splitter.left.trigger('resize.et2_split.mailSplitter');},200);
|
||||
undock();
|
||||
//window.setTimeout(function(){splitter.left.trigger('resize.et2_split.mailSplitter');},200);
|
||||
}
|
||||
this.mail_previewAreaActive = true;
|
||||
}
|
||||
@ -1193,11 +1203,15 @@ app.classes.mail = AppJS.extend(
|
||||
{
|
||||
// Leave if we're here and there is nothing selected, too many, or no data
|
||||
if (attachmentsBlock)
|
||||
{
|
||||
// check if the widget is attached before setting its content
|
||||
if (attachmentsBlock.parentNode)
|
||||
{
|
||||
attachmentsBlock.set_value({content:[]});
|
||||
attachmentsBlock.set_class('previewAttachmentArea noContent mail_DisplayNone');
|
||||
}
|
||||
var IframeHandle = this.et2.getWidgetById('messageIFRAME');
|
||||
IframeHandle.set_src('about:blank');
|
||||
if(IframeHandle) IframeHandle.set_src('about:blank');
|
||||
this.mail_disablePreviewArea(true);
|
||||
}
|
||||
if (!egwIsMobile())return;
|
||||
|
Loading…
Reference in New Issue
Block a user