Commit 1dc6944b authored by Alexey Golubev's avatar Alexey Golubev Committed by GitHub

Merge pull request #184 from ONLYOFFICE/feature/v5.0.3.2

Feature/v5.0.3.2
parents 4e4c44a3 f0d5a7aa
......@@ -106,9 +106,8 @@
if (window.captureEvents)
window.captureEvents(Event.MOUSEDOWN | Event.MOUSEUP);
var _frame = document.getElementById("plugin_iframe");
if (_frame)
_frame.style.pointerEvents = "none";
if (window.g_asc_plugins)
window.g_asc_plugins.disablePointerEvents();
/*
var parent = window;
......@@ -140,9 +139,8 @@
if (window.releaseEvents)
window.releaseEvents(Event.MOUSEMOVE);
var _frame = document.getElementById("plugin_iframe");
if (_frame)
_frame.style.pointerEvents = "";
if (window.g_asc_plugins)
window.g_asc_plugins.enablePointerEvents();
/*
var parent = window;
......
......@@ -1251,11 +1251,7 @@
if (!this.pluginsManager)
return;
var _pluginData = new Asc.CPluginData();
_pluginData.setAttribute("type", "enableMouseEvent");
_pluginData.setAttribute("isEnabled", isEnable);
this.pluginsManager.sendMessage(_pluginData);
this.pluginsManager.onEnableMouseEvents(isEnable);
};
baseEditorsApi.prototype["pluginMethod_GetFontList"] = function()
......
......@@ -1227,9 +1227,8 @@
}
else if (data.type === "onExternalPluginMessage")
{
var _iframe = document.getElementById("plugin_iframe");
if (_iframe)
_iframe.contentWindow.postMessage(event.data, "*");
if (window.g_asc_plugins)
window.g_asc_plugins.sendToAllPlugins(event.data);
}
} catch (err)
{
......
This diff is collapsed.
......@@ -3067,9 +3067,8 @@ ScrollObject.prototype = {
var evt = e || window.event;
// prevent pointer events on all iframes (while only plugin!)
var _frame = document.getElementById("plugin_iframe");
if (_frame)
_frame.style.pointerEvents = "";
if (window.g_asc_plugins)
window.g_asc_plugins.enablePointerEvents();
if ( evt.preventDefault )
evt.preventDefault();
......@@ -3115,9 +3114,8 @@ ScrollObject.prototype = {
var evt = e || window.event;
// prevent pointer events on all iframes (while only plugin!)
var _frame = document.getElementById("plugin_iframe");
if (_frame)
_frame.style.pointerEvents = "none";
if (window.g_asc_plugins)
window.g_asc_plugins.disablePointerEvents();
// если сделать превент дефолт - перестанет приходить mousemove от window
/*
......
......@@ -1784,7 +1784,7 @@
if (document.activeElement)
{
var _id = document.activeElement.id;
if (_id == "area_id" || _id == "plugin_iframe")
if (_id == "area_id" || (window.g_asc_plugins && window.g_asc_plugins.checkRunnedFrameId(_id)))
return;
}
......
......@@ -5908,7 +5908,7 @@ background-repeat: no-repeat;\
var top = ((height / 2) - (h / 2)) + dualScreenTop;
var _windowPos = "width=" + w + ",height=" + h + ",left=" + left + ",top=" + top;
this.reporterWindow = window.open("index.reporter.html", "_blank", "resizable=0,status=0,toolbar=0,location=0,menubar=0,directories=0,scrollbars=0," + _windowPos);
this.reporterWindow = window.open("index.reporter.html", "_blank", "resizable=yes,status=0,toolbar=0,location=0,menubar=0,directories=0,scrollbars=0," + _windowPos);
if (!this.reporterWindow)
return;
......
......@@ -409,6 +409,7 @@
this.documents = _docs;
this.returnDocuments = [];
this.current = -1;
this.guid = "";
this.start = function()
{
......@@ -417,14 +418,14 @@
this.api.incrementCounterLongAction();
if (window.g_asc_plugins)
window.g_asc_plugins.setPluginMethodReturnAsync();
this.guid = window.g_asc_plugins.setPluginMethodReturnAsync();
this.run();
};
this.end = function()
{
if (window.g_asc_plugins)
window.g_asc_plugins.onPluginMethodReturn(this.returnDocuments);
window.g_asc_plugins.onPluginMethodReturn(this.guid, this.returnDocuments);
delete this.api.__content_control_worker;
this.api.decrementCounterLongAction();
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment