diff options
-rw-r--r-- | src/bin/egui_gui/props_helper.c | 16 | ||||
-rw-r--r-- | src/bin/egui_gui/propview.c | 6 | ||||
-rw-r--r-- | src/lib/database.h | 1 |
3 files changed, 23 insertions, 0 deletions
diff --git a/src/bin/egui_gui/props_helper.c b/src/bin/egui_gui/props_helper.c index eae505f..572a807 100644 --- a/src/bin/egui_gui/props_helper.c +++ b/src/bin/egui_gui/props_helper.c | |||
@@ -146,6 +146,22 @@ props_hoversel_objects_add(Eo *box, Eo *hover_parent, const char *default_val, c | |||
146 | /*check, if wdg is content of w on any level. */ | 146 | /*check, if wdg is content of w on any level. */ |
147 | (wdg_is_content_of(w, wdg)))) | 147 | (wdg_is_content_of(w, wdg)))) |
148 | continue; | 148 | continue; |
149 | |||
150 | /* if widget already has this resize object, don't add it to hoversel*/ | ||
151 | Eina_List *itr2; | ||
152 | Gui_Widget_Property *prop; | ||
153 | Eina_Bool dont_add_this_widget = EINA_FALSE; | ||
154 | EINA_LIST_FOREACH(wdg_prop_list_get(wdg), itr2, prop) | ||
155 | { | ||
156 | if (!strcmp(prop_name_get(prop), RESIZE_OBJECT_ADD)) | ||
157 | { | ||
158 | Gui_Value *val = prop_value_nth_get(prop, 0); | ||
159 | if (DEP_ID_GET(val) == wdg_dep_id_get(w)) | ||
160 | dont_add_this_widget = EINA_TRUE; | ||
161 | } | ||
162 | } | ||
163 | if (dont_add_this_widget) continue; | ||
164 | |||
149 | elm_hoversel_item_add(hoversel, wdg_name_get(w), NULL, ELM_ICON_NONE, NULL, NULL); | 165 | elm_hoversel_item_add(hoversel, wdg_name_get(w), NULL, ELM_ICON_NONE, NULL, NULL); |
150 | } | 166 | } |
151 | } | 167 | } |
diff --git a/src/bin/egui_gui/propview.c b/src/bin/egui_gui/propview.c index 9b53d6c..401c160 100644 --- a/src/bin/egui_gui/propview.c +++ b/src/bin/egui_gui/propview.c | |||
@@ -133,6 +133,12 @@ _property_item_content_get(It_Data *it_data, Eo *box) | |||
133 | eo_do(obj, eo_key_data_set(_STR_EDITOR, pfd, free)); | 133 | eo_do(obj, eo_key_data_set(_STR_EDITOR, pfd, free)); |
134 | evas_object_event_callback_add(obj, EVAS_CALLBACK_DEL, _pfd_del, NULL); | 134 | evas_object_event_callback_add(obj, EVAS_CALLBACK_DEL, _pfd_del, NULL); |
135 | 135 | ||
136 | /* forbid changing of value in "resize_object_add"*/ | ||
137 | if (prop && value && (!strcmp(prop_name_get(prop), RESIZE_OBJECT_ADD))) | ||
138 | { | ||
139 | eo_do(obj, elm_obj_widget_disabled_set(EINA_TRUE)); | ||
140 | } | ||
141 | |||
136 | if (eo_isa(obj, ELM_OBJ_HOVERSEL_CLASS)) | 142 | if (eo_isa(obj, ELM_OBJ_HOVERSEL_CLASS)) |
137 | { | 143 | { |
138 | evas_object_smart_callback_add(obj, "selected", _view_cbs->property_update_cb_func, NULL); | 144 | evas_object_smart_callback_add(obj, "selected", _view_cbs->property_update_cb_func, NULL); |
diff --git a/src/lib/database.h b/src/lib/database.h index 7c79ee5..330550b 100644 --- a/src/lib/database.h +++ b/src/lib/database.h | |||
@@ -98,6 +98,7 @@ typedef struct _Container_Desc Container_Desc; | |||
98 | #define SIZE_HINT_WEIGHT_SET "size_hint_weight" | 98 | #define SIZE_HINT_WEIGHT_SET "size_hint_weight" |
99 | #define SIZE_HINT_ALIGN_SET "size_hint_align" | 99 | #define SIZE_HINT_ALIGN_SET "size_hint_align" |
100 | #define POSITION_SET "position" | 100 | #define POSITION_SET "position" |
101 | #define RESIZE_OBJECT_ADD "resize_object_add" | ||
101 | #define ELM_OBJ_WIN_CONSTRUCTOR "elm_obj_win_constructor" | 102 | #define ELM_OBJ_WIN_CONSTRUCTOR "elm_obj_win_constructor" |
102 | 103 | ||
103 | Eina_Bool | 104 | Eina_Bool |