kuuko pushed a commit to branch master.

commit 171e462b50c281277a6ff21394b91839196762c6
Author: Kai Huuhko <[email protected]>
Date:   Sat Apr 6 16:27:34 2013 +0300

    Elm: Fix segfault in tooltip content cb
---
 TODO                                | 4 +---
 efl/elementary/tooltips.pxi         | 6 +++---
 examples/elementary/test_tooltip.py | 1 +
 3 files changed, 5 insertions(+), 6 deletions(-)

diff --git a/TODO b/TODO
index e01044f..b75fffc 100644
--- a/TODO
+++ b/TODO
@@ -3,9 +3,6 @@ BUGS
 ====
 
 * Evas: smart object doesn't work
-* Elm: remove tooltips.pxi
-* _fruni() and _cfruni() are buggy when used with py3 (because they return the
-  internal buffer of the 'string' object declared inside the function)
 
 
 TODO
@@ -29,6 +26,7 @@ TODO
 * Review the internal functions and name them consistently
 * Add more documentation for the use of callbacks
 * Document our use of exceptions
+* evas.TextGrid
 
 
 IMAGES
diff --git a/efl/elementary/tooltips.pxi b/efl/elementary/tooltips.pxi
index 52b7ccf..5d4cc23 100644
--- a/efl/elementary/tooltips.pxi
+++ b/efl/elementary/tooltips.pxi
@@ -16,12 +16,12 @@
 # along with python-elementary.  If not, see <http://www.gnu.org/licenses/>.
 #
 
-from efl.evas cimport evas_object_data_get
+from efl.eo cimport object_from_instance
 
 cdef Evas_Object *_tooltip_content_create(void *data, Evas_Object *o, 
Evas_Object *t) with gil:
     cdef Object ret, obj, tooltip
 
-    obj = <Object>evas_object_data_get(o, "python-evas")
+    obj = object_from_instance(o)
     tooltip = object_from_instance(t)
     (func, args, kargs) = <object>data
     ret = func(obj, tooltip, *args, **kargs)
@@ -35,7 +35,7 @@ cdef void _tooltip_data_del_cb(void *data, Evas_Object *o, 
void *event_info) wit
 cdef Evas_Object *_tooltip_item_content_create(void *data, Evas_Object *o, 
Evas_Object *t, void *it) with gil:
    cdef Object ret, obj, tooltip
 
-   obj = <Object>evas_object_data_get(o, "python-evas")
+   obj = object_from_instance(o)
    tooltip = object_from_instance(t)
    (func, item, args, kargs) = <object>data
    ret = func(obj, item, *args, **kargs)
diff --git a/examples/elementary/test_tooltip.py 
b/examples/elementary/test_tooltip.py
index b98dec9..c7e07a5 100644
--- a/examples/elementary/test_tooltip.py
+++ b/examples/elementary/test_tooltip.py
@@ -11,6 +11,7 @@ from efl.elementary.button import Button
 from efl.elementary.entry import Entry
 from efl.elementary.list import List
 from efl.elementary.toolbar import Toolbar
+from efl.elementary.icon import Icon
 
 
 def _tt_icon(obj, *args, **kargs):

-- 

------------------------------------------------------------------------------
Minimize network downtime and maximize team effectiveness.
Reduce network management and security costs.Learn how to hire 
the most talented Cisco Certified professionals. Visit the 
Employer Resources Portal
http://www.cisco.com/web/learning/employer_resources/index.html

Reply via email to