Fix calendar entries mess up after editing an integrated entry (eg. infolog) while the calendar is not the active tab (happens only in F.F.)

This commit is contained in:
Hadi Nategh 2014-10-09 14:15:56 +00:00
parent 653ad3fd59
commit f54beab108

View File

@ -173,7 +173,20 @@ app.classes.calendar = AppJS.extend(
} }
else else
{ {
window.location.reload(); var iframe = parent.jQuery(parent.document).find('.egw_fw_content_browser_iframe');
var calTab = iframe.parentsUntil(jQuery('.egw_fw_ui_tab_content'),'.egw_fw_ui_tab_content');
if (!calTab.is(':visible'))
{
// F.F can not handle to style correctly an iframe which is hidden (display:none), therefore we need to
// bind a handler to refresh the calendar views after it shows up
iframe.one('show',function(){egw_refresh('','calendar');})
}
else
{
//window.location.reload();
window.egw_refresh('refreshing calendar','calendar');
}
} }
} }
} }