if (sd->delete_me) return;
+ if (sd->scrollable)
+ {
+ int w, h;
+ evas_object_geometry_get(obj, NULL, NULL, &w, &h);
+
+ if (sd->hidden) _drawer_close(obj, w, h, EINA_FALSE);
+ else _drawer_open(obj, w, h, EINA_FALSE);
+ }
+
evas_object_smart_calculate(sd->bx);
edje_object_size_min_calc(wd->resize_obj, &mw, &mh);
evas_object_size_hint_min_set(obj, mw, mh);
eo_do(obj, elm_interface_scrollable_content_pos_get(&pos, NULL));
horizontal = EINA_TRUE;
- if (!elm_widget_mirrored_get(obj))
+ if (elm_widget_mirrored_get(obj))
{
if (pos == 0) open = EINA_TRUE;
else if (pos == panel_size) open = EINA_FALSE;
evas_object_move(sd->hit_rect, x, y);
}
-static Eina_Bool
-_elm_panel_anim_cb(void *data)
-{
- Evas_Object *obj = data;
- ELM_PANEL_DATA_GET(obj, sd);
- int w, h;
-
- evas_object_geometry_get(obj, NULL, NULL, &w, &h);
-
- if (sd->hidden) _drawer_close(obj, w, h, EINA_FALSE);
- else _drawer_open(obj, w, h, EINA_FALSE);
-
- return ECORE_CALLBACK_CANCEL;
-}
-
EOLIAN static void
_elm_panel_evas_object_smart_resize(Eo *obj, Elm_Panel_Data *sd, Evas_Coord w, Evas_Coord h)
{
break;
}
- ecore_animator_add(_elm_panel_anim_cb, obj);
+ elm_layout_sizing_eval(obj);
}
EOLIAN static void
if (sd->orient == orient) return;
sd->orient = orient;
- if (sd->scrollable) _scrollable_layout_theme_set(obj, sd);
- else _orient_set_do(obj);
+ if (sd->scrollable)
+ {
+ _scrollable_layout_theme_set(obj, sd);
+
+ if (!sd->freeze)
+ {
+ switch (sd->orient)
+ {
+ case ELM_PANEL_ORIENT_TOP:
+ case ELM_PANEL_ORIENT_BOTTOM:
+ eo_do(obj, elm_interface_scrollable_movement_block_set
+ (ELM_SCROLLER_MOVEMENT_BLOCK_VERTICAL));
+ break;
+ case ELM_PANEL_ORIENT_LEFT:
+ case ELM_PANEL_ORIENT_RIGHT:
+ eo_do(obj, elm_interface_scrollable_movement_block_set
+ (ELM_SCROLLER_MOVEMENT_BLOCK_HORIZONTAL));
+ break;
+ }
+
+ sd->freeze = EINA_TRUE;
+ elm_layout_signal_emit(sd->scr_ly, "elm,state,content,hidden", "elm");
+ }
+
+ elm_panel_scrollable_content_size_set(obj, sd->content_size_ratio);
+ }
+ else
+ _orient_set_do(obj);
elm_layout_sizing_eval(obj);
}
break;
}
- ecore_animator_add(_elm_panel_anim_cb, obj);
+ elm_layout_sizing_eval(obj);
}
EOLIAN static Eina_Bool