elm: Fix invalid uses of Efl.Orientation

I think this closes the orientation vs. direction problem.
RTL vs. AnyRTL is not fully handled yet but this becomes a
widget-per-widget issue (eg. should a box in a RTL locale be mirrored if
set to horizontal?).

Fixes T5870
This commit is contained in:
Jean-Philippe Andre 2017-09-19 18:51:58 +09:00
parent 40e23ca459
commit 706cf9c488
3 changed files with 7 additions and 7 deletions

View File

@ -9,7 +9,7 @@ bx = new efl.Efl.Ui.Box(win);
bx.setHintWeight(1.0, 1.0);
win.setContent(bx);
bx.setVisible(true);
bx.setOrientation(efl.Efl.Orient.VERTICAL);
bx.setDirection(efl.Efl.Dir.VERTICAL);
ck = new efl.Elm.Clock(win);
bx.packEnd(ck);

View File

@ -255,12 +255,12 @@ _efl_ui_layout_part_box_efl_pack_linear_pack_index_get(Eo *obj EINA_UNUSED, Efl_
ELM_PART_RETURN_VAL(efl_pack_index_get(pack, subobj));
}
EOLIAN static Efl_Orient
_efl_ui_layout_part_box_efl_orientation_orientation_get(Eo *obj EINA_UNUSED, Efl_Ui_Layout_Box_Data *pd)
EOLIAN static Efl_Ui_Dir
_efl_ui_layout_part_box_efl_ui_direction_direction_get(Eo *obj EINA_UNUSED, Efl_Ui_Layout_Box_Data *pd)
{
ELM_WIDGET_DATA_GET_OR_RETURN(obj, wd, EFL_ORIENT_NONE);
ELM_WIDGET_DATA_GET_OR_RETURN(obj, wd, EFL_UI_DIR_DEFAULT);
ELM_PART_RETURN_VAL(efl_orientation_get(efl_part(wd->resize_obj, pd->part)));
ELM_PART_RETURN_VAL(efl_ui_direction_get(efl_part(wd->resize_obj, pd->part)));
}

View File

@ -1,5 +1,5 @@
class Efl.Ui.Layout.Part.Box (Efl.Object, Efl.Pack.Linear,
Efl.Orientation)
Efl.Ui.Direction)
{
[[Represents a Box created as part of a layout.
@ -22,7 +22,7 @@ class Efl.Ui.Layout.Part.Box (Efl.Object, Efl.Pack.Linear,
Efl.Container.content_iterate;
Efl.Container.content_count;
Efl.Container.content_remove;
Efl.Orientation.orientation { get; }
Efl.Ui.Direction.direction { get; }
Efl.Pack.pack_clear;
Efl.Pack.unpack_all;
Efl.Pack.unpack;