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

Side by Side Diff: ash/wm/window_modality_controller_unittest.cc

Issue 2160603002: ash: Adjust ascii art comment to avoid looking like multiline comment (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: ash: Adjust ascii art comment to avoid looking like multiline comment Created 4 years, 5 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 unified diff | Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "ui/wm/core/window_modality_controller.h" 5 #include "ui/wm/core/window_modality_controller.h"
6 6
7 #include "ash/shell.h" 7 #include "ash/shell.h"
8 #include "ash/test/ash_test_base.h" 8 #include "ash/test/ash_test_base.h"
9 #include "ash/test/child_modal_window.h" 9 #include "ash/test/child_modal_window.h"
10 #include "ash/wm/window_util.h" 10 #include "ash/wm/window_util.h"
(...skipping 303 matching lines...) Expand 10 before | Expand all | Expand 10 after
314 EXPECT_FALSE(modal_view->got_capture_lost()); 314 EXPECT_FALSE(modal_view->got_capture_lost());
315 EXPECT_FALSE(view->got_capture_lost()); 315 EXPECT_FALSE(view->got_capture_lost());
316 EXPECT_FALSE(view->got_press()); 316 EXPECT_FALSE(view->got_press());
317 } 317 }
318 318
319 // Test that when a child modal window becomes visible, we only release the 319 // Test that when a child modal window becomes visible, we only release the
320 // capture window if the current capture window is in the hierarchy of the child 320 // capture window if the current capture window is in the hierarchy of the child
321 // modal window's modal parent window. 321 // modal window's modal parent window.
322 TEST_F(WindowModalityControllerTest, ReleaseCapture) { 322 TEST_F(WindowModalityControllerTest, ReleaseCapture) {
323 // Create a window hierachy like this: 323 // Create a window hierachy like this:
324 // w0 324 // _______________w0______________
325 // / | \ 325 // | | |
326 // w1 <------ w3 w2 326 // w1 <------ w3 w2
327 // | (modal to) 327 // | (modal to)
328 // w11 328 // w11
329 329
330 aura::test::TestWindowDelegate d; 330 aura::test::TestWindowDelegate d;
331 std::unique_ptr<aura::Window> w1( 331 std::unique_ptr<aura::Window> w1(
332 CreateTestWindowInShellWithDelegate(&d, -1, gfx::Rect())); 332 CreateTestWindowInShellWithDelegate(&d, -1, gfx::Rect()));
333 std::unique_ptr<aura::Window> w11( 333 std::unique_ptr<aura::Window> w11(
334 aura::test::CreateTestWindowWithDelegate(&d, -11, gfx::Rect(), w1.get())); 334 aura::test::CreateTestWindowWithDelegate(&d, -11, gfx::Rect(), w1.get()));
335 std::unique_ptr<aura::Window> w2( 335 std::unique_ptr<aura::Window> w2(
336 CreateTestWindowInShellWithDelegate(&d, -2, gfx::Rect())); 336 CreateTestWindowInShellWithDelegate(&d, -2, gfx::Rect()));
(...skipping 305 matching lines...) Expand 10 before | Expand all | Expand 10 after
642 EXPECT_TRUE(wm::IsActiveWindow(w4.get())); 642 EXPECT_TRUE(wm::IsActiveWindow(w4.get()));
643 643
644 wm::ActivateWindow(w3.get()); 644 wm::ActivateWindow(w3.get());
645 EXPECT_TRUE(wm::IsActiveWindow(w4.get())); 645 EXPECT_TRUE(wm::IsActiveWindow(w4.get()));
646 646
647 wm::ActivateWindow(w4.get()); 647 wm::ActivateWindow(w4.get());
648 EXPECT_TRUE(wm::IsActiveWindow(w4.get())); 648 EXPECT_TRUE(wm::IsActiveWindow(w4.get()));
649 } 649 }
650 650
651 } // namespace ash 651 } // namespace ash
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698