Class: Twterm::Tab::Statuses::Home

Inherits:
AbstractStatusesTab show all
Includes:
Subscriber, Utils
Defined in:
lib/twterm/tab/statuses/home.rb

Instance Method Summary collapse

Methods included from Utils

check_type

Methods included from Subscriber

included, #subscribe, #unsubscribe

Methods inherited from AbstractStatusesTab

#append, #delete, #destroy_status, #drawable_item_count, #favorite, #items, #matches?, #open_link, #prepend, #quote, #reply, #respond_to_key, #retweet, #search_query_window, #show_conversation, #show_user, #statuses, #total_item_count

Methods included from Loadable

#initially_loaded!, #initially_loaded?

Methods included from Twterm::Tab::Searchable

#matches?, #search_query_window

Methods included from Twterm::Tab::Scrollable

#scroller, #total_item_count

Methods included from Publisher

#publish

Methods inherited from AbstractTab

#==, #find_or_fetch_list, #find_or_fetch_status, #find_or_fetch_user, #render, #respond_to_key

Constructor Details

#initialize(app, client) ⇒ Home

Returns a new instance of Home.



20
21
22
23
24
25
26
27
28
29
# File 'lib/twterm/tab/statuses/home.rb', line 20

def initialize(app, client)
  super(app, client)

  reload.then do
    initially_loaded!
    scroller.move_to_top
  end

  @auto_reloader = Scheduler.new(180) { reload }
end

Instance Method Details

#closeObject



12
13
14
# File 'lib/twterm/tab/statuses/home.rb', line 12

def close
  fail NotClosableError
end

#fetchObject



16
17
18
# File 'lib/twterm/tab/statuses/home.rb', line 16

def fetch
  client.home_timeline
end

#titleObject



31
32
33
# File 'lib/twterm/tab/statuses/home.rb', line 31

def title
  'Home'.freeze
end