diff options
author | fujiwarat <takao.fujiwara1@gmail.com> | 2015-06-12 11:43:56 +0900 |
---|---|---|
committer | fujiwarat <takao.fujiwara1@gmail.com> | 2015-06-12 11:43:56 +0900 |
commit | bd7673e73c2a8c54d2a827603a960d76dab7be1b (patch) | |
tree | 13c2276e2386166173288f69b17c5a51bd9bf58e | |
parent | b0f2536b58dff885fa887230909718a69b571053 (diff) | |
download | ibus-bd7673e73c2a8c54d2a827603a960d76dab7be1b.tar.gz |
Do not put lookup window at the minus position
tweetdeck.twitter.com seems has hidden GdkWindow and does not provide
the positive cursor position.
BUG=https://github.com/ibus/ibus/issues/1801
Review URL: https://codereview.appspot.com/246010043
-rw-r--r-- | ui/gtk3/candidatepanel.vala | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/ui/gtk3/candidatepanel.vala b/ui/gtk3/candidatepanel.vala index 1b7bec7c..c3260446 100644 --- a/ui/gtk3/candidatepanel.vala +++ b/ui/gtk3/candidatepanel.vala @@ -301,11 +301,15 @@ public class CandidatePanel : Gtk.Box{ x = root_width - allocation.width; else x = cursor_right_bottom.x; + if (x < 0) + x = 0; if (window_right_bottom.y > root_height) y = m_cursor_location.y - allocation.height; else y = cursor_right_bottom.y; + if (y < 0) + y = 0; move(x, y); } |