extern Ecore_Evas *binder_ecore_evas_new(vwin_info_t info);
extern int binder_widget_auto_align(void);
-#define GL_ENGINE "opengl_x11"
+#define GL_ENGINE_X11 "opengl_x11"
+#define GL_ENGINE "opengl"
/* End of a file */
#include <stdlib.h>
#define __USE_GNU
#include <dlfcn.h>
+#define _GNU_SOURCE
+#include <string.h>
#include <Elementary.h>
#include <Ecore_Evas.h>
}
}
+static inline int check_gl_engine(const char *engine)
+{
+ /**
+ * @todo
+ * If the "engine" string going to be changed to more complicated formatted string,
+ * We should replace this with sytanx recognizer (parser).
+ */
+ return !!strcasestr(engine, GL_ENGINE);
+}
+
Ecore_Evas *binder_ecore_evas_new(vwin_info_t info)
{
const char *engine;
engine = elm_config_accel_preference_get();
- DbgPrint("Preferred engine: %s (%s)\n", engine, GL_ENGINE);
- if (engine && !strcmp(engine, GL_ENGINE)) {
+ DbgPrint("Preferred engine: %s (%s or %s)\n", engine, GL_ENGINE, GL_ENGINE_X11);
+ if (engine && check_gl_engine(engine)) {
if (s_info.alloc_canvas_with_pixmap) {
ee = s_info.alloc_canvas_with_pixmap(NULL, 0u, 0, 0, info->w, info->h, alloc_pixmap_cb, free_pixmap_cb, info);
if (!ee) {