mirror of
https://github.com/swaywm/sway.git
synced 2024-11-21 23:41:27 +00:00
common: rename load_background_image to load_image
This commit is contained in:
parent
39b9c0d6ba
commit
439122e887
|
@ -104,7 +104,7 @@ static cairo_surface_t* gdk_cairo_image_surface_create_from_pixbuf(
|
||||||
}
|
}
|
||||||
#endif // HAVE_GDK_PIXBUF
|
#endif // HAVE_GDK_PIXBUF
|
||||||
|
|
||||||
cairo_surface_t *load_background_image(const char *path) {
|
cairo_surface_t *load_image(const char *path) {
|
||||||
cairo_surface_t *image;
|
cairo_surface_t *image;
|
||||||
#if HAVE_GDK_PIXBUF
|
#if HAVE_GDK_PIXBUF
|
||||||
GError *err = NULL;
|
GError *err = NULL;
|
||||||
|
|
|
@ -2,6 +2,6 @@
|
||||||
#define _SWAY_BACKGROUND_IMAGE_H
|
#define _SWAY_BACKGROUND_IMAGE_H
|
||||||
#include <cairo.h>
|
#include <cairo.h>
|
||||||
|
|
||||||
cairo_surface_t *load_background_image(const char *path);
|
cairo_surface_t *load_image(const char *path);
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -431,7 +431,7 @@ static void reload_sni(struct swaybar_sni *sni, char *icon_theme,
|
||||||
list_free(icon_search_paths);
|
list_free(icon_search_paths);
|
||||||
if (icon_path) {
|
if (icon_path) {
|
||||||
cairo_surface_destroy(sni->icon);
|
cairo_surface_destroy(sni->icon);
|
||||||
sni->icon = load_background_image(icon_path);
|
sni->icon = load_image(icon_path);
|
||||||
free(icon_path);
|
free(icon_path);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue