[recipes] Remove unused support for ingredient images



commit ce8127f4cdad9dac21e13620ba6881fd0e3bde76
Author: Matthias Clasen <mclasen redhat com>
Date:   Sat Feb 18 15:13:41 2017 -0500

    Remove unused support for ingredient images
    
    This can come back if and when we find a use for it.

 data/Makefile.am               |   17 -----------------
 data/ingredients/Almond.png    |  Bin 103202 -> 0 bytes
 data/ingredients/Amaretti.png  |  Bin 89671 -> 0 bytes
 data/ingredients/Anchovis.png  |  Bin 74538 -> 0 bytes
 data/ingredients/Apple.png     |  Bin 77697 -> 0 bytes
 data/ingredients/Apricot.png   |  Bin 42097 -> 0 bytes
 data/ingredients/Artichoke.png |  Bin 73234 -> 0 bytes
 data/ingredients/Asparagus.png |  Bin 88141 -> 0 bytes
 data/ingredients/Aubergine.png |  Bin 41129 -> 0 bytes
 data/ingredients/Bacon.png     |  Bin 59269 -> 0 bytes
 data/ingredients/Bagel.png     |  Bin 87279 -> 0 bytes
 data/ingredients/Banana.png    |  Bin 95409 -> 0 bytes
 data/ingredients/Basil.png     |  Bin 92957 -> 0 bytes
 data/ingredients/Biscotti.png  |  Bin 66423 -> 0 bytes
 data/ingredients/Carrot.png    |  Bin 35303 -> 0 bytes
 src/gr-ingredient.c            |   28 ----------------------------
 src/gr-ingredient.h            |    1 -
 17 files changed, 0 insertions(+), 46 deletions(-)
---
diff --git a/data/Makefile.am b/data/Makefile.am
index 247f0b7..2d44c29 100644
--- a/data/Makefile.am
+++ b/data/Makefile.am
@@ -25,26 +25,9 @@ EXTRA_DIST += $(desktop_in_files)
 mimedir = $(datadir)/mime/packages
 dist_mime_DATA = org.gnome.Recipes-mime.xml
 
-ingredientsdir = $(pkgdatadir)/ingredients
 imagesdir = $(pkgdatadir)/images
 soundsdir = $(pkgdatadir)/sounds
 
-dist_ingredients_DATA = \
-       ingredients/Almond.png          \
-       ingredients/Amaretti.png        \
-       ingredients/Anchovis.png        \
-       ingredients/Apple.png           \
-       ingredients/Apricot.png         \
-       ingredients/Artichoke.png       \
-       ingredients/Asparagus.png       \
-       ingredients/Aubergine.png       \
-       ingredients/Bacon.png           \
-       ingredients/Bagel.png           \
-       ingredients/Banana.png          \
-       ingredients/Basil.png           \
-       ingredients/Biscotti.png        \
-       ingredients/Carrot.png
-
 dist_images_DATA = \
        images/adelia.jpg               \
        images/adria.jpg                \
diff --git a/src/gr-ingredient.c b/src/gr-ingredient.c
index b55bd15..09a433b 100644
--- a/src/gr-ingredient.c
+++ b/src/gr-ingredient.c
@@ -122,31 +122,3 @@ gr_ingredient_get_negation (const char *name)
 
         return NULL;
 }
-
-char *
-gr_ingredient_get_image (const char *name)
-{
-        int i;
-        g_autofree char *filename = NULL;
-
-        for (i = 0; names[i]; i++) {
-                if (g_strcmp0 (name, names[i]) == 0) {
-                        filename = g_strconcat (names_[i], ".png", NULL);
-                        break;
-                }
-        }
-
-        if (filename) {
-                g_autofree char *current_dir = NULL;
-                char *path;
-
-                path = g_build_filename (get_pkg_data_dir (), "ingredients", filename, NULL);
-                if (g_file_test (path, G_FILE_TEST_EXISTS))
-                        return path;
-                g_free (path);
-                current_dir = g_get_current_dir ();
-                return g_build_filename (current_dir, "data", "ingredients", filename, NULL);
-        }
-
-        return NULL;
-}
diff --git a/src/gr-ingredient.h b/src/gr-ingredient.h
index a36dad2..c17b50a 100644
--- a/src/gr-ingredient.h
+++ b/src/gr-ingredient.h
@@ -28,6 +28,5 @@ const char    **gr_ingredient_get_names    (int        *length);
 const char     *gr_ingredient_find         (const char *text);
 const char     *gr_ingredient_get_id       (const char *name);
 const char     *gr_ingredient_get_negation (const char *name);
-char           *gr_ingredient_get_image    (const char *name);
 
 G_END_DECLS


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]