Class: Fusuma::Plugin::Detectors::RotateDetector::Quantity

Inherits:
Object
  • Object
show all
Defined in:
lib/fusuma/plugin/detectors/rotate_detector.rb

Overview

quantity of gesture

Instance Method Summary collapse

Constructor Details

#initialize(angle:) ⇒ Quantity

Returns a new instance of Quantity.



164
165
166
# File 'lib/fusuma/plugin/detectors/rotate_detector.rb', line 164

def initialize(angle:)
  @angle = angle.abs
end

Instance Method Details

#to_fObject



168
169
170
# File 'lib/fusuma/plugin/detectors/rotate_detector.rb', line 168

def to_f
  @angle.to_f
end