Class: UI::Storage::ModeHandler

Inherits:
Object
  • Object
show all
Defined in:
docs/4_Systems_200_Storage.rb

Overview

Class responsive of handling the mode for the PC UI

Constant Summary collapse

AVAILABLE_MODES =

List the available modes

%i[pokemon item battle]
AVAILABLE_SELECTION_MODES =

List the available modes

%i[detailed fast grouped]

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(mode, selection_mode) ⇒ ModeHandler

Create a new Mode Handler

Parameters:

  • selection_mode (Symbol)

    :detailed, :fast or :grouped



430
431
# File 'docs/4_Systems_200_Storage.rb', line 430

def initialize(mode, selection_mode)
end

Instance Attribute Details

#modeSymbol

Get the current mode

Returns:

  • (Symbol)

    :pokemon, :item, :battle, :box



419
420
421
# File 'docs/4_Systems_200_Storage.rb', line 419

def mode
  @mode
end

#selection_modeSymbol

box mode disabled for now Get the current selection mode

Returns:

  • (Symbol)

    :detailed, :fast, :grouped



425
426
427
# File 'docs/4_Systems_200_Storage.rb', line 425

def selection_mode
  @selection_mode
end

Instance Method Details

#add_mode_ui(mode_ui)

Add a mode ui

Parameters:



434
435
# File 'docs/4_Systems_200_Storage.rb', line 434

def add_mode_ui(mode_ui)
end

#add_selection_mode_ui(selection_mode_ui)

Add a selection mode ui

Parameters:



438
439
# File 'docs/4_Systems_200_Storage.rb', line 438

def add_selection_mode_ui(selection_mode_ui)
end

#swap_modeSymbol

Swap the mode

Returns:

  • (Symbol)


450
451
# File 'docs/4_Systems_200_Storage.rb', line 450

def swap_mode
end

#swap_selection_modeSymbol

Swap the selection mode

Returns:

  • (Symbol)


454
455
# File 'docs/4_Systems_200_Storage.rb', line 454

def swap_selection_mode
end