Class: MittensUi::FileMenu
Instance Attribute Summary
Attributes inherited from Core
Instance Method Summary collapse
-
#initialize(menu_items, options = {}) ⇒ FileMenu
constructor
A new instance of FileMenu.
- #render ⇒ Object
Methods inherited from Core
#hidden?, #hide, #remove, #show
Methods included from Helpers
#icon_map, #list_system_icons, #set_margin_from_opts_for
Constructor Details
#initialize(menu_items, options = {}) ⇒ FileMenu
Returns a new instance of FileMenu.
5 6 7 8 9 10 11 12 13 14 15 16 17 18 |
# File 'lib/mittens_ui/file_menu.rb', line 5 def initialize(, = {}) @menu_items = @menu_bar = Gtk::MenuBar.new # menu_name => menu_item(gtk) @raw_menu_items = {} super(@menu_bar, ) end |
Instance Method Details
#render ⇒ Object
20 21 22 23 |
# File 'lib/mittens_ui/file_menu.rb', line 20 def render $vertical_box.pack_start(@menu_bar) return self end |