Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
sdkjs
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Boris Kocherov
sdkjs
Commits
f0d5a7aa
Commit
f0d5a7aa
authored
Oct 17, 2017
by
Oleg Korshul
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
multiplugins scheme
parent
d5984bf1
Changes
7
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
487 additions
and
289 deletions
+487
-289
common/Drawings/WorkEvents.js
common/Drawings/WorkEvents.js
+4
-6
common/apiBase.js
common/apiBase.js
+1
-5
common/editorscommon.js
common/editorscommon.js
+2
-3
common/plugins.js
common/plugins.js
+472
-266
common/scroll.js
common/scroll.js
+4
-6
common/text_input.js
common/text_input.js
+1
-1
word/api.js
word/api.js
+3
-2
No files found.
common/Drawings/WorkEvents.js
View file @
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;
...
...
common/apiBase.js
View file @
f0d5a7aa
...
...
@@ -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
()
...
...
common/editorscommon.js
View file @
f0d5a7aa
...
...
@@ -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
)
{
...
...
common/plugins.js
View file @
f0d5a7aa
This diff is collapsed.
Click to expand it.
common/scroll.js
View file @
f0d5a7aa
...
...
@@ -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
/*
...
...
common/text_input.js
View file @
f0d5a7aa
...
...
@@ -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
;
}
...
...
word/api.js
View file @
f0d5a7aa
...
...
@@ -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
();
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment