From b20606c7187551ad184dc4cc15bf7952cab26db9 Mon Sep 17 00:00:00 2001 From: Zeke Sikelianos Date: Tue, 12 Jul 2016 21:47:28 -0700 Subject: [PATCH] fix heading levels in Menu doc --- docs/api/menu.md | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/docs/api/menu.md b/docs/api/menu.md index d54469545e6d..05af79a53203 100644 --- a/docs/api/menu.md +++ b/docs/api/menu.md @@ -183,11 +183,11 @@ Menu.setApplicationMenu(menu); Creates a new menu. -## Methods +### Static Methods -The `menu` class has the following methods: +The `menu` class has the following static methods: -### `Menu.setApplicationMenu(menu)` +#### `Menu.setApplicationMenu(menu)` * `menu` Menu @@ -196,11 +196,11 @@ will be set as each window's top menu. **Note:** This API has to be called after the `ready` event of `app` module. -### `Menu.getApplicationMenu()` +#### `Menu.getApplicationMenu()` Returns the application menu (an instance of `Menu`), if set, or `null`, if not set. -### `Menu.sendActionToFirstResponder(action)` _macOS_ +#### `Menu.sendActionToFirstResponder(action)` _macOS_ * `action` String @@ -211,7 +211,7 @@ emulating default Cocoa menu behaviors, usually you would just use the See the [macOS Cocoa Event Handling Guide](https://developer.apple.com/library/mac/documentation/Cocoa/Conceptual/EventOverview/EventArchitecture/EventArchitecture.html#//apple_ref/doc/uid/10000060i-CH3-SW7) for more information on macOS' native actions. -### `Menu.buildFromTemplate(template)` +#### `Menu.buildFromTemplate(template)` * `template` Array @@ -221,11 +221,11 @@ Generally, the `template` is just an array of `options` for constructing a You can also attach other fields to the element of the `template` and they will become properties of the constructed menu items. -## Instance Methods +### Instance Methods The `menu` object has the following instance methods: -### `menu.popup([browserWindow, x, y, positioningItem])` +#### `menu.popup([browserWindow, x, y, positioningItem])` * `browserWindow` BrowserWindow (optional) - Default is `null`. * `x` Number (optional) - Default is -1. @@ -238,24 +238,24 @@ 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)` +#### `menu.append(menuItem)` * `menuItem` MenuItem Appends the `menuItem` to the menu. -### `menu.insert(pos, menuItem)` +#### `menu.insert(pos, menuItem)` * `pos` Integer * `menuItem` MenuItem Inserts the `menuItem` to the `pos` position of the menu. -## Instance Properties +### Instance Properties `menu` objects also have the following properties: -### `menu.items` +#### `menu.items` Get an array containing the menu's items.