Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(5)

Unified Diff: ui/views/widget/desktop_aura/x11_desktop_handler.cc

Issue 137533006: Call XSetInputFocus after XRaiseWindow when activating. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « ui/views/widget/desktop_aura/x11_desktop_handler.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/views/widget/desktop_aura/x11_desktop_handler.cc
diff --git a/ui/views/widget/desktop_aura/x11_desktop_handler.cc b/ui/views/widget/desktop_aura/x11_desktop_handler.cc
index 3a14e04c076cebcbace6271db290e940ef144ef7..9e2c62962f731833e1f0a121993edee2ab50d9ae 100644
--- a/ui/views/widget/desktop_aura/x11_desktop_handler.cc
+++ b/ui/views/widget/desktop_aura/x11_desktop_handler.cc
@@ -94,6 +94,12 @@ void X11DesktopHandler::ActivateWindow(::Window window) {
&xclient);
} else {
XRaiseWindow(xdisplay_, window);
+
+ // XRaiseWindow will not give input focus to the window. We now need to ask
+ // the X server to do that. Note that the call will raise an X error if the
+ // window is not mapped.
+ XSetInputFocus(xdisplay_, window, RevertToParent, CurrentTime);
+
OnActiveWindowChanged(window);
}
}
« no previous file with comments | « ui/views/widget/desktop_aura/x11_desktop_handler.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698