Enlightenment CVS committal
Author : dj2
Project : e17
Module : libs/ewl
Dir : e17/libs/ewl/src
Modified Files:
Makefile.am ewl_theme.c ewl_theme.h
Log Message:
- remove edb theme support from ewl. its just edje themes now.
===================================================================
RCS file: /cvsroot/enlightenment/e17/libs/ewl/src/Makefile.am,v
retrieving revision 1.61
retrieving revision 1.62
diff -u -3 -r1.61 -r1.62
--- Makefile.am 30 Jul 2004 19:44:23 -0000 1.61
+++ Makefile.am 18 Aug 2004 04:27:03 -0000 1.62
@@ -2,7 +2,7 @@
MAINTAINERCLEANFILES = Ewl.h
-INCLUDES = @edje_cflags@ @ecore_cflags@ @edb_cflags@ @evas_cflags@ @etox_cflags@
@emotion_cflags@
+INCLUDES = @edje_cflags@ @ecore_cflags@ @evas_cflags@ @etox_cflags@ @emotion_cflags@
lib_LTLIBRARIES = libewl.la
@@ -131,5 +131,5 @@
installed_headersdir = $(prefix)/include/ewl
installed_headers_DATA = $(EWLHEADERS) $(EWLEMOTIONHEADERS)
-libewl_la_LIBADD = @edje_libs@ @ecore_libs@ @edb_libs@ @evas_libs@ @etox_libs@
@emotion_libs@ -lm
+libewl_la_LIBADD = @edje_libs@ @ecore_libs@ @evas_libs@ @etox_libs@ @emotion_libs@ -lm
libewl_la_LDFLAGS = -version-info 0:0:0
===================================================================
RCS file: /cvsroot/enlightenment/e17/libs/ewl/src/ewl_theme.c,v
retrieving revision 1.66
retrieving revision 1.67
diff -u -3 -r1.66 -r1.67
--- ewl_theme.c 18 Aug 2004 03:04:32 -0000 1.66
+++ ewl_theme.c 18 Aug 2004 04:27:03 -0000 1.67
@@ -7,8 +7,6 @@
static char *theme_name = NULL;
static char *theme_path = NULL;
-static E_DB_File *theme_db = NULL;
-
static Ecore_List *font_paths = NULL;
static Ecore_Hash *cached_theme_data = NULL;
static Ecore_Hash *def_theme_data = NULL;
@@ -64,61 +62,18 @@
/*
* Build a path to the theme if it is the users home dir and use it if
- * available. First attempts to use the theme.db method, but fails
- * over to an eet.
+ * available.
*/
- snprintf(theme_db_path, PATH_MAX, "%s/.e/ewl/themes/%s", home,
- theme_name);
-
- if (((stat(theme_db_path, &st)) == 0) && S_ISDIR(st.st_mode)) {
- snprintf(theme_db_path, PATH_MAX,
- "%s/.e/ewl/themes/%s/theme.db", home,
- theme_name);
- theme_db = e_db_open_read(theme_db_path);
- if (theme_db) {
- snprintf(theme_db_path, PATH_MAX,
- "%s/.e/ewl/themes/%s/", home,
- theme_name);
- theme_path = strdup(theme_db_path);
- }
- }
-
- if (!theme_path) {
- snprintf(theme_db_path, PATH_MAX, "%s/.e/ewl/themes/%s.eet",
- home, theme_name);
- if (((stat(theme_db_path, &st)) == 0) && S_ISREG(st.st_mode)) {
- theme_path = strdup(theme_db_path);
- }
+ snprintf(theme_db_path, PATH_MAX, "%s/.e/ewl/themes/%s.eet",
+ home, theme_name);
+ if (((stat(theme_db_path, &st)) == 0) && S_ISREG(st.st_mode)) {
+ theme_path = strdup(theme_db_path);
}
/*
- * No user theme, so we try the system-wide theme. Same failover
- * scheme, theme.db first fails over to the eet.
+ * No user theme, so we try the system-wide theme.
*/
if (!theme_path) {
-
- /*
- * Theme dir is ok, now get the specified theme's path
- */
- snprintf(theme_db_path, PATH_MAX, PACKAGE_DATA_DIR
- "/themes/%s", theme_name);
-
- if (((stat(theme_db_path, &st)) == 0) && S_ISDIR(st.st_mode)) {
- snprintf(theme_db_path, PATH_MAX, PACKAGE_DATA_DIR
- "/themes/%s/theme.db", theme_name);
-
- theme_db = e_db_open_read(theme_db_path);
- if (theme_db) {
- snprintf(theme_db_path, PATH_MAX,
- PACKAGE_DATA_DIR "/themes/%s",
- theme_name);
- theme_path = strdup(theme_db_path);
- }
- }
-
- }
-
- if (!theme_path) {
snprintf(theme_db_path, PATH_MAX, PACKAGE_DATA_DIR
"/themes/%s.eet", theme_name);
if (((stat(theme_db_path, &st)) == 0) &&
@@ -169,11 +124,6 @@
{
char *data;
- if (theme_db) {
- e_db_close(theme_db);
- theme_db = NULL;
- }
-
if (font_paths) {
while ((data = ecore_list_remove_first(font_paths)))
free(data);
@@ -297,16 +247,6 @@
}
/**
- * @brief Returns the open theme db file handle.
- * @return Returns the open theme database on success, NULL for an eet theme.
- */
-E_DB_File *ewl_theme_db_get()
-{
- DENTER_FUNCTION(DLEVEL_STABLE);
- DRETURN_PTR(theme_db, DLEVEL_STABLE);
-}
-
-/**
* @return Returns the font path of widget @a w on success, NULL on failure.
* @brief retrieve the path of a widgets theme's fonts
*/
@@ -356,7 +296,7 @@
DCHECK_PARAM_PTR_RET("k", k, NULL);
data = ewl_theme_data_str_get(w, k);
- if (!data && !theme_db)
+ if (!data)
data = strdup(theme_path);
if (!data)
@@ -415,10 +355,7 @@
ret = ecore_hash_get(cached_theme_data, temp);
if (!ret) {
- if (theme_db)
- ret = e_db_str_get(theme_db, temp);
- else
- ret = edje_file_data_get(theme_path, temp);
+ ret = edje_file_data_get(theme_path, temp);
if (ret && ewl_config.theme.cache) {
if (!cached_theme_data)
@@ -465,16 +402,12 @@
ret = (int) (ecore_hash_get(def_theme_data, temp));
if (!ret) {
- if (theme_db)
- e_db_int_get(theme_db, temp, &ret);
- else {
- char *val;
+ char *val;
- val = edje_file_data_get(theme_path, temp);
- if (val) {
- ret = atoi(val);
- FREE(val);
- }
+ val = edje_file_data_get(theme_path, temp);
+ if (val) {
+ ret = atoi(val);
+ FREE(val);
}
}
temp++;
===================================================================
RCS file: /cvsroot/enlightenment/e17/libs/ewl/src/ewl_theme.h,v
retrieving revision 1.25
retrieving revision 1.26
diff -u -3 -r1.25 -r1.26
--- ewl_theme.h 18 Aug 2004 03:04:33 -0000 1.25
+++ ewl_theme.h 18 Aug 2004 04:27:03 -0000 1.26
@@ -36,7 +36,6 @@
void ewl_theme_name_set(char *name);
char *ewl_theme_name_get(void);
char *ewl_theme_path_get(void);
-E_DB_File *ewl_theme_db_get();
Ecore_List *ewl_theme_font_path_get(void);
void ewl_theme_font_path_add(char *path);
char *ewl_theme_image_get(Ewl_Widget * w, char *k);
-------------------------------------------------------
SF.Net email is sponsored by Shop4tech.com-Lowest price on Blank Media
100pk Sonic DVD-R 4x for only $29 -100pk Sonic DVD+R for only $33
Save 50% off Retail on Ink & Toner - Free Shipping and Free Gift.
http://www.shop4tech.com/z/Inkjet_Cartridges/9_108_r285
_______________________________________________
enlightenment-cvs mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs