Class: Context::Widget
Direct Known Subclasses
Instance Attribute Summary collapse
-
#delegate ⇒ Object
readonly
Returns the value of attribute delegate.
Instance Method Summary collapse
-
#add(widget) ⇒ Object
Use this widget as a container for the passed widget.
-
#addedTo(widget) ⇒ Object
This method is called after the widget has been successfully added to another widget.
- #eql?(widget) ⇒ Boolean
-
#initialize(delegate) ⇒ Widget
constructor
A new instance of Widget.
- #remove(widget) ⇒ Object
-
#removedFrom(widget) ⇒ Object
This method is called after the widget has been successfully removed from another widget.
Constructor Details
#initialize(delegate) ⇒ Widget
Returns a new instance of Widget.
7 8 9 |
# File 'lib/Context/Widget.rb', line 7 def initialize(delegate) @delegate = delegate end |
Instance Attribute Details
#delegate ⇒ Object (readonly)
Returns the value of attribute delegate.
5 6 7 |
# File 'lib/Context/Widget.rb', line 5 def delegate @delegate end |
Instance Method Details
#add(widget) ⇒ Object
Use this widget as a container for the passed widget
26 27 28 29 |
# File 'lib/Context/Widget.rb', line 26 def add() # This is an abstract method, the child classes should # implement this end |
#addedTo(widget) ⇒ Object
This method is called after the widget has been successfully added to another widget
13 14 15 16 |
# File 'lib/Context/Widget.rb', line 13 def addedTo() # This is an abstract method, the child classes should # implement this end |
#eql?(widget) ⇒ Boolean
36 37 38 |
# File 'lib/Context/Widget.rb', line 36 def eql?() @delegate.eql?(.delegate) end |
#remove(widget) ⇒ Object
31 32 33 34 |
# File 'lib/Context/Widget.rb', line 31 def remove() # This is an abstract method, the child classes should # implement this end |
#removedFrom(widget) ⇒ Object
This method is called after the widget has been successfully removed from another widget
20 21 22 23 |
# File 'lib/Context/Widget.rb', line 20 def removedFrom() # This is an abstract method, the child classes should # implement this end |