Changeset 12655


Ignore:
Timestamp:
Aug 8, 2011, 5:10:55 PM (10 years ago)
Author:
jordan
Message:

remove the gtr_idle_add() portability wrapper around gdk_threads_add_idle() -- it's unnecessary now that the minimum gtk version's been bumped.

Location:
trunk/gtk
Files:
7 edited

Legend:

Unmodified
Added
Removed
  • trunk/gtk/favicon.c

    r12638 r12655  
    1818
    1919#include "favicon.h"
    20 #include "util.h" /* gtr_idle_add() */
     20#include "util.h" /* gtr_get_host_from_url() */
    2121
    2222#define IMAGE_TYPES 4
     
    141141    fav->len = len;
    142142
    143     gtr_idle_add( favicon_web_done_idle_cb, fav );
     143    gdk_threads_add_idle( favicon_web_done_idle_cb, fav );
    144144}
    145145
  • trunk/gtk/filter.c

    r12639 r12655  
    2323#include "hig.h" /* GUI_PAD */
    2424#include "tr-core.h" /* MC_TORRENT */
    25 #include "util.h" /* gtr_idle_add() */
     25#include "util.h" /* gtr_get_host_from_url() */
    2626
    2727static GQuark DIRTY_KEY = 0;
     
    379379        GSourceFunc func = (GSourceFunc) category_filter_model_update;
    380380        g_object_set_qdata( o, DIRTY_KEY, GINT_TO_POINTER(1) );
    381         gtr_idle_add( func, category_model );
     381        gdk_threads_add_idle( func, category_model );
    382382    }
    383383}
     
    751751        GSourceFunc func = (GSourceFunc) activity_filter_model_update;
    752752        g_object_set_qdata( o, DIRTY_KEY, GINT_TO_POINTER(1) );
    753         gtr_idle_add( func, activity_model );
     753        gdk_threads_add_idle( func, activity_model );
    754754    }
    755755}
  • trunk/gtk/main.c

    r12654 r12655  
    335335
    336336    if( data->refresh_actions_tag == 0 )
    337         data->refresh_actions_tag = gtr_idle_add( refresh_actions, data );
     337        data->refresh_actions_tag = gdk_threads_add_idle( refresh_actions, data );
    338338}
    339339
     
    468468            data->id = tr_torrentId( tor );
    469469            data->core = cbdata->core;
    470             gtr_idle_add( rpc_torrent_add_idle, data );
     470            gdk_threads_add_idle( rpc_torrent_add_idle, data );
    471471            break;
    472472        }
     
    478478            data->core = cbdata->core;
    479479            data->delete_files = type == TR_RPC_TORRENT_TRASHING;
    480             gtr_idle_add( rpc_torrent_remove_idle, data );
     480            gdk_threads_add_idle( rpc_torrent_remove_idle, data );
    481481            status = TR_RPC_NOREMOVE;
    482482            break;
     
    10541054    gdk_threads_enter( );
    10551055    gtr_core_close( cbdata->core );
    1056     gtr_idle_add( on_session_closed, gdata );
     1056    gdk_threads_add_idle( on_session_closed, gdata );
    10571057    gdk_threads_leave( );
    10581058    return NULL;
     
    14431443
    14441444    if( data->update_model_soon_tag == 0 )
    1445         data->update_model_soon_tag = gtr_idle_add( update_model_once, data );
     1445        data->update_model_soon_tag = gdk_threads_add_idle( update_model_once, data );
    14461446}
    14471447
  • trunk/gtk/tr-core.c

    r12654 r12655  
    981981        data->torrent_id = tr_torrentId( tor );
    982982        g_object_ref( G_OBJECT( data->core ) );
    983         gtr_idle_add( on_torrent_completeness_changed_idle, data );
     983        gdk_threads_add_idle( on_torrent_completeness_changed_idle, data );
    984984    }
    985985}
     
    10601060    data->torrent_id = tr_torrentId( tor );
    10611061    g_object_ref( G_OBJECT( data->core ) );
    1062     gtr_idle_add( on_torrent_metadata_changed_idle, data );
     1062    gdk_threads_add_idle( on_torrent_metadata_changed_idle, data );
    10631063}
    10641064
     
    12791279    tr_ctorSetMetainfo( data->ctor, response, response_byte_count );
    12801280
    1281     gtr_idle_add( on_url_done_idle, data );
     1281    gdk_threads_add_idle( on_url_done_idle, data );
    12821282}
    12831283
     
    17671767    struct evbuffer * buf = evbuffer_new( );
    17681768    evbuffer_add_buffer( buf, response );
    1769     gtr_idle_add( core_read_rpc_response_idle, buf );
     1769    gdk_threads_add_idle( core_read_rpc_response_idle, buf );
    17701770}
    17711771
  • trunk/gtk/tr-window.c

    r12639 r12655  
    346346onAltSpeedToggled( tr_session * s UNUSED, bool isEnabled UNUSED, bool byUser UNUSED, void * p )
    347347{
    348     gtr_idle_add( onAltSpeedToggledIdle, p );
     348    gdk_threads_add_idle( onAltSpeedToggledIdle, p );
    349349}
    350350
  • trunk/gtk/util.c

    r12654 r12655  
    621621***/
    622622
    623 guint
    624 gtr_idle_add( GSourceFunc function, gpointer data )
    625 {
    626     return gdk_threads_add_idle( function, data );
    627 }
    628 
    629623void
    630624gtr_http_failure_dialog( GtkWidget * parent, const char * url, long response_code )
  • trunk/gtk/util.h

    r12654 r12655  
    109109***/
    110110
    111 /* backwards-compatible wrapper around gdk_threads_add_idle() */
    112 guint gtr_idle_add( GSourceFunc  func, gpointer data );
    113 
    114111/* backwards-compatible wrapper around gtk_widget_set_visible() */
    115112void gtr_widget_set_visible( GtkWidget *, gboolean );
Note: See TracChangeset for help on using the changeset viewer.