Ephoto: Trailing whitespace cleanup - memcpy fix.

This commit is contained in:
Stephen Houston 2016-10-11 00:41:45 -05:00
parent 92736b10aa
commit 9f8024bae5
16 changed files with 92 additions and 94 deletions

View File

@ -160,9 +160,9 @@ void ephoto_filter_emboss(Ephoto *ephoto, Evas_Object *image);
void ephoto_filter_histogram_eq(Ephoto *ephoto, Evas_Object *image); void ephoto_filter_histogram_eq(Ephoto *ephoto, Evas_Object *image);
/*file functions*/ /*file functions*/
void ephoto_file_save_image(Ephoto *ephoto, Ephoto_Entry *entry, void ephoto_file_save_image(Ephoto *ephoto, Ephoto_Entry *entry,
Evas_Object *image); Evas_Object *image);
void ephoto_file_save_image_as(Ephoto *ephoto, Ephoto_Entry *entry, void ephoto_file_save_image_as(Ephoto *ephoto, Ephoto_Entry *entry,
Evas_Object *image); Evas_Object *image);
void ephoto_file_upload_image(Ephoto *ephoto, Ephoto_Entry *entry); void ephoto_file_upload_image(Ephoto *ephoto, Ephoto_Entry *entry);
void ephoto_file_new_dir(Ephoto *ephoto, const char *path); void ephoto_file_new_dir(Ephoto *ephoto, const char *path);
@ -281,7 +281,7 @@ struct _Ephoto
Ecore_Con_Url *url_up; Ecore_Con_Url *url_up;
char *url_ret; char *url_ret;
char *upload_error; char *upload_error;
int file_errors; int file_errors;
const char *top_directory; const char *top_directory;
const char *destination; const char *destination;

View File

@ -15,7 +15,7 @@ struct _Ephoto_BCG
int brightness; int brightness;
double gamma; double gamma;
Evas_Coord w, h; Evas_Coord w, h;
unsigned int *original_im_data; unsigned int *original_im_data;
}; };
static int static int
@ -274,8 +274,8 @@ _bcg_apply(void *data, int type EINA_UNUSED,
unsigned int *image_data; unsigned int *image_data;
Evas_Coord w, h; Evas_Coord w, h;
if (elm_slider_value_get(ebcg->bslider) == 0 && if (elm_slider_value_get(ebcg->bslider) == 0 &&
elm_slider_value_get(ebcg->cslider) == 0 && elm_slider_value_get(ebcg->cslider) == 0 &&
elm_slider_value_get(ebcg->gslider) == 1) elm_slider_value_get(ebcg->gslider) == 1)
{ {
ephoto_single_browser_cancel_editing(ebcg->main); ephoto_single_browser_cancel_editing(ebcg->main);

View File

@ -258,7 +258,7 @@ _color_apply(void *data, int type EINA_UNUSED,
Ephoto_Color *eco = data; Ephoto_Color *eco = data;
unsigned int *image_data; unsigned int *image_data;
Evas_Coord w, h; Evas_Coord w, h;
if (elm_slider_value_get(eco->rslider) == 0 && if (elm_slider_value_get(eco->rslider) == 0 &&
elm_slider_value_get(eco->gslider) == 0 && elm_slider_value_get(eco->gslider) == 0 &&
elm_slider_value_get(eco->bslider) == 0) elm_slider_value_get(eco->bslider) == 0)
@ -336,7 +336,7 @@ ephoto_color_add(Ephoto *ephoto, Evas_Object *main, Evas_Object *parent, Evas_Ob
memcpy(eco->original_im_data, im_data, memcpy(eco->original_im_data, im_data,
sizeof(unsigned int) * eco->w * eco->h); sizeof(unsigned int) * eco->w * eco->h);
eco->editor = ephoto_editor_add(ephoto, _("Adjust Color Levels"), eco->editor = ephoto_editor_add(ephoto, _("Adjust Color Levels"),
"eco", eco); "eco", eco);
evas_object_event_callback_add(eco->editor, EVAS_CALLBACK_DEL, _editor_del, evas_object_event_callback_add(eco->editor, EVAS_CALLBACK_DEL, _editor_del,
eco); eco);

View File

@ -130,7 +130,7 @@ _config_general(Ephoto *ephoto, Evas_Object *parent)
elm_object_text_set(label, _("Top Level Directory")); elm_object_text_set(label, _("Top Level Directory"));
evas_object_size_hint_align_set(label, 0.5, 0.5); evas_object_size_hint_align_set(label, 0.5, 0.5);
elm_table_pack(table, label, 0, 5, 1, 1); elm_table_pack(table, label, 0, 5, 1, 1);
evas_object_show(label); evas_object_show(label);
hoversel = elm_hoversel_add(table); hoversel = elm_hoversel_add(table);
elm_hoversel_hover_parent_set(hoversel, ephoto->win); elm_hoversel_hover_parent_set(hoversel, ephoto->win);

View File

@ -70,7 +70,7 @@ _menu_empty_cb(void *data, Evas_Object *obj EINA_UNUSED,
Eina_List *paths = NULL; Eina_List *paths = NULL;
Elm_Object_Item *item; Elm_Object_Item *item;
Ephoto_Entry *file; Ephoto_Entry *file;
item = elm_genlist_first_item_get(db->fsel); item = elm_genlist_first_item_get(db->fsel);
while (item) while (item)
{ {
@ -442,7 +442,7 @@ _dir_go_trash(void *data, Evas_Object *obj EINA_UNUSED,
20*elm_config_scale_get()); 20*elm_config_scale_get());
elm_icon_standard_set(ic, "go-previous"); elm_icon_standard_set(ic, "go-previous");
evas_object_size_hint_aspect_set(ic, EVAS_ASPECT_CONTROL_BOTH, 1, 1); evas_object_size_hint_aspect_set(ic, EVAS_ASPECT_CONTROL_BOTH, 1, 1);
but = elm_button_add(db->leftbox); but = elm_button_add(db->leftbox);
elm_object_text_set(but, _("Back")); elm_object_text_set(but, _("Back"));
elm_object_part_content_set(but, "icon", ic); elm_object_part_content_set(but, "icon", ic);
@ -759,7 +759,7 @@ _monitor_cb(void *data, int type,
return ECORE_CALLBACK_PASS_ON; return ECORE_CALLBACK_PASS_ON;
if (ephoto_entry_exists(entry->ephoto, ev->filename)) if (ephoto_entry_exists(entry->ephoto, ev->filename))
return ECORE_CALLBACK_PASS_ON; return ECORE_CALLBACK_PASS_ON;
if (elm_genlist_item_type_get(entry->item) == ELM_GENLIST_ITEM_TREE && if (elm_genlist_item_type_get(entry->item) == ELM_GENLIST_ITEM_TREE &&
elm_genlist_item_expanded_get(entry->item) == EINA_TRUE) elm_genlist_item_expanded_get(entry->item) == EINA_TRUE)
{ {
@ -819,7 +819,7 @@ _monitor_cb(void *data, int type,
parent = parent =
elm_genlist_item_insert_before(entry->genlist, ic, entry, elm_genlist_item_insert_before(entry->genlist, ic, entry,
entry->parent, entry->item, ELM_GENLIST_ITEM_NONE, NULL, NULL); entry->parent, entry->item, ELM_GENLIST_ITEM_NONE, NULL, NULL);
entry->no_delete = EINA_TRUE; entry->no_delete = EINA_TRUE;
elm_object_item_del(entry->item); elm_object_item_del(entry->item);
if (entry->monitor) if (entry->monitor)
@ -831,7 +831,6 @@ _monitor_cb(void *data, int type,
entry->item = parent; entry->item = parent;
_monitor_add(entry); _monitor_add(entry);
entry->no_delete = EINA_FALSE; entry->no_delete = EINA_FALSE;
} }
if (!ecore_file_exists(entry->ephoto->config->directory)) if (!ecore_file_exists(entry->ephoto->config->directory))
{ {
@ -884,7 +883,7 @@ _top_monitor_cb(void *data, int type,
if (type == EIO_MONITOR_DIRECTORY_CREATED || type == EIO_MONITOR_FILE_CREATED) if (type == EIO_MONITOR_DIRECTORY_CREATED || type == EIO_MONITOR_FILE_CREATED)
{ {
if (!ecore_file_is_dir(ecore_file_realpath(ev->filename))) if (!ecore_file_is_dir(ecore_file_realpath(ev->filename)))
return ECORE_CALLBACK_PASS_ON; return ECORE_CALLBACK_PASS_ON;
if (ephoto_entry_exists(db->ephoto, ev->filename)) if (ephoto_entry_exists(db->ephoto, ev->filename))
return ECORE_CALLBACK_PASS_ON; return ECORE_CALLBACK_PASS_ON;
snprintf(buf, PATH_MAX, "%s", ev->filename); snprintf(buf, PATH_MAX, "%s", ev->filename);
@ -1191,7 +1190,7 @@ ephoto_directory_browser_initialize_structure(Ephoto *ephoto)
const char *n = eina_list_data_get(eina_list_next(l)); const char *n = eina_list_data_get(eina_list_next(l));
it = eina_file_stat_ls(dir); it = eina_file_stat_ls(dir);
cur = next; cur = next;
EINA_ITERATOR_FOREACH(it, finfo) EINA_ITERATOR_FOREACH(it, finfo)
{ {
if (finfo->type != EINA_FILE_DIR && finfo->type != EINA_FILE_LNK) if (finfo->type != EINA_FILE_DIR && finfo->type != EINA_FILE_LNK)

View File

@ -4,7 +4,7 @@ static void
_editor_reset(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, _editor_reset(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED,
void *event_info EINA_UNUSED) void *event_info EINA_UNUSED)
{ {
ecore_event_add(EPHOTO_EVENT_EDITOR_RESET, NULL, NULL, NULL); ecore_event_add(EPHOTO_EVENT_EDITOR_RESET, NULL, NULL, NULL);
} }
static void static void
@ -27,7 +27,7 @@ _editor_cancel(void *data, Evas_Object *obj EINA_UNUSED,
ecore_event_add(EPHOTO_EVENT_EDITOR_CANCEL, NULL, NULL, NULL); ecore_event_add(EPHOTO_EVENT_EDITOR_CANCEL, NULL, NULL, NULL);
edje_object_signal_emit(elm_layout_edje_get(ephoto->layout), edje_object_signal_emit(elm_layout_edje_get(ephoto->layout),
"ephoto,editor,hide", "ephoto"); "ephoto,editor,hide", "ephoto");
ephoto->editor_blocking = EINA_FALSE; ephoto->editor_blocking = EINA_FALSE;
} }
@ -61,7 +61,7 @@ ephoto_editor_add(Ephoto *ephoto, const char *title, const char *data_name,
evas_object_show(box); evas_object_show(box);
ic = elm_icon_add(box); ic = elm_icon_add(box);
evas_object_size_hint_min_set(ic, 20*elm_config_scale_get(), evas_object_size_hint_min_set(ic, 20*elm_config_scale_get(),
20*elm_config_scale_get()); 20*elm_config_scale_get());
evas_object_size_hint_aspect_set(ic, EVAS_ASPECT_CONTROL_VERTICAL, 1, 1); evas_object_size_hint_aspect_set(ic, EVAS_ASPECT_CONTROL_VERTICAL, 1, 1);
elm_icon_standard_set(ic, "edit-undo"); elm_icon_standard_set(ic, "edit-undo");
@ -78,7 +78,7 @@ ephoto_editor_add(Ephoto *ephoto, const char *title, const char *data_name,
evas_object_show(button); evas_object_show(button);
ic = elm_icon_add(box); ic = elm_icon_add(box);
evas_object_size_hint_min_set(ic, 20*elm_config_scale_get(), evas_object_size_hint_min_set(ic, 20*elm_config_scale_get(),
20*elm_config_scale_get()); 20*elm_config_scale_get());
evas_object_size_hint_aspect_set(ic, EVAS_ASPECT_CONTROL_VERTICAL, 1, 1); evas_object_size_hint_aspect_set(ic, EVAS_ASPECT_CONTROL_VERTICAL, 1, 1);
elm_icon_standard_set(ic, "document-save"); elm_icon_standard_set(ic, "document-save");
@ -95,7 +95,7 @@ ephoto_editor_add(Ephoto *ephoto, const char *title, const char *data_name,
evas_object_show(button); evas_object_show(button);
ic = elm_icon_add(box); ic = elm_icon_add(box);
evas_object_size_hint_min_set(ic, 20*elm_config_scale_get(), evas_object_size_hint_min_set(ic, 20*elm_config_scale_get(),
20*elm_config_scale_get()); 20*elm_config_scale_get());
evas_object_size_hint_aspect_set(ic, EVAS_ASPECT_CONTROL_VERTICAL, 1, 1); evas_object_size_hint_aspect_set(ic, EVAS_ASPECT_CONTROL_VERTICAL, 1, 1);
elm_icon_standard_set(ic, "window-close"); elm_icon_standard_set(ic, "window-close");
@ -106,10 +106,10 @@ ephoto_editor_add(Ephoto *ephoto, const char *title, const char *data_name,
evas_object_smart_callback_add(button, "clicked", _editor_cancel, ephoto); evas_object_smart_callback_add(button, "clicked", _editor_cancel, ephoto);
evas_object_size_hint_weight_set(button, EVAS_HINT_FILL, EVAS_HINT_FILL); evas_object_size_hint_weight_set(button, EVAS_HINT_FILL, EVAS_HINT_FILL);
evas_object_size_hint_align_set(button, EVAS_HINT_FILL, EVAS_HINT_FILL); evas_object_size_hint_align_set(button, EVAS_HINT_FILL, EVAS_HINT_FILL);
evas_object_size_hint_min_set(button, 220*elm_config_scale_get(), evas_object_size_hint_min_set(button, 220*elm_config_scale_get(),
30*elm_config_scale_get()); 30*elm_config_scale_get());
elm_box_pack_end(box, button); elm_box_pack_end(box, button);
evas_object_show(button); evas_object_show(button);
edje_object_signal_emit(elm_layout_edje_get(ephoto->layout), edje_object_signal_emit(elm_layout_edje_get(ephoto->layout),
"ephoto,editor,show", "ephoto"); "ephoto,editor,show", "ephoto");

View File

@ -750,7 +750,7 @@ _delete_thread_cb(void *data, Ecore_Thread *et EINA_UNUSED)
ret = ecore_file_unlink(file); ret = ecore_file_unlink(file);
} }
else else
{ {
snprintf(fp, PATH_MAX, "%s", file); snprintf(fp, PATH_MAX, "%s", file);
snprintf(dest, PATH_MAX, "%s/%s", destination, basename(fp)); snprintf(dest, PATH_MAX, "%s/%s", destination, basename(fp));
if (ecore_file_exists(dest)) if (ecore_file_exists(dest))
@ -998,7 +998,7 @@ _prompt_save_image_as_apply(void *data, Evas_Object *obj, void *event_info)
char buf[PATH_MAX]; char buf[PATH_MAX];
const char *ex, *ext; const char *ex, *ext;
ex = strrchr(selected, '.'); ex = strrchr(selected, '.');
if (!ex) if (!ex)
{ {
@ -1478,7 +1478,7 @@ ephoto_file_paste(Ephoto *ephoto, Eina_List *files, Eina_Bool copy, const char *
_copy_files(ephoto, files, path); _copy_files(ephoto, files, path);
} }
} }
} }
void void
ephoto_file_delete(Ephoto *ephoto, Eina_List *files, Eina_File_Type type) ephoto_file_delete(Ephoto *ephoto, Eina_List *files, Eina_File_Type type)

View File

@ -312,7 +312,7 @@ _blur_vertical(Ephoto_Filter *ef, double rad)
gt = _normalize_color(gt); gt = _normalize_color(gt);
rt = _normalize_color(rt); rt = _normalize_color(rt);
at = _normalize_color(at); at = _normalize_color(at);
ef->im_data_new[t++] = (at << 24) | (rt << 16) ef->im_data_new[t++] = (at << 24) | (rt << 16)
| (gt << 8) | bt; | (gt << 8) | bt;
} }
for (i = rad + 1; i < w - rad; i++) for (i = rad + 1; i < w - rad; i++)
@ -333,7 +333,7 @@ _blur_vertical(Ephoto_Filter *ef, double rad)
gt = _normalize_color(gt); gt = _normalize_color(gt);
rt = _normalize_color(rt); rt = _normalize_color(rt);
at = _normalize_color(at); at = _normalize_color(at);
ef->im_data_new[t++] = (at << 24) | (rt << 16) ef->im_data_new[t++] = (at << 24) | (rt << 16)
| (gt << 8) | bt; | (gt << 8) | bt;
} }
for (i = w - rad; i < w; i++) for (i = w - rad; i < w; i++)
@ -344,7 +344,7 @@ _blur_vertical(Ephoto_Filter *ef, double rad)
valg += lvg - gs[ll]; valg += lvg - gs[ll];
valr += lvr - rs[ll]; valr += lvr - rs[ll];
vala += lva - as[ll]; vala += lva - as[ll];
bt = (int) round(valb * iarr); bt = (int) round(valb * iarr);
gt = (int) round(valg * iarr); gt = (int) round(valg * iarr);
rt = (int) round(valr * iarr); rt = (int) round(valr * iarr);
@ -353,7 +353,7 @@ _blur_vertical(Ephoto_Filter *ef, double rad)
gt = _normalize_color(gt); gt = _normalize_color(gt);
rt = _normalize_color(rt); rt = _normalize_color(rt);
at = _normalize_color(at); at = _normalize_color(at);
ef->im_data_new[t++] = (at << 24) | (rt << 16) ef->im_data_new[t++] = (at << 24) | (rt << 16)
| (gt << 8) | bt; | (gt << 8) | bt;
} }
} }
@ -427,7 +427,7 @@ _blur_horizontal(Ephoto_Filter *ef, double rad)
valg += gs[rr] - fg; valg += gs[rr] - fg;
valr += rs[rr] - fr; valr += rs[rr] - fr;
vala += as[rr] - fa; vala += as[rr] - fa;
bt = (int) round(valb * iarr); bt = (int) round(valb * iarr);
gt = (int) round(valg * iarr); gt = (int) round(valg * iarr);
rt = (int) round(valr * iarr); rt = (int) round(valr * iarr);
@ -436,7 +436,7 @@ _blur_horizontal(Ephoto_Filter *ef, double rad)
gt = _normalize_color(gt); gt = _normalize_color(gt);
rt = _normalize_color(rt); rt = _normalize_color(rt);
at = _normalize_color(at); at = _normalize_color(at);
ef->im_data[t] = (at << 24) | (rt << 16) ef->im_data[t] = (at << 24) | (rt << 16)
| (gt << 8) | bt; | (gt << 8) | bt;
rr += w; rr += w;
@ -457,7 +457,7 @@ _blur_horizontal(Ephoto_Filter *ef, double rad)
gt = _normalize_color(gt); gt = _normalize_color(gt);
rt = _normalize_color(rt); rt = _normalize_color(rt);
at = _normalize_color(at); at = _normalize_color(at);
ef->im_data[t] = (at << 24) | (rt << 16) ef->im_data[t] = (at << 24) | (rt << 16)
| (gt << 8) | bt; | (gt << 8) | bt;
l += w; l += w;
@ -479,7 +479,7 @@ _blur_horizontal(Ephoto_Filter *ef, double rad)
gt = _normalize_color(gt); gt = _normalize_color(gt);
rt = _normalize_color(rt); rt = _normalize_color(rt);
at = _normalize_color(at); at = _normalize_color(at);
ef->im_data[t] = (at << 24) | (rt << 16) ef->im_data[t] = (at << 24) | (rt << 16)
| (gt << 8) | bt; | (gt << 8) | bt;
l += w; l += w;
@ -574,7 +574,7 @@ _sharpen(void *data, Ecore_Thread *th EINA_UNUSED)
p2++; p2++;
p1++; p1++;
} }
} }
} }
static void static void
@ -611,7 +611,7 @@ _dither(void *data, Ecore_Thread *th EINA_UNUSED)
bb = _demul_color_alpha(bb, a); bb = _demul_color_alpha(bb, a);
gg = _demul_color_alpha(gg, a); gg = _demul_color_alpha(gg, a);
rr = _demul_color_alpha(rr, a); rr = _demul_color_alpha(rr, a);
ef->im_data_new[index] = (a << 24) | (rr << 16) | ef->im_data_new[index] = (a << 24) | (rr << 16) |
(gg << 8) | bb; (gg << 8) | bb;
errb = b - bb; errb = b - bb;
errg = g - gg; errg = g - gg;
@ -636,7 +636,7 @@ _dither(void *data, Ecore_Thread *th EINA_UNUSED)
bb = _demul_color_alpha(bb, a); bb = _demul_color_alpha(bb, a);
gg = _demul_color_alpha(gg, a); gg = _demul_color_alpha(gg, a);
rr = _demul_color_alpha(rr, a); rr = _demul_color_alpha(rr, a);
ef->im_data_new[index] = (a << 24) | (rr << 16) | ef->im_data_new[index] = (a << 24) | (rr << 16) |
(gg << 8) | bb; (gg << 8) | bb;
} }
if (x > 0 && (y+1) < h) if (x > 0 && (y+1) < h)
@ -658,8 +658,8 @@ _dither(void *data, Ecore_Thread *th EINA_UNUSED)
bb = _demul_color_alpha(bb, a); bb = _demul_color_alpha(bb, a);
gg = _demul_color_alpha(gg, a); gg = _demul_color_alpha(gg, a);
rr = _demul_color_alpha(rr, a); rr = _demul_color_alpha(rr, a);
ef->im_data_new[index] = (a << 24) | (rr << 16) | ef->im_data_new[index] = (a << 24) | (rr << 16) |
(gg << 8) | bb; (gg << 8) | bb;
} }
if ((y+1) < h) if ((y+1) < h)
{ {
@ -680,12 +680,12 @@ _dither(void *data, Ecore_Thread *th EINA_UNUSED)
bb = _demul_color_alpha(bb, a); bb = _demul_color_alpha(bb, a);
gg = _demul_color_alpha(gg, a); gg = _demul_color_alpha(gg, a);
rr = _demul_color_alpha(rr, a); rr = _demul_color_alpha(rr, a);
ef->im_data_new[index] = (a << 24) | (rr << 16) | ef->im_data_new[index] = (a << 24) | (rr << 16) |
(gg << 8) | bb; (gg << 8) | bb;
} }
if ((y+1) < h && (x+1) < w) if ((y+1) < h && (x+1) < w)
{ {
index = (y + 1) * w + (x + 1); index = (y + 1) * w + (x + 1);
b = (ef->im_data_new[index] & 0xff); b = (ef->im_data_new[index] & 0xff);
g = ((ef->im_data_new[index] >> 8) & 0xff); g = ((ef->im_data_new[index] >> 8) & 0xff);
r = ((ef->im_data_new[index] >> 16) & 0xff); r = ((ef->im_data_new[index] >> 16) & 0xff);
@ -702,7 +702,7 @@ _dither(void *data, Ecore_Thread *th EINA_UNUSED)
bb = _demul_color_alpha(bb, a); bb = _demul_color_alpha(bb, a);
gg = _demul_color_alpha(gg, a); gg = _demul_color_alpha(gg, a);
rr = _demul_color_alpha(rr, a); rr = _demul_color_alpha(rr, a);
ef->im_data_new[index] = (a << 24) | (rr << 16) | ef->im_data_new[index] = (a << 24) | (rr << 16) |
(gg << 8) | bb; (gg << 8) | bb;
} }
} }
@ -752,7 +752,7 @@ _sepia(void *data, Ecore_Thread *th EINA_UNUSED)
for (x = 0; x < w; x++) for (x = 0; x < w; x++)
{ {
i = y * w + x; i = y * w + x;
b = ((ef->im_data[i]) & 0xff); b = ((ef->im_data[i]) & 0xff);
g = ((ef->im_data[i] >> 8) & 0xff); g = ((ef->im_data[i] >> 8) & 0xff);
r = ((ef->im_data[i] >> 16) & 0xff); r = ((ef->im_data[i] >> 16) & 0xff);
@ -875,12 +875,12 @@ _dodge(void *data, Ecore_Thread *th EINA_UNUSED)
gg = ((ef->im_data[i] >> 8) & 0xff); gg = ((ef->im_data[i] >> 8) & 0xff);
rr = ((ef->im_data[i] >> 16) & 0xff); rr = ((ef->im_data[i] >> 16) & 0xff);
aa = ((ef->im_data[i] >> 24) & 0xff); aa = ((ef->im_data[i] >> 24) & 0xff);
b *= 255; b *= 255;
g *= 255; g *= 255;
r *= 255; r *= 255;
a *= 255; a *= 255;
bbb = rint(b / (255 - bb)); bbb = rint(b / (255 - bb));
ggg = rint(g / (255 - gg)); ggg = rint(g / (255 - gg));
rrr = rint(r / (255 - rr)); rrr = rint(r / (255 - rr));
@ -926,7 +926,7 @@ _sobel(void *data, Ecore_Thread *th EINA_UNUSED)
for (j = -1; j <= 1; j++) for (j = -1; j <= 1; j++)
{ {
int index, pix; int index, pix;
index = (y + i) * w + x + j; index = (y + i) * w + x + j;
pix = ef->im_data[index]; pix = ef->im_data[index];
hpval += pix * sobx[i+1][j+1]; hpval += pix * sobx[i+1][j+1];
@ -978,7 +978,7 @@ _emboss(void *data, Ecore_Thread *th EINA_UNUSED)
int index, pix; int index, pix;
index = (y + i) * w + x + j; index = (y + i) * w + x + j;
pix = ef->im_data[index]; pix = ef->im_data[index];
bb += (int) ((pix) & 0xff) * bb += (int) ((pix) & 0xff) *
emboss[i+1][j+1]; emboss[i+1][j+1];
gg += (int) ((pix >> 8) & 0xff) * gg += (int) ((pix >> 8) & 0xff) *
emboss[i+1][j+1]; emboss[i+1][j+1];
@ -1031,10 +1031,10 @@ _histogram_eq(void *data, Ecore_Thread *th EINA_UNUSED)
p1++; p1++;
} }
} }
sum = 0; sum = 0;
for (i = 0; i < 256; i++) for (i = 0; i < 256; i++)
{ {
sum += ((double) ef->hist[i] / sum += ((double) ef->hist[i] /
(double) total); (double) total);
ef->cdf[i] = (int) round(sum * 255); ef->cdf[i] = (int) round(sum * 255);
} }
@ -1184,7 +1184,7 @@ void ephoto_filter_sketch(Ephoto *ephoto, Evas_Object *image)
ef->queue = eina_list_append(ef->queue, _dodge); ef->queue = eina_list_append(ef->queue, _dodge);
ef->popup = _processing(ephoto->win); ef->popup = _processing(ephoto->win);
ef->thread = ecore_thread_run(_grayscale, _thread_finished_cb, ef->thread = ecore_thread_run(_grayscale, _thread_finished_cb,
NULL, ef); NULL, ef);
} }
void ephoto_filter_edge(Ephoto *ephoto, Evas_Object *image) void ephoto_filter_edge(Ephoto *ephoto, Evas_Object *image)

View File

@ -358,11 +358,11 @@ ephoto_hsv_add(Ephoto *ephoto, Evas_Object *main, Evas_Object *parent, Evas_Obje
memcpy(ehsv->original_im_data, im_data, memcpy(ehsv->original_im_data, im_data,
sizeof(unsigned int) * ehsv->w * ehsv->h); sizeof(unsigned int) * ehsv->w * ehsv->h);
ehsv->editor = ephoto_editor_add(ephoto, _("Hue/Saturation/Value"), ehsv->editor = ephoto_editor_add(ephoto, _("Hue/Saturation/Value"),
"ehsv", ehsv); "ehsv", ehsv);
evas_object_event_callback_add(ehsv->editor, EVAS_CALLBACK_DEL, _editor_del, evas_object_event_callback_add(ehsv->editor, EVAS_CALLBACK_DEL, _editor_del,
ehsv); ehsv);
slider = elm_slider_add(ehsv->editor); slider = elm_slider_add(ehsv->editor);
elm_object_text_set(slider, _("Value")); elm_object_text_set(slider, _("Value"));
elm_slider_min_max_set(slider, -100, 100); elm_slider_min_max_set(slider, -100, 100);

View File

@ -38,7 +38,7 @@ e_ipc_init(void)
else else
ERR("XDG_RUNTIME_DIR of '%s' cannot be accessed", tmp); ERR("XDG_RUNTIME_DIR of '%s' cannot be accessed", tmp);
} }
tmp = getenv("SD_USER_SOCKETS_DIR"); tmp = getenv("SD_USER_SOCKETS_DIR");
if (tmp) if (tmp)
{ {
@ -137,7 +137,7 @@ _e_ipc_cb_client_data(void *data EINA_UNUSED, int type EINA_UNUSED, void *event)
case EPHOTO_IPC_DOMAIN_THUMB: case EPHOTO_IPC_DOMAIN_THUMB:
e_thumb_client_data(e); e_thumb_client_data(e);
break; break;
default: default:
break; break;
} }

View File

@ -314,7 +314,7 @@ _mouse_out_cb(void *data, Evas_Object *obj EINA_UNUSED,
{ {
Ephoto *ephoto = data; Ephoto *ephoto = data;
ephoto->blocking = EINA_FALSE; ephoto->blocking = EINA_FALSE;
if (ephoto->overlay_timer) if (ephoto->overlay_timer)
ecore_timer_del(ephoto->overlay_timer); ecore_timer_del(ephoto->overlay_timer);
ephoto->overlay_timer = ecore_timer_add(3.0, _timer_cb, ephoto); ephoto->overlay_timer = ecore_timer_add(3.0, _timer_cb, ephoto);
@ -507,7 +507,7 @@ ephoto_window_add(const char *path)
_ephoto_thumb_browser_changed_directory, ephoto); _ephoto_thumb_browser_changed_directory, ephoto);
evas_object_smart_callback_add(ephoto->thumb_browser, "slideshow", evas_object_smart_callback_add(ephoto->thumb_browser, "slideshow",
_ephoto_thumb_browser_slideshow, ephoto); _ephoto_thumb_browser_slideshow, ephoto);
ephoto->single_browser = ephoto_single_browser_add(ephoto, ephoto->layout); ephoto->single_browser = ephoto_single_browser_add(ephoto, ephoto->layout);
if (!ephoto->single_browser) if (!ephoto->single_browser)
{ {
@ -581,7 +581,7 @@ ephoto_window_add(const char *path)
elm_object_style_set(ephoto->infolabel, "info"); elm_object_style_set(ephoto->infolabel, "info");
elm_label_line_wrap_set(ephoto->infolabel, ELM_WRAP_MIXED); elm_label_line_wrap_set(ephoto->infolabel, ELM_WRAP_MIXED);
elm_object_text_set(ephoto->infolabel, _("Information")); elm_object_text_set(ephoto->infolabel, _("Information"));
evas_object_size_hint_weight_set(ephoto->infolabel, evas_object_size_hint_weight_set(ephoto->infolabel,
EVAS_HINT_EXPAND, EVAS_HINT_EXPAND); EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
evas_object_size_hint_align_set(ephoto->infolabel, EVAS_HINT_FILL, evas_object_size_hint_align_set(ephoto->infolabel, EVAS_HINT_FILL,
EVAS_HINT_FILL); EVAS_HINT_FILL);
@ -604,7 +604,7 @@ ephoto_window_add(const char *path)
20*elm_config_scale_get()); 20*elm_config_scale_get());
ret = elm_icon_standard_set(ic, "media-playback-start"); ret = elm_icon_standard_set(ic, "media-playback-start");
evas_object_size_hint_aspect_set(ic, EVAS_ASPECT_CONTROL_BOTH, 1, 1); evas_object_size_hint_aspect_set(ic, EVAS_ASPECT_CONTROL_BOTH, 1, 1);
but = elm_button_add(ephoto->statusbar); but = elm_button_add(ephoto->statusbar);
elm_object_part_content_set(but, "icon", ic); elm_object_part_content_set(but, "icon", ic);
if (!ret) if (!ret)
@ -1211,7 +1211,7 @@ ephoto_entry_new(Ephoto *ephoto, const char *path, const char *label,
return entry; return entry;
} }
Eina_Bool Eina_Bool
ephoto_entry_exists(Ephoto *ephoto, const char *path) ephoto_entry_exists(Ephoto *ephoto, const char *path)
{ {
Ephoto_Entry *entry; Ephoto_Entry *entry;
@ -1231,7 +1231,7 @@ ephoto_entry_free(Ephoto *ephoto, Ephoto_Entry *entry)
Ephoto_Entry_Free_Listener *fl; Ephoto_Entry_Free_Listener *fl;
Ecore_Event_Handler *handler; Ecore_Event_Handler *handler;
Eina_List *node; Eina_List *node;
EINA_LIST_FREE(entry->free_listeners, fl) EINA_LIST_FREE(entry->free_listeners, fl)
{ {
fl->cb((void *) fl->data, entry); fl->cb((void *) fl->data, entry);

View File

@ -123,7 +123,7 @@ _es_apply(void *data, int type EINA_UNUSED,
evas_image_cache_set(eecanvas, 0); evas_image_cache_set(eecanvas, 0);
evas_font_cache_set(eecanvas, 0); evas_font_cache_set(eecanvas, 0);
alpha = 1; alpha = 1;
im = evas_object_image_add(eecanvas); im = evas_object_image_add(eecanvas);
evas_object_image_load_size_set(im, w, h); evas_object_image_load_size_set(im, w, h);
evas_object_image_load_orientation_set(im, EINA_TRUE); evas_object_image_load_orientation_set(im, EINA_TRUE);
@ -132,10 +132,10 @@ _es_apply(void *data, int type EINA_UNUSED,
evas_object_image_fill_set(im, 0, 0, w, h); evas_object_image_fill_set(im, 0, 0, w, h);
evas_object_move(im, 0, 0); evas_object_move(im, 0, 0);
evas_object_resize(im, w, h); evas_object_resize(im, w, h);
ecore_evas_alpha_set(ee, alpha); ecore_evas_alpha_set(ee, alpha);
ecore_evas_resize(ee, w, h); ecore_evas_resize(ee, w, h);
evas_object_show(im); evas_object_show(im);
image_data = ecore_evas_buffer_pixels_get(ee); image_data = ecore_evas_buffer_pixels_get(ee);

View File

@ -511,7 +511,7 @@ _orient_apply(Ephoto_Single_Browser *sb)
evas_object_size_hint_max_set(v->image, w, h); evas_object_size_hint_max_set(v->image, w, h);
elm_table_pack(v->table, v->image, 0, 0, 1, 1); elm_table_pack(v->table, v->image, 0, 0, 1, 1);
elm_object_content_set(v->scroller, v->table); elm_object_content_set(v->scroller, v->table);
if (v->fit) if (v->fit)
_viewer_zoom_fit_apply(v); _viewer_zoom_fit_apply(v);
else else
@ -1015,7 +1015,7 @@ _close_editor(void *data, Evas_Object *obj EINA_UNUSED,
void *event_info EINA_UNUSED) void *event_info EINA_UNUSED)
{ {
Ephoto_Single_Browser *sb = data; Ephoto_Single_Browser *sb = data;
edje_object_signal_emit(elm_layout_edje_get(sb->ephoto->layout), edje_object_signal_emit(elm_layout_edje_get(sb->ephoto->layout),
"ephoto,editor,hide", "ephoto"); "ephoto,editor,hide", "ephoto");
evas_object_del(sb->edit_main); evas_object_del(sb->edit_main);
@ -1048,7 +1048,7 @@ _upload_image(void *data, Evas_Object *obj EINA_UNUSED,
void *event_info EINA_UNUSED) void *event_info EINA_UNUSED)
{ {
Ephoto_Single_Browser *sb = data; Ephoto_Single_Browser *sb = data;
ephoto_file_upload_image(sb->ephoto, sb->entry); ephoto_file_upload_image(sb->ephoto, sb->entry);
} }
@ -1068,7 +1068,7 @@ _rename_image(void *data, Evas_Object *obj EINA_UNUSED,
void *event_info EINA_UNUSED) void *event_info EINA_UNUSED)
{ {
Ephoto_Single_Browser *sb = data; Ephoto_Single_Browser *sb = data;
ephoto_file_rename(sb->ephoto, sb->entry->path); ephoto_file_rename(sb->ephoto, sb->entry->path);
} }
@ -1177,7 +1177,7 @@ _go_hsv(void *data, Evas_Object *obj EINA_UNUSED, void *event_info EINA_UNUSED)
Ephoto_Single_Browser *sb = data; Ephoto_Single_Browser *sb = data;
if (sb->viewer) if (sb->viewer)
{ {
sb->editing = EINA_TRUE; sb->editing = EINA_TRUE;
Ephoto_Viewer *v = evas_object_data_get(sb->viewer, "viewer"); Ephoto_Viewer *v = evas_object_data_get(sb->viewer, "viewer");
@ -1425,7 +1425,7 @@ static Eina_Bool
_animate_cb(void *data) _animate_cb(void *data)
{ {
Ephoto_Viewer *v = data; Ephoto_Viewer *v = data;
v->cur_frame++; v->cur_frame++;
if (v->cur_frame > v->frame_count) if (v->cur_frame > v->frame_count)
v->cur_frame = 1; v->cur_frame = 1;
@ -1839,7 +1839,7 @@ _show_edit_main(void *data, int type EINA_UNUSED,
sb->edit_main = NULL; sb->edit_main = NULL;
} }
_editor_menu(sb, NULL, NULL); _editor_menu(sb, NULL, NULL);
return ECORE_CALLBACK_PASS_ON; return ECORE_CALLBACK_PASS_ON;
} }
@ -1883,7 +1883,7 @@ _ephoto_main_edit_menu(Ephoto_Single_Browser *sb)
elm_menu_move(menu, x, y); elm_menu_move(menu, x, y);
_add_edit_menu_items(sb, menu); _add_edit_menu_items(sb, menu);
evas_object_smart_callback_add(menu, "dismissed", _menu_dismissed_cb, evas_object_smart_callback_add(menu, "dismissed", _menu_dismissed_cb,
sb); sb);
evas_object_show(menu); evas_object_show(menu);
@ -2087,7 +2087,7 @@ _ephoto_main_del(void *data, Evas *e EINA_UNUSED, Evas_Object *obj EINA_UNUSED,
void void
ephoto_single_browser_adjust_offsets(Ephoto *ephoto) ephoto_single_browser_adjust_offsets(Ephoto *ephoto)
{ {
Ephoto_Single_Browser *sb = evas_object_data_get(ephoto->single_browser, Ephoto_Single_Browser *sb = evas_object_data_get(ephoto->single_browser,
"single_browser"); "single_browser");
Edje_Message_Int_Set *msg; Edje_Message_Int_Set *msg;
@ -2097,7 +2097,7 @@ ephoto_single_browser_adjust_offsets(Ephoto *ephoto)
msg->val[1] = 0; msg->val[1] = 0;
edje_object_message_send(elm_layout_edje_get(sb->ephoto->layout), edje_object_message_send(elm_layout_edje_get(sb->ephoto->layout),
EDJE_MESSAGE_INT_SET, 1, msg); EDJE_MESSAGE_INT_SET, 1, msg);
_image_changed(sb, NULL, NULL, NULL); _image_changed(sb, NULL, NULL, NULL);
} }
@ -2165,7 +2165,7 @@ ephoto_single_browser_entry_set(Evas_Object *obj, Ephoto_Entry *entry)
evas_object_image_size_get(v->image, &w, &h); evas_object_image_size_get(v->image, &w, &h);
eh = calloc(1, sizeof(Ephoto_History)); eh = calloc(1, sizeof(Ephoto_History));
eh->im_data = malloc(sizeof(unsigned int) * w * h); eh->im_data = malloc(sizeof(unsigned int) * w * h);
eh->im_data = memcpy(eh->im_data, evas_object_image_data_get(v->image, EINA_FALSE), memcpy(eh->im_data, evas_object_image_data_get(v->image, EINA_FALSE),
sizeof(unsigned int) * w * h); sizeof(unsigned int) * w * h);
eh->w = w; eh->w = w;
eh->h = h; eh->h = h;
@ -2361,8 +2361,8 @@ ephoto_single_browser_show_controls(Ephoto *ephoto)
20*elm_config_scale_get()); 20*elm_config_scale_get());
ret = elm_icon_standard_set(ic, "zoom-in"); ret = elm_icon_standard_set(ic, "zoom-in");
evas_object_size_hint_aspect_set(ic, EVAS_ASPECT_CONTROL_BOTH, 1, 1); evas_object_size_hint_aspect_set(ic, EVAS_ASPECT_CONTROL_BOTH, 1, 1);
but = elm_button_add(ephoto->controls_left); but = elm_button_add(ephoto->controls_left);
if (!ret) if (!ret)
elm_object_text_set(but, _("Zoom In")); elm_object_text_set(but, _("Zoom In"));
elm_object_part_content_set(but, "icon", ic); elm_object_part_content_set(but, "icon", ic);
@ -2377,7 +2377,7 @@ ephoto_single_browser_show_controls(Ephoto *ephoto)
20*elm_config_scale_get()); 20*elm_config_scale_get());
elm_icon_standard_set(ic, "zoom-out"); elm_icon_standard_set(ic, "zoom-out");
evas_object_size_hint_aspect_set(ic, EVAS_ASPECT_CONTROL_BOTH, 1, 1); evas_object_size_hint_aspect_set(ic, EVAS_ASPECT_CONTROL_BOTH, 1, 1);
but = elm_button_add(ephoto->controls_left); but = elm_button_add(ephoto->controls_left);
if (!ret) if (!ret)
elm_object_text_set(but, _("Zoom Out")); elm_object_text_set(but, _("Zoom Out"));

View File

@ -387,12 +387,12 @@ _slideshow_transition(void *data)
if (!eina_list_nth(ss->entries, ss->current)) if (!eina_list_nth(ss->entries, ss->current))
ss->current = 0; ss->current = 0;
if (ss->old_item) if (ss->old_item)
evas_object_del(ss->old_item); evas_object_del(ss->old_item);
ss->old_item = ss->current_item; ss->old_item = ss->current_item;
ss->current_item = _slideshow_item_get(ss, eina_list_nth(ss->entries, ss->current), ss->current_item = _slideshow_item_get(ss, eina_list_nth(ss->entries, ss->current),
ss->slideshow); ss->slideshow);
elm_layout_content_set(ss->slideshow, "ephoto.swallow.slideshow.item2", elm_layout_content_set(ss->slideshow, "ephoto.swallow.slideshow.item2",
ss->current_item); ss->current_item);
evas_object_show(ss->current_item); evas_object_show(ss->current_item);
@ -803,7 +803,6 @@ ephoto_slideshow_show_controls(Ephoto *ephoto)
ss->fullscreen_after = ss->fullscreen_after =
_add_icon(ss->notify, "preferences-other", _("Settings"), NULL); _add_icon(ss->notify, "preferences-other", _("Settings"), NULL);
evas_object_smart_callback_add(ss->fullscreen_after, "clicked", _settings, ss); evas_object_smart_callback_add(ss->fullscreen_after, "clicked", _settings, ss);
elm_layout_content_set(ephoto->layout, "ephoto.swallow.controls", ss->notify); elm_layout_content_set(ephoto->layout, "ephoto.swallow.controls", ss->notify);
} }

View File

@ -256,7 +256,7 @@ _dnd_drag_start(void *data EINA_UNUSED, Evas_Object *obj)
elm_object_cursor_set(tb->main, ELM_CURSOR_HAND2); elm_object_cursor_set(tb->main, ELM_CURSOR_HAND2);
ephoto_show_folders(tb->ephoto, EINA_FALSE); ephoto_show_folders(tb->ephoto, EINA_FALSE);
tb->dragging = 1; tb->dragging = 1;
} }
@ -918,7 +918,7 @@ _grid_mouse_up_cb(void *data, Evas *e EINA_UNUSED,
} }
if (clear_selection) if (clear_selection)
{ {
Eina_List *sel = eina_list_clone(selected); Eina_List *sel = eina_list_clone(selected);
Elm_Object_Item *it; Elm_Object_Item *it;
if (eina_list_count(sel) > 0) if (eina_list_count(sel) > 0)
{ {
@ -1566,7 +1566,7 @@ _ephoto_thumb_populate_end(void *data, int type EINA_UNUSED,
} }
if (tb->ephoto->state == EPHOTO_STATE_THUMB) if (tb->ephoto->state == EPHOTO_STATE_THUMB)
{ {
evas_object_smart_callback_call(tb->main, "changed,directory", NULL); evas_object_smart_callback_call(tb->main, "changed,directory", NULL);
ephoto_thumb_browser_update_info_label(tb->ephoto); ephoto_thumb_browser_update_info_label(tb->ephoto);
} }
tb->entries = tb->ephoto->entries; tb->entries = tb->ephoto->entries;
@ -1913,7 +1913,7 @@ _ephoto_main_del(void *data, Evas *e EINA_UNUSED, Evas_Object *obj EINA_UNUSED,
/*Ephoto Thumb Browser Public Functions*/ /*Ephoto Thumb Browser Public Functions*/
void void
ephoto_thumb_browser_dirs_only_set(Ephoto *ephoto, Eina_Bool dirs_only) ephoto_thumb_browser_dirs_only_set(Ephoto *ephoto, Eina_Bool dirs_only)
{ {
Ephoto_Thumb_Browser *tb = Ephoto_Thumb_Browser *tb =
@ -1929,7 +1929,7 @@ ephoto_thumb_browser_clear(Ephoto *ephoto)
evas_object_data_get(ephoto->thumb_browser, "thumb_browser"); evas_object_data_get(ephoto->thumb_browser, "thumb_browser");
elm_gengrid_clear(tb->grid); elm_gengrid_clear(tb->grid);
} }
void void
ephoto_thumb_browser_paste(Ephoto *ephoto, Elm_Object_Item *item) ephoto_thumb_browser_paste(Ephoto *ephoto, Elm_Object_Item *item)
@ -2089,7 +2089,7 @@ ephoto_thumb_browser_show_controls(Ephoto *ephoto)
20*elm_config_scale_get()); 20*elm_config_scale_get());
ret = elm_icon_standard_set(ic, "zoom-in"); ret = elm_icon_standard_set(ic, "zoom-in");
evas_object_size_hint_aspect_set(ic, EVAS_ASPECT_CONTROL_BOTH, 1, 1); evas_object_size_hint_aspect_set(ic, EVAS_ASPECT_CONTROL_BOTH, 1, 1);
but = elm_button_add(ephoto->controls_left); but = elm_button_add(ephoto->controls_left);
if (!ret) if (!ret)
elm_object_text_set(but, _("Zoom In")); elm_object_text_set(but, _("Zoom In"));
@ -2105,7 +2105,7 @@ ephoto_thumb_browser_show_controls(Ephoto *ephoto)
20*elm_config_scale_get()); 20*elm_config_scale_get());
elm_icon_standard_set(ic, "zoom-out"); elm_icon_standard_set(ic, "zoom-out");
evas_object_size_hint_aspect_set(ic, EVAS_ASPECT_CONTROL_BOTH, 1, 1); evas_object_size_hint_aspect_set(ic, EVAS_ASPECT_CONTROL_BOTH, 1, 1);
but = elm_button_add(ephoto->controls_left); but = elm_button_add(ephoto->controls_left);
if (!ret) if (!ret)
elm_object_text_set(but, _("Zoom Out")); elm_object_text_set(but, _("Zoom Out"));

View File

@ -298,7 +298,7 @@ _e_thumb_generate(E_Thumb *eth)
unsigned int *data1; unsigned int *data1;
Eina_Bool sortkey; Eina_Bool sortkey;
Evas_Object *im2, *bg; Evas_Object *im2, *bg;
im = NULL; im = NULL;
im2 = NULL; im2 = NULL;
bg = NULL; bg = NULL;
@ -317,7 +317,7 @@ _e_thumb_generate(E_Thumb *eth)
ext = strrchr(eth->file, '.'); ext = strrchr(eth->file, '.');
sortkey = EINA_FALSE; sortkey = EINA_FALSE;
if ((ext) && (eth->key) && if ((ext) && (eth->key) &&
((!strcasecmp(ext, ".edj")) || ((!strcasecmp(ext, ".edj")) ||
(!strcasecmp(ext, ".eap")))) (!strcasecmp(ext, ".eap"))))
@ -374,7 +374,7 @@ _e_thumb_generate(E_Thumb *eth)
evas_object_move(bg, 0, 0); evas_object_move(bg, 0, 0);
evas_object_resize(bg, ww, hh); evas_object_resize(bg, ww, hh);
evas_object_show(bg); evas_object_show(bg);
im = evas_object_text_add(evas); im = evas_object_text_add(evas);
evas_object_text_font_set(im, eth->file, hh / 4); evas_object_text_font_set(im, eth->file, hh / 4);
evas_object_color_set(im, 192, 192, 192, 255); evas_object_color_set(im, 192, 192, 192, 255);
@ -387,7 +387,7 @@ _e_thumb_generate(E_Thumb *eth)
evas_object_move(im, tx, ty); evas_object_move(im, tx, ty);
evas_object_resize(im, tw, th); evas_object_resize(im, tw, th);
evas_object_show(im); evas_object_show(im);
im2 = evas_object_text_add(evas); im2 = evas_object_text_add(evas);
evas_object_text_font_set(im2, eth->file, hh / 4); evas_object_text_font_set(im2, eth->file, hh / 4);
evas_object_color_set(im2, 255, 255, 255, 255); evas_object_color_set(im2, 255, 255, 255, 255);
@ -427,7 +427,7 @@ _e_thumb_generate(E_Thumb *eth)
} }
else else
goto end; goto end;
ecore_evas_alpha_set(ee, alpha); ecore_evas_alpha_set(ee, alpha);
ecore_evas_resize(ee, ww, hh); ecore_evas_resize(ee, ww, hh);
evas_object_show(im); evas_object_show(im);
@ -463,7 +463,7 @@ _e_thumb_generate(E_Thumb *eth)
if (data) if (data)
{ {
unsigned int *data2; unsigned int *data2;
data2 = malloc(ww * hh * sizeof(unsigned int)); data2 = malloc(ww * hh * sizeof(unsigned int));
memcpy(data2, data, ww * hh * sizeof(unsigned int)); memcpy(data2, data, ww * hh * sizeof(unsigned int));
ww = 1; hh = 1; ww = 1; hh = 1;
@ -489,7 +489,7 @@ _e_thumb_generate(E_Thumb *eth)
1, 14, 7, 8, 1, 14, 7, 8,
4, 11, 2, 13 4, 11, 2, 13
}; };
/* ww = hh = 1 here */ /* ww = hh = 1 here */
data3 = malloc(sizeof(unsigned int)); data3 = malloc(sizeof(unsigned int));
memcpy(data3, data, sizeof(unsigned int)); memcpy(data3, data, sizeof(unsigned int));