yakov pushed a commit to branch master.

http://git.enlightenment.org/tools/erigo.git/commit/?id=6d522fc87983d9b4ff0c6576c8c03e2584b1e146

commit 6d522fc87983d9b4ff0c6576c8c03e2584b1e146
Author: Yakov Goldberg <yako...@samsung.com>
Date:   Sun Apr 26 15:36:24 2015 +0300

    Refactor settings window
---
 src/bin/egui_gui/egui_layout.json | 16 ++++++++++++++--
 src/bin/egui_gui/settings_view.c  |  5 ++---
 2 files changed, 16 insertions(+), 5 deletions(-)

diff --git a/src/bin/egui_gui/egui_layout.json 
b/src/bin/egui_gui/egui_layout.json
index 71cff4d..29f3c29 100644
--- a/src/bin/egui_gui/egui_layout.json
+++ b/src/bin/egui_gui/egui_layout.json
@@ -35,7 +35,8 @@
       "_contentview_down_btn_clicked":"_contentview_down_btn_clicked",
       "_contentview_del_btn_clicked":"_contentview_del_btn_clicked",
       "_itemview_up_btn_clicked":"_itemview_up_btn_clicked",
-      "_itemview_down_btn_clicked":"_itemview_down_btn_clicked"
+      "_itemview_down_btn_clicked":"_itemview_down_btn_clicked",
+      "_settingsview_toolbar_clicked":"_settingsview_toolbar_clicked"
     },
     "Edjes":
     {
@@ -687,6 +688,17 @@
         "Evas.Object.size_hint_weight":[1, 0],
         "Evas.Object.size_hint_align":[-1, 0],
         "Efl.Gfx.Base.visible":[true]
+      },
+      "Items":
+      {
+        "settings_toolbar_it0":
+        {
+          "type":"regular",
+          "public":true,
+          "icon":"preferences-system",
+          "label":"Project Settings",
+          "callback":"_settingsview_toolbar_clicked"
+        }
       }
     },
     "settings_table":
@@ -3813,4 +3825,4 @@
       }
     }
   }
- }
+ }
\ No newline at end of file
diff --git a/src/bin/egui_gui/settings_view.c b/src/bin/egui_gui/settings_view.c
index 9806f0f..b8a08c1 100644
--- a/src/bin/egui_gui/settings_view.c
+++ b/src/bin/egui_gui/settings_view.c
@@ -31,7 +31,7 @@ _settings_apply_button_enable(void *data EINA_UNUSED, Eo *obj 
EINA_UNUSED, const
 }
 
 /* Toolbar item clicked callback. */
-static void
+void
 _settingsview_toolbar_clicked(void *data, Evas_Object *obj EINA_UNUSED, void 
*event_info EINA_UNUSED)
 {
    SettingsView_Type type = (int) (intptr_t) data;
@@ -100,8 +100,7 @@ _settings_win_request_delete(void *data EINA_UNUSED, Eo 
*obj EINA_UNUSED, const
 void
 settings_win_post_configure()
 {
-   eo_do(g_settings_win->settings_toolbar, 
elm_obj_toolbar_item_append("preferences-system", "Project",
-                                                    
_settingsview_toolbar_clicked, (void *) (intptr_t) SETTINGSVIEW_MAIN));
+   elm_object_item_data_set(g_settings_win->settings_toolbar_it0, (void *) 
(intptr_t) SETTINGSVIEW_MAIN);
 }
 
 static Eina_Bool

-- 


Reply via email to