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

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

Issue 2875753002: Implement aura::WindowPortMus::CreateCompositorFrameSink() (Closed)
Patch Set: WIP Created 3 years, 7 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 | « services/ui/ws/window_tree.h ('k') | ui/aura/mus/mus_context_factory.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 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 <stddef.h> 7 #include <stddef.h>
8 8
9 #include <utility> 9 #include <utility>
10 10
(...skipping 2129 matching lines...) Expand 10 before | Expand all | Expand 10 after
2140 if (!display_root) { 2140 if (!display_root) {
2141 DVLOG(1) << "CancelWindowMove failed (no such window manager display root)"; 2141 DVLOG(1) << "CancelWindowMove failed (no such window manager display root)";
2142 return; 2142 return;
2143 } 2143 }
2144 2144
2145 WindowManagerState* wms = display_root->window_manager_state(); 2145 WindowManagerState* wms = display_root->window_manager_state();
2146 wms->window_tree()->window_manager_internal_->WmCancelMoveLoop( 2146 wms->window_tree()->window_manager_internal_->WmCancelMoveLoop(
2147 window_server_->GetCurrentMoveLoopChangeId()); 2147 window_server_->GetCurrentMoveLoopChangeId());
2148 } 2148 }
2149 2149
2150 void WindowTree::GetFrameSinkId(Id window_id,
2151 const GetFrameSinkIdCallback& callback) {
2152 ServerWindow* window = GetWindowByClientId(ClientWindowId(window_id));
2153 if (!window) {
2154 DVLOG(1) << "GetFrameSinkId failed (invalid window id)";
2155 callback.Run(base::Optional<cc::FrameSinkId>());
2156 return;
2157 }
2158 callback.Run(window->frame_sink_id());
2159 }
2160
2150 void WindowTree::AddAccelerators( 2161 void WindowTree::AddAccelerators(
2151 std::vector<mojom::WmAcceleratorPtr> accelerators, 2162 std::vector<mojom::WmAcceleratorPtr> accelerators,
2152 const AddAcceleratorsCallback& callback) { 2163 const AddAcceleratorsCallback& callback) {
2153 DCHECK(window_manager_state_); 2164 DCHECK(window_manager_state_);
2154 2165
2155 bool success = true; 2166 bool success = true;
2156 for (auto iter = accelerators.begin(); iter != accelerators.end(); ++iter) { 2167 for (auto iter = accelerators.begin(); iter != accelerators.end(); ++iter) {
2157 if (!window_manager_state_->event_dispatcher()->AddAccelerator( 2168 if (!window_manager_state_->event_dispatcher()->AddAccelerator(
2158 iter->get()->id, std::move(iter->get()->event_matcher))) 2169 iter->get()->id, std::move(iter->get()->event_matcher)))
2159 success = false; 2170 success = false;
(...skipping 323 matching lines...) Expand 10 before | Expand all | Expand 10 after
2483 client()->OnCompleteDrop(client_window_id.id, event_flags, cursor_offset, 2494 client()->OnCompleteDrop(client_window_id.id, event_flags, cursor_offset,
2484 effect_bitmask, callback); 2495 effect_bitmask, callback);
2485 } 2496 }
2486 2497
2487 void WindowTree::PerformOnDragDropDone() { 2498 void WindowTree::PerformOnDragDropDone() {
2488 client()->OnDragDropDone(); 2499 client()->OnDragDropDone();
2489 } 2500 }
2490 2501
2491 } // namespace ws 2502 } // namespace ws
2492 } // namespace ui 2503 } // namespace ui
OLDNEW
« no previous file with comments | « services/ui/ws/window_tree.h ('k') | ui/aura/mus/mus_context_factory.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698