Changeset a429907
- Timestamp:
- 2010-12-05T12:28:07Z (14 years ago)
- Branches:
- master
- Children:
- d88c92a
- Parents:
- fd65edb
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
doc/user-guide/commands.xml
rfd65edb ra429907 1540 1540 <short-description>Rename (renick) a buddy</short-description> 1541 1541 <syntax>rename <oldnick> <newnick></syntax> 1542 <syntax>rename -del <oldnick></syntax> 1542 1543 1543 1544 <description> 1544 1545 <para> 1545 1546 Renick a user in your buddy list. Very useful, in fact just very important, if you got a lot of people with stupid account names (or hard ICQ numbers). 1547 </para> 1548 1549 <para> 1550 <emphasis>rename -del</emphasis> can be used to erase your manually set nickname for a contact and reset it to what was automatically generated. 1546 1551 </para> 1547 1552 </description> -
irc.h
rfd65edb ra429907 339 339 /* irc_im.c */ 340 340 void bee_irc_channel_update( irc_t *irc, irc_channel_t *ic, irc_user_t *iu ); 341 void bee_irc_user_nick_reset( irc_user_t *iu ); 341 342 342 343 #endif -
irc_im.c
rfd65edb ra429907 361 361 362 362 return TRUE; 363 } 364 365 void bee_irc_user_nick_reset( irc_user_t *iu ) 366 { 367 bee_user_t *bu = iu->bu; 368 bee_user_flags_t online; 369 370 if( bu == FALSE ) 371 return; 372 373 /* In this case, pretend the user is offline. */ 374 if( ( online = bu->flags & BEE_USER_ONLINE ) ) 375 bu->flags &= ~BEE_USER_ONLINE; 376 377 nick_del( bu ); 378 bee_irc_user_nick_update( iu ); 379 380 bu->flags |= online; 363 381 } 364 382 -
root_commands.c
rfd65edb ra429907 774 774 { 775 775 irc_user_t *iu, *old; 776 777 iu = irc_user_by_name( irc, cmd[1] ); 776 gboolean del = g_strcasecmp( cmd[1], "-del" ) == 0; 777 778 iu = irc_user_by_name( irc, cmd[del ? 2 : 1] ); 778 779 779 780 if( iu == NULL ) 780 781 { 781 782 irc_usermsg( irc, "Nick `%s' does not exist", cmd[1] ); 783 } 784 else if( del ) 785 { 786 if( iu->bu ) 787 bee_irc_user_nick_reset( iu ); 788 irc_usermsg( irc, "Nickname reset to `%s'", iu->nick ); 782 789 } 783 790 else if( iu == irc->user )
Note: See TracChangeset
for help on using the changeset viewer.