summaryrefslogtreecommitdiff
path: root/legacy
diff options
context:
space:
mode:
authorBruno Dilly <bdilly@profusion.mobi>2011-10-24 23:43:34 +0000
committerBruno Dilly <bdilly@profusion.mobi>2011-10-24 23:43:34 +0000
commitcee4098e1f9033f98f2202b3861dbdb702333030 (patch)
tree9008549f26e8408bfe031efdd5f507e907f2f085 /legacy
parent842daf46ecb06b213126ee64a7a0b57b139214f9 (diff)
Elementary: remove vars set but not used
Remove almost all of them. Remaining: - device on _event_history_clear, elm_gesture_layer - config has a hand of these cases. - ctxpopup var inside macro - segment control edje external (it's unfinished) SVN revision: 64365
Diffstat (limited to 'legacy')
-rw-r--r--legacy/elementary/src/bin/test_flip_page.c2
-rw-r--r--legacy/elementary/src/bin/test_genlist.c16
-rw-r--r--legacy/elementary/src/bin/test_menu.c4
-rw-r--r--legacy/elementary/src/bin/test_segment_control.c40
-rw-r--r--legacy/elementary/src/lib/elm_gengrid.c4
-rw-r--r--legacy/elementary/src/lib/els_cursor.c3
6 files changed, 32 insertions, 37 deletions
diff --git a/legacy/elementary/src/bin/test_flip_page.c b/legacy/elementary/src/bin/test_flip_page.c
index 2307a763ef..5537ea1150 100644
--- a/legacy/elementary/src/bin/test_flip_page.c
+++ b/legacy/elementary/src/bin/test_flip_page.c
@@ -318,7 +318,6 @@ _state_update(State *st)
318 double b, minv = 0.0, minva, mgrad; 318 double b, minv = 0.0, minva, mgrad;
319 int gx, gy, gszw, gszh, gw, gh, col, row, nw, nh; 319 int gx, gy, gszw, gszh, gw, gh, col, row, nw, nh;
320 double rho, A, theta, perc, percm, n, rhol, Al, thetal; 320 double rho, A, theta, perc, percm, n, rhol, Al, thetal;
321 Vertex2 *tvi;
322 Vertex3 *tvo, *tvol; 321 Vertex3 *tvo, *tvol;
323 322
324 st->backflip = 0; 323 st->backflip = 0;
@@ -474,7 +473,6 @@ _state_update(State *st)
474 473
475 num = (st->slices_w + 1) * (st->slices_h + 1); 474 num = (st->slices_w + 1) * (st->slices_h + 1);
476 475
477 tvi = alloca(sizeof(Vertex2) * num);
478 tvo = alloca(sizeof(Vertex3) * num); 476 tvo = alloca(sizeof(Vertex3) * num);
479 tvol = alloca(sizeof(Vertex3) * (st->slices_w + 1)); 477 tvol = alloca(sizeof(Vertex3) * (st->slices_w + 1));
480 478
diff --git a/legacy/elementary/src/bin/test_genlist.c b/legacy/elementary/src/bin/test_genlist.c
index dd8e5bb327..23f2d166e3 100644
--- a/legacy/elementary/src/bin/test_genlist.c
+++ b/legacy/elementary/src/bin/test_genlist.c
@@ -1348,7 +1348,7 @@ test_genlist8(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *event_in
1348{ 1348{
1349 Evas_Object *win, *bg, *gl, *bt[8], *bx, *bx2, *bx3; 1349 Evas_Object *win, *bg, *gl, *bt[8], *bx, *bx2, *bx3;
1350 Elm_Genlist_Item *gli = NULL, *git = NULL; 1350 Elm_Genlist_Item *gli = NULL, *git = NULL;
1351 int i, bt_count, bt_num; 1351 int i, bt_num;
1352 1352
1353 win = elm_win_add(NULL, "genlist-group", ELM_WIN_BASIC); 1353 win = elm_win_add(NULL, "genlist-group", ELM_WIN_BASIC);
1354 elm_win_title_set(win, "Genlist Group"); 1354 elm_win_title_set(win, "Genlist Group");
@@ -1460,7 +1460,6 @@ test_genlist8(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *event_in
1460 elm_box_pack_end(bx, bx3); 1460 elm_box_pack_end(bx, bx3);
1461 evas_object_show(bx3); 1461 evas_object_show(bx3);
1462 1462
1463 bt_count = 0;
1464 for (i = 0; i < 500; i++) 1463 for (i = 0; i < 500; i++)
1465 { 1464 {
1466 if (!(i % 10)) 1465 if (!(i % 10))
@@ -1889,7 +1888,6 @@ test_genlist12(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *event_i
1889{ 1888{
1890 Evas_Object *win, *bg, *bx, *gl; 1889 Evas_Object *win, *bg, *bx, *gl;
1891 int i; 1890 int i;
1892 Elm_Genlist_Item *gli;
1893 1891
1894 win = elm_win_add(NULL, "genlist-textblock", ELM_WIN_BASIC); 1892 win = elm_win_add(NULL, "genlist-textblock", ELM_WIN_BASIC);
1895 elm_win_title_set(win, "Genlist Textblock"); 1893 elm_win_title_set(win, "Genlist Textblock");
@@ -1920,12 +1918,12 @@ test_genlist12(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *event_i
1920 1918
1921 for (i = 0; i < 1000; i++) 1919 for (i = 0; i < 1000; i++)
1922 { 1920 {
1923 gli = elm_genlist_item_append(gl, &itc1, 1921 elm_genlist_item_append(gl, &itc1,
1924 (void *)(long)i/* item data */, 1922 (void *)(long)i/* item data */,
1925 NULL/* parent */, 1923 NULL/* parent */,
1926 ELM_GENLIST_ITEM_NONE, 1924 ELM_GENLIST_ITEM_NONE,
1927 gl_sel/* func */, 1925 gl_sel/* func */,
1928 (void *)(long)(i * 10)/* func data */); 1926 (void *)(long)(i * 10)/* func data */);
1929 } 1927 }
1930 1928
1931 evas_object_resize(win, 400, 500); 1929 evas_object_resize(win, 400, 500);
diff --git a/legacy/elementary/src/bin/test_menu.c b/legacy/elementary/src/bin/test_menu.c
index b880994cb8..540b425848 100644
--- a/legacy/elementary/src/bin/test_menu.c
+++ b/legacy/elementary/src/bin/test_menu.c
@@ -72,7 +72,7 @@ _populate_2(Elm_Menu_Item *item)
72static void 72static void
73_populate_1(Evas_Object *win, Elm_Menu_Item *item) 73_populate_1(Evas_Object *win, Elm_Menu_Item *item)
74{ 74{
75 Elm_Menu_Item *item2, *item3; 75 Elm_Menu_Item *item2;
76 Evas_Object *radio; 76 Evas_Object *radio;
77 77
78 radio = elm_radio_add(win); 78 radio = elm_radio_add(win);
@@ -80,7 +80,7 @@ _populate_1(Evas_Object *win, Elm_Menu_Item *item)
80 elm_radio_value_set(radio, 0); 80 elm_radio_value_set(radio, 0);
81 elm_object_text_set(radio, "radio in menu"); 81 elm_object_text_set(radio, "radio in menu");
82 item2 = elm_menu_item_add(menu, item, "object-rotate-left", "menu 1", NULL, NULL); 82 item2 = elm_menu_item_add(menu, item, "object-rotate-left", "menu 1", NULL, NULL);
83 item3 = elm_menu_item_add_object(menu, item, radio, NULL, NULL); 83 elm_menu_item_add_object(menu, item, radio, NULL, NULL);
84 84
85 _populate_2(item2); 85 _populate_2(item2);
86} 86}
diff --git a/legacy/elementary/src/bin/test_segment_control.c b/legacy/elementary/src/bin/test_segment_control.c
index 63ad4e34c8..60d3a49dc4 100644
--- a/legacy/elementary/src/bin/test_segment_control.c
+++ b/legacy/elementary/src/bin/test_segment_control.c
@@ -8,7 +8,7 @@ void
8test_segment_control(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *event_info __UNUSED__) 8test_segment_control(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *event_info __UNUSED__)
9{ 9{
10 Evas_Object *win, *bg, *ic, *ic1, *ic2, *ic3, *ic4, *ic5; 10 Evas_Object *win, *bg, *ic, *ic1, *ic2, *ic3, *ic4, *ic5;
11 Elm_Segment_Item *it1, *it2, *it3, *it4, *it5; 11 Elm_Segment_Item *it;
12 12
13 Evas_Object * in_layout; 13 Evas_Object * in_layout;
14 Evas_Object *segment1, *segment2, *segment3, *segment4; 14 Evas_Object *segment1, *segment2, *segment3, *segment4;
@@ -46,19 +46,19 @@ test_segment_control(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *e
46 evas_object_size_hint_aspect_set(ic1, EVAS_ASPECT_CONTROL_BOTH, 1, 1); 46 evas_object_size_hint_aspect_set(ic1, EVAS_ASPECT_CONTROL_BOTH, 1, 1);
47 47
48 segment1 = elm_segment_control_add(win); 48 segment1 = elm_segment_control_add(win);
49 it1 = elm_segment_control_item_add(segment1, NULL, "Only Text"); 49 elm_segment_control_item_add(segment1, NULL, "Only Text");
50 it2 = elm_segment_control_item_add(segment1, ic, NULL); 50 it = elm_segment_control_item_add(segment1, ic, NULL);
51 elm_segment_control_item_selected_set(it2, EINA_TRUE); 51 elm_segment_control_item_selected_set(it, EINA_TRUE);
52 it3 = elm_segment_control_item_add(segment1, ic1, "Text_Icon_test"); 52 elm_segment_control_item_add(segment1, ic1, "Text_Icon_test");
53 it4 = elm_segment_control_item_add(segment1, NULL, "Seg4"); 53 elm_segment_control_item_add(segment1, NULL, "Seg4");
54 it5 = elm_segment_control_item_add(segment1, NULL, "Seg5"); 54 elm_segment_control_item_add(segment1, NULL, "Seg5");
55 55
56 segment2 = elm_segment_control_add(win); 56 segment2 = elm_segment_control_add(win);
57 it1 = elm_segment_control_item_add(segment2, NULL, "SegmentItem"); 57 elm_segment_control_item_add(segment2, NULL, "SegmentItem");
58 it2 = elm_segment_control_item_add(segment2, NULL, "SegmentItem"); 58 it = elm_segment_control_item_add(segment2, NULL, "SegmentItem");
59 elm_segment_control_item_selected_set(it2, EINA_TRUE); 59 elm_segment_control_item_selected_set(it, EINA_TRUE);
60 it3 = elm_segment_control_item_add(segment2, NULL, "SegmentControlItem"); 60 elm_segment_control_item_add(segment2, NULL, "SegmentControlItem");
61 it4 = elm_segment_control_item_add(segment2, NULL, "SegmentItem"); 61 elm_segment_control_item_add(segment2, NULL, "SegmentItem");
62 62
63 ic2 = elm_icon_add(in_layout); 63 ic2 = elm_icon_add(in_layout);
64 snprintf(buf3, sizeof(buf3), "%s/images/logo.png", elm_app_data_dir_get()); 64 snprintf(buf3, sizeof(buf3), "%s/images/logo.png", elm_app_data_dir_get());
@@ -76,10 +76,10 @@ test_segment_control(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *e
76 evas_object_size_hint_aspect_set(ic4, EVAS_ASPECT_CONTROL_BOTH, 1, 1); 76 evas_object_size_hint_aspect_set(ic4, EVAS_ASPECT_CONTROL_BOTH, 1, 1);
77 77
78 segment3 = elm_segment_control_add(win); 78 segment3 = elm_segment_control_add(win);
79 it1 = elm_segment_control_item_add(segment3, ic2, NULL); 79 elm_segment_control_item_add(segment3, ic2, NULL);
80 it2 = elm_segment_control_item_add(segment3, ic3, NULL); 80 it = elm_segment_control_item_add(segment3, ic3, NULL);
81 elm_segment_control_item_selected_set(it2, EINA_TRUE); 81 elm_segment_control_item_selected_set(it, EINA_TRUE);
82 it3 = elm_segment_control_item_add(segment3, ic4, NULL); 82 elm_segment_control_item_add(segment3, ic4, NULL);
83 83
84 ic5 = elm_icon_add(in_layout); 84 ic5 = elm_icon_add(in_layout);
85 snprintf(buf6, sizeof(buf6), "%s/images/logo.png", elm_app_data_dir_get()); 85 snprintf(buf6, sizeof(buf6), "%s/images/logo.png", elm_app_data_dir_get());
@@ -87,10 +87,10 @@ test_segment_control(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *e
87 evas_object_size_hint_aspect_set(ic5, EVAS_ASPECT_CONTROL_BOTH, 1, 1); 87 evas_object_size_hint_aspect_set(ic5, EVAS_ASPECT_CONTROL_BOTH, 1, 1);
88 88
89 segment4 = elm_segment_control_add(win); 89 segment4 = elm_segment_control_add(win);
90 it1 = elm_segment_control_item_add(segment4, NULL, "Disabled"); 90 elm_segment_control_item_add(segment4, NULL, "Disabled");
91 it2 = elm_segment_control_item_add(segment4, ic5, "Disabled"); 91 it = elm_segment_control_item_add(segment4, ic5, "Disabled");
92 elm_segment_control_item_selected_set(it2, EINA_TRUE); 92 elm_segment_control_item_selected_set(it, EINA_TRUE);
93 it3 = elm_segment_control_item_add(segment4, NULL, "Disabled"); 93 elm_segment_control_item_add(segment4, NULL, "Disabled");
94 elm_object_disabled_set(segment4, EINA_TRUE); 94 elm_object_disabled_set(segment4, EINA_TRUE);
95 95
96 elm_layout_content_set(in_layout, "segment1", segment1); 96 elm_layout_content_set(in_layout, "segment1", segment1);
diff --git a/legacy/elementary/src/lib/elm_gengrid.c b/legacy/elementary/src/lib/elm_gengrid.c
index 8ac7c1d4d1..50d11f7849 100644
--- a/legacy/elementary/src/lib/elm_gengrid.c
+++ b/legacy/elementary/src/lib/elm_gengrid.c
@@ -948,10 +948,10 @@ _item_realize(Elm_Gen_Item *it)
948 EINA_LIST_FOREACH(it->labels, l, key) 948 EINA_LIST_FOREACH(it->labels, l, key)
949 { 949 {
950 char *s = it->itc->func.label_get 950 char *s = it->itc->func.label_get
951 ((void *)it->base.data, WIDGET(it), l->data); 951 ((void *)it->base.data, WIDGET(it), key);
952 if (s) 952 if (s)
953 { 953 {
954 edje_object_part_text_set(VIEW(it), l->data, s); 954 edje_object_part_text_set(VIEW(it), key, s);
955 free(s); 955 free(s);
956 } 956 }
957 } 957 }
diff --git a/legacy/elementary/src/lib/els_cursor.c b/legacy/elementary/src/lib/els_cursor.c
index 9fd0a4ce7f..6c0c8810b2 100644
--- a/legacy/elementary/src/lib/els_cursor.c
+++ b/legacy/elementary/src/lib/els_cursor.c
@@ -300,9 +300,8 @@ _elm_cursor_cur_set(Elm_Cursor *cur)
300 if (cur->use_engine) 300 if (cur->use_engine)
301 { 301 {
302#ifdef HAVE_ELEMENTARY_X 302#ifdef HAVE_ELEMENTARY_X
303 struct _Cursor_Id cur_search, *cur_id; 303 struct _Cursor_Id *cur_id;
304 304
305 cur_search.name = cur->cursor_name;
306 cur_id = bsearch(&(cur->cursor_name), _cursors, _cursors_count, 305 cur_id = bsearch(&(cur->cursor_name), _cursors, _cursors_count,
307 sizeof(struct _Cursor_Id), _elm_cursor_strcmp); 306 sizeof(struct _Cursor_Id), _elm_cursor_strcmp);
308 307