And horribly break everything. Need to rewrite a bunch of stuff dealing with inheritance.
This commit is contained in:
@ -2,26 +2,17 @@
|
||||
#include "ecdb.h"
|
||||
|
||||
static void
|
||||
_widget_focus_handle(const char *name, Evas_Object *o)
|
||||
_widget_focus_handle(Evas_Object *o)
|
||||
{
|
||||
static char *old_source;
|
||||
Evas_Object *eo;
|
||||
static Evas_Object *old_object;
|
||||
|
||||
// Some widgets aren't named (such as when in combo), so check
|
||||
if (!name)
|
||||
return;
|
||||
if (old_object)
|
||||
{
|
||||
if (old_object != o)
|
||||
edje_object_signal_emit(old_object, "ecdb,focus,out", "ecdb");
|
||||
}
|
||||
|
||||
if ((old_source) && (strcmp(old_source, name)))
|
||||
{
|
||||
eo = evas_object_name_find(ecore_evas_get(em->main_win_ee), old_source);
|
||||
edje_object_signal_emit(eo, "ecdb,focus,out", "ecdb");
|
||||
FREE(old_source);
|
||||
old_source = strdup(name);
|
||||
}
|
||||
else if (!old_source)
|
||||
{
|
||||
old_source = strdup(name);
|
||||
}
|
||||
old_object = o;
|
||||
|
||||
// Send focus to the freshly clicked widget
|
||||
evas_object_focus_set(o, 1);
|
||||
@ -31,20 +22,14 @@ static void
|
||||
_mouse_down_edje(void *data, Evas_Object *o, const char *emission,
|
||||
const char *source)
|
||||
{
|
||||
const char *name;
|
||||
|
||||
name = evas_object_name_get(o);
|
||||
_widget_focus_handle(name, o);
|
||||
_widget_focus_handle(o);
|
||||
}
|
||||
|
||||
static void
|
||||
_mouse_down_evas(void *data, Evas *e __UNUSED__, Evas_Object *eo,
|
||||
void *ev_data __UNUSED__)
|
||||
{
|
||||
const char *name;
|
||||
|
||||
name = evas_object_name_get(eo);
|
||||
_widget_focus_handle(name, eo);
|
||||
_widget_focus_handle(eo);
|
||||
}
|
||||
|
||||
void
|
||||
@ -1138,7 +1123,7 @@ ecdb_config_inwin_add(Evas_Object *parent, const char *name)
|
||||
return NULL;
|
||||
}
|
||||
|
||||
iwd->popup = ecdb_widget_add(parent, NULL);
|
||||
iwd->popup = edje_object_add(evas_object_evas_get(parent));
|
||||
if (!iwd->popup)
|
||||
{
|
||||
printf("ecdb_config_inwin_add: NULL return!\n");
|
||||
|
Reference in New Issue
Block a user