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

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

Issue 115153002: wm: public window_types. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: ozone deps Created 7 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « ash/wm/video_detector_unittest.cc ('k') | ash/wm/window_positioner.cc » ('j') | 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 "ash/shell.h" 5 #include "ash/shell.h"
6 #include "ash/shell_window_ids.h" 6 #include "ash/shell_window_ids.h"
7 #include "ash/test/ash_test_base.h" 7 #include "ash/test/ash_test_base.h"
8 #include "ash/test/shell_test_api.h" 8 #include "ash/test/shell_test_api.h"
9 #include "ash/test/test_activation_delegate.h" 9 #include "ash/test/test_activation_delegate.h"
10 #include "ash/wm/window_util.h" 10 #include "ash/wm/window_util.h"
(...skipping 358 matching lines...) Expand 10 before | Expand all | Expand 10 after
369 EXPECT_EQ(w1.get(), focus_client->GetFocusedWindow()); 369 EXPECT_EQ(w1.get(), focus_client->GetFocusedWindow());
370 } 370 }
371 } 371 }
372 372
373 TEST_F(WindowManagerTest, PanelActivation) { 373 TEST_F(WindowManagerTest, PanelActivation) {
374 aura::test::TestWindowDelegate wd; 374 aura::test::TestWindowDelegate wd;
375 scoped_ptr<aura::Window> w1(CreateTestWindowInShellWithDelegate( 375 scoped_ptr<aura::Window> w1(CreateTestWindowInShellWithDelegate(
376 &wd, -1, gfx::Rect(10, 10, 50, 50))); 376 &wd, -1, gfx::Rect(10, 10, 50, 50)));
377 aura::test::TestWindowDelegate pd; 377 aura::test::TestWindowDelegate pd;
378 scoped_ptr<aura::Window> p1(CreateTestWindowInShellWithDelegateAndType( 378 scoped_ptr<aura::Window> p1(CreateTestWindowInShellWithDelegateAndType(
379 &pd, aura::client::WINDOW_TYPE_PANEL, -1, gfx::Rect(10, 10, 50, 50))); 379 &pd, ui::wm::WINDOW_TYPE_PANEL, -1, gfx::Rect(10, 10, 50, 50)));
380 aura::client::FocusClient* focus_client = 380 aura::client::FocusClient* focus_client =
381 aura::client::GetFocusClient(w1.get()); 381 aura::client::GetFocusClient(w1.get());
382 382
383 // Activate w1. 383 // Activate w1.
384 wm::ActivateWindow(w1.get()); 384 wm::ActivateWindow(w1.get());
385 EXPECT_TRUE(wm::IsActiveWindow(w1.get())); 385 EXPECT_TRUE(wm::IsActiveWindow(w1.get()));
386 386
387 // Activate p1. 387 // Activate p1.
388 wm::ActivateWindow(p1.get()); 388 wm::ActivateWindow(p1.get());
389 EXPECT_TRUE(wm::IsActiveWindow(p1.get())); 389 EXPECT_TRUE(wm::IsActiveWindow(p1.get()));
(...skipping 423 matching lines...) Expand 10 before | Expand all | Expand 10 after
813 observer_a.reset(); 813 observer_a.reset();
814 observer_b.reset(); 814 observer_b.reset();
815 generator.MoveMouseTo(50, 50); 815 generator.MoveMouseTo(50, 50);
816 EXPECT_TRUE(observer_a.did_visibility_change()); 816 EXPECT_TRUE(observer_a.did_visibility_change());
817 EXPECT_FALSE(observer_b.did_visibility_change()); 817 EXPECT_FALSE(observer_b.did_visibility_change());
818 EXPECT_TRUE(observer_a.is_cursor_visible()); 818 EXPECT_TRUE(observer_a.is_cursor_visible());
819 } 819 }
820 #endif // defined(OS_CHROMEOS) 820 #endif // defined(OS_CHROMEOS)
821 821
822 } // namespace ash 822 } // namespace ash
OLDNEW
« no previous file with comments | « ash/wm/video_detector_unittest.cc ('k') | ash/wm/window_positioner.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698