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.



4449
4450
4451
4452
4453
4454
4455
4456
4457
4458
4459
# File 'lib/ruby-macrodroid.rb', line 4449

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



4461
4462
4463
# File 'lib/ruby-macrodroid.rb', line 4461

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