asdfuser pushed a commit to branch master.

commit 3112de826b33ffb847c8df827f172772f2f0ef96
Author: Daniel Willmann <[email protected]>
Date:   Tue Jun 11 11:18:25 2013 +0100

    els_tooltip: Don't expect to have X running if support is compiled in
    
    Refactor the code so common code is not duplicated inside the
    if (transparent) and else blocks
    
    Signed-off-by: Daniel Willmann <[email protected]>
---
 src/lib/els_tooltip.c | 13 ++++++-------
 1 file changed, 6 insertions(+), 7 deletions(-)

diff --git a/src/lib/els_tooltip.c b/src/lib/els_tooltip.c
index 54ab0ff..5df3f2e 100644
--- a/src/lib/els_tooltip.c
+++ b/src/lib/els_tooltip.c
@@ -306,20 +306,19 @@ _elm_tooltip_reconfigure(Elm_Tooltip *tt)
                {
                   evas_object_hide(tt->tt_win);
                   elm_win_alpha_set(tt->tt_win, EINA_TRUE);
-#ifdef HAVE_ELEMENTARY_X
-                  
ecore_x_window_shape_input_rectangle_set(elm_win_xwindow_get(tt->tt_win), 0, 0, 
0, 0);
-#endif
-                  evas_object_show(tt->tt_win);
                }
              else
                {
                   evas_object_hide(tt->tt_win);
                   elm_win_alpha_set(tt->tt_win, EINA_FALSE);
+               }
 #ifdef HAVE_ELEMENTARY_X
-                  
ecore_x_window_shape_input_rectangle_set(elm_win_xwindow_get(tt->tt_win), 0, 0, 
0, 0);
+             Ecore_X_Window win;
+             win = elm_win_xwindow_get(tt->tt_win);
+             if (win)
+               ecore_x_window_shape_input_rectangle_set(win, 0, 0, 0, 0);
 #endif
-                  evas_object_show(tt->tt_win);
-               }
+             evas_object_show(tt->tt_win);
           }
 
         str = edje_object_data_get(tt->tooltip, "pad_x");

-- 

------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:

Build for Windows Store.

http://p.sf.net/sfu/windows-dev2dev

Reply via email to