summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJean-Philippe Andre <jp.andre@samsung.com>2018-01-16 15:12:49 +0900
committerJean-Philippe Andre <jp.andre@samsung.com>2018-01-16 18:37:05 +0900
commita92186be6ab7ba6b8ba0b2bedeaec51dcb4a3898 (patch)
treec22e99af65360feb242ead4bccd12acee605d424
parentf2b5b00ca204e8a0b8c4ab671f60088da4edfca3 (diff)
ecore/edje/elm: Fix a few WRN from calls to NULL
This fixes some of the warnings generated by calling functions on NULL objects. One of the main remaining points is to avoid unwanted warnings on non-existing parts. Ref T6326
-rw-r--r--src/lib/ecore_input_evas/ecore_input_evas.c28
-rw-r--r--src/lib/edje/edje_calc.c3
-rw-r--r--src/lib/edje/edje_smart.c16
-rw-r--r--src/lib/edje/edje_util.c6
-rw-r--r--src/lib/elementary/efl_ui_button.c1
-rw-r--r--src/lib/elementary/efl_ui_check.c1
-rw-r--r--src/lib/elementary/efl_ui_focus_manager_calc.c15
-rw-r--r--src/lib/elementary/efl_ui_focus_manager_sub.c9
-rw-r--r--src/lib/elementary/efl_ui_focus_util.c2
-rw-r--r--src/lib/elementary/efl_ui_layout.c37
-rw-r--r--src/lib/elementary/efl_ui_progressbar.c1
-rw-r--r--src/lib/elementary/efl_ui_radio.c6
-rw-r--r--src/lib/elementary/efl_ui_widget.c21
-rw-r--r--src/lib/elementary/elm_entry.c3
-rw-r--r--src/lib/elementary/elm_interface_scrollable.c3
-rw-r--r--src/lib/elementary/elm_widget.h7
-rw-r--r--src/lib/elementary/els_cursor.c2
17 files changed, 105 insertions, 56 deletions
diff --git a/src/lib/ecore_input_evas/ecore_input_evas.c b/src/lib/ecore_input_evas/ecore_input_evas.c
index 7866bd5d9a..bd2f0d1868 100644
--- a/src/lib/ecore_input_evas/ecore_input_evas.c
+++ b/src/lib/ecore_input_evas/ecore_input_evas.c
@@ -417,12 +417,12 @@ static Eina_Bool
417_ecore_event_evas_key(Ecore_Event_Key *e, Ecore_Event_Press press) 417_ecore_event_evas_key(Ecore_Event_Key *e, Ecore_Event_Press press)
418{ 418{
419 Ecore_Input_Window *lookup; 419 Ecore_Input_Window *lookup;
420 Eo *seat;
420 421
421 lookup = _ecore_event_window_match(e->event_window); 422 lookup = _ecore_event_window_match(e->event_window);
422 if (!lookup) return ECORE_CALLBACK_PASS_ON; 423 if (!lookup) return ECORE_CALLBACK_PASS_ON;
423 ecore_event_evas_seat_modifier_lock_update(lookup->evas, 424 seat = e->dev ? efl_input_device_seat_get(e->dev) : NULL;
424 e->modifiers, 425 ecore_event_evas_seat_modifier_lock_update(lookup->evas, e->modifiers, seat);
425 efl_input_device_seat_get(e->dev));
426 if (press == ECORE_DOWN) 426 if (press == ECORE_DOWN)
427 { 427 {
428 if (!lookup->direct || 428 if (!lookup->direct ||
@@ -531,9 +531,8 @@ _ecore_event_evas_mouse_button(Ecore_Event_Mouse_Button *e, Ecore_Event_Press pr
531 531
532 if (e->multi.device == 0) 532 if (e->multi.device == 0)
533 { 533 {
534 ecore_event_evas_seat_modifier_lock_update(lookup->evas, 534 Eo *seat = e->dev ? efl_input_device_seat_get(e->dev) : NULL;
535 e->modifiers, 535 ecore_event_evas_seat_modifier_lock_update(lookup->evas, e->modifiers, seat);
536 efl_input_device_seat_get(e->dev));
537 if (press == ECORE_DOWN) 536 if (press == ECORE_DOWN)
538 { 537 {
539 if (!lookup->direct || 538 if (!lookup->direct ||
@@ -612,10 +611,9 @@ ecore_event_evas_mouse_move(void *data EINA_UNUSED, int type EINA_UNUSED, void *
612 if (!lookup) return ECORE_CALLBACK_PASS_ON; 611 if (!lookup) return ECORE_CALLBACK_PASS_ON;
613 if (e->multi.device == 0) 612 if (e->multi.device == 0)
614 { 613 {
614 Eo *seat = e->dev ? efl_input_device_seat_get(e->dev) : NULL;
615 _ecore_event_evas_push_mouse_move(e); 615 _ecore_event_evas_push_mouse_move(e);
616 ecore_event_evas_seat_modifier_lock_update(lookup->evas, 616 ecore_event_evas_seat_modifier_lock_update(lookup->evas, e->modifiers, seat);
617 e->modifiers,
618 efl_input_device_seat_get(e->dev));
619 if (!lookup->direct || 617 if (!lookup->direct ||
620 !lookup->direct(lookup->window, ECORE_EVENT_MOUSE_MOVE, e)) 618 !lookup->direct(lookup->window, ECORE_EVENT_MOUSE_MOVE, e))
621 { 619 {
@@ -671,12 +669,13 @@ static Eina_Bool
671_ecore_event_evas_mouse_io(Ecore_Event_Mouse_IO *e, Ecore_Event_IO io) 669_ecore_event_evas_mouse_io(Ecore_Event_Mouse_IO *e, Ecore_Event_IO io)
672{ 670{
673 Ecore_Input_Window *lookup; 671 Ecore_Input_Window *lookup;
672 Eo *seat;
674 673
675 lookup = _ecore_event_window_match(e->event_window); 674 lookup = _ecore_event_window_match(e->event_window);
676 if (!lookup) return ECORE_CALLBACK_PASS_ON; 675 if (!lookup) return ECORE_CALLBACK_PASS_ON;
677 ecore_event_evas_seat_modifier_lock_update(lookup->evas, 676 seat = e->dev ? efl_input_device_seat_get(e->dev) : NULL;
678 e->modifiers, 677 ecore_event_evas_seat_modifier_lock_update(lookup->evas, e->modifiers, seat);
679 efl_input_device_seat_get(e->dev)); 678
680 switch (io) 679 switch (io)
681 { 680 {
682 case ECORE_IN: 681 case ECORE_IN:
@@ -718,12 +717,13 @@ ecore_event_evas_mouse_wheel(void *data EINA_UNUSED, int type EINA_UNUSED, void
718{ 717{
719 Ecore_Event_Mouse_Wheel *e; 718 Ecore_Event_Mouse_Wheel *e;
720 Ecore_Input_Window *lookup; 719 Ecore_Input_Window *lookup;
720 Eo *seat;
721 721
722 e = event; 722 e = event;
723 lookup = _ecore_event_window_match(e->event_window); 723 lookup = _ecore_event_window_match(e->event_window);
724 if (!lookup) return ECORE_CALLBACK_PASS_ON; 724 if (!lookup) return ECORE_CALLBACK_PASS_ON;
725 ecore_event_evas_seat_modifier_lock_update(lookup->evas, e->modifiers, 725 seat = e->dev ? efl_input_device_seat_get(e->dev) : NULL;
726 efl_input_device_seat_get(e->dev)); 726 ecore_event_evas_seat_modifier_lock_update(lookup->evas, e->modifiers, seat);
727 if (!lookup->direct || 727 if (!lookup->direct ||
728 !lookup->direct(lookup->window, ECORE_EVENT_MOUSE_WHEEL, e)) 728 !lookup->direct(lookup->window, ECORE_EVENT_MOUSE_WHEEL, e))
729 { 729 {
diff --git a/src/lib/edje/edje_calc.c b/src/lib/edje/edje_calc.c
index 64b95ed72e..2e186213bd 100644
--- a/src/lib/edje/edje_calc.c
+++ b/src/lib/edje/edje_calc.c
@@ -1083,7 +1083,8 @@ _edje_dragable_pos_set(Edje *ed, Edje_Real_Part *ep, FLOAT_T x, FLOAT_T y)
1083 * value we would set foo to, because it would depend on the 1083 * value we would set foo to, because it would depend on the
1084 * size of the dragable... 1084 * size of the dragable...
1085 */ 1085 */
1086 evas_object_geometry_get(ep->object, &ex, &ey, NULL, NULL); 1086 if (ep->object)
1087 evas_object_geometry_get(ep->object, &ex, &ey, NULL, NULL);
1087 1088
1088 if (NEQ(ep->drag->x, x) || ep->drag->tmp.x) 1089 if (NEQ(ep->drag->x, x) || ep->drag->tmp.x)
1089 { 1090 {
diff --git a/src/lib/edje/edje_smart.c b/src/lib/edje/edje_smart.c
index ae038fb10e..6b4ed89256 100644
--- a/src/lib/edje/edje_smart.c
+++ b/src/lib/edje/edje_smart.c
@@ -182,13 +182,21 @@ _efl_canvas_layout_efl_gfx_position_set(Eo *obj, Edje *ed, Eina_Position2D pos)
182 ep = ed->table_parts[i]; 182 ep = ed->table_parts[i];
183 if ((ep->type == EDJE_RP_TYPE_TEXT) && (ep->typedata.text)) 183 if ((ep->type == EDJE_RP_TYPE_TEXT) && (ep->typedata.text))
184 { 184 {
185 evas_object_move(ep->object, 185 if (ep->object)
186 ed->x + ep->x + ep->typedata.text->offset.x, 186 evas_object_move(ep->object,
187 ed->y + ep->y + ep->typedata.text->offset.y); 187 ed->x + ep->x + ep->typedata.text->offset.x,
188 ed->y + ep->y + ep->typedata.text->offset.y);
189 else if (ep->type != EFL_CANVAS_LAYOUT_PART_TYPE_NONE)
190 WRN("No object for part '%s' in group '%s'",
191 ep->part ? ep->part->name : "<invalid>", ed->group);
188 } 192 }
189 else 193 else
190 { 194 {
191 evas_object_move(ep->object, ed->x + ep->x, ed->y + ep->y); 195 if (ep->object)
196 evas_object_move(ep->object, ed->x + ep->x, ed->y + ep->y);
197 else if (ep->type != EFL_CANVAS_LAYOUT_PART_TYPE_NONE)
198 WRN("No object for part '%s' in group '%s'",
199 ep->part ? ep->part->name : "<invalid>", ed->group);
192 if ((ep->type == EDJE_RP_TYPE_SWALLOW) && 200 if ((ep->type == EDJE_RP_TYPE_SWALLOW) &&
193 (ep->typedata.swallow)) 201 (ep->typedata.swallow))
194 { 202 {
diff --git a/src/lib/edje/edje_util.c b/src/lib/edje/edje_util.c
index b5638ecfc1..cfbccd6c26 100644
--- a/src/lib/edje/edje_util.c
+++ b/src/lib/edje/edje_util.c
@@ -3297,7 +3297,11 @@ _efl_canvas_layout_efl_part_part(Eo *obj, Edje *ed, const char *part)
3297 if ((!ed) || (!part)) return NULL; 3297 if ((!ed) || (!part)) return NULL;
3298 3298
3299 rp = _edje_real_part_recursive_get(&ed, part); 3299 rp = _edje_real_part_recursive_get(&ed, part);
3300 if (!rp) return NULL; 3300 if (EINA_UNLIKELY(!rp))
3301 {
3302 WRN("No such part '%s' in group '%s'.", part, ed->group);
3303 return NULL;
3304 }
3301 3305
3302 if (rp->part->type == EDJE_PART_TYPE_BOX) 3306 if (rp->part->type == EDJE_PART_TYPE_BOX)
3303 return _edje_box_internal_proxy_get(obj, ed, rp); 3307 return _edje_box_internal_proxy_get(obj, ed, rp);
diff --git a/src/lib/elementary/efl_ui_button.c b/src/lib/elementary/efl_ui_button.c
index 34dbd02ca7..8cdfa7d161 100644
--- a/src/lib/elementary/efl_ui_button.c
+++ b/src/lib/elementary/efl_ui_button.c
@@ -109,6 +109,7 @@ _icon_signal_emit(Evas_Object *obj)
109{ 109{
110 char buf[64]; 110 char buf[64];
111 111
112 if (!elm_widget_resize_object_get(obj)) return;
112 snprintf(buf, sizeof(buf), "elm,state,icon,%s", 113 snprintf(buf, sizeof(buf), "elm,state,icon,%s",
113 elm_layout_content_get(obj, "icon") ? "visible" : "hidden"); 114 elm_layout_content_get(obj, "icon") ? "visible" : "hidden");
114 115
diff --git a/src/lib/elementary/efl_ui_check.c b/src/lib/elementary/efl_ui_check.c
index f4917b32e4..2bb3e07a4c 100644
--- a/src/lib/elementary/efl_ui_check.c
+++ b/src/lib/elementary/efl_ui_check.c
@@ -93,6 +93,7 @@ _icon_signal_emit(Evas_Object *obj)
93 ELM_WIDGET_DATA_GET_OR_RETURN(obj, wd); 93 ELM_WIDGET_DATA_GET_OR_RETURN(obj, wd);
94 char buf[64]; 94 char buf[64];
95 95
96 if (!elm_widget_resize_object_get(obj)) return;
96 snprintf(buf, sizeof(buf), "elm,state,icon,%s", 97 snprintf(buf, sizeof(buf), "elm,state,icon,%s",
97 elm_layout_content_get(obj, "icon") ? "visible" : "hidden"); 98 elm_layout_content_get(obj, "icon") ? "visible" : "hidden");
98 99
diff --git a/src/lib/elementary/efl_ui_focus_manager_calc.c b/src/lib/elementary/efl_ui_focus_manager_calc.c
index c8641b5338..2e1b10a1d3 100644
--- a/src/lib/elementary/efl_ui_focus_manager_calc.c
+++ b/src/lib/elementary/efl_ui_focus_manager_calc.c
@@ -81,6 +81,8 @@ typedef struct {
81static void 81static void
82_manager_in_chain_set(Eo *obj, Efl_Ui_Focus_Manager_Calc_Data *pd) 82_manager_in_chain_set(Eo *obj, Efl_Ui_Focus_Manager_Calc_Data *pd)
83{ 83{
84 Eo *manager;
85
84 EINA_SAFETY_ON_NULL_RETURN(pd->root); 86 EINA_SAFETY_ON_NULL_RETURN(pd->root);
85 87
86 if (!efl_isa(pd->root->focusable, EFL_UI_WIN_CLASS)) 88 if (!efl_isa(pd->root->focusable, EFL_UI_WIN_CLASS))
@@ -89,7 +91,12 @@ _manager_in_chain_set(Eo *obj, Efl_Ui_Focus_Manager_Calc_Data *pd)
89 //so we dont run infinitly this does not fix it, but at least we only have a error 91 //so we dont run infinitly this does not fix it, but at least we only have a error
90 EINA_SAFETY_ON_TRUE_RETURN(efl_ui_focus_user_focus_manager_get(pd->root->focusable) == obj); 92 EINA_SAFETY_ON_TRUE_RETURN(efl_ui_focus_user_focus_manager_get(pd->root->focusable) == obj);
91 93
92 efl_ui_focus_manager_focus_set(efl_ui_focus_user_focus_manager_get(pd->root->focusable), pd->root->focusable); 94 manager = efl_ui_focus_user_focus_manager_get(pd->root->focusable);
95 if (manager)
96 efl_ui_focus_manager_focus_set(manager, pd->root->focusable);
97 else
98 DBG("No focus manager for focusable %s@%p",
99 efl_class_name_get(pd->root->focusable), pd->root->focusable);
93} 100}
94 101
95static Efl_Ui_Focus_Direction 102static Efl_Ui_Focus_Direction
@@ -1569,8 +1576,10 @@ _efl_ui_focus_manager_calc_efl_ui_focus_manager_manager_focus_set(Eo *obj, Efl_U
1569 if (node_type == NODE_TYPE_NORMAL) 1576 if (node_type == NODE_TYPE_NORMAL)
1570 { 1577 {
1571 //populate the new change 1578 //populate the new change
1572 efl_ui_focus_object_focus_set(last_focusable, EINA_FALSE); 1579 if (last_focusable)
1573 efl_ui_focus_object_focus_set(new_focusable, EINA_TRUE); 1580 efl_ui_focus_object_focus_set(last_focusable, EINA_FALSE);
1581 if (new_focusable)
1582 efl_ui_focus_object_focus_set(new_focusable, EINA_TRUE);
1574 efl_event_callback_call(obj, EFL_UI_FOCUS_MANAGER_EVENT_FOCUSED, last_focusable); 1583 efl_event_callback_call(obj, EFL_UI_FOCUS_MANAGER_EVENT_FOCUSED, last_focusable);
1575 } 1584 }
1576 1585
diff --git a/src/lib/elementary/efl_ui_focus_manager_sub.c b/src/lib/elementary/efl_ui_focus_manager_sub.c
index 5404eb05ee..4e1ce22052 100644
--- a/src/lib/elementary/efl_ui_focus_manager_sub.c
+++ b/src/lib/elementary/efl_ui_focus_manager_sub.c
@@ -137,10 +137,10 @@ _logical_manager_change(void *data EINA_UNUSED, const Efl_Event *ev)
137 Eina_List *n; 137 Eina_List *n;
138 Efl_Ui_Focus_User *b; 138 Efl_Ui_Focus_User *b;
139 Efl_Ui_Focus_Manager *manager; 139 Efl_Ui_Focus_Manager *manager;
140 manager = efl_ui_focus_user_focus_manager_get(ev->object);
141 140
142 if (!ev->info) return; 141 if (!ev->info) return;
143 142
143 manager = efl_ui_focus_user_focus_manager_get(ev->object);
144 EINA_LIST_FOREACH(pd->current_border, n, b) 144 EINA_LIST_FOREACH(pd->current_border, n, b)
145 { 145 {
146 if (b == ev->object) continue; 146 if (b == ev->object) continue;
@@ -156,13 +156,12 @@ _flush_manager(Eo *obj, Efl_Ui_Focus_Manager_Sub_Data *pd)
156 Efl_Ui_Focus_User *b; 156 Efl_Ui_Focus_User *b;
157 Eina_List *n; 157 Eina_List *n;
158 158
159
160 logical = efl_ui_focus_user_focus_parent_get(obj); 159 logical = efl_ui_focus_user_focus_parent_get(obj);
161 manager = efl_ui_focus_user_focus_manager_get(obj); 160 manager = efl_ui_focus_user_focus_manager_get(obj);
162 161
163 //unregister from the old 162 //unregister from the old
164 efl_event_callback_array_del(pd->manager, parent_manager(), obj); 163 if (pd->manager) efl_event_callback_array_del(pd->manager, parent_manager(), obj);
165 efl_event_callback_array_add(manager, parent_manager(), obj); 164 if (manager) efl_event_callback_array_add(manager, parent_manager(), obj);
166 165
167 EINA_LIST_FOREACH(pd->current_border , n, b) 166 EINA_LIST_FOREACH(pd->current_border , n, b)
168 { 167 {
@@ -203,7 +202,7 @@ _efl_ui_focus_manager_sub_efl_object_destructor(Eo *obj, Efl_Ui_Focus_Manager_Su
203{ 202{
204 _border_unregister(obj, pd); 203 _border_unregister(obj, pd);
205 204
206 efl_event_callback_array_del(pd->manager, parent_manager(), obj); 205 if (pd->manager) efl_event_callback_array_del(pd->manager, parent_manager(), obj);
207 206
208 efl_destructor(efl_super(obj, MY_CLASS)); 207 efl_destructor(efl_super(obj, MY_CLASS));
209} 208}
diff --git a/src/lib/elementary/efl_ui_focus_util.c b/src/lib/elementary/efl_ui_focus_util.c
index 76ec9280e5..aa0fbbdb42 100644
--- a/src/lib/elementary/efl_ui_focus_util.c
+++ b/src/lib/elementary/efl_ui_focus_util.c
@@ -25,7 +25,7 @@ _efl_ui_focus_util_focus(Eo *obj EINA_UNUSED, void *pd EINA_UNUSED, Efl_Ui_Focus
25 top = elm_widget_top_get(user); 25 top = elm_widget_top_get(user);
26 26
27 o = efl_key_data_get(top, "__delayed_focus_set"); 27 o = efl_key_data_get(top, "__delayed_focus_set");
28 efl_event_callback_del(o, EFL_UI_FOCUS_USER_EVENT_MANAGER_CHANGED, _manager_changed, o); 28 if (o) efl_event_callback_del(o, EFL_UI_FOCUS_USER_EVENT_MANAGER_CHANGED, _manager_changed, o);
29 efl_key_data_set(top, "__delayed_focus_set", NULL); 29 efl_key_data_set(top, "__delayed_focus_set", NULL);
30 30
31 if (!m) 31 if (!m)
diff --git a/src/lib/elementary/efl_ui_layout.c b/src/lib/elementary/efl_ui_layout.c
index 60c6500828..06849d167c 100644
--- a/src/lib/elementary/efl_ui_layout.c
+++ b/src/lib/elementary/efl_ui_layout.c
@@ -165,8 +165,12 @@ _icon_signal_emit(Efl_Ui_Layout_Data *sd,
165{ 165{
166 char buf[1024]; 166 char buf[1024];
167 const char *type; 167 const char *type;
168 Eo *edje;
168 int i; 169 int i;
169 170
171 edje = elm_widget_resize_object_get(sd->obj);
172 if (!edje) return;
173
170 //FIXME: Don't limit to the icon and end here. 174 //FIXME: Don't limit to the icon and end here.
171 // send signals for all contents after elm 2.0 175 // send signals for all contents after elm 2.0
172 if (sub_d->type != SWALLOW) return; 176 if (sub_d->type != SWALLOW) return;
@@ -184,11 +188,10 @@ _icon_signal_emit(Efl_Ui_Layout_Data *sd,
184 snprintf(buf, sizeof(buf), "elm,state,%s,%s", type, 188 snprintf(buf, sizeof(buf), "elm,state,%s,%s", type,
185 visible ? "visible" : "hidden"); 189 visible ? "visible" : "hidden");
186 190
187 ELM_WIDGET_DATA_GET_OR_RETURN(sd->obj, wd); 191 edje_object_signal_emit(edje, buf, "elm");
188 edje_object_signal_emit(wd->resize_obj, buf, "elm");
189 192
190 /* themes might need immediate action here */ 193 /* themes might need immediate action here */
191 edje_object_message_signal_process(wd->resize_obj); 194 edje_object_message_signal_process(edje);
192} 195}
193 196
194static inline void 197static inline void
@@ -640,17 +643,14 @@ _efl_ui_layout_efl_canvas_group_group_del(Eo *obj, Efl_Ui_Layout_Data *sd)
640 Efl_Ui_Layout_Sub_Connect *sc; 643 Efl_Ui_Layout_Sub_Connect *sc;
641 Edje_Signal_Data *esd; 644 Edje_Signal_Data *esd;
642 Evas_Object *child; 645 Evas_Object *child;
643 Eina_List *l; 646 Eina_List *l, *ll;
644 647
645 ELM_WIDGET_DATA_GET_OR_RETURN(obj, wd); 648 ELM_WIDGET_DATA_GET_OR_RETURN(obj, wd);
646 649
647 elm_layout_freeze(obj); 650 elm_layout_freeze(obj);
648 651
649 EINA_LIST_FREE(sd->subs, sub_d) 652 EINA_LIST_FOREACH_SAFE(sd->subs, l, ll, sub_d)
650 { 653 efl_ui_widget_sub_object_del(obj, sub_d->obj);
651 eina_stringshare_del(sub_d->part);
652 free(sub_d);
653 }
654 654
655 EINA_LIST_FREE(sd->parts_cursors, pc) 655 EINA_LIST_FREE(sd->parts_cursors, pc)
656 _part_cursor_free(pc); 656 _part_cursor_free(pc);
@@ -2430,17 +2430,18 @@ elm_layout_theme_set(Evas_Object *obj, const char *klass, const char *group, con
2430EOLIAN static Eo * 2430EOLIAN static Eo *
2431_efl_ui_layout_efl_part_part(const Eo *obj, Efl_Ui_Layout_Data *sd EINA_UNUSED, const char *part) 2431_efl_ui_layout_efl_part_part(const Eo *obj, Efl_Ui_Layout_Data *sd EINA_UNUSED, const char *part)
2432{ 2432{
2433 Efl_Canvas_Layout_Part_Type type; 2433 Efl_Canvas_Layout_Part_Type type = EFL_CANVAS_LAYOUT_PART_TYPE_NONE;
2434 2434
2435 EINA_SAFETY_ON_NULL_RETURN_VAL(part, NULL); 2435 EINA_SAFETY_ON_NULL_RETURN_VAL(part, NULL);
2436 ELM_WIDGET_DATA_GET_OR_RETURN((Eo *) obj, wd, NULL); 2436 ELM_WIDGET_DATA_GET_OR_RETURN((Eo *) obj, wd, NULL);
2437 2437
2438 // Check part type without using edje_object_part_object_get(), as this 2438 // Check part type without using edje_object_part_object_get(), as this
2439 // can cause recalc, which has side effects... and could be slow. 2439 // can cause recalc, which has side effects... and could be slow.
2440 type = efl_canvas_layout_part_type_get(efl_part(wd->resize_obj, part));
2441 2440
2442 if (eina_streq(part, "background")) 2441 if (eina_streq(part, "background"))
2443 { 2442 {
2443 if (efl_layout_group_part_exist_get(wd->resize_obj, part))
2444 type = efl_canvas_layout_part_type_get(efl_part(wd->resize_obj, part));
2444 if (type != EFL_CANVAS_LAYOUT_PART_TYPE_SWALLOW) 2445 if (type != EFL_CANVAS_LAYOUT_PART_TYPE_SWALLOW)
2445 { 2446 {
2446 if (type < EFL_CANVAS_LAYOUT_PART_TYPE_LAST && 2447 if (type < EFL_CANVAS_LAYOUT_PART_TYPE_LAST &&
@@ -2459,9 +2460,18 @@ _efl_ui_layout_efl_part_part(const Eo *obj, Efl_Ui_Layout_Data *sd EINA_UNUSED,
2459 else if (eina_streq(part, "shadow")) 2460 else if (eina_streq(part, "shadow"))
2460 return efl_part(efl_super(obj, MY_CLASS), part); 2461 return efl_part(efl_super(obj, MY_CLASS), part);
2461 2462
2463 if (!efl_layout_group_part_exist_get(wd->resize_obj, part))
2464 {
2465 WRN("No such part '%s' in group '%s'",
2466 part, elm_widget_theme_element_get(obj));
2467 return NULL;
2468 }
2469
2470 type = efl_canvas_layout_part_type_get(efl_part(wd->resize_obj, part));
2462 if (type >= EFL_CANVAS_LAYOUT_PART_TYPE_LAST) 2471 if (type >= EFL_CANVAS_LAYOUT_PART_TYPE_LAST)
2463 { 2472 {
2464 ERR("Invalid type found for part '%s' in group '%s'", part, elm_widget_theme_element_get(obj)); 2473 ERR("Invalid type found for part '%s' in group '%s'",
2474 part, elm_widget_theme_element_get(obj));
2465 return NULL; 2475 return NULL;
2466 } 2476 }
2467 2477
@@ -2475,9 +2485,6 @@ _efl_ui_layout_efl_part_part(const Eo *obj, Efl_Ui_Layout_Data *sd EINA_UNUSED,
2475 return ELM_PART_IMPLEMENT(EFL_UI_LAYOUT_PART_TEXT_CLASS, obj, part); 2485 return ELM_PART_IMPLEMENT(EFL_UI_LAYOUT_PART_TEXT_CLASS, obj, part);
2476 case EFL_CANVAS_LAYOUT_PART_TYPE_SWALLOW: 2486 case EFL_CANVAS_LAYOUT_PART_TYPE_SWALLOW:
2477 return ELM_PART_IMPLEMENT(EFL_UI_LAYOUT_PART_CONTENT_CLASS, obj, part); 2487 return ELM_PART_IMPLEMENT(EFL_UI_LAYOUT_PART_CONTENT_CLASS, obj, part);
2478 case EFL_CANVAS_LAYOUT_PART_TYPE_NONE:
2479 WRN("No such part '%s' in group '%s'", part, elm_widget_theme_element_get(obj));
2480 return NULL;
2481 default: 2488 default:
2482 return ELM_PART_IMPLEMENT(EFL_UI_LAYOUT_PART_CLASS, obj, part); 2489 return ELM_PART_IMPLEMENT(EFL_UI_LAYOUT_PART_CLASS, obj, part);
2483 } 2490 }
diff --git a/src/lib/elementary/efl_ui_progressbar.c b/src/lib/elementary/efl_ui_progressbar.c
index 6c41b669e0..4bd7e87afc 100644
--- a/src/lib/elementary/efl_ui_progressbar.c
+++ b/src/lib/elementary/efl_ui_progressbar.c
@@ -172,6 +172,7 @@ _icon_signal_emit(Evas_Object *obj)
172{ 172{
173 char buf[64]; 173 char buf[64];
174 174
175 if (!elm_widget_resize_object_get(obj)) return;
175 snprintf(buf, sizeof(buf), "elm,state,icon,%s", 176 snprintf(buf, sizeof(buf), "elm,state,icon,%s",
176 elm_layout_content_get(obj, "icon") ? "visible" : "hidden"); 177 elm_layout_content_get(obj, "icon") ? "visible" : "hidden");
177 178
diff --git a/src/lib/elementary/efl_ui_radio.c b/src/lib/elementary/efl_ui_radio.c
index 51d406c0b9..1486cf8b31 100644
--- a/src/lib/elementary/efl_ui_radio.c
+++ b/src/lib/elementary/efl_ui_radio.c
@@ -137,14 +137,16 @@ _key_action_activate(Evas_Object *obj, const char *params EINA_UNUSED)
137static void 137static void
138_icon_signal_emit(Evas_Object *obj) 138_icon_signal_emit(Evas_Object *obj)
139{ 139{
140 ELM_WIDGET_DATA_GET_OR_RETURN(obj, wd);
141 char buf[64]; 140 char buf[64];
141 Eo *edje;
142 142
143 edje = elm_widget_resize_object_get(obj);
144 if (!edje) return;
143 snprintf(buf, sizeof(buf), "elm,state,icon,%s", 145 snprintf(buf, sizeof(buf), "elm,state,icon,%s",
144 elm_layout_content_get(obj, "icon") ? "visible" : "hidden"); 146 elm_layout_content_get(obj, "icon") ? "visible" : "hidden");
145 147
146 elm_layout_signal_emit(obj, buf, "elm"); 148 elm_layout_signal_emit(obj, buf, "elm");
147 edje_object_message_signal_process(wd->resize_obj); 149 edje_object_message_signal_process(edje);
148} 150}
149 151
150EOLIAN static Efl_Ui_Theme_Apply 152EOLIAN static Efl_Ui_Theme_Apply
diff --git a/src/lib/elementary/efl_ui_widget.c b/src/lib/elementary/efl_ui_widget.c
index 4767f9a32f..4b7b2b2d1a 100644
--- a/src/lib/elementary/efl_ui_widget.c
+++ b/src/lib/elementary/efl_ui_widget.c
@@ -311,7 +311,7 @@ _focus_manager_eval(Eo *obj, Elm_Widget_Smart_Data *pd)
311 { 311 {
312 new = parent; 312 new = parent;
313 } 313 }
314 else 314 else if (parent)
315 { 315 {
316 new = efl_ui_focus_user_focus_manager_get(parent); 316 new = efl_ui_focus_user_focus_manager_get(parent);
317 provider = parent; 317 provider = parent;
@@ -358,10 +358,11 @@ _efl_ui_widget_focus_state_apply(Eo *obj, Elm_Widget_Smart_Data *pd EINA_UNUSED,
358 358
359 if (!current_state.manager) registered = EINA_FALSE; 359 if (!current_state.manager) registered = EINA_FALSE;
360 360
361 if (//check if we have changed the manager 361 if ((//check if we have changed the manager
362 (current_state.manager != configured_state->manager) || 362 (current_state.manager != configured_state->manager) ||
363 //check if we are already registered but in a different state 363 //check if we are already registered but in a different state
364 (current_state.logical != configured_state->logical)) 364 (current_state.logical != configured_state->logical))
365 && registered)
365 { 366 {
366 //we need to unregister here 367 //we need to unregister here
367 efl_ui_focus_manager_calc_unregister(current_state.manager, obj); 368 efl_ui_focus_manager_calc_unregister(current_state.manager, obj);
@@ -2439,10 +2440,14 @@ _efl_ui_widget_disabled_set(Eo *obj, Elm_Widget_Smart_Data *sd, Eina_Bool disabl
2439} 2440}
2440 2441
2441EOLIAN static Eina_Bool 2442EOLIAN static Eina_Bool
2442_efl_ui_widget_disabled_get(Eo *obj EINA_UNUSED, Elm_Widget_Smart_Data *sd) 2443_efl_ui_widget_disabled_get(Eo *obj, Elm_Widget_Smart_Data *sd)
2443{ 2444{
2445 Eo *parent;
2446
2444 if (sd->disabled) return EINA_TRUE; 2447 if (sd->disabled) return EINA_TRUE;
2445 return elm_widget_disabled_get(elm_widget_parent_get(obj)); 2448 if ((parent = elm_widget_parent_get(obj)) != NULL)
2449 return elm_widget_disabled_get(parent);
2450 return EINA_FALSE;
2446} 2451}
2447 2452
2448EOLIAN static void 2453EOLIAN static void
@@ -5480,7 +5485,7 @@ _efl_ui_widget_efl_object_provider_find(const Eo *obj, Elm_Widget_Smart_Data *pd
5480 if (pd->provider_lookup) return NULL; 5485 if (pd->provider_lookup) return NULL;
5481 pd->provider_lookup = EINA_TRUE; 5486 pd->provider_lookup = EINA_TRUE;
5482 5487
5483 lookup = efl_provider_find(pd->parent_obj, klass); 5488 if (pd->parent_obj) lookup = efl_provider_find(pd->parent_obj, klass);
5484 if (!lookup) lookup = efl_provider_find(efl_super(obj, MY_CLASS), klass); 5489 if (!lookup) lookup = efl_provider_find(efl_super(obj, MY_CLASS), klass);
5485 5490
5486 pd->provider_lookup = EINA_FALSE; 5491 pd->provider_lookup = EINA_FALSE;
diff --git a/src/lib/elementary/elm_entry.c b/src/lib/elementary/elm_entry.c
index 103de3fa32..b1b7e9d12d 100644
--- a/src/lib/elementary/elm_entry.c
+++ b/src/lib/elementary/elm_entry.c
@@ -1295,7 +1295,8 @@ _elm_entry_focus_update(Eo *obj, Elm_Entry_Data *sd)
1295 edje_object_part_text_select_none(sd->entry_edje, "elm.text"); 1295 edje_object_part_text_select_none(sd->entry_edje, "elm.text");
1296 } 1296 }
1297 } 1297 }
1298 edje_object_signal_emit(sd->scr_edje, "validation,default", "elm"); 1298 if (sd->scr_edje)
1299 edje_object_signal_emit(sd->scr_edje, "validation,default", "elm");
1299 } 1300 }
1300} 1301}
1301 1302
diff --git a/src/lib/elementary/elm_interface_scrollable.c b/src/lib/elementary/elm_interface_scrollable.c
index 63d1405664..ce73fcf8e5 100644
--- a/src/lib/elementary/elm_interface_scrollable.c
+++ b/src/lib/elementary/elm_interface_scrollable.c
@@ -82,7 +82,8 @@ _round(double value, int pos)
82static void 82static void
83_elm_pan_update(Elm_Pan_Smart_Data *psd) 83_elm_pan_update(Elm_Pan_Smart_Data *psd)
84{ 84{
85 evas_object_move(psd->content, psd->x - psd->px, psd->y - psd->py); 85 if (psd->content)
86 evas_object_move(psd->content, psd->x - psd->px, psd->y - psd->py);
86} 87}
87 88
88EOLIAN static void 89EOLIAN static void
diff --git a/src/lib/elementary/elm_widget.h b/src/lib/elementary/elm_widget.h
index a25cf236ac..4bdff24148 100644
--- a/src/lib/elementary/elm_widget.h
+++ b/src/lib/elementary/elm_widget.h
@@ -830,6 +830,13 @@ EAPI extern Eina_Bool _elm_legacy_add;
830#define elm_legacy_add(k, p, ...) ({ _elm_legacy_add = 1; \ 830#define elm_legacy_add(k, p, ...) ({ _elm_legacy_add = 1; \
831 efl_add(k, p, efl_canvas_object_legacy_ctor(efl_added), ##__VA_ARGS__); }) 831 efl_add(k, p, efl_canvas_object_legacy_ctor(efl_added), ##__VA_ARGS__); })
832 832
833static inline Eo *
834elm_widget_resize_object_get(const Eo *obj)
835{
836 Elm_Widget_Smart_Data *wd = efl_data_scope_safe_get(obj, EFL_UI_WIDGET_CLASS);
837 return wd ? wd->resize_obj : NULL;
838}
839
833static inline Eina_Bool 840static inline Eina_Bool
834elm_widget_is_legacy(const Eo *obj) 841elm_widget_is_legacy(const Eo *obj)
835{ 842{
diff --git a/src/lib/elementary/els_cursor.c b/src/lib/elementary/els_cursor.c
index 8d15df1762..fbcde054bf 100644
--- a/src/lib/elementary/els_cursor.c
+++ b/src/lib/elementary/els_cursor.c
@@ -212,6 +212,8 @@ _elm_cursor_set_hot_spots(Elm_Cursor *cur)
212 Evas_Coord cx, cy, cw, ch, x, y, w, h; 212 Evas_Coord cx, cy, cw, ch, x, y, w, h;
213 int prev_hot_x, prev_hot_y; 213 int prev_hot_x, prev_hot_y;
214 214
215 if (!cur->visible) return;
216
215 prev_hot_x = cur->hot_x; 217 prev_hot_x = cur->hot_x;
216 prev_hot_y = cur->hot_y; 218 prev_hot_y = cur->hot_y;
217 219