[recipes] Apply image rotation in recipe tiles
- From: Matthias Clasen <matthiasc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [recipes] Apply image rotation in recipe tiles
- Date: Tue, 24 Jan 2017 06:55:53 +0000 (UTC)
commit 4dde0a1a2d919f3dec9e8edfbe4ef80ab5d26b07
Author: Matthias Clasen <mclasen redhat com>
Date: Tue Jan 24 09:54:47 2017 +0300
Apply image rotation in recipe tiles
This was simply overlooked since we didn't have any recipes
with rotated images that would show up in tiles.
https://bugzilla.gnome.org/show_bug.cgi?id=777671
src/gr-recipe-tile.c | 4 +++-
1 files changed, 3 insertions(+), 1 deletions(-)
---
diff --git a/src/gr-recipe-tile.c b/src/gr-recipe-tile.c
index d8e5933..55836bf 100644
--- a/src/gr-recipe-tile.c
+++ b/src/gr-recipe-tile.c
@@ -73,11 +73,13 @@ add_recipe_css (GrRecipe *recipe,
if (images->len > 0) {
GrRotatedImage *ri = &g_array_index (images, GrRotatedImage, 0);
+ g_autofree char *path = NULL;
+ path = ensure_rotated_image (ri->path, ri->angle);
g_string_append_printf (css, "image.recipe.small.%s,\nbox.recipe.%s {\n", id, id);
g_string_append_printf (css, " background: url('%s');\n"
" background-size: cover;\n"
- " background-position: center;\n", ri->path);
+ " background-position: center;\n", path);
g_string_append (css, "}\n\n");
}
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]