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

Side by Side Diff: components/exo/surface.h

Issue 2383263002: Generalize layer mirroring for phantom windows (Closed)
Patch Set: Created 4 years, 2 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
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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_EXO_SURFACE_H_ 5 #ifndef COMPONENTS_EXO_SURFACE_H_
6 #define COMPONENTS_EXO_SURFACE_H_ 6 #define COMPONENTS_EXO_SURFACE_H_
7 7
8 #include <list> 8 #include <list>
9 #include <memory> 9 #include <memory>
10 #include <set> 10 #include <set>
(...skipping 192 matching lines...) Expand 10 before | Expand all | Expand 10 after
203 203
204 // Returns a trace value representing the state of the surface. 204 // Returns a trace value representing the state of the surface.
205 std::unique_ptr<base::trace_event::TracedValue> AsTracedValue() const; 205 std::unique_ptr<base::trace_event::TracedValue> AsTracedValue() const;
206 206
207 bool HasPendingDamageForTesting(const gfx::Rect& damage) const { 207 bool HasPendingDamageForTesting(const gfx::Rect& damage) const {
208 return pending_damage_.contains(gfx::RectToSkIRect(damage)); 208 return pending_damage_.contains(gfx::RectToSkIRect(damage));
209 } 209 }
210 210
211 // Overridden from ui::LayerOwnerDelegate: 211 // Overridden from ui::LayerOwnerDelegate:
212 void OnLayerRecreated(ui::Layer* old_layer, ui::Layer* new_layer) override; 212 void OnLayerRecreated(ui::Layer* old_layer, ui::Layer* new_layer) override;
213 void OnLayerMirrored(ui::Layer* mirror) override;
213 214
214 // Overridden from ui::ContextFactoryObserver. 215 // Overridden from ui::ContextFactoryObserver.
215 void OnLostResources() override; 216 void OnLostResources() override;
216 217
217 void WillDraw(const cc::SurfaceId& surface_id); 218 void WillDraw(const cc::SurfaceId& surface_id);
218 219
219 // Check whether this Surface and its children need to create new cc::Surface 220 // Check whether this Surface and its children need to create new cc::Surface
220 // IDs for their contents next time they get new buffer contents. 221 // IDs for their contents next time they get new buffer contents.
221 void CheckIfSurfaceHierarchyNeedsCommitToNewSurfaces(); 222 void CheckIfSurfaceHierarchyNeedsCommitToNewSurfaces();
222 223
(...skipping 176 matching lines...) Expand 10 before | Expand all | Expand 10 after
399 400
400 // Surface observer list. Surface does not own the observers. 401 // Surface observer list. Surface does not own the observers.
401 base::ObserverList<SurfaceObserver, true> observers_; 402 base::ObserverList<SurfaceObserver, true> observers_;
402 403
403 DISALLOW_COPY_AND_ASSIGN(Surface); 404 DISALLOW_COPY_AND_ASSIGN(Surface);
404 }; 405 };
405 406
406 } // namespace exo 407 } // namespace exo
407 408
408 #endif // COMPONENTS_EXO_SURFACE_H_ 409 #endif // COMPONENTS_EXO_SURFACE_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698