Changeset 1195cec
- Timestamp:
- 2008-04-05T13:03:31Z (17 years ago)
- Branches:
- master
- Children:
- aa31117
- Parents:
- f35aee7
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
bitlbee.h
rf35aee7 r1195cec 160 160 gboolean bitlbee_shutdown( gpointer data, gint fd, b_input_condition cond ); 161 161 162 char *set_eval_root_nick( set_t *set, char *new_nick ); 163 162 164 extern global_t global; 163 165 -
doc/user-guide/commands.xml
rf35aee7 r1195cec 589 589 </bitlbee-setting> 590 590 591 <bitlbee-setting name="root_nick" type="string" scope="global"> 592 <default>root</default> 593 594 <description> 595 <para> 596 Normally the "bot" that takes all your BitlBee commands is called "root". If you don't like this name, you can rename it to anything else using the <emphasis>rename</emphasis> command, or by changing this setting. 597 </para> 598 </description> 599 </bitlbee-setting> 600 591 601 <bitlbee-setting name="save_on_quit" type="boolean" scope="global"> 592 602 <default>true</default> -
irc.c
rf35aee7 r1195cec 151 151 set_add( &irc->set, "private", "true", set_eval_bool, irc ); 152 152 set_add( &irc->set, "query_order", "lifo", NULL, irc ); 153 set_add( &irc->set, "root_nick", irc->mynick, set_eval_root_nick, irc ); 153 154 set_add( &irc->set, "save_on_quit", "true", set_eval_bool, irc ); 154 155 set_add( &irc->set, "simulate_netsplit", "true", set_eval_bool, irc ); -
root_commands.c
rf35aee7 r1195cec 603 603 g_free( irc->mynick ); 604 604 irc->mynick = g_strdup( cmd[2] ); 605 606 if( strcmp( cmd[0], "set_rename" ) != 0 ) 607 set_setstr( &irc->set, "root_nick", cmd[2] ); 605 608 } 606 609 else if( u->send_handler == buddy_send_handler ) … … 611 614 irc_usermsg( irc, "Nick successfully changed" ); 612 615 } 616 } 617 618 char *set_eval_root_nick( set_t *set, char *new_nick ) 619 { 620 irc_t *irc = set->data; 621 622 if( strcmp( irc->mynick, new_nick ) != 0 ) 623 { 624 char *cmd[] = { "set_rename", irc->mynick, new_nick, NULL }; 625 626 cmd_rename( irc, cmd ); 627 } 628 629 return strcmp( irc->mynick, new_nick ) == 0 ? new_nick : NULL; 613 630 } 614 631
Note: See TracChangeset
for help on using the changeset viewer.