[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[core/elementary] master 02/03: elm_flip.c: set focus to the flip's content object when flip go to is called.



seoz pushed a commit to branch master.

commit 43ce72a8bc870d01f31c973ce4cd8e3f19e208a6
Author: Daniel Juyung Seo <seojuyung2@gmail.com>
Date:   Mon Sep 16 00:14:50 2013 +0900

    elm_flip.c: set focus to the flip's content object when flip go to is called.
---
 ChangeLog          | 5 +++++
 NEWS               | 1 +
 src/lib/elm_flip.c | 7 +++++++
 3 files changed, 13 insertions(+)

diff --git a/ChangeLog b/ChangeLog
index e4d9780..dde64e4 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1620,3 +1620,8 @@
 2013-09-14  Daniel Juyung Seo (SeoZ)
 
         * spinner : fixed arrow key focus movement bug.
+
+2013-09-15  Daniel Juyung Seo (SeoZ)
+
+        * flip : set the focus to it's content object when flip go to is called
+        while flip is focused.
diff --git a/NEWS b/NEWS
index ffd4a87..73be6e9 100644
--- a/NEWS
+++ b/NEWS
@@ -136,6 +136,7 @@ Improvements:
    * Popup: Support "language,changed" smart callback.
    * Add hide effect for notify.
    * Widget: Improve performance in applying widget theme. It prevents applying themes more strictly if it tries to apply same theme. This increases the performance hugely in case that user applies a specific theme to the window object.
+   * Flip now sets the focus to it's content object when flip go to is called while flip is focused.
 
 Fixes:
    * Now elm_datetime_field_limit_set() can set year limits wihtout problems.
diff --git a/src/lib/elm_flip.c b/src/lib/elm_flip.c
index eefe4a7..a6a6623 100644
--- a/src/lib/elm_flip.c
+++ b/src/lib/elm_flip.c
@@ -1979,6 +1979,13 @@ _elm_flip_go_to(Evas_Object *obj,
    _configure(obj);
    // FIXME: end hack
    evas_object_smart_callback_call(obj, SIG_ANIMATE_BEGIN, NULL);
+
+   // set focus to the content object when flip go to is called
+   if (elm_object_focus_get(obj))
+     {
+        if (front) elm_object_focus_set(sd->front.content, EINA_TRUE);
+        else elm_object_focus_set(sd->back.content, EINA_TRUE);
+     }
 }
 
 EAPI void

--