forked from enlightenment/efl
From: Bluezery <ohpowel@gmail.com>
Subject: [E-devel] [elm_map] ecore_file_download_full() should be used properly elm_map only checked that returned job is NULL. But ecore_file_download_full() returns EINA_FALSE when error occurred. So return value should be checked for proper usage. Please review this simple bug fix SVN revision: 64794
This commit is contained in:
parent
6d00462910
commit
84f0b47a95
|
@ -49,3 +49,4 @@ Kim Yunhan <spbear@gmail.com>
|
||||||
Bluezery <ohpowel@gmail.com>
|
Bluezery <ohpowel@gmail.com>
|
||||||
Nicolas Aguirre <aguirre.nicolas@gmail.com>
|
Nicolas Aguirre <aguirre.nicolas@gmail.com>
|
||||||
Sanjeev BA <iamsanjeev@gmail.com>
|
Sanjeev BA <iamsanjeev@gmail.com>
|
||||||
|
Bluezery <ohpowel@gmail.com>
|
||||||
|
|
|
@ -711,7 +711,7 @@ _map_mouse_up(void *data __UNUSED__, Evas *evas __UNUSED__, Evas_Object *obj __U
|
||||||
void
|
void
|
||||||
test_map(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *event_info __UNUSED__)
|
test_map(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *event_info __UNUSED__)
|
||||||
{
|
{
|
||||||
Evas_Object *win, *bg, *map;
|
Evas_Object *win, *bg, *map, *tab, *r, *en;
|
||||||
int idx = 0;
|
int idx = 0;
|
||||||
|
|
||||||
win = elm_win_add(NULL, "map", ELM_WIN_BASIC);
|
win = elm_win_add(NULL, "map", ELM_WIN_BASIC);
|
||||||
|
@ -723,6 +723,19 @@ test_map(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *event_info __
|
||||||
elm_win_resize_object_add(win, bg);
|
elm_win_resize_object_add(win, bg);
|
||||||
evas_object_show(bg);
|
evas_object_show(bg);
|
||||||
|
|
||||||
|
tab = elm_table_add(win);
|
||||||
|
evas_object_size_hint_weight_set(tab, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
|
||||||
|
elm_win_resize_object_add(win, tab);
|
||||||
|
evas_object_show(tab);
|
||||||
|
|
||||||
|
r = evas_object_rectangle_add(evas_object_evas_get(win));
|
||||||
|
evas_object_color_set(r, 20, 40, 60, 255);
|
||||||
|
evas_object_size_hint_min_set(r, 200, 200);
|
||||||
|
evas_object_size_hint_weight_set(r, EVAS_HINT_EXPAND, 0);
|
||||||
|
evas_object_size_hint_fill_set(r, EVAS_HINT_FILL, EVAS_HINT_FILL);
|
||||||
|
elm_table_pack(tab, r, 0, 0, 1, 1);
|
||||||
|
evas_object_show(r);
|
||||||
|
|
||||||
map = elm_map_add(win);
|
map = elm_map_add(win);
|
||||||
if (map)
|
if (map)
|
||||||
{
|
{
|
||||||
|
@ -736,7 +749,9 @@ test_map(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *event_info __
|
||||||
printf("]\n");
|
printf("]\n");
|
||||||
|
|
||||||
evas_object_size_hint_weight_set(map, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
|
evas_object_size_hint_weight_set(map, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
|
||||||
elm_win_resize_object_add(win, map);
|
evas_object_size_hint_fill_set(map, EVAS_HINT_FILL, EVAS_HINT_FILL);
|
||||||
|
elm_table_pack(tab, map, 0, 2, 1, 1);
|
||||||
|
// elm_win_resize_object_add(win, map);
|
||||||
evas_object_data_set(map, "window", win);
|
evas_object_data_set(map, "window", win);
|
||||||
|
|
||||||
//
|
//
|
||||||
|
@ -827,6 +842,14 @@ test_map(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *event_info __
|
||||||
|
|
||||||
evas_object_show(map);
|
evas_object_show(map);
|
||||||
}
|
}
|
||||||
|
en = elm_entry_add(win);
|
||||||
|
elm_entry_scrollable_set(en, EINA_TRUE);
|
||||||
|
elm_entry_single_line_set(en, 1);
|
||||||
|
evas_object_size_hint_weight_set(en, EVAS_HINT_EXPAND, 0.0);
|
||||||
|
evas_object_size_hint_align_set(en, EVAS_HINT_FILL, 0.1);
|
||||||
|
elm_table_pack(tab, en, 0, 1, 1, 1);
|
||||||
|
evas_object_show(en);
|
||||||
|
|
||||||
|
|
||||||
evas_object_resize(win, 800, 800);
|
evas_object_resize(win, 800, 800);
|
||||||
evas_object_show(win);
|
evas_object_show(win);
|
||||||
|
|
|
@ -3263,7 +3263,12 @@ _queue_process(Widget_Data *wd)
|
||||||
it = wd->queue->data;
|
it = wd->queue->data;
|
||||||
wd->queue = eina_list_remove_list(wd->queue, wd->queue);
|
wd->queue = eina_list_remove_list(wd->queue, wd->queue);
|
||||||
it->item->queued = EINA_FALSE;
|
it->item->queued = EINA_FALSE;
|
||||||
_item_block_add(wd, it);
|
if (!wd->blocks)
|
||||||
|
{
|
||||||
|
_item_block_add(wd, it);
|
||||||
|
_item_block_realize(it->item->block);
|
||||||
|
}
|
||||||
|
else _item_block_add(wd, it);
|
||||||
t = ecore_time_get();
|
t = ecore_time_get();
|
||||||
if (it->item->block->changed)
|
if (it->item->block->changed)
|
||||||
{
|
{
|
||||||
|
|
|
@ -1284,9 +1284,9 @@ _process_download_list(Evas_Object *obj)
|
||||||
if (gi->wd->download_num >= MAX_CONCURRENT_DOWNLOAD)
|
if (gi->wd->download_num >= MAX_CONCURRENT_DOWNLOAD)
|
||||||
break;
|
break;
|
||||||
|
|
||||||
ecore_file_download_full(gi->source, gi->file, _tile_downloaded, NULL, gi, &(gi->job), wd->ua);
|
Eina_Bool ret = ecore_file_download_full(gi->source, gi->file, _tile_downloaded, NULL, gi, &(gi->job), wd->ua);
|
||||||
if (!gi->job)
|
if (!ret || !gi->job)
|
||||||
DBG("Can't start to download %s to %s", gi->source, gi->file);
|
WRN("Can't start to download %s to %s", gi->source, gi->file);
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
gi->wd->download_num++;
|
gi->wd->download_num++;
|
||||||
|
|
Loading…
Reference in New Issue