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

Side by Side Diff: cc/tree_synchronizer.h

Issue 11472021: cc: Pass LayerTreeHostImpl to LayerImpl constructor (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase Created 8 years 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 | Annotate | Revision Log
« no previous file with comments | « cc/tiled_layer_unittest.cc ('k') | cc/tree_synchronizer.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 2011 The Chromium Authors. All rights reserved. 1 // Copyright 2011 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 CC_TREE_SYNCHRONIZER_H_ 5 #ifndef CC_TREE_SYNCHRONIZER_H_
6 #define CC_TREE_SYNCHRONIZER_H_ 6 #define CC_TREE_SYNCHRONIZER_H_
7 7
8 #include "base/basictypes.h" 8 #include "base/basictypes.h"
9 #include "base/memory/scoped_ptr.h" 9 #include "base/memory/scoped_ptr.h"
10 #include "cc/cc_export.h" 10 #include "cc/cc_export.h"
(...skipping 11 matching lines...) Expand all
22 // of the Layer tree, reusing the LayerImpls in the tree provided by oldLaye rImplRoot if possible. 22 // of the Layer tree, reusing the LayerImpls in the tree provided by oldLaye rImplRoot if possible.
23 static scoped_ptr<LayerImpl> synchronizeTrees(Layer* layerRoot, scoped_ptr<L ayerImpl> oldLayerImplRoot, LayerTreeHostImpl*); 23 static scoped_ptr<LayerImpl> synchronizeTrees(Layer* layerRoot, scoped_ptr<L ayerImpl> oldLayerImplRoot, LayerTreeHostImpl*);
24 24
25 private: 25 private:
26 TreeSynchronizer(); // Not instantiable. 26 TreeSynchronizer(); // Not instantiable.
27 27
28 typedef ScopedPtrHashMap<int, LayerImpl> ScopedPtrLayerImplMap; 28 typedef ScopedPtrHashMap<int, LayerImpl> ScopedPtrLayerImplMap;
29 typedef base::hash_map<int, LayerImpl*> RawPtrLayerImplMap; 29 typedef base::hash_map<int, LayerImpl*> RawPtrLayerImplMap;
30 30
31 // Declared as static member functions so they can access functions on Layer as a friend class. 31 // Declared as static member functions so they can access functions on Layer as a friend class.
32 static scoped_ptr<LayerImpl> reuseOrCreateLayerImpl(RawPtrLayerImplMap& newL ayers, ScopedPtrLayerImplMap& oldLayers, Layer*); 32 static scoped_ptr<LayerImpl> reuseOrCreateLayerImpl(RawPtrLayerImplMap& newL ayers, ScopedPtrLayerImplMap& oldLayers, Layer*, LayerTreeHostImpl*);
33 static void collectExistingLayerImplRecursive(ScopedPtrLayerImplMap& oldLaye rs, scoped_ptr<LayerImpl>); 33 static void collectExistingLayerImplRecursive(ScopedPtrLayerImplMap& oldLaye rs, scoped_ptr<LayerImpl>);
34 static scoped_ptr<LayerImpl> synchronizeTreeRecursive(RawPtrLayerImplMap& ne wLayers, ScopedPtrLayerImplMap& oldLayers, Layer*, LayerTreeHostImpl*); 34 static scoped_ptr<LayerImpl> synchronizeTreeRecursive(RawPtrLayerImplMap& ne wLayers, ScopedPtrLayerImplMap& oldLayers, Layer*, LayerTreeHostImpl*);
35 static void updateScrollbarLayerPointersRecursive(const RawPtrLayerImplMap& newLayers, Layer*); 35 static void updateScrollbarLayerPointersRecursive(const RawPtrLayerImplMap& newLayers, Layer*);
36 36
37 DISALLOW_COPY_AND_ASSIGN(TreeSynchronizer); 37 DISALLOW_COPY_AND_ASSIGN(TreeSynchronizer);
38 }; 38 };
39 39
40 } // namespace cc 40 } // namespace cc
41 41
42 #endif // CC_TREE_SYNCHRONIZER_H_ 42 #endif // CC_TREE_SYNCHRONIZER_H_
OLDNEW
« no previous file with comments | « cc/tiled_layer_unittest.cc ('k') | cc/tree_synchronizer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698