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

Side by Side Diff: ash/mus/top_level_window_factory.cc

Issue 2762633003: Remove unused |context| from GetDefaultParent(). (Closed)
Patch Set: Fix chromecast compile error. Created 3 years, 9 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 | « ash/common/wm/container_finder.cc ('k') | ash/wm/stacking_controller.h » ('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 2017 The Chromium Authors. All rights reserved. 1 // Copyright 2017 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/mus/top_level_window_factory.h" 5 #include "ash/mus/top_level_window_factory.h"
6 6
7 #include "ash/common/wm/container_finder.h" 7 #include "ash/common/wm/container_finder.h"
8 #include "ash/common/wm/window_state.h" 8 #include "ash/common/wm/window_state.h"
9 #include "ash/common/wm_window.h" 9 #include "ash/common/wm_window.h"
10 #include "ash/mus/disconnected_app_handler.h" 10 #include "ash/mus/disconnected_app_handler.h"
(...skipping 171 matching lines...) Expand 10 before | Expand all | Expand 10 after
182 container_window->AddChild(window); 182 container_window->AddChild(window);
183 } else { 183 } else {
184 WmWindow* root = root_window_controller->GetWindow(); 184 WmWindow* root = root_window_controller->GetWindow();
185 gfx::Point origin = 185 gfx::Point origin =
186 root->ConvertPointToTarget(root->GetRootWindow(), gfx::Point()); 186 root->ConvertPointToTarget(root->GetRootWindow(), gfx::Point());
187 origin += root_window_controller->GetWindow() 187 origin += root_window_controller->GetWindow()
188 ->GetDisplayNearestWindow() 188 ->GetDisplayNearestWindow()
189 .bounds() 189 .bounds()
190 .OffsetFromOrigin(); 190 .OffsetFromOrigin();
191 gfx::Rect bounds_in_screen(origin, bounds.size()); 191 gfx::Rect bounds_in_screen(origin, bounds.size());
192 ash::wm::GetDefaultParent(WmWindow::Get(context), WmWindow::Get(window), 192 ash::wm::GetDefaultParent(WmWindow::Get(window), bounds_in_screen)
193 bounds_in_screen)
194 ->aura_window() 193 ->aura_window()
195 ->AddChild(window); 194 ->AddChild(window);
196 } 195 }
197 return window; 196 return window;
198 } 197 }
199 198
200 } // namespace 199 } // namespace
201 200
202 aura::Window* CreateAndParentTopLevelWindow( 201 aura::Window* CreateAndParentTopLevelWindow(
203 WindowManager* window_manager, 202 WindowManager* window_manager,
(...skipping 25 matching lines...) Expand all
229 if (non_client_frame_controller) 228 if (non_client_frame_controller)
230 non_client_frame_controller->set_can_activate(can_focus); 229 non_client_frame_controller->set_can_activate(can_focus);
231 // No need to persist this value. 230 // No need to persist this value.
232 properties->erase(focusable_iter); 231 properties->erase(focusable_iter);
233 } 232 }
234 return window; 233 return window;
235 } 234 }
236 235
237 } // namespace mus 236 } // namespace mus
238 } // namespace ash 237 } // namespace ash
OLDNEW
« no previous file with comments | « ash/common/wm/container_finder.cc ('k') | ash/wm/stacking_controller.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698