Class: SetBrightnessAction

Inherits:
ScreenAction show all
Defined in:
lib/ruby-macrodroid.rb

Overview

Category: Screen

Instance Attribute Summary

Attributes inherited from Action

#constraints

Attributes inherited from MacroObject

#options, #siguid, #type

Instance Method Summary collapse

Methods inherited from Action

#invoke

Methods inherited from MacroObject

#to_h

Constructor Details

#initialize(h = {}) ⇒ SetBrightnessAction

Returns a new instance of SetBrightnessAction.



4457
4458
4459
4460
4461
4462
4463
4464
4465
4466
4467
# File 'lib/ruby-macrodroid.rb', line 4457

def initialize(h={})

  options = {
    brightness_percent: 81,
    force_pie_mode: false,
    brightness: 0
  }

  super(options.merge h)

end

Instance Method Details

#to_s(colour: false) ⇒ Object Also known as: to_summary



4469
4470
4471
# File 'lib/ruby-macrodroid.rb', line 4469

def to_s(colour: false)
  'SetBrightnessAction ' + @h.inspect
end