Class: ShowPreviousGenerationAction

Inherits:
ShowPastGenerationAction show all
Defined in:
lib/life_game_viewer/view/actions.rb

Instance Method Summary collapse

Methods inherited from ShowPastGenerationAction

#should_be_enabled?

Methods inherited from MoveAction

#actionPerformed

Constructor Details

#initialize(table_model) ⇒ ShowPreviousGenerationAction

Returns a new instance of ShowPreviousGenerationAction.



82
83
84
# File 'lib/life_game_viewer/view/actions.rb', line 82

def initialize(table_model)
  super(table_model)
end

Instance Method Details

#captionObject



90
91
92
# File 'lib/life_game_viewer/view/actions.rb', line 90

def caption
  "Previous (4)"
end

#moveObject



86
87
88
# File 'lib/life_game_viewer/view/actions.rb', line 86

def move
  @table_model.go_to_previous_generation
end