Changeset a2640485 for perl/modules/Twitter/lib/BarnOwl/Module/Twitter.pm
- Timestamp:
- May 23, 2010, 12:07:41 PM (15 years ago)
- Branches:
- master, release-1.10, release-1.7, release-1.8, release-1.9
- Children:
- 5756999
- Parents:
- 1fd469d4
- git-author:
- Nelson Elhage <nelhage@mit.edu> (05/23/10 12:06:23)
- git-committer:
- Nelson Elhage <nelhage@mit.edu> (05/23/10 12:07:41)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
perl/modules/Twitter/lib/BarnOwl/Module/Twitter.pm
r47a5e46 ra2640485 26 26 our @twitter_handles = (); 27 27 our $default_handle = undef; 28 29 our $prefix;30 28 31 29 my $desc = <<'END_DESC'; … … 298 296 usage => 'twitter-count-chars', 299 297 description => <<END_DESCRIPTION 300 Displays the number of characters entered in the edit window so far. Correctly 301 takes into account any \@user prefix that will be added by the Twitter plugin. 298 Displays the number of characters entered in the edit window so far. 302 299 END_DESCRIPTION 303 300 }); … … 314 311 } 315 312 } 316 undef $prefix;317 313 BarnOwl::start_edit_win("What's happening?" . (defined $account ? " ($account)" : ""), sub{twitter($account, shift)}); 318 314 } … … 323 319 die("Usage: $cmd USER\n") unless $user; 324 320 my $account = find_account_default(shift); 325 undef $prefix;326 321 BarnOwl::start_edit_win("$cmd $user " . ($account->nickname||""), 327 322 sub { $account->twitter_direct($user, shift) }); … … 334 329 my $account = find_account_default(shift); 335 330 336 $prefix = "\@$user ";337 331 BarnOwl::start_edit_win("Reply to \@" . $user . ($account->nickname ? (" on " . $account->nickname) : ""), 338 332 sub { $account->twitter_atreply($user, $id, shift) }); 333 BarnOwl::Editwin::insert_text("\@$user "); 339 334 } 340 335 … … 378 373 }; 379 374 my $len = length($text); 380 $len += length($prefix) if $prefix;381 375 BarnOwl::message($len); 382 376 return $len;
Note: See TracChangeset
for help on using the changeset viewer.