OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2012 Google, Inc. All rights reserved. | 2 * Copyright (C) 2012 Google, 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 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
48 enum DeferOption { NoDefer, LazyLoad, IdleLoad }; | 48 enum DeferOption { NoDefer, LazyLoad, IdleLoad }; |
49 enum OriginRestriction { | 49 enum OriginRestriction { |
50 UseDefaultOriginRestrictionForType, | 50 UseDefaultOriginRestrictionForType, |
51 RestrictToSameOrigin, | 51 RestrictToSameOrigin, |
52 NoOriginRestriction | 52 NoOriginRestriction |
53 }; | 53 }; |
54 enum PlaceholderImageRequestType { | 54 enum PlaceholderImageRequestType { |
55 DisallowPlaceholder = 0, // The requested image must not be a placeholder. | 55 DisallowPlaceholder = 0, // The requested image must not be a placeholder. |
56 AllowPlaceholder, // The image is allowed to be a placeholder. | 56 AllowPlaceholder, // The image is allowed to be a placeholder. |
57 }; | 57 }; |
| 58 // TODO(toyoshim): Consider to define an enum for preload options, and use it |
| 59 // instead of bool in this class, FrameFetchContext, and so on. If it is |
| 60 // reasonable, we try merging m_forPreload and m_linkPreload into one enum |
| 61 // type. See https://crbug.com/675883. |
58 | 62 |
59 struct ResourceWidth { | 63 struct ResourceWidth { |
60 DISALLOW_NEW(); | 64 DISALLOW_NEW(); |
61 float width; | 65 float width; |
62 bool isSet; | 66 bool isSet; |
63 | 67 |
64 ResourceWidth() : width(0), isSet(false) {} | 68 ResourceWidth() : width(0), isSet(false) {} |
65 }; | 69 }; |
66 | 70 |
67 FetchRequest(const ResourceRequest&, | 71 FetchRequest(const ResourceRequest&, |
(...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
154 DeferOption m_defer; | 158 DeferOption m_defer; |
155 OriginRestriction m_originRestriction; | 159 OriginRestriction m_originRestriction; |
156 ResourceWidth m_resourceWidth; | 160 ResourceWidth m_resourceWidth; |
157 ClientHintsPreferences m_clientHintPreferences; | 161 ClientHintsPreferences m_clientHintPreferences; |
158 PlaceholderImageRequestType m_placeholderImageRequestType; | 162 PlaceholderImageRequestType m_placeholderImageRequestType; |
159 }; | 163 }; |
160 | 164 |
161 } // namespace blink | 165 } // namespace blink |
162 | 166 |
163 #endif | 167 #endif |
OLD | NEW |