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

Side by Side Diff: ash/display/window_tree_host_manager.cc

Issue 1547223002: Convert Pass()→std::move() in //ash (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 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
« no previous file with comments | « ash/display/mouse_cursor_event_filter.cc ('k') | ash/drag_drop/drag_drop_controller.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/display/window_tree_host_manager.h" 5 #include "ash/display/window_tree_host_manager.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <cmath> 8 #include <cmath>
9 #include <map> 9 #include <map>
10 #include <utility>
10 11
11 #include "ash/ash_switches.h" 12 #include "ash/ash_switches.h"
12 #include "ash/display/cursor_window_controller.h" 13 #include "ash/display/cursor_window_controller.h"
13 #include "ash/display/display_layout_store.h" 14 #include "ash/display/display_layout_store.h"
14 #include "ash/display/display_manager.h" 15 #include "ash/display/display_manager.h"
15 #include "ash/display/mirror_window_controller.h" 16 #include "ash/display/mirror_window_controller.h"
16 #include "ash/display/root_window_transformers.h" 17 #include "ash/display/root_window_transformers.h"
17 #include "ash/host/ash_window_tree_host.h" 18 #include "ash/host/ash_window_tree_host.h"
18 #include "ash/host/ash_window_tree_host_init_params.h" 19 #include "ash/host/ash_window_tree_host_init_params.h"
19 #include "ash/host/root_window_transformer.h" 20 #include "ash/host/root_window_transformer.h"
(...skipping 121 matching lines...) Expand 10 before | Expand all | Expand 10 after
141 142
142 if (!display.IsInternal()) 143 if (!display.IsInternal())
143 scale *= kCursorMultiplierForExternalDisplays; 144 scale *= kCursorMultiplierForExternalDisplays;
144 145
145 ui::CursorController::GetInstance()->SetCursorConfigForWindow( 146 ui::CursorController::GetInstance()->SetCursorConfigForWindow(
146 host->GetAcceleratedWidget(), info.GetActiveRotation(), scale); 147 host->GetAcceleratedWidget(), info.GetActiveRotation(), scale);
147 #endif 148 #endif
148 #endif 149 #endif
149 scoped_ptr<RootWindowTransformer> transformer( 150 scoped_ptr<RootWindowTransformer> transformer(
150 CreateRootWindowTransformerForDisplay(host->window(), display)); 151 CreateRootWindowTransformerForDisplay(host->window(), display));
151 ash_host->SetRootWindowTransformer(transformer.Pass()); 152 ash_host->SetRootWindowTransformer(std::move(transformer));
152 153
153 DisplayMode mode = 154 DisplayMode mode =
154 GetDisplayManager()->GetActiveModeForDisplayId(display.id()); 155 GetDisplayManager()->GetActiveModeForDisplayId(display.id());
155 if (mode.refresh_rate > 0.0f) { 156 if (mode.refresh_rate > 0.0f) {
156 host->compositor()->SetAuthoritativeVSyncInterval( 157 host->compositor()->SetAuthoritativeVSyncInterval(
157 base::TimeDelta::FromMicroseconds(base::Time::kMicrosecondsPerSecond / 158 base::TimeDelta::FromMicroseconds(base::Time::kMicrosecondsPerSecond /
158 mode.refresh_rate)); 159 mode.refresh_rate));
159 } 160 }
160 161
161 // Just movnig the display requires the full redraw. 162 // Just movnig the display requires the full redraw.
(...skipping 765 matching lines...) Expand 10 before | Expand all | Expand 10 after
927 ->display_configurator_animation() 928 ->display_configurator_animation()
928 ->StartFadeInAnimation(); 929 ->StartFadeInAnimation();
929 #endif 930 #endif
930 } 931 }
931 932
932 void WindowTreeHostManager::SetMirrorModeAfterAnimation(bool mirror) { 933 void WindowTreeHostManager::SetMirrorModeAfterAnimation(bool mirror) {
933 GetDisplayManager()->SetMirrorMode(mirror); 934 GetDisplayManager()->SetMirrorMode(mirror);
934 } 935 }
935 936
936 } // namespace ash 937 } // namespace ash
OLDNEW
« no previous file with comments | « ash/display/mouse_cursor_event_filter.cc ('k') | ash/drag_drop/drag_drop_controller.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698