netstar pushed a commit to branch master.

http://git.enlightenment.org/tools/edi.git/commit/?id=9ea0ba05c39ff0561410d1d82c126f15ad163d66

commit 9ea0ba05c39ff0561410d1d82c126f15ad163d66
Author: Al Poole <nets...@gmail.com>
Date:   Wed Aug 30 23:55:34 2017 +0100

    scm stash: on stash don't refresh all panels, let user decide on focus.
    
    Removed the call to mainview_refresh_all which means after stashing
    of changes the user can decide to reload the file contents when
    focussing the editor.
---
 src/bin/edi_main.c                    | 1 -
 src/bin/mainview/edi_mainview_panel.c | 9 ++++++---
 2 files changed, 6 insertions(+), 4 deletions(-)

diff --git a/src/bin/edi_main.c b/src/bin/edi_main.c
index c83d08c..0223387 100644
--- a/src/bin/edi_main.c
+++ b/src/bin/edi_main.c
@@ -1025,7 +1025,6 @@ static void
 _edi_scm_stash_do_cb(void *data EINA_UNUSED)
 {
    edi_scm_stash();
-   edi_mainview_refresh_all();
 }
 
 static void
diff --git a/src/bin/mainview/edi_mainview_panel.c 
b/src/bin/mainview/edi_mainview_panel.c
index f0e76f5..ae7c089 100644
--- a/src/bin/mainview/edi_mainview_panel.c
+++ b/src/bin/mainview/edi_mainview_panel.c
@@ -271,9 +271,12 @@ _promote(void *data, Evas_Object *obj EINA_UNUSED,
 
    panel = edi_mainview_panel_for_item_get((Edi_Mainview_Item *)data);
 
-   editor = (Edi_Editor *)evas_object_data_get(panel->current->view, "editor");
-   if (editor)
-     elm_object_focus_set(editor->entry, EINA_FALSE);
+   if (panel && panel->current)
+     {
+        editor = (Edi_Editor *)evas_object_data_get(panel->current->view, 
"editor");
+        if (editor)
+          elm_object_focus_set(editor->entry, EINA_FALSE);
+     }
 
    edi_mainview_panel_item_select(panel, (Edi_Mainview_Item *)data);
 }

-- 


Reply via email to