Changeset 5c7b45c


Ignore:
Timestamp:
2010-07-04T13:36:08Z (14 years ago)
Author:
Wilmer van der Gaast <wilmer@…>
Branches:
master
Children:
f537044
Parents:
c8eeadd
Message:

Auto joins for chatrooms.

Files:
3 edited

Legend:

Unmodified
Added
Removed
  • irc_im.c

    rc8eeadd r5c7b45c  
    3030
    3131static const struct irc_user_funcs irc_user_im_funcs;
     32
     33static void bee_irc_imc_connected( struct im_connection *ic )
     34{
     35        irc_t *irc = (irc_t*) ic->bee->ui_data;
     36       
     37        irc_channel_auto_joins( irc, ic->acc );
     38}
     39
     40static void bee_irc_imc_disconnected( struct im_connection *ic )
     41{
     42        /* Maybe try to send /QUITs here instead of later on. */
     43}
    3244
    3345static gboolean bee_irc_user_new( bee_t *bee, bee_user_t *bu )
     
    823835
    824836const struct bee_ui_funcs irc_ui_funcs = {
     837        bee_irc_imc_connected,
     838        bee_irc_imc_disconnected,
     839       
    825840        bee_irc_user_new,
    826841        bee_irc_user_free,
  • protocols/bee.h

    rc8eeadd r5c7b45c  
    8282typedef struct bee_ui_funcs
    8383{
     84        void (*imc_connected)( struct im_connection *ic );
     85        void (*imc_disconnected)( struct im_connection *ic );
     86       
    8487        gboolean (*user_new)( bee_t *bee, struct bee_user *bu );
    8588        gboolean (*user_free)( bee_t *bee, struct bee_user *bu );
  • protocols/nogaim.c

    rc8eeadd r5c7b45c  
    287287        ic->acc->auto_reconnect_delay = 0;
    288288       
     289        if( ic->bee->ui->imc_connected )
     290                ic->bee->ui->imc_connected( ic );
     291       
    289292        /*
    290293        for( c = irc->chatrooms; c; c = c->next )
     
    328331        else
    329332                ic->flags |= OPT_LOGGING_OUT;
     333       
     334        if( ic->bee->ui->imc_disconnected )
     335                ic->bee->ui->imc_disconnected( ic );
    330336       
    331337        imcb_log( ic, "Signing off.." );
Note: See TracChangeset for help on using the changeset viewer.