X-Git-Url: http://pileus.org/git/?p=grits;a=blobdiff_plain;f=src%2Fplugins%2Fsat.c;h=fae0c37044cb42c23cb9f508f2919a3156f74cb6;hp=edbe652834ae855349e3873bf4bcd6cd0cfb3c77;hb=7a6093db8586e5cb0625a6092ee8304af900941f;hpb=78550a3dc871c42dbc3e124abce78b902f978afd diff --git a/src/plugins/sat.c b/src/plugins/sat.c index edbe652..fae0c37 100644 --- a/src/plugins/sat.c +++ b/src/plugins/sat.c @@ -147,6 +147,13 @@ static void _on_location_changed(GisViewer *viewer, g_thread_create(_update_tiles, sat, FALSE, NULL); } +static gpointer _threaded_init(GisPluginSat *sat) +{ + _load_tile(sat->tiles, sat); + _update_tiles(sat); + return NULL; +} + /*********** * Methods * ***********/ @@ -165,8 +172,7 @@ GisPluginSat *gis_plugin_sat_new(GisViewer *viewer) sat->viewer = g_object_ref(viewer); /* Load initial tiles */ - _load_tile(sat->tiles, sat); - g_thread_create(_update_tiles, sat, FALSE, NULL); + g_thread_create((GThreadFunc)_threaded_init, sat, FALSE, NULL); /* Connect signals */ sat->sigid = g_signal_connect(sat->viewer, "location-changed",