forked from enlightenment/efl
make use of the signal propagatin to child objects for cursors etc. and so
indicate focus with a cursor. SVN revision: 37689
This commit is contained in:
parent
d43b3344e2
commit
1917ae7240
|
@ -1,4 +1,3 @@
|
||||||
|
|
||||||
collections {
|
collections {
|
||||||
|
|
||||||
///////////////////////////////////////////////////////////////////////////////
|
///////////////////////////////////////////////////////////////////////////////
|
||||||
|
@ -2976,9 +2975,23 @@ collections {
|
||||||
image: "cur_glow.png" COMP;
|
image: "cur_glow.png" COMP;
|
||||||
}
|
}
|
||||||
parts {
|
parts {
|
||||||
|
part { name: "clip2";
|
||||||
|
type: RECT;
|
||||||
|
mouse_events: 0;
|
||||||
|
description { state: "default" 0.0;
|
||||||
|
rel1.to: "clip";
|
||||||
|
rel2.to: "clip";
|
||||||
|
visible: 0;
|
||||||
|
}
|
||||||
|
description { state: "focused" 0.0;
|
||||||
|
inherit: "default" 0.0;
|
||||||
|
visible: 1;
|
||||||
|
}
|
||||||
|
}
|
||||||
part { name: "clip";
|
part { name: "clip";
|
||||||
type: RECT;
|
type: RECT;
|
||||||
mouse_events: 0;
|
mouse_events: 0;
|
||||||
|
clip_to: "clip2";
|
||||||
description { state: "default" 0.0;
|
description { state: "default" 0.0;
|
||||||
rel1.offset: -10 0;
|
rel1.offset: -10 0;
|
||||||
rel2.offset: 9 9;
|
rel2.offset: 9 9;
|
||||||
|
@ -3027,6 +3040,7 @@ collections {
|
||||||
part { name: "shine";
|
part { name: "shine";
|
||||||
mouse_events: 0;
|
mouse_events: 0;
|
||||||
clip_to: "clip";
|
clip_to: "clip";
|
||||||
|
clip_to: "clip2";
|
||||||
description { state: "default" 0.0;
|
description { state: "default" 0.0;
|
||||||
rel1.to: "base";
|
rel1.to: "base";
|
||||||
rel2.to: "base";
|
rel2.to: "base";
|
||||||
|
@ -3038,6 +3052,7 @@ collections {
|
||||||
}
|
}
|
||||||
part { name: "glow";
|
part { name: "glow";
|
||||||
mouse_events: 0;
|
mouse_events: 0;
|
||||||
|
clip_to: "clip2";
|
||||||
description { state: "default" 0.0;
|
description { state: "default" 0.0;
|
||||||
rel1.to: "base";
|
rel1.to: "base";
|
||||||
rel1.relative: 0.0 -2.0;
|
rel1.relative: 0.0 -2.0;
|
||||||
|
@ -3084,6 +3099,18 @@ collections {
|
||||||
target: "glow";
|
target: "glow";
|
||||||
after: "show";
|
after: "show";
|
||||||
}
|
}
|
||||||
|
program { name: "focused";
|
||||||
|
signal: "elm,action,focus";
|
||||||
|
source: "elm";
|
||||||
|
action: STATE_SET "focused" 0.0;
|
||||||
|
target: "clip2";
|
||||||
|
}
|
||||||
|
program { name: "unfocused";
|
||||||
|
signal: "elm,action,unfocus";
|
||||||
|
source: "elm";
|
||||||
|
action: STATE_SET "default" 0.0;
|
||||||
|
target: "clip2";
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -281,19 +281,28 @@ extern "C" {
|
||||||
*/
|
*/
|
||||||
|
|
||||||
// FIXME: fixes to do
|
// FIXME: fixes to do
|
||||||
// * current sizing tree inefficient
|
// (bugs)
|
||||||
// * scroller could do with page up/down/left/right buttons and and idea of
|
// * entry click below text doesnt put cursor at end
|
||||||
// a page size
|
// * single line entry on scale change adds newlines
|
||||||
|
// * scale change for hover doesnt seem to do new size alloc nicely
|
||||||
|
// * left/right arrow broken with password mode for entry
|
||||||
|
// * for some reason on oe builds of elementary initial text set doesnt work.
|
||||||
|
//
|
||||||
|
// (incomplete)
|
||||||
|
// * disabled not supported
|
||||||
// * tab widget focusing (not useful for touchscreen tho...)
|
// * tab widget focusing (not useful for touchscreen tho...)
|
||||||
// * entry has no way to show its focused vs other entries
|
// * entry needs to support setting selection to all, or clearing
|
||||||
|
// * bubble should allow style (left/right + top/bottom)
|
||||||
|
// * need to get toplevel
|
||||||
|
// * entry needs to set vkbd properties/hint (as does win)
|
||||||
// * entry selection conflicts with finger scroll
|
// * entry selection conflicts with finger scroll
|
||||||
|
// * on the fly theme changes - test (should work)
|
||||||
|
//
|
||||||
|
// (more widgets/features)
|
||||||
// * toolbar widget (edje + box + button + separators)
|
// * toolbar widget (edje + box + button + separators)
|
||||||
// * listitem widget (simple label + icon)
|
// * listitem widget (simple label + icon)
|
||||||
// * radio widget + group handling
|
// * radio widget + group handling
|
||||||
// * checkbox widget (like toggle)
|
// * checkbox widget (like toggle)
|
||||||
// * entry needs to support setting selection to all, or clearing
|
|
||||||
// * entry click below text doesnt put cursor at end
|
|
||||||
// * bubble should allow style (left/right + top/bottom)
|
|
||||||
// * need separator widget (h/v)
|
// * need separator widget (h/v)
|
||||||
// * need slide-open "panel" that can hold stuff and optionally scroll
|
// * need slide-open "panel" that can hold stuff and optionally scroll
|
||||||
// * need "photoframe" widget (for contact photos?)
|
// * need "photoframe" widget (for contact photos?)
|
||||||
|
@ -301,9 +310,6 @@ extern "C" {
|
||||||
// * need multi-sel (with button + hover + ...)
|
// * need multi-sel (with button + hover + ...)
|
||||||
// * need slider widget
|
// * need slider widget
|
||||||
// * need range selector (select range of values from X to Y over an interval)
|
// * need range selector (select range of values from X to Y over an interval)
|
||||||
// * need a way to filter entry data for entry (eg for phone numbers)
|
|
||||||
// * entry needs to set vkbd properties/hint (as does win)
|
|
||||||
// * need to get toplevel
|
|
||||||
// * need "dialogbutton" widget (bigger button for bottom of wins)
|
// * need "dialogbutton" widget (bigger button for bottom of wins)
|
||||||
// * need dialog window widget
|
// * need dialog window widget
|
||||||
// * need a phone-number widget (hilight country dial prefixes, add flags,
|
// * need a phone-number widget (hilight country dial prefixes, add flags,
|
||||||
|
@ -311,8 +317,12 @@ extern "C" {
|
||||||
// * need imageview widget (for large not iconic images)
|
// * need imageview widget (for large not iconic images)
|
||||||
// * tiled image + zoom widget (tiled map viewer)
|
// * tiled image + zoom widget (tiled map viewer)
|
||||||
// * dialpad widget - need one with a phone dialpad
|
// * dialpad widget - need one with a phone dialpad
|
||||||
// * on the fly theme changes - test (should work)
|
//
|
||||||
// * single line entry on scale change adds newlines
|
// (improvements)
|
||||||
// * scale change for hover doesnt seem to do new size alloc nicely
|
// * widgets should show who is focused (not useful for touchscreen)
|
||||||
// * left/right arrow broken with password mode for entry
|
// * scroller could do with page up/down/left/right buttons and and idea of
|
||||||
|
// a page size
|
||||||
|
// * current sizing tree inefficient
|
||||||
|
// * need a way to filter entry data for entry (eg for phone numbers)
|
||||||
|
//
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -15,7 +15,6 @@ static void _del_pre_hook(Evas_Object *obj);
|
||||||
static void _del_hook(Evas_Object *obj);
|
static void _del_hook(Evas_Object *obj);
|
||||||
static void _sizing_eval(Evas_Object *obj);
|
static void _sizing_eval(Evas_Object *obj);
|
||||||
static void _changed_size_hints(void *data, Evas *e, Evas_Object *obj, void *event_info);
|
static void _changed_size_hints(void *data, Evas *e, Evas_Object *obj, void *event_info);
|
||||||
static void _on_focus_hook(void *data, Evas_Object *obj);
|
|
||||||
static void _parent_del(void *data, Evas *e, Evas_Object *obj, void *event_info);
|
static void _parent_del(void *data, Evas *e, Evas_Object *obj, void *event_info);
|
||||||
|
|
||||||
static void
|
static void
|
||||||
|
|
|
@ -15,7 +15,6 @@ static void _del_pre_hook(Evas_Object *obj);
|
||||||
static void _del_hook(Evas_Object *obj);
|
static void _del_hook(Evas_Object *obj);
|
||||||
static void _sizing_eval(Evas_Object *obj);
|
static void _sizing_eval(Evas_Object *obj);
|
||||||
static void _changed_size_hints(void *data, Evas *e, Evas_Object *obj, void *event_info);
|
static void _changed_size_hints(void *data, Evas *e, Evas_Object *obj, void *event_info);
|
||||||
static void _on_focus_hook(void *data, Evas_Object *obj);
|
|
||||||
static void _parent_del(void *data, Evas *e, Evas_Object *obj, void *event_info);
|
static void _parent_del(void *data, Evas *e, Evas_Object *obj, void *event_info);
|
||||||
|
|
||||||
static void
|
static void
|
||||||
|
|
|
@ -98,7 +98,16 @@ static void
|
||||||
_on_focus_hook(void *data, Evas_Object *obj)
|
_on_focus_hook(void *data, Evas_Object *obj)
|
||||||
{
|
{
|
||||||
Widget_Data *wd = elm_widget_data_get(obj);
|
Widget_Data *wd = elm_widget_data_get(obj);
|
||||||
evas_object_focus_set(wd->ent, 1);
|
if (elm_widget_focus_get(obj))
|
||||||
|
{
|
||||||
|
evas_object_focus_set(wd->ent, 1);
|
||||||
|
edje_object_signal_emit(wd->ent, "elm,action,focus", "elm");
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
edje_object_signal_emit(wd->ent, "elm,action,unfocus", "elm");
|
||||||
|
evas_object_focus_set(wd->ent, 0);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
|
|
|
@ -443,6 +443,7 @@ elm_widget_focused_object_clear(Evas_Object *obj)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (sd->focus_func) sd->focus_func(obj);
|
if (sd->focus_func) sd->focus_func(obj);
|
||||||
|
if (sd->on_focus_func) sd->on_focus_func(sd->on_focus_data, obj);
|
||||||
}
|
}
|
||||||
|
|
||||||
EAPI void
|
EAPI void
|
||||||
|
|
Loading…
Reference in New Issue