Class: Flumtter::TimeLine::DeletedTweet

Inherits:
Base
  • Object
show all
Defined in:
lib/flumtter/app/plugins/timeline/deleted_tweet.rb

Defined Under Namespace

Classes: TweetNotFound

Instance Method Summary collapse

Methods inherited from Base

[], #to_s

Methods included from Util

#command_value_regexp, #dialog_for_index, #error, #error_handler, #id2obj, #if_tweet, #index_regexp, #index_with_dialog, #on_event, #parse_index, #parse_time, #sarastire, #sarastire_user, #screen_name_regexp

Constructor Details

#initialize(object, twitter) ⇒ DeletedTweet

Returns a new instance of DeletedTweet.

Raises:



8
9
10
11
12
# File 'lib/flumtter/app/plugins/timeline/deleted_tweet.rb', line 8

def initialize(object, twitter)
  object = @@elements.find{|e|e.is_a?(Twitter::Tweet) && e.id == object.id}
  raise TweetNotFound if object.nil?
  super(object, twitter)
end

Instance Method Details

#colorObject



14
15
16
# File 'lib/flumtter/app/plugins/timeline/deleted_tweet.rb', line 14

def color
  Setting.dig(:color, :timeline, :deletedtweet) || :white
end

#headerObject



18
19
20
# File 'lib/flumtter/app/plugins/timeline/deleted_tweet.rb', line 18

def header
  "DELETED ".ljust(Terminal.x, ?-)
end