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

Unified Diff: ui/aura/test/test_stacking_client.cc

Issue 8926004: Revert 114095 - Move the concept of Activation to the Shell. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 9 years 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/aura/test/test_stacking_client.h ('k') | ui/aura/test/test_window_delegate.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/aura/test/test_stacking_client.cc
===================================================================
--- ui/aura/test/test_stacking_client.cc (revision 114098)
+++ ui/aura/test/test_stacking_client.cc (working copy)
@@ -26,5 +26,20 @@
default_container_->AddChild(window);
}
+bool TestStackingClient::CanActivateWindow(Window* window) const {
+ return window->parent() == default_container_;
+}
+
+Window* TestStackingClient::GetTopmostWindowToActivate(Window* ignore) const {
+ for (aura::Window::Windows::const_reverse_iterator i =
+ default_container_->children().rbegin();
+ i != default_container_->children().rend();
+ ++i) {
+ if (*i != ignore && (*i)->CanActivate())
+ return *i;
+ }
+ return NULL;
+}
+
} // namespace test
} // namespace aura
« no previous file with comments | « ui/aura/test/test_stacking_client.h ('k') | ui/aura/test/test_window_delegate.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698