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

Side by Side Diff: third_party/WebKit/Source/core/dom/AXObjectCache.h

Issue 2050123002: Remove OwnPtr from Blink. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: First attempt to land. Created 4 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
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2003, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All rights reserved. 2 * Copyright (C) 2003, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 1. Redistributions of source code must retain the above copyright 7 * 1. Redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer. 8 * notice, this list of conditions and the following disclaimer.
9 * 2. Redistributions in binary form must reproduce the above copyright 9 * 2. Redistributions in binary form must reproduce the above copyright
10 * notice, this list of conditions and the following disclaimer in the 10 * notice, this list of conditions and the following disclaimer in the
(...skipping 10 matching lines...) Expand all
21 * OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 21 * OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
22 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 22 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
23 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 23 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
24 */ 24 */
25 25
26 #ifndef AXObjectCache_h 26 #ifndef AXObjectCache_h
27 #define AXObjectCache_h 27 #define AXObjectCache_h
28 28
29 #include "core/CoreExport.h" 29 #include "core/CoreExport.h"
30 #include "core/dom/Document.h" 30 #include "core/dom/Document.h"
31 #include <memory>
31 32
32 typedef unsigned AXID; 33 typedef unsigned AXID;
33 34
34 namespace blink { 35 namespace blink {
35 36
36 class AbstractInlineTextBox; 37 class AbstractInlineTextBox;
37 class AXObject; 38 class AXObject;
38 class FrameView; 39 class FrameView;
39 class HTMLOptionElement; 40 class HTMLOptionElement;
40 class HTMLSelectElement; 41 class HTMLSelectElement;
(...skipping 106 matching lines...) Expand 10 before | Expand all | Expand 10 after
147 AXObjectCache(); 148 AXObjectCache();
148 149
149 private: 150 private:
150 static AXObjectCacheCreateFunction m_createFunction; 151 static AXObjectCacheCreateFunction m_createFunction;
151 }; 152 };
152 153
153 class CORE_EXPORT ScopedAXObjectCache { 154 class CORE_EXPORT ScopedAXObjectCache {
154 USING_FAST_MALLOC(ScopedAXObjectCache); 155 USING_FAST_MALLOC(ScopedAXObjectCache);
155 WTF_MAKE_NONCOPYABLE(ScopedAXObjectCache); 156 WTF_MAKE_NONCOPYABLE(ScopedAXObjectCache);
156 public: 157 public:
157 static PassOwnPtr<ScopedAXObjectCache> create(Document&); 158 static std::unique_ptr<ScopedAXObjectCache> create(Document&);
158 ~ScopedAXObjectCache(); 159 ~ScopedAXObjectCache();
159 160
160 AXObjectCache* get(); 161 AXObjectCache* get();
161 162
162 private: 163 private:
163 explicit ScopedAXObjectCache(Document&); 164 explicit ScopedAXObjectCache(Document&);
164 165
165 Persistent<Document> m_document; 166 Persistent<Document> m_document;
166 Persistent<AXObjectCache> m_cache; 167 Persistent<AXObjectCache> m_cache;
167 }; 168 };
168 169
169 } // namespace blink 170 } // namespace blink
170 171
171 #endif 172 #endif
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698