summaryrefslogtreecommitdiff
path: root/src/lib/elementary/efl_ui_panel.c
diff options
context:
space:
mode:
authorMike Blumenkrantz <zmike@samsung.com>2019-08-05 09:13:05 -0400
committerMarcel Hollerbach <mail@marcel-hollerbach.de>2019-08-07 14:48:39 +0200
commitf34f92bb29724c8e2c796c9787c2572d29d6619d (patch)
tree843f9064409709d0491c15ade89069626f3a95e6 /src/lib/elementary/efl_ui_panel.c
parentc5030346d4b44690c652afa4e6eb91cfa8e552ea (diff)
efl_ui: use unified size hints api and be explicit about which hint is changed
unified widgets should use unified api internally and also be more explicit about which min size hint (restricted or user) is being set in order to improve readability of code when unified widgets also implement legacy wrappers, legacy api should be used for the legacy objects no functional changes Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de> Differential Revision: https://phab.enlightenment.org/D9495
Diffstat (limited to 'src/lib/elementary/efl_ui_panel.c')
-rw-r--r--src/lib/elementary/efl_ui_panel.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/lib/elementary/efl_ui_panel.c b/src/lib/elementary/efl_ui_panel.c
index cad4a8f..1f6f21d 100644
--- a/src/lib/elementary/efl_ui_panel.c
+++ b/src/lib/elementary/efl_ui_panel.c
@@ -228,7 +228,7 @@ _efl_ui_panel_efl_ui_widget_theme_apply(Eo *obj, Efl_Ui_Panel_Data *sd)
228 228
229 evas_object_hide(sd->event); 229 evas_object_hide(sd->event);
230 elm_coords_finger_size_adjust(1, &minw, 1, &minh); 230 elm_coords_finger_size_adjust(1, &minw, 1, &minh);
231 evas_object_size_hint_min_set(sd->event, minw, minh); 231 efl_gfx_hint_size_min_set(sd->event, EINA_SIZE2D(minw, minh));
232 232
233 if (edje_object_part_exists(wd->resize_obj, "efl.swallow.event")) 233 if (edje_object_part_exists(wd->resize_obj, "efl.swallow.event"))
234 efl_content_set(efl_part(efl_super(obj, MY_CLASS), "efl.swallow.event"), sd->event); 234 efl_content_set(efl_part(efl_super(obj, MY_CLASS), "efl.swallow.event"), sd->event);
@@ -770,15 +770,15 @@ _scrollable_layout_resize(Eo *obj, Efl_Ui_Panel_Data *sd, Evas_Coord w, Evas_Coo
770 case EFL_UI_PANEL_ORIENT_BOTTOM: 770 case EFL_UI_PANEL_ORIENT_BOTTOM:
771 // vertical 771 // vertical
772 evas_object_resize(sd->scr_ly, w, (1 + sd->content_size_ratio) * h); 772 evas_object_resize(sd->scr_ly, w, (1 + sd->content_size_ratio) * h);
773 evas_object_size_hint_min_set(sd->scr_panel, w, (sd->content_size_ratio * h)); 773 efl_gfx_hint_size_min_set(sd->scr_panel, EINA_SIZE2D(w, (sd->content_size_ratio * h)));
774 evas_object_size_hint_min_set(sd->scr_event, w, h); 774 efl_gfx_hint_size_min_set(sd->scr_event, EINA_SIZE2D(w, h));
775 break; 775 break;
776 case EFL_UI_PANEL_ORIENT_LEFT: 776 case EFL_UI_PANEL_ORIENT_LEFT:
777 case EFL_UI_PANEL_ORIENT_RIGHT: 777 case EFL_UI_PANEL_ORIENT_RIGHT:
778 // horizontal 778 // horizontal
779 evas_object_resize(sd->scr_ly, (1 + sd->content_size_ratio) * w, h); 779 evas_object_resize(sd->scr_ly, (1 + sd->content_size_ratio) * w, h);
780 evas_object_size_hint_min_set(sd->scr_panel, (sd->content_size_ratio * w), h); 780 efl_gfx_hint_size_min_set(sd->scr_panel, EINA_SIZE2D((sd->content_size_ratio * w), h));
781 evas_object_size_hint_min_set(sd->scr_event, w, h); 781 efl_gfx_hint_size_min_set(sd->scr_event, EINA_SIZE2D(w, h));
782 break; 782 break;
783 } 783 }
784 efl_canvas_group_change(obj); 784 efl_canvas_group_change(obj);
@@ -868,7 +868,7 @@ _efl_ui_panel_efl_object_constructor(Eo *obj, Efl_Ui_Panel_Data *_pd)
868 Evas_Coord minw = 0, minh = 0; 868 Evas_Coord minw = 0, minh = 0;
869 869
870 elm_coords_finger_size_adjust(1, &minw, 1, &minh); 870 elm_coords_finger_size_adjust(1, &minw, 1, &minh);
871 evas_object_size_hint_min_set(_pd->event, minw, minh); 871 efl_gfx_hint_size_min_set(_pd->event, EINA_SIZE2D(minw, minh));
872 efl_content_set(efl_part(efl_super(obj, MY_CLASS), "efl.swallow.event"), _pd->event); 872 efl_content_set(efl_part(efl_super(obj, MY_CLASS), "efl.swallow.event"), _pd->event);
873 } 873 }
874 } 874 }