Class: RUI::GuiBuilder::ActionList::Entry

Inherits:
Object
  • Object
show all
Defined in:
lib/rui/toolkits/qtbase/gui_builder.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(parent) ⇒ Entry

Returns a new instance of Entry.



139
140
141
142
# File 'lib/rui/toolkits/qtbase/gui_builder.rb', line 139

def initialize(parent)
  @parent = parent
  @actions = []
end

Instance Attribute Details

#parentObject (readonly)

Returns the value of attribute parent.



137
138
139
# File 'lib/rui/toolkits/qtbase/gui_builder.rb', line 137

def parent
  @parent
end

Instance Method Details

#add_action(action) ⇒ Object



144
145
146
147
# File 'lib/rui/toolkits/qtbase/gui_builder.rb', line 144

def add_action(action)
  @parent.add_action(action)
  @actions << action
end

#clearObject



149
150
151
152
153
154
# File 'lib/rui/toolkits/qtbase/gui_builder.rb', line 149

def clear
  @actions.each do |action|
    action.dispose
  end
  @actions = []
end