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

Side by Side Diff: include/core/SkData.h

Issue 2198453002: Conditionally define SK_SUPPORT_LEGACY_DATA_FACTORIES. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 4 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 | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright 2011 Google Inc. 2 * Copyright 2011 Google Inc.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license that can be 4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file. 5 * found in the LICENSE file.
6 */ 6 */
7 7
8 #ifndef SkData_DEFINED 8 #ifndef SkData_DEFINED
9 #define SkData_DEFINED 9 #define SkData_DEFINED
10 10
11 #include <stdio.h> 11 #include <stdio.h>
12 12
13 #include "SkRefCnt.h" 13 #include "SkRefCnt.h"
14 14
15 class SkStream; 15 class SkStream;
16 16
17 #ifndef SK_SUPPORT_LEGACY_DATA_FACTORIES
17 #define SK_SUPPORT_LEGACY_DATA_FACTORIES 18 #define SK_SUPPORT_LEGACY_DATA_FACTORIES
19 #endif
18 20
19 /** 21 /**
20 * SkData holds an immutable data buffer. Not only is the data immutable, 22 * SkData holds an immutable data buffer. Not only is the data immutable,
21 * but the actual ptr that is returned (by data() or bytes()) is guaranteed 23 * but the actual ptr that is returned (by data() or bytes()) is guaranteed
22 * to always be the same for the life of this instance. 24 * to always be the same for the life of this instance.
23 */ 25 */
24 class SK_API SkData : public SkRefCnt { 26 class SK_API SkData : public SkRefCnt {
25 public: 27 public:
26 /** 28 /**
27 * Returns the number of bytes stored. 29 * Returns the number of bytes stored.
(...skipping 192 matching lines...) Expand 10 before | Expand all | Expand 10 after
220 222
221 typedef SkRefCnt INHERITED; 223 typedef SkRefCnt INHERITED;
222 }; 224 };
223 225
224 #ifdef SK_SUPPORT_LEGACY_DATA_FACTORIES 226 #ifdef SK_SUPPORT_LEGACY_DATA_FACTORIES
225 /** Typedef of SkAutoTUnref<SkData> for automatically unref-ing a SkData. */ 227 /** Typedef of SkAutoTUnref<SkData> for automatically unref-ing a SkData. */
226 typedef SkAutoTUnref<SkData> SkAutoDataUnref; 228 typedef SkAutoTUnref<SkData> SkAutoDataUnref;
227 #endif 229 #endif
228 230
229 #endif 231 #endif
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698