positionItem => positioningItem
This commit is contained in:
parent
ba933ef085
commit
5065e159f1
1 changed files with 4 additions and 4 deletions
|
@ -44,7 +44,7 @@ Menu.prototype._init = function () {
|
|||
}
|
||||
|
||||
Menu.prototype.popup = function (options) {
|
||||
let {window, x, y, positionItem, callback} = options
|
||||
let {window, x, y, positioningItem, callback} = options
|
||||
|
||||
// no callback passed
|
||||
if (!callback || typeof callback !== 'function') callback = () => {}
|
||||
|
@ -52,7 +52,7 @@ Menu.prototype.popup = function (options) {
|
|||
// set defaults
|
||||
if (typeof x !== 'number') x = -1
|
||||
if (typeof y !== 'number') y = -1
|
||||
if (typeof positionItem !== 'number') positionItem = -1
|
||||
if (typeof positioningItem !== 'number') positioningItem = -1
|
||||
if (!window || (window && window.constructor !== BrowserWindow)) {
|
||||
window = BrowserWindow.getFocusedWindow()
|
||||
|
||||
|
@ -67,8 +67,8 @@ Menu.prototype.popup = function (options) {
|
|||
}
|
||||
}
|
||||
|
||||
this.popupAt(window, x, y, positionItem, callback)
|
||||
return { browserWindow: window, x, y, position: positionItem }
|
||||
this.popupAt(window, x, y, positioningItem, callback)
|
||||
return { browserWindow: window, x, y, position: positioningItem }
|
||||
}
|
||||
|
||||
Menu.prototype.closePopup = function (window) {
|
||||
|
|
Loading…
Reference in a new issue