X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;f=src%2Fui%2Fviews%2Fwidget%2Fdesktop_aura%2Fx11_desktop_handler.cc;h=198b9c660707d67c422c0e6587b8bda82d42bd71;hb=ff3e2503a20db9193d323c1d19c38c68004dec4a;hp=e5dd2c198cae8ab4cbdc695d15c41d98bbc74b38;hpb=d1e23c6ec4202b125fc446349b2230d4cd978d86;p=platform%2Fframework%2Fweb%2Fcrosswalk.git diff --git a/src/ui/views/widget/desktop_aura/x11_desktop_handler.cc b/src/ui/views/widget/desktop_aura/x11_desktop_handler.cc index e5dd2c1..198b9c6 100644 --- a/src/ui/views/widget/desktop_aura/x11_desktop_handler.cc +++ b/src/ui/views/widget/desktop_aura/x11_desktop_handler.cc @@ -14,7 +14,7 @@ #if !defined(OS_CHROMEOS) #include "ui/views/ime/input_method.h" -#include "ui/views/widget/desktop_aura/desktop_root_window_host_x11.h" +#include "ui/views/widget/desktop_aura/desktop_window_tree_host_x11.h" #endif namespace { @@ -139,12 +139,17 @@ void X11DesktopHandler::ProcessXEvent(const base::NativeEvent& event) { current_window_ == event->xcrossing.window) OnActiveWindowChanged(None); break; + case FocusIn: + if (event->xfocus.mode == NotifyNormal && + current_window_ != event->xfocus.window) + OnActiveWindowChanged(event->xfocus.window); + break; default: NOTREACHED(); } } -bool X11DesktopHandler::Dispatch(const base::NativeEvent& event) { +uint32_t X11DesktopHandler::Dispatch(const base::NativeEvent& event) { // Check for a change to the active window. switch (event->type) { case PropertyNotify: { @@ -162,7 +167,7 @@ bool X11DesktopHandler::Dispatch(const base::NativeEvent& event) { } } - return true; + return POST_DISPATCH_NONE; } void X11DesktopHandler::OnWindowInitialized(aura::Window* window) {