}
static void
+_selectall(void *data, Evas_Object *obj __UNUSED__, void *event_info __UNUSED__)
+{
+ Widget_Data *wd = elm_widget_data_get(data);
+ if (!wd) return;
+ wd->selmode = EINA_TRUE;
+ if (!wd->password)
+ edje_object_part_text_select_allow_set(wd->ent, "elm.text", EINA_TRUE);
+ edje_object_signal_emit(wd->ent, "elm,state,select,on", "elm");
+ edje_object_part_text_select_all(wd->ent, "elm.text");
+ //elm_widget_scroll_hold_push(data);
+ elm_object_scroll_freeze_pop(data);
+}
+
+static void
_select(void *data, Evas_Object *obj __UNUSED__, void *event_info __UNUSED__)
{
Widget_Data *wd = elm_widget_data_get(data);
if (!wd->password)
edje_object_part_text_select_allow_set(wd->ent, "elm.text", EINA_TRUE);
edje_object_signal_emit(wd->ent, "elm,state,select,on", "elm");
+ elm_object_scroll_freeze_pop(data);
//elm_widget_scroll_hold_push(data);
}
ext_mod->cut = _cut;
ext_mod->paste = _paste;
ext_mod->select = _select;
- ext_mod->selectall = NULL; /* to be implemented*/
+ ext_mod->selectall = _selectall;
ext_mod->ent = wd->ent;
ext_mod->items = wd->items;
ext_mod->longpress_timer = wd->longpress_timer;
}
static void
+_select_all(void *data, Evas_Object *obj, void *event_info)
+{
+ ext_mod->selectall(data,obj,event_info);
+ evas_object_hide(obj);
+}
+
+static void
_select(void *data, Evas_Object *obj, void *event_info)
{
ext_mod->select(data,obj,event_info);
if (!ext_mod->selmode)
{
if (!ext_mod->password)
+ {
elm_ctxpopup_item_add(ext_mod->popup, NULL, "Select",_select, obj );
+ elm_ctxpopup_item_add(ext_mod->popup, NULL, "Select All",_select_all, obj );
+ }
if (1) // need way to detect if someone has a selection
{
if (ext_mod->editable)
{
_cancel(obj,ext_mod->popup,NULL);
elm_ctxpopup_item_add(ext_mod->popup, NULL, "Select",_select, obj );
+ elm_ctxpopup_item_add(ext_mod->popup, NULL, "Select All",_select_all, obj );
if (1) // need way to detect if someone has a selection
{
if (ext_mod->editable)