OLD | NEW |
| 1 /* |
| 2 * Copyright 2013 Google Inc. |
| 3 |
| 4 * Use of this source code is governed by a BSD-style license that can be |
| 5 * found in the LICENSE file. |
| 6 */ |
| 7 |
1 #include "SkPdfVariableTextFieldDictionary_autogen.h" | 8 #include "SkPdfVariableTextFieldDictionary_autogen.h" |
2 | 9 |
3 | 10 |
4 #include "SkPdfNativeDoc.h" | 11 #include "SkPdfNativeDoc.h" |
5 SkPdfDictionary* SkPdfVariableTextFieldDictionary::DR(SkPdfNativeDoc* doc) { | 12 SkPdfDictionary* SkPdfVariableTextFieldDictionary::DR(SkPdfNativeDoc* doc) { |
6 SkPdfNativeObject* ret = get("DR", ""); | 13 SkPdfNativeObject* ret = get("DR", ""); |
7 if (doc) {ret = doc->resolveReference(ret);} | 14 if (doc) {ret = doc->resolveReference(ret);} |
8 if ((ret != NULL && ret->isDictionary()) || (doc == NULL && ret != NULL && ret
->isReference())) return (SkPdfDictionary*)ret; | 15 if ((ret != NULL && ret->isDictionary()) || (doc == NULL && ret != NULL && ret
->isReference())) return (SkPdfDictionary*)ret; |
9 // TODO(edisonn): warn about missing required field, assert for known good pdf
s | 16 // TODO(edisonn): warn about missing required field, assert for known good pdf
s |
10 return NULL; | 17 return NULL; |
(...skipping 20 matching lines...) Expand all Loading... |
31 if (doc) {ret = doc->resolveReference(ret);} | 38 if (doc) {ret = doc->resolveReference(ret);} |
32 if ((ret != NULL && ret->isInteger()) || (doc == NULL && ret != NULL && ret->i
sReference())) return ret->intValue(); | 39 if ((ret != NULL && ret->isInteger()) || (doc == NULL && ret != NULL && ret->i
sReference())) return ret->intValue(); |
33 // TODO(edisonn): warn about missing default value for optional fields | 40 // TODO(edisonn): warn about missing default value for optional fields |
34 return 0; | 41 return 0; |
35 } | 42 } |
36 | 43 |
37 bool SkPdfVariableTextFieldDictionary::has_Q() const { | 44 bool SkPdfVariableTextFieldDictionary::has_Q() const { |
38 return get("Q", "") != NULL; | 45 return get("Q", "") != NULL; |
39 } | 46 } |
40 | 47 |
OLD | NEW |