From a97fdcba0774aed2a6d26e871d10e35d2c516bc3 Mon Sep 17 00:00:00 2001 From: Sung-jae Park Date: Thu, 6 Nov 2014 12:56:06 +0900 Subject: [PATCH] Implement theme loader. [model] Redwood,Kiran,B3(Wearable) [binary_type] AP [customer] Docomo/Orange/ATT/Open [issue#] N/A [problem] [cause] [solution] [team] HomeTF [request] [horizontal_expansion] Change-Id: I3b0651f89580c28779a0f25aeab77bd292a891c4 --- CMakeLists.txt | 20 +++++++++++--------- src/main.c | 6 +++++- 2 files changed, 16 insertions(+), 10 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index a887b38..0b38d9c 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -64,6 +64,7 @@ ADD_DEFINITIONS("-DNDEBUG") #ADD_DEFINITIONS("-D_ENABLE_MCHECK") ADD_DEFINITIONS("-DLOG_TAG=\"DATA_PROVIDER_SLAVE\"") ADD_DEFINITIONS("-D_USE_ECORE_TIME_GET") +ADD_DEFINITIONS("-DTHEME_DIR=\"/opt/usr/share/live_magazine/theme\"") #ADD_DEFINITIONS("-D_ESTIMATE_PERF") ADD_DEFINITIONS(${pkg_CFLAGS}) @@ -75,15 +76,16 @@ SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall") SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wall -Winline -Werror -g -fno-builtin-malloc -fpie") SET(BUILD_SOURCE - src/main.c - src/so_handler.c - src/fault.c - src/update_monitor.c - src/util.c - src/dbox.c - src/client.c - src/critical_log.c - src/connection.c + src/main.c + src/so_handler.c + src/fault.c + src/update_monitor.c + src/util.c + src/dbox.c + src/client.c + src/critical_log.c + src/connection.c + src/theme_loader.c ) IF (WAYLAND_SUPPORT) diff --git a/src/main.c b/src/main.c index 5a1dcc1..b00bb75 100644 --- a/src/main.c +++ b/src/main.c @@ -54,6 +54,7 @@ #include "so_handler.h" #include "dbox.h" #include "conf.h" +#include "theme_loader.h" #define TEXT_CLASS "tizen" #define DEFAULT_FONT_SIZE -100 @@ -398,7 +399,7 @@ static bool app_create(void *argv) int ret; elm_app_base_scale_set(WVGA_DEFAULT_SCALE); -// elm_config_preferred_engine_set("opengl_x11"); + elm_config_preferred_engine_set("opengl_x11"); dynamicbox_conf_init(); if (!dynamicbox_conf_is_loaded()) { @@ -478,6 +479,7 @@ static bool app_create(void *argv) font_changed_cb(NULL); font_size_cb(SYSTEM_SETTINGS_KEY_FONT_SIZE, NULL); + theme_loader_load(THEME_DIR); dbox_init(); @@ -492,6 +494,8 @@ static void app_terminate(void *data) dbox_fini(); + theme_loader_unload(); + if (s_info.table) { DbgPrint("FONT TABLE Destroyed"); ea_theme_font_table_free(s_info.table); -- 2.7.4