clean up the data section for some organisation.. in preparation for e to have

proper abstractions to finding the right data files depending on user config
etc.


SVN revision: 3987
This commit is contained in:
Carsten Haitzler 2000-12-13 23:44:24 +00:00
parent 36bfc191e6
commit e79f8efd51
34 changed files with 192 additions and 19 deletions

View File

@ -12,9 +12,7 @@ install-data-local:
if test -d $(srcdir)/data; then \
$(mkinstalldirs) $(DESTDIR)$(pkgdatadir)/data; \
for d in $(srcdir)/data/*; do \
if test -f $$d; then \
$(INSTALL_DATA) $$d $(DESTDIR)$(pkgdatadir)/data; \
fi \
cp -ar $$d $(DESTDIR)$(pkgdatadir)/data; \
done \
fi
@ -22,9 +20,7 @@ dist-hook:
if test -d data; then \
mkdir $(distdir)/data; \
for d in data/*; do \
if test -f $$d; then \
cp -p $$d $(distdir)/d; \
fi \
cp -ar $$d $(distdir)/data; \
done \
fi

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

BIN
data/fonts/nationff.ttf Normal file

Binary file not shown.

BIN
data/images/bg.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 257 KiB

BIN
data/images/e_logo.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 16 KiB

BIN
data/orig/b1.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.3 KiB

BIN
data/orig/b2.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 123 B

BIN
data/orig/b3.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 758 B

BIN
data/orig/b4.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 118 B

BIN
data/orig/b5.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

BIN
data/orig/b_t1.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.7 KiB

BIN
data/orig/b_t2.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.2 KiB

BIN
data/orig/b_t3.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.6 KiB

BIN
data/orig/bt1.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 540 B

BIN
data/orig/bt2.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 548 B

BIN
data/orig/bt3.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 517 B

BIN
data/orig/bt4.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 473 B

BIN
data/orig/bt5.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 517 B

BIN
data/orig/bt6.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 481 B

BIN
data/orig/bt7.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 572 B

BIN
data/orig/bt8.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 528 B

BIN
data/orig/s.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 301 B

BIN
data/orig/t1.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.4 KiB

BIN
data/orig/t2.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 947 B

BIN
data/orig/t3.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 KiB

177
data/scripts/build_db.sh Executable file
View File

@ -0,0 +1,177 @@
# enumerated variables
ACT_MOUSE_IN=0
ACT_MOUSE_OUT=1
ACT_MOUSE_CLICK=2
ACT_MOUSE_DOUBLE=3
ACT_MOUSE_TRIPLE=4
ACT_MOUSE_UP=5
ACT_MOUSE_CLICKED=6
ACT_MOUSE_MOVE=7
ACT_KEY_DOWN=8
ACT_KEY_UP=9
MOD_ANY=-1
MOD_NONE=0
MOD_SHIFT=1
MOD_CTRL=2
MOD_ALT=4
MOD_WIN=8
FOCUS_POINTER=0
FOCUS_SLOPPY=1
FOCUS_CLICK=2
# actions defining how to react to things
DB="./actions.db"
NUM=0
edb_ed $DB add "/actions/"$NUM"/name" str "Title_Bar"
edb_ed $DB add "/actions/"$NUM"/action" str "Window_Raise"
edb_ed $DB add "/actions/"$NUM"/params" str ""
edb_ed $DB add "/actions/"$NUM"/event" int $ACT_MOUSE_CLICK
edb_ed $DB add "/actions/"$NUM"/button" int 1
edb_ed $DB add "/actions/"$NUM"/key" str ""
edb_ed $DB add "/actions/"$NUM"/modifiers" int $MOD_NONE
NUM=$[ $NUM + 1 ];
edb_ed $DB add "/actions/"$NUM"/name" str "Title_Bar"
edb_ed $DB add "/actions/"$NUM"/action" str "Window_Move"
edb_ed $DB add "/actions/"$NUM"/params" str ""
edb_ed $DB add "/actions/"$NUM"/event" int $ACT_MOUSE_CLICK
edb_ed $DB add "/actions/"$NUM"/button" int 1
edb_ed $DB add "/actions/"$NUM"/key" str ""
edb_ed $DB add "/actions/"$NUM"/modifiers" int $MOD_NONE
NUM=$[ $NUM + 1 ];
edb_ed $DB add "/actions/"$NUM"/name" str "Title_Bar"
edb_ed $DB add "/actions/"$NUM"/action" str "Window_Shade"
edb_ed $DB add "/actions/"$NUM"/params" str ""
edb_ed $DB add "/actions/"$NUM"/event" int $ACT_MOUSE_DOUBLE
edb_ed $DB add "/actions/"$NUM"/button" int 1
edb_ed $DB add "/actions/"$NUM"/key" str ""
edb_ed $DB add "/actions/"$NUM"/modifiers" int $MOD_NONE
NUM=$[ $NUM + 1 ];
edb_ed $DB add "/actions/"$NUM"/name" str "Resize"
edb_ed $DB add "/actions/"$NUM"/action" str "Window_Resize"
edb_ed $DB add "/actions/"$NUM"/params" str ""
edb_ed $DB add "/actions/"$NUM"/event" int $ACT_MOUSE_CLICK
edb_ed $DB add "/actions/"$NUM"/button" int 1
edb_ed $DB add "/actions/"$NUM"/key" str ""
edb_ed $DB add "/actions/"$NUM"/modifiers" int $MOD_NONE
NUM=$[ $NUM + 1 ];
edb_ed $DB add "/actions/"$NUM"/name" str "Resize_Horizontal"
edb_ed $DB add "/actions/"$NUM"/action" str "Window_Resize_Horizontal"
edb_ed $DB add "/actions/"$NUM"/params" str ""
edb_ed $DB add "/actions/"$NUM"/event" int $ACT_MOUSE_CLICK
edb_ed $DB add "/actions/"$NUM"/button" int 1
edb_ed $DB add "/actions/"$NUM"/key" str ""
edb_ed $DB add "/actions/"$NUM"/modifiers" int $MOD_NONE
NUM=$[ $NUM + 1 ];
edb_ed $DB add "/actions/"$NUM"/name" str "Resize_Vertical"
edb_ed $DB add "/actions/"$NUM"/action" str "Window_Resize_Vertical"
edb_ed $DB add "/actions/"$NUM"/params" str ""
edb_ed $DB add "/actions/"$NUM"/event" int $ACT_MOUSE_CLICK
edb_ed $DB add "/actions/"$NUM"/button" int 1
edb_ed $DB add "/actions/"$NUM"/key" str ""
edb_ed $DB add "/actions/"$NUM"/modifiers" int $MOD_NONE
NUM=$[ $NUM + 1 ];
edb_ed $DB add "/actions/"$NUM"/name" str "Window_Grab"
edb_ed $DB add "/actions/"$NUM"/action" str "Window_Move"
edb_ed $DB add "/actions/"$NUM"/params" str ""
edb_ed $DB add "/actions/"$NUM"/event" int $ACT_MOUSE_CLICK
edb_ed $DB add "/actions/"$NUM"/button" int 1
edb_ed $DB add "/actions/"$NUM"/key" str ""
edb_ed $DB add "/actions/"$NUM"/modifiers" int $MOD_ALT
NUM=$[ $NUM + 1 ];
edb_ed $DB add "/actions/"$NUM"/name" str "Window_Grab"
edb_ed $DB add "/actions/"$NUM"/action" str "Window_Resize"
edb_ed $DB add "/actions/"$NUM"/params" str ""
edb_ed $DB add "/actions/"$NUM"/event" int $ACT_MOUSE_CLICK
edb_ed $DB add "/actions/"$NUM"/button" int 2
edb_ed $DB add "/actions/"$NUM"/key" str ""
edb_ed $DB add "/actions/"$NUM"/modifiers" int $MOD_ALT
NUM=$[ $NUM + 1 ];
edb_ed $DB add "/actions/"$NUM"/name" str "Resize"
edb_ed $DB add "/actions/"$NUM"/action" str "Window_Move"
edb_ed $DB add "/actions/"$NUM"/params" str ""
edb_ed $DB add "/actions/"$NUM"/event" int $ACT_MOUSE_CLICK
edb_ed $DB add "/actions/"$NUM"/button" int 3
edb_ed $DB add "/actions/"$NUM"/key" str ""
edb_ed $DB add "/actions/"$NUM"/modifiers" int $MOD_NONE
NUM=$[ $NUM + 1 ];
edb_ed $DB add "/actions/"$NUM"/name" str "Resize_Horizontal"
edb_ed $DB add "/actions/"$NUM"/action" str "Window_Move"
edb_ed $DB add "/actions/"$NUM"/params" str ""
edb_ed $DB add "/actions/"$NUM"/event" int $ACT_MOUSE_CLICK
edb_ed $DB add "/actions/"$NUM"/button" int 3
edb_ed $DB add "/actions/"$NUM"/key" str ""
edb_ed $DB add "/actions/"$NUM"/modifiers" int $MOD_NONE
NUM=$[ $NUM + 1 ];
edb_ed $DB add "/actions/"$NUM"/name" str "Resize_Vertical"
edb_ed $DB add "/actions/"$NUM"/action" str "Window_Move"
edb_ed $DB add "/actions/"$NUM"/params" str ""
edb_ed $DB add "/actions/"$NUM"/event" int $ACT_MOUSE_CLICK
edb_ed $DB add "/actions/"$NUM"/button" int 3
edb_ed $DB add "/actions/"$NUM"/key" str ""
edb_ed $DB add "/actions/"$NUM"/modifiers" int $MOD_NONE
NUM=$[ $NUM + 1 ];
edb_ed $DB add "/actions/"$NUM"/name" str "Close"
edb_ed $DB add "/actions/"$NUM"/action" str "Window_Close"
edb_ed $DB add "/actions/"$NUM"/params" str ""
edb_ed $DB add "/actions/"$NUM"/event" int $ACT_MOUSE_CLICKED
edb_ed $DB add "/actions/"$NUM"/button" int 1
edb_ed $DB add "/actions/"$NUM"/key" str ""
edb_ed $DB add "/actions/"$NUM"/modifiers" int $MOD_NONE
NUM=$[ $NUM + 1 ];
edb_ed $DB add "/actions/"$NUM"/name" str "Close"
edb_ed $DB add "/actions/"$NUM"/action" str "Window_Kill"
edb_ed $DB add "/actions/"$NUM"/params" str ""
edb_ed $DB add "/actions/"$NUM"/event" int $ACT_MOUSE_CLICKED
edb_ed $DB add "/actions/"$NUM"/button" int 3
edb_ed $DB add "/actions/"$NUM"/key" str ""
edb_ed $DB add "/actions/"$NUM"/modifiers" int $MOD_NONE
NUM=$[ $NUM + 1 ];
edb_ed $DB add "/actions/"$NUM"/name" str "Max_Size"
edb_ed $DB add "/actions/"$NUM"/action" str "Window_Max_Size"
edb_ed $DB add "/actions/"$NUM"/params" str ""
edb_ed $DB add "/actions/"$NUM"/event" int $ACT_MOUSE_CLICKED
edb_ed $DB add "/actions/"$NUM"/button" int 1
edb_ed $DB add "/actions/"$NUM"/key" str ""
edb_ed $DB add "/actions/"$NUM"/modifiers" int $MOD_NONE
NUM=$[ $NUM + 1 ];
edb_ed $DB add "/actions/"$NUM"/name" str "Iconify"
edb_ed $DB add "/actions/"$NUM"/action" str "Window_Iconify"
edb_ed $DB add "/actions/"$NUM"/params" str ""
edb_ed $DB add "/actions/"$NUM"/event" int $ACT_MOUSE_CLICKED
edb_ed $DB add "/actions/"$NUM"/button" int 1
edb_ed $DB add "/actions/"$NUM"/key" str ""
edb_ed $DB add "/actions/"$NUM"/modifiers" int $MOD_NONE
NUM=$[ $NUM + 1 ];
edb_ed $DB add "/actions/"$NUM"/name" str "Menu"
edb_ed $DB add "/actions/"$NUM"/action" str "Menu"
edb_ed $DB add "/actions/"$NUM"/params" str ""
edb_ed $DB add "/actions/"$NUM"/event" int $ACT_MOUSE_CLICKED
edb_ed $DB add "/actions/"$NUM"/button" int 1
edb_ed $DB add "/actions/"$NUM"/key" str ""
edb_ed $DB add "/actions/"$NUM"/modifiers" int $MOD_NONE
NUM=$[ $NUM + 1 ];
edb_ed $DB add "/actions/count" int $NUM
# basic settings
DB="./settings.db"
edb_ed $DB add "/move/resist" int 1
edb_ed $DB add "/move/resist/desk" int 24
edb_ed $DB add "/move/resist/win" int 12
edb_ed $DB add "/focus/mode " int $FOCUS_POINTER
# what events on windows are "grabbed" by the window manager
DB="./grabs.db"
NUM=0
edb_ed $DB add "/grabs/"$NUM"/button" int 1
edb_ed $DB add "/grabs/"$NUM"/modifiers" int $MOD_ALT
NUM=$[ $NUM + 1 ];
edb_ed $DB add "/grabs/"$NUM"/button" int 2
edb_ed $DB add "/grabs/"$NUM"/modifiers" int $MOD_ALT
NUM=$[ $NUM + 1 ];
edb_ed $DB add "/grabs/"$NUM"/button" int 3
edb_ed $DB add "/grabs/"$NUM"/modifiers" int $MOD_ALT
NUM=$[ $NUM + 1 ];
edb_ed $DB add "/grabs/count" int $NUM

View File

@ -57,7 +57,7 @@ static void e_act_zoom_start (void *o, E_Action *a, void *data, int x, int y, in
static void
_e_action_find(char *action, int act, int button, char *key, Ev_Key_Modifiers mods, void *o)
{
char *actions_db = PACKAGE_DATA_DIR"/data/actions.db";
char *actions_db = PACKAGE_DATA_DIR"/data/config/behavior/default/actions.db";
E_DB_File *db;
int i, num;
char *a_name = NULL;

View File

@ -377,7 +377,7 @@ e_focus_out(Eevent * ev)
b = e_border_find_by_window(e->win);
if (b)
{
char *settings_db = PACKAGE_DATA_DIR"/data/settings.db";
char *settings_db = PACKAGE_DATA_DIR"/data/config/behavior/default/settings.db";
E_DB_File *db;
int focus_mode;
char buf[4096];
@ -988,9 +988,9 @@ e_border_apply_border(E_Border *b)
int pl, pr, pt, pb;
if ((!b->client.titlebar) &&
(!b->client.border)) e_border_set_bits(b, PACKAGE_DATA_DIR"/data/borderless.bits.db");
else if (b->current.selected) e_border_set_bits(b, PACKAGE_DATA_DIR"/data/border.bits.db");
else e_border_set_bits(b, PACKAGE_DATA_DIR"/data/border2.bits.db");
(!b->client.border)) e_border_set_bits(b, PACKAGE_DATA_DIR"/data/config/appearance/default/borders/borderless.bits.db");
else if (b->current.selected) e_border_set_bits(b, PACKAGE_DATA_DIR"/data/config/appearance/default/borders/border.bits.db");
else e_border_set_bits(b, PACKAGE_DATA_DIR"/data/config/appearance/default/borders/border2.bits.db");
pl = pr = pt = pb = 0;
if (b->bits.t) ebits_get_insets(b->bits.t, &pl, &pr, &pt, &pb);
@ -1066,7 +1066,7 @@ e_border_new(void)
int max_colors = 216;
int font_cache = 1024 * 1024;
int image_cache = 8192 * 1024;
char *font_dir = PACKAGE_DATA_DIR"/data/fnt";
char *font_dir = PACKAGE_DATA_DIR"/data/fonts";
E_Desktop *desk;
b = NEW(E_Border, 1);
@ -1223,8 +1223,8 @@ e_border_remove_mouse_grabs(E_Border *b)
void
e_border_attach_mouse_grabs(E_Border *b)
{
char *grabs_db = PACKAGE_DATA_DIR"/data/grabs.db";
char *settings_db = PACKAGE_DATA_DIR"/data/settings.db";
char *grabs_db = PACKAGE_DATA_DIR"/data/config/behavior/default/grabs.db";
char *settings_db = PACKAGE_DATA_DIR"/data/config/behavior/default/settings.db";
E_DB_File *db;
int focus_mode;
char buf[4096];
@ -1316,8 +1316,8 @@ e_border_attach_all_mouse_grabs(void)
void
e_border_redo_grabs(void)
{
char *grabs_db = PACKAGE_DATA_DIR"/data/grabs.db";
char *settings_db = PACKAGE_DATA_DIR"/data/settings.db";
char *grabs_db = PACKAGE_DATA_DIR"/data/config/behavior/default/grabs.db";
char *settings_db = PACKAGE_DATA_DIR"/data/config/behavior/default/settings.db";
static time_t mod_date_grabs = 0;
static time_t mod_date_settings = 0;
time_t mod;

View File

@ -372,7 +372,7 @@ e_desktops_init_file_display(E_Desktop *desk)
int max_colors = 216;
int font_cache = 1024 * 1024;
int image_cache = 8192 * 1024;
char *font_dir = "./fnt";
char *font_dir = PACKAGE_DATA_DIR"/data/fonts";
/* software */
desk->evas.desk = evas_new_all(e_display_get(),
@ -398,11 +398,11 @@ e_desktops_init_file_display(E_Desktop *desk)
Evas e;
e = desk->evas.desk;
o = evas_add_image_from_file(e, PACKAGE_DATA_DIR"/data/bg.png");
o = evas_add_image_from_file(e, PACKAGE_DATA_DIR"/data/images/bg.png");
evas_move(e, o, 0, 0);
evas_resize(e, o, screen_w, screen_h);
evas_show(e, o);
o = evas_add_image_from_file(e, PACKAGE_DATA_DIR"/data/e_logo.png");
o = evas_add_image_from_file(e, PACKAGE_DATA_DIR"/data/images/e_logo.png");
evas_move(e, o, 0, 0);
evas_show(e, o);
}