-static struct wlsc_surface *
-background_create(struct wlsc_output *output, const char *filename)
-{
- struct wlsc_surface *background;
- struct wlsc_sprite *sprite;
-
- background = wlsc_surface_create(output->compositor,
- output->x, output->y,
- output->current->width,
- output->current->height);
- if (background == NULL)
- return NULL;
-
- sprite = create_sprite_from_png(output->compositor, filename, 0);
- if (sprite == NULL) {
- free(background);
- return NULL;
- }
-
- wlsc_sprite_attach(sprite, &background->surface);
-
- return background;
-}
-