Class: Plushie::Event::Sensor
- Inherits:
-
Data
- Object
- Data
- Plushie::Event::Sensor
- Defined in:
- lib/plushie/event.rb
Overview
Sensor events for detecting widget size changes. Triggered when a sensor widget's measured dimensions change.
Instance Attribute Summary collapse
-
#height ⇒ Object
readonly
Returns the value of attribute height.
-
#height [Float, nil] measured height([Float, nil]) ⇒ Object
readonly
Sensor events for detecting widget size changes.
-
#id ⇒ Object
readonly
Returns the value of attribute id.
-
#id [String] sensor widget ID([String]) ⇒ Object
readonly
Sensor events for detecting widget size changes.
-
#scope ⇒ Object
readonly
Returns the value of attribute scope.
-
#scope [Array<String>] reversed ancestor scope chain([Array<String>]) ⇒ Object
readonly
Sensor events for detecting widget size changes.
-
#type ⇒ Object
readonly
Returns the value of attribute type.
-
#type [Symbol] :resized([Symbol]) ⇒ Object
readonly
Sensor events for detecting widget size changes.
-
#width ⇒ Object
readonly
Returns the value of attribute width.
-
#width [Float, nil] measured width([Float, nil]) ⇒ Object
readonly
Sensor events for detecting widget size changes.
Instance Method Summary collapse
-
#initialize(type:, id:, width: nil, height: nil, scope: []) ⇒ Sensor
constructor
A new instance of Sensor.
Constructor Details
#initialize(type:, id:, width: nil, height: nil, scope: []) ⇒ Sensor
Returns a new instance of Sensor.
234 235 236 |
# File 'lib/plushie/event.rb', line 234 def initialize(type:, id:, width: nil, height: nil, scope: []) super end |
Instance Attribute Details
#height ⇒ Object (readonly)
Returns the value of attribute height
233 234 235 |
# File 'lib/plushie/event.rb', line 233 def height @height end |
#height [Float, nil] measured height([Float, nil]) ⇒ Object (readonly)
Sensor events for detecting widget size changes. Triggered when a sensor widget's measured dimensions change.
233 234 235 236 237 |
# File 'lib/plushie/event.rb', line 233 Sensor = Data.define(:type, :id, :width, :height, :scope) do def initialize(type:, id:, width: nil, height: nil, scope: []) super end end |
#id ⇒ Object (readonly)
Returns the value of attribute id
233 234 235 |
# File 'lib/plushie/event.rb', line 233 def id @id end |
#id [String] sensor widget ID([String]) ⇒ Object (readonly)
Sensor events for detecting widget size changes. Triggered when a sensor widget's measured dimensions change.
233 234 235 236 237 |
# File 'lib/plushie/event.rb', line 233 Sensor = Data.define(:type, :id, :width, :height, :scope) do def initialize(type:, id:, width: nil, height: nil, scope: []) super end end |
#scope ⇒ Object (readonly)
Returns the value of attribute scope
233 234 235 |
# File 'lib/plushie/event.rb', line 233 def scope @scope end |
#scope [Array<String>] reversed ancestor scope chain([Array<String>]) ⇒ Object (readonly)
Sensor events for detecting widget size changes. Triggered when a sensor widget's measured dimensions change.
233 234 235 236 237 |
# File 'lib/plushie/event.rb', line 233 Sensor = Data.define(:type, :id, :width, :height, :scope) do def initialize(type:, id:, width: nil, height: nil, scope: []) super end end |
#type ⇒ Object (readonly)
Returns the value of attribute type
233 234 235 |
# File 'lib/plushie/event.rb', line 233 def type @type end |
#type [Symbol] :resized([Symbol]) ⇒ Object (readonly)
Sensor events for detecting widget size changes. Triggered when a sensor widget's measured dimensions change.
233 234 235 236 237 |
# File 'lib/plushie/event.rb', line 233 Sensor = Data.define(:type, :id, :width, :height, :scope) do def initialize(type:, id:, width: nil, height: nil, scope: []) super end end |
#width ⇒ Object (readonly)
Returns the value of attribute width
233 234 235 |
# File 'lib/plushie/event.rb', line 233 def width @width end |
#width [Float, nil] measured width([Float, nil]) ⇒ Object (readonly)
Sensor events for detecting widget size changes. Triggered when a sensor widget's measured dimensions change.
233 234 235 236 237 |
# File 'lib/plushie/event.rb', line 233 Sensor = Data.define(:type, :id, :width, :height, :scope) do def initialize(type:, id:, width: nil, height: nil, scope: []) super end end |