Update BDFDB.max.js

This commit is contained in:
Mirco Wittrien 2019-09-09 11:36:15 +02:00
parent 26853407bb
commit 8f9641b8b6
1 changed files with 2 additions and 2 deletions

View File

@ -1615,7 +1615,7 @@ var BDFDB = {myPlugins: BDFDB && BDFDB.myPlugins ? BDFDB.myPlugins : {}, BDv2Api
function patchContext (type, module) {
if (module && module.prototype) BDFDB.WebModules.patch(module.prototype, 'render', plugin, {after: e => {
let instance = e.thisObject, menu = BDFDB.React.findDOMNodeSafe(e.thisObject), returnvalue = e.returnvalue;
let instance = e.thisObject, menu = BDFDB.React.findDOMNodeSafe(e.thisObject), returnvalue = e.returnValue;
if (instance && menu && returnvalue) {
if (type && typeof plugin[`on${type}ContextMenu`] === 'function') plugin[`on${type}ContextMenu`](instance, menu, returnvalue);
else if (!type && typeof plugin[`onContextMenu`] === 'function') plugin[`onContextMenu`](instance, menu, returnvalue);
@ -1624,7 +1624,7 @@ var BDFDB = {myPlugins: BDFDB && BDFDB.myPlugins ? BDFDB.myPlugins : {}, BDv2Api
}
function patchPopout (type, module) {
if (module && module.prototype) BDFDB.WebModules.patch(module.prototype, 'render', plugin, {after: e => {
let instance = e.thisObject, popout = BDFDB.React.findDOMNodeSafe(e.thisObject), returnvalue = e.returnvalue;
let instance = e.thisObject, popout = BDFDB.React.findDOMNodeSafe(e.thisObject), returnvalue = e.returnValue;
if (instance && popout && returnvalue) {
if (type && typeof plugin[`on${type}Popout`] === 'function') plugin[`on${type}Popout`](instance, popout, returnvalue);
}