OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2013 Google, Inc. | 2 * Copyright (C) 2013 Google, Inc. |
3 * | 3 * |
4 * This library is free software; you can redistribute it and/or | 4 * This library is free software; you can redistribute it and/or |
5 * modify it under the terms of the GNU Library General Public | 5 * modify it under the terms of the GNU Library General Public |
6 * License as published by the Free Software Foundation; either | 6 * License as published by the Free Software Foundation; either |
7 * version 2 of the License, or (at your option) any later version. | 7 * version 2 of the License, or (at your option) any later version. |
8 * | 8 * |
9 * This library is distributed in the hope that it will be useful, | 9 * This library is distributed in the hope that it will be useful, |
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of | 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of |
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | 11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
12 * Library General Public License for more details. | 12 * Library General Public License for more details. |
13 * | 13 * |
14 * You should have received a copy of the GNU Library General Public License | 14 * You should have received a copy of the GNU Library General Public License |
15 * along with this library; see the file COPYING.LIB. If not, write to | 15 * along with this library; see the file COPYING.LIB. If not, write to |
16 * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, | 16 * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, |
17 * Boston, MA 02110-1301, USA. | 17 * Boston, MA 02110-1301, USA. |
18 * | 18 * |
19 */ | 19 */ |
20 | 20 |
21 #ifndef CustomFontData_h | 21 #ifndef CustomFontData_h |
22 #define CustomFontData_h | 22 #define CustomFontData_h |
23 | 23 |
24 #include "platform/PlatformExport.h" | 24 #include "platform/PlatformExport.h" |
25 #include "wtf/PassRefPtr.h" | 25 #include "wtf/PassRefPtr.h" |
26 #include "wtf/RefCounted.h" | 26 #include "wtf/RefCounted.h" |
27 | 27 |
28 namespace blink { | 28 namespace blink { |
29 | 29 |
30 class SimpleFontData; | |
31 | |
32 class PLATFORM_EXPORT CustomFontData : public RefCounted<CustomFontData> { | 30 class PLATFORM_EXPORT CustomFontData : public RefCounted<CustomFontData> { |
33 public: | 31 public: |
34 static PassRefPtr<CustomFontData> create() { | 32 static PassRefPtr<CustomFontData> create() { |
35 return adoptRef(new CustomFontData()); | 33 return adoptRef(new CustomFontData()); |
36 } | 34 } |
37 | 35 |
38 virtual ~CustomFontData() {} | 36 virtual ~CustomFontData() {} |
39 | 37 |
40 virtual void beginLoadIfNeeded() const {} | 38 virtual void beginLoadIfNeeded() const {} |
41 virtual bool isLoading() const { return false; } | 39 virtual bool isLoading() const { return false; } |
42 virtual bool isLoadingFallback() const { return false; } | 40 virtual bool isLoadingFallback() const { return false; } |
43 virtual bool shouldSkipDrawing() const { return false; } | 41 virtual bool shouldSkipDrawing() const { return false; } |
44 virtual void clearFontFaceSource() {} | 42 virtual void clearFontFaceSource() {} |
45 | 43 |
46 protected: | 44 protected: |
47 CustomFontData() {} | 45 CustomFontData() {} |
48 }; | 46 }; |
49 | 47 |
50 } // namespace blink | 48 } // namespace blink |
51 | 49 |
52 #endif // CustomFontData_h | 50 #endif // CustomFontData_h |
OLD | NEW |