Class: Tuile::Component::Tabs::TabSelectedEvent

Inherits:
Data
  • Object
show all
Includes:
Event
Defined in:
lib/tuile/component/tabs.rb,
sig/tuile.rbs

Overview

What #on_tab_selected fires — and what Tuile::Component::TabSheet#on_tab_selected fires too, with itself as the #source, which is the only thing telling the two apart.

Instance Attribute Summary collapse

Instance Attribute Details

#index ⇒ Integer? (readonly)

@return — the new selection's position, nil once the last tab has been removed.

Returns:

  • (Integer, nil)


161
# File 'lib/tuile/component/tabs.rb', line 161

TabSelectedEvent = Data.define(:source, :index, :tab) { include Tuile::Event }

#source ⇒ Tabs, TabSheet (readonly)

@return — whose selection changed.

Returns:



161
# File 'lib/tuile/component/tabs.rb', line 161

TabSelectedEvent = Data.define(:source, :index, :tab) { include Tuile::Event }

#tab ⇒ Tab? (readonly)

@return — the newly selected tab, nil with the index.

Returns:



161
# File 'lib/tuile/component/tabs.rb', line 161

TabSelectedEvent = Data.define(:source, :index, :tab) { include Tuile::Event }