lib/fusuma/plugin/buffers/gesture_buffer.rb in fusuma-2.1.0 vs lib/fusuma/plugin/buffers/gesture_buffer.rb in fusuma-2.2.0
- old
+ new
@@ -44,10 +44,15 @@
end
def ended?
return false if empty?
- @events.last.record.status == 'end'
+ case @events.last.record.status
+ when 'end', 'cancelled'
+ true
+ else
+ false
+ end
end
# @param attr [Symbol]
# @return [Float]
def sum_attrs(attr)