]> khamidou — GitHub mirrors - electron.git/commitdiff
docs: Default parameter for Menu.popup
authorCheng Zhao <zcbenz@gmail.com>
Fri, 22 Jan 2016 18:29:26 +0000 (11:29 -0700)
committerCheng Zhao <zcbenz@gmail.com>
Fri, 22 Jan 2016 18:29:26 +0000 (11:29 -0700)
docs/api/menu.md

index 7b563d57801462f1341d7a047da03e23c0d918f0..ca35d4bb42a0226459129fd2e84a31c0167d218c 100644 (file)
@@ -239,16 +239,15 @@ will become properties of the constructed menu items.
 
 ### `Menu.popup([browserWindow, x, y, positioningItem])`
 
-* `browserWindow` BrowserWindow (optional)
-* `x` Number (optional)
-* `y` Number (**required** if `x` is used)
-* `positioningItem` Number (optional) _OS X_
-
-Pops up this menu as a context menu in the `browserWindow`. You
-can optionally provide a `x,y` coordinate to place the menu at, otherwise it
-will be placed at the current mouse cursor position. `positioningItem` is the
-index of the menu item to be positioned under the mouse cursor at the specified
-coordinates (only supported on OS X).
+* `browserWindow` BrowserWindow (optional) - Default is `null`.
+* `x` Number (optional) - Default is -1.
+* `y` Number (**required** if `x` is used) - Default is -1.
+* `positioningItem` Number (optional) _OS X_ - the index of the menu item to
+  be positioned under the mouse cursor at the specified coordinates.
+
+Pops up this menu as a context menu in the `browserWindow`. You can optionally
+provide a `x, y` coordinate to place the menu at, otherwise it will be placed
+at the current mouse cursor position.
 
 ### `Menu.append(menuItem)`