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

Side by Side Diff: cc/TreeSynchronizer.h

Issue 10914268: Change cc files from namespace WebCore to cc (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebased Created 8 years, 3 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 | Annotate | Revision Log
« no previous file with comments | « cc/TiledLayerChromium.cpp ('k') | cc/TreeSynchronizer.cpp » ('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 TreeSynchronizer_h 5 #ifndef TreeSynchronizer_h
6 #define TreeSynchronizer_h 6 #define TreeSynchronizer_h
7 7
8 #include <wtf/HashMap.h> 8 #include <wtf/HashMap.h>
9 #include <wtf/Noncopyable.h> 9 #include <wtf/Noncopyable.h>
10 #include <wtf/OwnPtr.h> 10 #include <wtf/OwnPtr.h>
11 #include <wtf/PassOwnPtr.h> 11 #include <wtf/PassOwnPtr.h>
12 12
13 namespace WebCore { 13 namespace cc {
14 14
15 class CCLayerImpl; 15 class CCLayerImpl;
16 class CCLayerTreeHostImpl; 16 class CCLayerTreeHostImpl;
17 class LayerChromium; 17 class LayerChromium;
18 18
19 class TreeSynchronizer { 19 class TreeSynchronizer {
20 WTF_MAKE_NONCOPYABLE(TreeSynchronizer); 20 WTF_MAKE_NONCOPYABLE(TreeSynchronizer);
21 public: 21 public:
22 // Accepts a LayerChromium tree and returns a reference to a CCLayerImpl tre e that duplicates the structure 22 // Accepts a LayerChromium tree and returns a reference to a CCLayerImpl tre e that duplicates the structure
23 // of the LayerChromium tree, reusing the CCLayerImpls in the tree provided by oldCCLayerImplRoot if possible. 23 // of the LayerChromium tree, reusing the CCLayerImpls in the tree provided by oldCCLayerImplRoot if possible.
24 static PassOwnPtr<CCLayerImpl> synchronizeTrees(LayerChromium* layerRoot, Pa ssOwnPtr<CCLayerImpl> oldCCLayerImplRoot, CCLayerTreeHostImpl*); 24 static PassOwnPtr<CCLayerImpl> synchronizeTrees(LayerChromium* layerRoot, Pa ssOwnPtr<CCLayerImpl> oldCCLayerImplRoot, CCLayerTreeHostImpl*);
25 25
26 private: 26 private:
27 TreeSynchronizer(); // Not instantiable. 27 TreeSynchronizer(); // Not instantiable.
28 28
29 typedef HashMap<int, OwnPtr<CCLayerImpl> > OwnPtrCCLayerImplMap; 29 typedef HashMap<int, OwnPtr<CCLayerImpl> > OwnPtrCCLayerImplMap;
30 typedef HashMap<int, CCLayerImpl*> RawPtrCCLayerImplMap; 30 typedef HashMap<int, CCLayerImpl*> RawPtrCCLayerImplMap;
31 31
32 // Declared as static member functions so they can access functions on Layer Chromium as a friend class. 32 // Declared as static member functions so they can access functions on Layer Chromium as a friend class.
33 static PassOwnPtr<CCLayerImpl> reuseOrCreateCCLayerImpl(RawPtrCCLayerImplMap & newLayers, OwnPtrCCLayerImplMap& oldLayers, LayerChromium*); 33 static PassOwnPtr<CCLayerImpl> reuseOrCreateCCLayerImpl(RawPtrCCLayerImplMap & newLayers, OwnPtrCCLayerImplMap& oldLayers, LayerChromium*);
34 static void collectExistingCCLayerImplRecursive(OwnPtrCCLayerImplMap& oldLay ers, PassOwnPtr<CCLayerImpl>); 34 static void collectExistingCCLayerImplRecursive(OwnPtrCCLayerImplMap& oldLay ers, PassOwnPtr<CCLayerImpl>);
35 static PassOwnPtr<CCLayerImpl> synchronizeTreeRecursive(RawPtrCCLayerImplMap & newLayers, OwnPtrCCLayerImplMap& oldLayers, LayerChromium*, CCLayerTreeHostImp l*); 35 static PassOwnPtr<CCLayerImpl> synchronizeTreeRecursive(RawPtrCCLayerImplMap & newLayers, OwnPtrCCLayerImplMap& oldLayers, LayerChromium*, CCLayerTreeHostImp l*);
36 static void updateScrollbarLayerPointersRecursive(const RawPtrCCLayerImplMap & newLayers, LayerChromium*); 36 static void updateScrollbarLayerPointersRecursive(const RawPtrCCLayerImplMap & newLayers, LayerChromium*);
37 }; 37 };
38 38
39 } // namespace WebCore 39 } // namespace cc
40 40
41 #endif // TreeSynchronizer_h 41 #endif // TreeSynchronizer_h
OLDNEW
« no previous file with comments | « cc/TiledLayerChromium.cpp ('k') | cc/TreeSynchronizer.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698