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

Side by Side Diff: ui/views/controls/native/native_view_host_aura_unittest.cc

Issue 2611773002: Removes code using mus client lib (Closed)
Patch Set: dont run on linux Created 3 years, 11 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
OLDNEW
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 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/views/controls/native/native_view_host_aura.h" 5 #include "ui/views/controls/native/native_view_host_aura.h"
6 6
7 #include <memory> 7 #include <memory>
8 8
9 #include "base/macros.h" 9 #include "base/macros.h"
10 #include "ui/aura/client/aura_constants.h" 10 #include "ui/aura/client/aura_constants.h"
(...skipping 251 matching lines...) Expand 10 before | Expand all | Expand 10 after
262 262
263 NativeViewHostWindowObserver test_observer; 263 NativeViewHostWindowObserver test_observer;
264 child_win->AddObserver(&test_observer); 264 child_win->AddObserver(&test_observer);
265 265
266 host()->Detach(); 266 host()->Detach();
267 EXPECT_EQ(root_window, child_win->GetRootWindow()); 267 EXPECT_EQ(root_window, child_win->GetRootWindow());
268 EXPECT_EQ(child_win_tree_host, child_win->GetHost()); 268 EXPECT_EQ(child_win_tree_host, child_win->GetHost());
269 269
270 DestroyHost(); 270 DestroyHost();
271 DestroyTopLevel(); 271 DestroyTopLevel();
272 if (!IsMus() && !IsAuraMusClient()) { 272 if (!IsMus()) {
273 // The window is detached, so no longer associated with any Widget 273 // The window is detached, so no longer associated with any Widget
274 // hierarchy. The root window still owns it, but the test harness checks 274 // hierarchy. The root window still owns it, but the test harness checks
275 // for orphaned windows during TearDown(). 275 // for orphaned windows during TearDown().
276 EXPECT_EQ(0u, test_observer.events().size()) 276 EXPECT_EQ(0u, test_observer.events().size())
277 << (*test_observer.events().begin()).type; 277 << (*test_observer.events().begin()).type;
278 delete child_win; 278 delete child_win;
279 } else { 279 } else {
280 // In mus and aura-mus, the child window is still attached to the 280 // In mus and aura-mus, the child window is still attached to the
281 // aura::WindowTreeHost for the Widget. So destroying the toplevel Widget 281 // aura::WindowTreeHost for the Widget. So destroying the toplevel Widget
282 // takes down the child window with it. 282 // takes down the child window with it.
(...skipping 87 matching lines...) Expand 10 before | Expand all | Expand 10 after
370 370
371 host()->SetVisible(false); 371 host()->SetVisible(false);
372 EXPECT_FALSE(clipping_window()->IsVisible()); 372 EXPECT_FALSE(clipping_window()->IsVisible());
373 EXPECT_FALSE(child()->IsVisible()); 373 EXPECT_FALSE(child()->IsVisible());
374 374
375 DestroyHost(); 375 DestroyHost();
376 DestroyTopLevel(); 376 DestroyTopLevel();
377 } 377 }
378 378
379 } // namespace views 379 } // namespace views
OLDNEW
« no previous file with comments | « ui/views/controls/menu/menu_runner_unittest.cc ('k') | ui/views/corewm/tooltip_controller_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698