Class: Motion::Project::Config

Inherits:
Object
  • Object
show all
Defined in:
lib/motion-screenshots.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#is_taking_screenshotsObject

Returns the value of attribute is_taking_screenshots.



16
17
18
# File 'lib/motion-screenshots.rb', line 16

def is_taking_screenshots
  @is_taking_screenshots
end

#screenshot_callbackObject

Returns the value of attribute screenshot_callback.



16
17
18
# File 'lib/motion-screenshots.rb', line 16

def screenshot_callback
  @screenshot_callback
end

Instance Method Details

#after_screenshots(&block) ⇒ Object Also known as: manage_screenshots



26
27
28
# File 'lib/motion-screenshots.rb', line 26

def after_screenshots(&block)
  @screenshot_callback = block
end

#before_screenshots(&block) ⇒ Object



20
21
22
23
24
# File 'lib/motion-screenshots.rb', line 20

def before_screenshots(&block)
  if is_taking_screenshots
    block.call
  end
end