summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorzmike <michael.blumenkrantz@gmail.com>2014-04-22 09:29:49 -0400
committerMike Blumenkrantz <zmike@samsung.com>2014-04-22 09:33:43 -0400
commit378f7eedfa0cd09cde5cb7716b7778e7770c6951 (patch)
tree52d84be7cd5f183ff722ab418697aa77679b64cb
parent634c4b7ec0af18e52603fa47bec38096969d489c (diff)
tooltips position more accurately in X in xinerama
elm_win_screen_size_get() is broken for this use case since the tooltip actually needs the full xinerama screen geometry, which is the geometry of the root window and NOT the current screen @fix
-rw-r--r--src/lib/els_tooltip.c11
1 files changed, 10 insertions, 1 deletions
diff --git a/src/lib/els_tooltip.c b/src/lib/els_tooltip.c
index 4ea4a4863..aeec007e3 100644
--- a/src/lib/els_tooltip.c
+++ b/src/lib/els_tooltip.c
@@ -393,7 +393,16 @@ _elm_tooltip_reconfigure(Elm_Tooltip *tt)
393 TTDBG("TTSIZE: tw=%d,th=%d,ominw=%d,ominh=%d\n", tw, th, ominw, ominh); 393 TTDBG("TTSIZE: tw=%d,th=%d,ominw=%d,ominh=%d\n", tw, th, ominw, ominh);
394 394
395 if (tt->tt_win) 395 if (tt->tt_win)
396 elm_win_screen_size_get(elm_widget_top_get(tt->owner), NULL, NULL, &cw, &ch); 396 {
397#ifdef HAVE_ELEMENTARY_X
398 Evas_Object *win = elm_widget_top_get(tt->owner);
399 Ecore_X_Window xwin = elm_win_xwindow_get(win);
400 if (xwin)
401 ecore_x_window_size_get(ecore_x_window_root_get(xwin), &cw, &ch);
402#endif
403 if (!cw)
404 elm_win_screen_size_get(elm_widget_top_get(tt->owner), NULL, NULL, &cw, &ch);
405 }
397 if (!cw) 406 if (!cw)
398 evas_output_size_get(tt->tt_evas ?: tt->evas, &cw, &ch); 407 evas_output_size_get(tt->tt_evas ?: tt->evas, &cw, &ch);
399 TTDBG("SCREEN: cw=%d,ch=%d\n", cw, ch); 408 TTDBG("SCREEN: cw=%d,ch=%d\n", cw, ch);