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

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

Issue 2875753002: Implement aura::WindowPortMus::CreateCompositorFrameSink() (Closed)
Patch Set: Fix build problem Created 3 years, 6 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 | « components/viz/client/client_compositor_frame_sink.cc ('k') | services/ui/ws/window_tree.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 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_server.h" 5 #include "services/ui/ws/window_server.h"
6 6
7 #include <set> 7 #include <set>
8 #include <string> 8 #include <string>
9 9
10 #include "base/logging.h" 10 #include "base/logging.h"
(...skipping 864 matching lines...) Expand 10 before | Expand all | Expand 10 after
875 display->platform_display()->GetFrameGenerator()->OnSurfaceCreated( 875 display->platform_display()->GetFrameGenerator()->OnSurfaceCreated(
876 surface_info); 876 surface_info);
877 display->root_window() 877 display->root_window()
878 ->GetOrCreateCompositorFrameSinkManager() 878 ->GetOrCreateCompositorFrameSinkManager()
879 ->ClaimTemporaryReference(surface_info.id()); 879 ->ClaimTemporaryReference(surface_info.id());
880 return; 880 return;
881 } 881 }
882 882
883 HandleTemporaryReferenceForNewSurface(surface_info.id(), window); 883 HandleTemporaryReferenceForNewSurface(surface_info.id(), window);
884 884
885 if (!window->parent()) 885 // We always use the owner of the window's id (even for an embedded window),
886 return; 886 // because an embedded window's id is allocated by the parent's window tree.
887 887 WindowTree* window_tree = GetTreeWithId(window->id().client_id);
888 WindowTree* window_tree = GetTreeWithId(window->parent()->id().client_id);
889 if (window_tree) 888 if (window_tree)
890 window_tree->ProcessWindowSurfaceChanged(window, surface_info); 889 window_tree->ProcessWindowSurfaceChanged(window, surface_info);
891 } 890 }
892 891
893 void WindowServer::OnActiveUserIdChanged(const UserId& previously_active_id, 892 void WindowServer::OnActiveUserIdChanged(const UserId& previously_active_id,
894 const UserId& active_id) { 893 const UserId& active_id) {
895 } 894 }
896 895
897 void WindowServer::OnUserIdAdded(const UserId& id) { 896 void WindowServer::OnUserIdAdded(const UserId& id) {
898 activity_monitor_map_[id] = base::MakeUnique<UserActivityMonitor>(nullptr); 897 activity_monitor_map_[id] = base::MakeUnique<UserActivityMonitor>(nullptr);
899 } 898 }
900 899
901 void WindowServer::OnUserIdRemoved(const UserId& id) { 900 void WindowServer::OnUserIdRemoved(const UserId& id) {
902 activity_monitor_map_.erase(id); 901 activity_monitor_map_.erase(id);
903 } 902 }
904 903
905 } // namespace ws 904 } // namespace ws
906 } // namespace ui 905 } // namespace ui
OLDNEW
« no previous file with comments | « components/viz/client/client_compositor_frame_sink.cc ('k') | services/ui/ws/window_tree.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698