Upstream version 10.39.225.0
[platform/framework/web/crosswalk.git] / src / chrome / browser / ui / ash / ash_util.cc
index f6d6ce2..de8b919 100644 (file)
@@ -7,23 +7,23 @@
 #include "ash/shell.h"
 #include "chrome/browser/ui/ash/ash_init.h"
 #include "chrome/browser/ui/host_desktop.h"
-#include "ui/aura/root_window.h"
+#include "ui/aura/window_event_dispatcher.h"
 
 namespace chrome {
 
 bool IsNativeViewInAsh(gfx::NativeView native_view) {
 #if defined(OS_CHROMEOS)
-  // Optimization. There is only ash on ChromeOS.
-  return true;
+  // Optimization. There is only ash or only athena on ChromeOS.
+  return ash::Shell::HasInstance();
 #endif
 
   if (!ash::Shell::HasInstance())
     return false;
 
-  ash::Shell::RootWindowList root_windows =
+  aura::Window::Windows root_windows =
       ash::Shell::GetInstance()->GetAllRootWindows();
 
-  for (ash::Shell::RootWindowList::const_iterator it = root_windows.begin();
+  for (aura::Window::Windows::const_iterator it = root_windows.begin();
        it != root_windows.end(); ++it) {
     if ((*it)->Contains(native_view))
       return true;
@@ -36,14 +36,4 @@ bool IsNativeWindowInAsh(gfx::NativeWindow native_window) {
   return IsNativeViewInAsh(native_window);
 }
 
-void ToggleAshDesktop() {
-  if (chrome::HOST_DESKTOP_TYPE_ASH == chrome::HOST_DESKTOP_TYPE_NATIVE)
-    return;
-
-  if (!ash::Shell::HasInstance())
-    OpenAsh();
-  else
-    CloseAsh();
-}
-
 }  // namespace chrome