forked from enlightenment/enlightenment
perf config fifnt allow you to easily see font cache at all - the default was
0.5 mb! SVN revision: 25956
This commit is contained in:
parent
ce76a89968
commit
c01892990b
|
@ -2376,12 +2376,16 @@ _e_fm2_cb_dnd_drop(void *data, const char *type, void *event)
|
||||||
{
|
{
|
||||||
E_Fm2_Smart_Data *sd;
|
E_Fm2_Smart_Data *sd;
|
||||||
E_Event_Dnd_Drop *ev;
|
E_Event_Dnd_Drop *ev;
|
||||||
|
char **selected, *f;
|
||||||
|
int i;
|
||||||
|
|
||||||
sd = data;
|
sd = data;
|
||||||
if (!type) return;
|
if (!type) return;
|
||||||
if (strcmp(type, "text/uri-list")) return;
|
if (strcmp(type, "text/uri-list")) return;
|
||||||
ev = (E_Event_Dnd_Drop *)event;
|
ev = (E_Event_Dnd_Drop *)event;
|
||||||
printf("DROP: %i %i %s\n", ev->x, ev->y, ev->data);
|
selected = ev->data;
|
||||||
|
printf("DROP: %i %i\n", ev->x, ev->y);
|
||||||
|
for (i = 0, f = selected[i]; f; i++, f = selected[i]) printf(" %s\n", f);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
|
@ -2548,7 +2552,12 @@ _e_fm2_cb_icon_mouse_up(void *data, Evas *e, Evas_Object *obj, void *event_info)
|
||||||
static void
|
static void
|
||||||
_e_fm2_cb_drag_finished(E_Drag *drag, int dropped)
|
_e_fm2_cb_drag_finished(E_Drag *drag, int dropped)
|
||||||
{
|
{
|
||||||
free(drag->data);
|
char **selected, *f;
|
||||||
|
int i;
|
||||||
|
|
||||||
|
selected = drag->data;
|
||||||
|
for (i = 0, f = selected[i]; f; i++, f = selected[i]) free(f);
|
||||||
|
free(selected);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
|
@ -2572,8 +2581,11 @@ _e_fm2_cb_icon_mouse_move(void *data, Evas *e, Evas_Object *obj, void *event_inf
|
||||||
Evas_Object *o, *o2;
|
Evas_Object *o, *o2;
|
||||||
Evas_Coord x, y, w, h;
|
Evas_Coord x, y, w, h;
|
||||||
const char *drag_types[] = { "text/uri-list" }, *realpath;
|
const char *drag_types[] = { "text/uri-list" }, *realpath;
|
||||||
|
char **selected = NULL;
|
||||||
char buf[4096];
|
char buf[4096];
|
||||||
E_Container *con = NULL;
|
E_Container *con = NULL;
|
||||||
|
Evas_List *l, *sl;
|
||||||
|
int i;
|
||||||
|
|
||||||
switch (ic->sd->eobj->type)
|
switch (ic->sd->eobj->type)
|
||||||
{
|
{
|
||||||
|
@ -2598,14 +2610,20 @@ _e_fm2_cb_icon_mouse_move(void *data, Evas *e, Evas_Object *obj, void *event_inf
|
||||||
ic->drag.start = 0;
|
ic->drag.start = 0;
|
||||||
evas_object_geometry_get(ic->obj, &x, &y, &w, &h);
|
evas_object_geometry_get(ic->obj, &x, &y, &w, &h);
|
||||||
realpath = e_fm2_real_path_get(ic->sd->obj);
|
realpath = e_fm2_real_path_get(ic->sd->obj);
|
||||||
if (!strcmp(realpath, "/"))
|
sl = e_fm2_selected_list_get(ic->sd->obj);
|
||||||
snprintf(buf, sizeof(buf), "/%s", ic->info.file);
|
selected = E_NEW(char *, evas_list_count(sl) + 1);
|
||||||
else
|
for (l = sl, i = 0; l; l = l->next, i++)
|
||||||
snprintf(buf, sizeof(buf), "%s/%s", realpath, ic->info.file);
|
{
|
||||||
|
if (!strcmp(realpath, "/"))
|
||||||
|
snprintf(buf, sizeof(buf), "/%s", ic->info.file);
|
||||||
|
else
|
||||||
|
snprintf(buf, sizeof(buf), "%s/%s", realpath, ic->info.file);
|
||||||
|
selected[i] = strdup(buf);
|
||||||
|
}
|
||||||
|
evas_list_free(sl);
|
||||||
d = e_drag_new(con,
|
d = e_drag_new(con,
|
||||||
x, y, drag_types, 1,
|
x, y, drag_types, 1,
|
||||||
strdup(buf), -1, _e_fm2_cb_drag_finished);
|
selected, -1, _e_fm2_cb_drag_finished);
|
||||||
o = edje_object_add(e_drag_evas_get(d));
|
o = edje_object_add(e_drag_evas_get(d));
|
||||||
if (ic->sd->config->view.mode == E_FM2_VIEW_MODE_LIST)
|
if (ic->sd->config->view.mode == E_FM2_VIEW_MODE_LIST)
|
||||||
{
|
{
|
||||||
|
|
|
@ -13,8 +13,8 @@ struct _E_Config_Dialog_Data
|
||||||
|
|
||||||
/* Advanced */
|
/* Advanced */
|
||||||
double cache_flush_interval;
|
double cache_flush_interval;
|
||||||
int font_cache;
|
double font_cache;
|
||||||
int image_cache;
|
double image_cache;
|
||||||
int edje_cache;
|
int edje_cache;
|
||||||
int edje_collection_cache;
|
int edje_collection_cache;
|
||||||
};
|
};
|
||||||
|
@ -45,8 +45,8 @@ static void
|
||||||
_fill_data(E_Config_Dialog_Data *cfdata)
|
_fill_data(E_Config_Dialog_Data *cfdata)
|
||||||
{
|
{
|
||||||
cfdata->framerate = e_config->framerate;
|
cfdata->framerate = e_config->framerate;
|
||||||
cfdata->font_cache = (e_config->font_cache / 1024);
|
cfdata->font_cache = ((double)e_config->font_cache / 1024);
|
||||||
cfdata->image_cache = (e_config->image_cache / 1024);
|
cfdata->image_cache = ((double)e_config->image_cache / 1024);
|
||||||
cfdata->edje_cache = e_config->edje_cache;
|
cfdata->edje_cache = e_config->edje_cache;
|
||||||
cfdata->edje_collection_cache = e_config->edje_collection_cache;
|
cfdata->edje_collection_cache = e_config->edje_collection_cache;
|
||||||
cfdata->cache_flush_interval = e_config->cache_flush_interval;
|
cfdata->cache_flush_interval = e_config->cache_flush_interval;
|
||||||
|
@ -133,12 +133,12 @@ _advanced_create_widgets(E_Config_Dialog *cfd, Evas *evas, E_Config_Dialog_Data
|
||||||
|
|
||||||
ob = e_widget_label_add(evas, _("Size Of Font Cache"));
|
ob = e_widget_label_add(evas, _("Size Of Font Cache"));
|
||||||
e_widget_framelist_object_append(of, ob);
|
e_widget_framelist_object_append(of, ob);
|
||||||
ob = e_widget_slider_add(evas, 1, 0, _("%1.1f MB"), 0, 32, 0.5, 0, NULL, &(cfdata->font_cache), 150);
|
ob = e_widget_slider_add(evas, 1, 0, _("%1.1f MB"), 0, 4, 0.1, 0, &(cfdata->font_cache), NULL, 150);
|
||||||
e_widget_framelist_object_append(of, ob);
|
e_widget_framelist_object_append(of, ob);
|
||||||
|
|
||||||
ob = e_widget_label_add(evas, _("Size Of Image Cache"));
|
ob = e_widget_label_add(evas, _("Size Of Image Cache"));
|
||||||
e_widget_framelist_object_append(of, ob);
|
e_widget_framelist_object_append(of, ob);
|
||||||
ob = e_widget_slider_add(evas, 1, 0, _("%1.0f MB"), 0, 256, 1, 0, NULL, &(cfdata->image_cache), 150);
|
ob = e_widget_slider_add(evas, 1, 0, _("%1.0f MB"), 0, 32, 1, 0, &(cfdata->image_cache), NULL, 150);
|
||||||
e_widget_framelist_object_append(of, ob);
|
e_widget_framelist_object_append(of, ob);
|
||||||
|
|
||||||
ob = e_widget_label_add(evas, _("Number Of Edje Files To Cache"));
|
ob = e_widget_label_add(evas, _("Number Of Edje Files To Cache"));
|
||||||
|
|
Loading…
Reference in New Issue