forked from enlightenment/efl
Revert "scroller : fix mirrored contents_pos_set call"
Summary:
This reverts commit de313d6296
.
Because x-coordination mirroring is called properly from wanted_regison_set.
There was a problem in scroller init process.
Before edje_obj was initialize in elm_interface_scrollable_objects_set, mirrored_set was being called.
So Move mirrored_set after elm_interface_scrollable_objects_set
it can fix this issue(https://phab.enlightenment.org/D4944)
Reviewers: raster, woohyun, SanghyeonLee, akanad, eagleeye, cedric, singh.amitesh, eunue
Subscribers: jpeg, cedric
Differential Revision: https://phab.enlightenment.org/D4945
This commit is contained in:
parent
802b547310
commit
d1e5bd2727
|
@ -1675,22 +1675,22 @@ _elm_interface_scrollable_mirrored_set(Eo *obj EINA_UNUSED, Elm_Scrollable_Smart
|
|||
{
|
||||
Evas_Coord wx;
|
||||
|
||||
if (!sid->edje_obj || !sid->pan_obj) return;
|
||||
if (!sid->edje_obj) return;
|
||||
|
||||
mirrored = !!mirrored;
|
||||
|
||||
if (sid->is_mirrored == mirrored)
|
||||
return;
|
||||
|
||||
sid->is_mirrored = mirrored;
|
||||
edje_object_mirrored_set(sid->edje_obj, mirrored);
|
||||
|
||||
if (sid->is_mirrored)
|
||||
wx = _elm_scroll_x_mirrored_get(sid->obj, sid->wx);
|
||||
else
|
||||
wx = sid->wx;
|
||||
|
||||
elm_interface_scrollable_content_pos_set(sid->obj, wx, sid->wy, EINA_FALSE);
|
||||
|
||||
if (sid->is_mirrored == mirrored)
|
||||
return;
|
||||
|
||||
sid->is_mirrored = mirrored;
|
||||
edje_object_mirrored_set(sid->edje_obj, mirrored);
|
||||
}
|
||||
|
||||
/* returns TRUE when we need to move the scroller, FALSE otherwise.
|
||||
|
|
|
@ -329,13 +329,6 @@ _elm_scroller_elm_widget_activate(Eo *obj, Elm_Scroller_Data *_pd EINA_UNUSED, E
|
|||
return EINA_TRUE;
|
||||
}
|
||||
|
||||
static void
|
||||
_mirrored_set(Evas_Object *obj,
|
||||
Eina_Bool mirrored)
|
||||
{
|
||||
elm_interface_scrollable_mirrored_set(obj, mirrored);
|
||||
}
|
||||
|
||||
EOLIAN static void
|
||||
_elm_scroller_elm_layout_sizing_eval(Eo *obj, Elm_Scroller_Data *sd)
|
||||
{
|
||||
|
@ -401,8 +394,13 @@ _elm_scroller_elm_layout_sizing_eval(Eo *obj, Elm_Scroller_Data *sd)
|
|||
if ((maxh > 0) && (h > maxh)) h = maxh;
|
||||
|
||||
evas_object_size_hint_min_set(obj, w, h);
|
||||
}
|
||||
|
||||
_mirrored_set(obj, elm_widget_mirrored_get(obj));
|
||||
static void
|
||||
_mirrored_set(Evas_Object *obj,
|
||||
Eina_Bool mirrored)
|
||||
{
|
||||
elm_interface_scrollable_mirrored_set(obj, mirrored);
|
||||
}
|
||||
|
||||
EOLIAN static Elm_Theme_Apply
|
||||
|
@ -412,6 +410,8 @@ _elm_scroller_elm_widget_theme_apply(Eo *obj, Elm_Scroller_Data *sd EINA_UNUSED)
|
|||
int_ret = elm_obj_widget_theme_apply(efl_super(obj, MY_CLASS));
|
||||
if (!int_ret) return ELM_THEME_APPLY_FAILED;
|
||||
|
||||
_mirrored_set(obj, elm_widget_mirrored_get(obj));
|
||||
|
||||
elm_layout_sizing_eval(obj);
|
||||
|
||||
return int_ret;
|
||||
|
|
Loading…
Reference in New Issue