Gio.Menu
const Gio = imports.gi.Gio; let menu = new Gio.Menu();
Gio.Menu is a simple implementation of Gio.MenuModel. You populate a Gio.Menu by adding Gio.MenuItem instances to it.
There are some convenience functions to allow you to directly add items (avoiding Gio.MenuItem) for the common cases. To add a regular item, use Gio.Menu.prototype.insert. To add a section, use Gio.Menu.prototype.insert_section. To add a submenu, use Gio.Menu.prototype.insert_submenu.
Since 2.32
Hierarchy
-
GObject.Object
-
Gio.MenuModel
- Gio.Menu
-
Constructors
Methods
- Gio.Menu.prototype.append
- Gio.Menu.prototype.append_item
- Gio.Menu.prototype.append_section
- Gio.Menu.prototype.append_submenu
- Gio.Menu.prototype.freeze
- Gio.Menu.prototype.insert
- Gio.Menu.prototype.insert_item
- Gio.Menu.prototype.insert_section
- Gio.Menu.prototype.insert_submenu
- Gio.Menu.prototype.prepend
- Gio.Menu.prototype.prepend_item
- Gio.Menu.prototype.prepend_section
- Gio.Menu.prototype.prepend_submenu
- Gio.Menu.prototype.remove
- Gio.Menu.prototype.remove_all