Changeset dfaa47d
- Timestamp:
- May 14, 2009, 11:41:34 PM (15 years ago)
- Branches:
- master, release-1.10, release-1.4, release-1.5, release-1.6, release-1.7, release-1.8, release-1.9
- Children:
- cdaf294
- Parents:
- e1b136bf
- git-author:
- Geoffrey Thomas <geofft@mit.edu> (05/14/09 23:39:12)
- git-committer:
- Geoffrey Thomas <geofft@mit.edu> (05/14/09 23:41:34)
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
perl/modules/IRC/lib/BarnOwl/Message/IRC.pm
rf79d6a2 rdfaa47d 70 70 sub context {shift->{network};} 71 71 sub subcontext {shift->{recipient};} 72 sub personal_context {"on " . shift->{network};} 72 73 73 74 sub long_sender {shift->{from} || ""}; -
perl/modules/Jabber/lib/BarnOwl/Message/Jabber.pm
r9375f8c rdfaa47d 50 50 sub subcontext { 51 51 return shift->subject || ""; 52 } 53 54 sub personal_context { 55 return "to " . shift->to; 52 56 } 53 57 -
perlwrap.pm
r2b6de9d rdfaa47d 390 390 sub pretty_sender { return shift->sender; } 391 391 sub pretty_recipient { return shift->recipient; } 392 393 # Override if you want a context (instance, network, etc.) on personals 394 sub personal_context { return ""; } 392 395 393 396 sub delete { … … 584 587 my ($m) = @_; 585 588 return ((lc($m->class) eq "message") 586 && (lc($m->instance) eq "personal")587 589 && $m->is_private); 588 590 } … … 601 603 my ($m) = @_; 602 604 return strip_realm($m->recipient); 605 } 606 607 sub personal_context { 608 my ($m) = @_; 609 if (lc($m->instance) eq "personal") { 610 return ""; 611 } else { 612 return "-i " . $m->instance; 613 } 603 614 } 604 615 … … 1023 1034 my $header; 1024 1035 if ( $m->is_personal ) { 1036 my $personal_context = $m->personal_context; 1037 $personal_context = ' [' . $personal_context . ']' if $personal_context; 1038 1025 1039 if ( $m->direction eq "out" ) { 1026 $header = ucfirst $m->type . " sent to " . $m->pretty_recipient;1040 $header = ucfirst $m->type . $personal_context . " sent to " . $m->pretty_recipient; 1027 1041 } else { 1028 $header = ucfirst $m->type . " from " . $m->pretty_sender;1042 $header = ucfirst $m->type . $personal_context . " from " . $m->pretty_sender; 1029 1043 } 1030 1044 } else {
Note: See TracChangeset
for help on using the changeset viewer.