File tree Expand file tree Collapse file tree 2 files changed +6
-19
lines changed
Expand file tree Collapse file tree 2 files changed +6
-19
lines changed Original file line number Diff line number Diff line change @@ -136,16 +136,10 @@ clock_map_init (ClockMap *this)
136136
137137 for (i = 0 ; i < MARKER_NB ; i ++ ) {
138138 char * resource ;
139- GInputStream * stream ;
140139
141140 resource = g_strconcat (CLOCK_RESOURCE_PATH "icons/" , marker_files [i ], NULL );
142- stream = g_resources_open_stream (resource , 0 , NULL );
141+ priv -> location_marker_pixbuf [ i ] = gdk_pixbuf_new_from_resource (resource , NULL );
143142 g_free (resource );
144-
145- if (stream != NULL ) {
146- priv -> location_marker_pixbuf [i ] = gdk_pixbuf_new_from_stream (stream , NULL , NULL );
147- g_object_unref (stream );
148- }
149143 }
150144}
151145
@@ -217,17 +211,10 @@ clock_map_refresh (ClockMap *this)
217211 }
218212
219213 if (!priv -> stock_map_pixbuf ) {
220- GInputStream * stream = g_resources_open_stream (CLOCK_RESOURCE_PATH "icons/clock-map.png" ,
221- 0 , NULL );
222- if (stream != NULL ) {
223- GdkPixbuf * pixbuf = gdk_pixbuf_new_from_stream_at_scale (stream ,
224- priv -> width , priv -> height ,
225- FALSE,
226- NULL , NULL );
227- g_object_unref (stream );
228-
229- priv -> stock_map_pixbuf = pixbuf ;
230- }
214+ priv -> stock_map_pixbuf = gdk_pixbuf_new_from_resource_at_scale (CLOCK_RESOURCE_PATH "icons/clock-map.png" ,
215+ priv -> width , priv -> height ,
216+ FALSE,
217+ NULL );
231218 }
232219
233220 clock_map_place_locations (this );
Original file line number Diff line number Diff line change 5555LT_LIB_M
5656
5757LIBMATE_DESKTOP_REQUIRED=1.17.0
58- GDK_PIXBUF_REQUIRED=2.7.1
58+ GDK_PIXBUF_REQUIRED=2.25.2
5959PANGO_REQUIRED=1.15.4
6060GLIB_REQUIRED=2.50.0
6161LIBMATE_MENU_REQUIRED=1.10.0
You can’t perform that action at this time.
0 commit comments