forked from enlightenment/efl
evas_generic_loaders: Don't use deprecated code
SVN revision: 77619
This commit is contained in:
parent
f1a88e0726
commit
306d657e9a
|
@ -121,8 +121,16 @@ AC_ARG_ENABLE([svg],
|
|||
[want_svg="yes"]
|
||||
)
|
||||
|
||||
have_svg_2_36="no"
|
||||
if test "x$want_svg" = "xyes" ; then
|
||||
PKG_CHECK_MODULES([SVG], [librsvg-2.0 >= 2.14.0 cairo >= 1.0.0], [have_svg="yes"], [have_svg="no"])
|
||||
PKG_CHECK_MODULES(
|
||||
[SVG_2_36], [librsvg-2.0 >= 2.36.0 cairo >= 1.0.0],
|
||||
[
|
||||
have_svg_2_36="yes"
|
||||
AC_DEFINE(HAVE_SVG_2_36, 1, [Have librsvg >= 2.36])
|
||||
],
|
||||
[have_svg_2_36="no"])
|
||||
else
|
||||
have_svg=no
|
||||
fi
|
||||
|
|
|
@ -56,7 +56,11 @@ static inline Eina_Bool evas_image_load_file_is_svg(const char *file)
|
|||
static int
|
||||
_svg_init(const char *file)
|
||||
{
|
||||
#ifdef HAVE_SVG_2_36
|
||||
g_type_init();
|
||||
#else
|
||||
rsvg_init();
|
||||
#endif
|
||||
|
||||
if (!evas_image_load_file_is_svg(file)) return 0;
|
||||
|
||||
|
@ -74,7 +78,9 @@ _svg_shutdown(void)
|
|||
g_object_unref(rsvg);
|
||||
}
|
||||
// Maybe it's not crashing anymore, let's try it.
|
||||
#ifndef HAVE_SVG_2_36
|
||||
rsvg_term();
|
||||
#endif
|
||||
}
|
||||
|
||||
static int
|
||||
|
|
Loading…
Reference in New Issue