Changeset 0e8b3e8
- Timestamp:
- 2010-06-07T15:21:21Z (15 years ago)
- Branches:
- master
- Children:
- c5aefa4
- Parents:
- 56699f0
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
irc.c
r56699f0 r0e8b3e8 100 100 b->ui = &irc_ui_funcs; 101 101 102 s = set_add( &b->set, "away_devoice", "true", NULL/*set_eval_away_devoice*/, irc );102 s = set_add( &b->set, "away_devoice", "true", set_eval_away_devoice, irc ); 103 103 s = set_add( &b->set, "charset", "utf-8", set_eval_charset, irc ); 104 104 s = set_add( &b->set, "default_target", "root", NULL, irc ); … … 819 819 return value; 820 820 } 821 822 char *set_eval_away_devoice( set_t *set, char *value ) 823 { 824 irc_t *irc = set->data; 825 826 if( !is_bool( value ) ) 827 return SET_INVALID; 828 829 /* The usual problem: The setting isn't actually changed at this 830 point and we need it to be, so do it by hand. */ 831 g_free( set->value ); 832 set->value = g_strdup( value ); 833 834 bee_irc_channel_update( irc, NULL, NULL ); 835 836 return value; 837 } -
irc_im.c
r56699f0 r0e8b3e8 169 169 irc_channel_user_set_mode( ic, iu, ( iu->bu->flags & BEE_USER_AWAY ) ? 170 170 0 : IRC_CHANNEL_USER_VOICE ); 171 else 172 irc_channel_user_set_mode( ic, iu, 0 ); 171 173 } 172 174 } -
protocols/nogaim.c
r56699f0 r0e8b3e8 536 536 return bee_user_by_handle( ic->bee, ic, handle ); 537 537 } 538 539 540 /* Misc. BitlBee stuff which shouldn't really be here */541 #if 0542 char *set_eval_away_devoice( set_t *set, char *value )543 {544 irc_t *irc = set->data;545 int st;546 547 if( !is_bool( value ) )548 return SET_INVALID;549 550 st = bool2int( value );551 552 /* Horror.... */553 554 if( st != set_getbool( &irc->b->set, "away_devoice" ) )555 {556 char list[80] = "";557 user_t *u = irc->users;558 int i = 0, count = 0;559 char pm;560 char v[80];561 562 if( st )563 pm = '+';564 else565 pm = '-';566 567 while( u )568 {569 if( u->ic && u->online && !u->away )570 {571 if( ( strlen( list ) + strlen( u->nick ) ) >= 79 )572 {573 for( i = 0; i < count; v[i++] = 'v' ); v[i] = 0;574 irc_write( irc, ":%s MODE %s %c%s%s",575 irc->myhost,576 irc->channel, pm, v, list );577 578 *list = 0;579 count = 0;580 }581 582 sprintf( list + strlen( list ), " %s", u->nick );583 count ++;584 }585 u = u->next;586 }587 588 /* $v = 'v' x $i */589 for( i = 0; i < count; v[i++] = 'v' ); v[i] = 0;590 irc_write( irc, ":%s MODE %s %c%s%s", irc->myhost,591 irc->channel, pm, v, list );592 }593 594 return value;595 }596 #endif597 538 598 539 /* The plan is to not allow straight calls to prpl functions anymore, but do
Note: See TracChangeset
for help on using the changeset viewer.