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

Side by Side Diff: services/ui/ws/window_tree_unittest.cc

Issue 2589663003: mojo:: Rename mojo::GetProxy() to mojo::MakeRequest() (Closed)
Patch Set: Rebase Created 3 years, 12 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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 "services/ui/ws/window_tree.h" 5 #include "services/ui/ws/window_tree.h"
6 6
7 #include <stdint.h> 7 #include <stdint.h>
8 8
9 #include <string> 9 #include <string>
10 #include <vector> 10 #include <vector>
(...skipping 204 matching lines...) Expand 10 before | Expand all | Expand 10 after
215 EXPECT_TRUE( 215 EXPECT_TRUE(
216 wm_tree()->NewWindow(embed_window_id, ServerWindow::Properties())); 216 wm_tree()->NewWindow(embed_window_id, ServerWindow::Properties()));
217 ServerWindow* embed_window = wm_tree()->GetWindowByClientId(embed_window_id); 217 ServerWindow* embed_window = wm_tree()->GetWindowByClientId(embed_window_id);
218 ASSERT_TRUE(embed_window); 218 ASSERT_TRUE(embed_window);
219 EXPECT_TRUE(wm_tree()->SetWindowVisibility(embed_window_id, true)); 219 EXPECT_TRUE(wm_tree()->SetWindowVisibility(embed_window_id, true));
220 ASSERT_TRUE(FirstRoot(wm_tree())); 220 ASSERT_TRUE(FirstRoot(wm_tree()));
221 const ClientWindowId wm_root_id = FirstRootId(wm_tree()); 221 const ClientWindowId wm_root_id = FirstRootId(wm_tree());
222 EXPECT_TRUE(wm_tree()->AddWindow(wm_root_id, embed_window_id)); 222 EXPECT_TRUE(wm_tree()->AddWindow(wm_root_id, embed_window_id));
223 display()->root_window()->SetBounds(gfx::Rect(0, 0, 100, 100)); 223 display()->root_window()->SetBounds(gfx::Rect(0, 0, 100, 100));
224 mojom::WindowTreeClientPtr client; 224 mojom::WindowTreeClientPtr client;
225 mojom::WindowTreeClientRequest client_request = GetProxy(&client); 225 mojom::WindowTreeClientRequest client_request = MakeRequest(&client);
226 wm_client()->Bind(std::move(client_request)); 226 wm_client()->Bind(std::move(client_request));
227 const uint32_t embed_flags = 0; 227 const uint32_t embed_flags = 0;
228 wm_tree()->Embed(embed_window_id, std::move(client), embed_flags); 228 wm_tree()->Embed(embed_window_id, std::move(client), embed_flags);
229 WindowTree* tree1 = window_server()->GetTreeWithRoot(embed_window); 229 WindowTree* tree1 = window_server()->GetTreeWithRoot(embed_window);
230 ASSERT_TRUE(tree1 != nullptr); 230 ASSERT_TRUE(tree1 != nullptr);
231 ASSERT_NE(tree1, wm_tree()); 231 ASSERT_NE(tree1, wm_tree());
232 232
233 embed_window->SetBounds(gfx::Rect(0, 0, 50, 50)); 233 embed_window->SetBounds(gfx::Rect(0, 0, 50, 50));
234 234
235 const ClientWindowId child1_id(BuildClientWindowId(tree1, 1)); 235 const ClientWindowId child1_id(BuildClientWindowId(tree1, 1));
(...skipping 1138 matching lines...) Expand 10 before | Expand all | Expand 10 after
1374 client->tracker()->changes()->clear(); 1374 client->tracker()->changes()->clear();
1375 } 1375 }
1376 1376
1377 // Client should not have got any messages after shutdown. 1377 // Client should not have got any messages after shutdown.
1378 EXPECT_TRUE(client->tracker()->changes()->empty()); 1378 EXPECT_TRUE(client->tracker()->changes()->empty());
1379 } 1379 }
1380 1380
1381 } // namespace test 1381 } // namespace test
1382 } // namespace ws 1382 } // namespace ws
1383 } // namespace ui 1383 } // namespace ui
OLDNEW
« no previous file with comments | « services/ui/ws/window_tree_client_unittest.cc ('k') | services/video_capture/test/fake_device_descriptor_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698