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

Side by Side Diff: components/viz/host/host_frame_sink_manager.h

Issue 2951053005: Add Mojo API for Blink hit testing (Closed)
Patch Set: Address Rob's comments Created 3 years, 4 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/host/DEPS ('k') | components/viz/host/host_frame_sink_manager.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 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 #ifndef COMPONENTS_VIZ_HOST_HOST_FRAME_SINK_MANAGER_H_ 5 #ifndef COMPONENTS_VIZ_HOST_HOST_FRAME_SINK_MANAGER_H_
6 #define COMPONENTS_VIZ_HOST_HOST_FRAME_SINK_MANAGER_H_ 6 #define COMPONENTS_VIZ_HOST_HOST_FRAME_SINK_MANAGER_H_
7 7
8 #include <memory> 8 #include <memory>
9 9
10 #include "base/compiler_specific.h" 10 #include "base/compiler_specific.h"
(...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after
77 const FrameSinkId& child_frame_sink_id); 77 const FrameSinkId& child_frame_sink_id);
78 78
79 // Unregisters FrameSink hierarchy. Client must have registered FrameSink 79 // Unregisters FrameSink hierarchy. Client must have registered FrameSink
80 // hierarchy before unregistering. 80 // hierarchy before unregistering.
81 void UnregisterFrameSinkHierarchy(const FrameSinkId& parent_frame_sink_id, 81 void UnregisterFrameSinkHierarchy(const FrameSinkId& parent_frame_sink_id,
82 const FrameSinkId& child_frame_sink_id); 82 const FrameSinkId& child_frame_sink_id);
83 83
84 // CompositorFrameSinkSupportManager: 84 // CompositorFrameSinkSupportManager:
85 std::unique_ptr<CompositorFrameSinkSupport> CreateCompositorFrameSinkSupport( 85 std::unique_ptr<CompositorFrameSinkSupport> CreateCompositorFrameSinkSupport(
86 CompositorFrameSinkSupportClient* client, 86 CompositorFrameSinkSupportClient* client,
87 mojom::TargetFrameForInputDelegate*,
87 const FrameSinkId& frame_sink_id, 88 const FrameSinkId& frame_sink_id,
88 bool is_root, 89 bool is_root,
89 bool handles_frame_sink_id_invalidation, 90 bool handles_frame_sink_id_invalidation,
90 bool needs_sync_points) override; 91 bool needs_sync_points) override;
91 92
92 private: 93 private:
93 friend class test::HostFrameSinkManagerTest; 94 friend class test::HostFrameSinkManagerTest;
94 95
95 struct FrameSinkData { 96 struct FrameSinkData {
96 FrameSinkData(); 97 FrameSinkData();
(...skipping 16 matching lines...) Expand all
113 // The FrameSinkId registered as the parent in the BeginFrame hierarchy. 114 // The FrameSinkId registered as the parent in the BeginFrame hierarchy.
114 base::Optional<FrameSinkId> parent; 115 base::Optional<FrameSinkId> parent;
115 116
116 // If a mojom::CompositorFrameSink was created for this FrameSinkId. This 117 // If a mojom::CompositorFrameSink was created for this FrameSinkId. This
117 // will always be false if not using Mojo. 118 // will always be false if not using Mojo.
118 bool has_created_compositor_frame_sink = false; 119 bool has_created_compositor_frame_sink = false;
119 120
120 // This will be null if using Mojo. 121 // This will be null if using Mojo.
121 CompositorFrameSinkSupport* support = nullptr; 122 CompositorFrameSinkSupport* support = nullptr;
122 123
124 // Hit test interface from the renderer.
125 mojom::TargetFrameForInputDelegate* target_frame_for_input_delegate =
126 nullptr;
127
123 private: 128 private:
124 DISALLOW_COPY_AND_ASSIGN(FrameSinkData); 129 DISALLOW_COPY_AND_ASSIGN(FrameSinkData);
125 }; 130 };
126 131
127 // Assigns the temporary reference to the frame sink that is expected to 132 // Assigns the temporary reference to the frame sink that is expected to
128 // embeded |surface_id|, otherwise drops the temporary reference. 133 // embeded |surface_id|, otherwise drops the temporary reference.
129 void PerformAssignTemporaryReference(const SurfaceId& surface_id); 134 void PerformAssignTemporaryReference(const SurfaceId& surface_id);
130 135
131 // mojom::FrameSinkManagerClient: 136 // mojom::FrameSinkManagerClient:
132 void OnSurfaceCreated(const SurfaceInfo& surface_info) override; 137 void OnSurfaceCreated(const SurfaceInfo& surface_info) override;
(...skipping 23 matching lines...) Expand all
156 base::ObserverList<FrameSinkObserver> observers_; 161 base::ObserverList<FrameSinkObserver> observers_;
157 162
158 base::WeakPtrFactory<HostFrameSinkManager> weak_ptr_factory_; 163 base::WeakPtrFactory<HostFrameSinkManager> weak_ptr_factory_;
159 164
160 DISALLOW_COPY_AND_ASSIGN(HostFrameSinkManager); 165 DISALLOW_COPY_AND_ASSIGN(HostFrameSinkManager);
161 }; 166 };
162 167
163 } // namespace viz 168 } // namespace viz
164 169
165 #endif // COMPONENTS_VIZ_HOST_HOST_FRAME_SINK_MANAGER_H_ 170 #endif // COMPONENTS_VIZ_HOST_HOST_FRAME_SINK_MANAGER_H_
OLDNEW
« no previous file with comments | « components/viz/host/DEPS ('k') | components/viz/host/host_frame_sink_manager.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698