| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef ClientHintsPreferences_h | 5 #ifndef ClientHintsPreferences_h |
| 6 #define ClientHintsPreferences_h | 6 #define ClientHintsPreferences_h |
| 7 | 7 |
| 8 #include "core/CoreExport.h" | 8 #include "core/CoreExport.h" |
| 9 #include "wtf/text/WTFString.h" | 9 #include "wtf/text/WTFString.h" |
| 10 | 10 |
| 11 namespace blink { | 11 namespace blink { |
| 12 | 12 |
| 13 class Document; | 13 class ResourceFetcher; |
| 14 | 14 |
| 15 class ClientHintsPreferences { | 15 class ClientHintsPreferences { |
| 16 public: | 16 public: |
| 17 ClientHintsPreferences() | 17 ClientHintsPreferences() |
| 18 : m_shouldSendDPR(false) | 18 : m_shouldSendDPR(false) |
| 19 , m_shouldSendResourceWidth(false) | 19 , m_shouldSendResourceWidth(false) |
| 20 , m_shouldSendViewportWidth(false) | 20 , m_shouldSendViewportWidth(false) |
| 21 { | 21 { |
| 22 } | 22 } |
| 23 | 23 |
| (...skipping 10 matching lines...) Expand all Loading... |
| 34 bool shouldSendDPR() const { return m_shouldSendDPR; } | 34 bool shouldSendDPR() const { return m_shouldSendDPR; } |
| 35 bool shouldSendResourceWidth() const { return m_shouldSendResourceWidth; } | 35 bool shouldSendResourceWidth() const { return m_shouldSendResourceWidth; } |
| 36 bool shouldSendViewportWidth() const { return m_shouldSendViewportWidth; } | 36 bool shouldSendViewportWidth() const { return m_shouldSendViewportWidth; } |
| 37 | 37 |
| 38 private: | 38 private: |
| 39 bool m_shouldSendDPR; | 39 bool m_shouldSendDPR; |
| 40 bool m_shouldSendResourceWidth; | 40 bool m_shouldSendResourceWidth; |
| 41 bool m_shouldSendViewportWidth; | 41 bool m_shouldSendViewportWidth; |
| 42 }; | 42 }; |
| 43 | 43 |
| 44 CORE_EXPORT void handleAcceptClientHintsHeader(const String& headerValue, Client
HintsPreferences&); | 44 CORE_EXPORT void handleAcceptClientHintsHeader(const String& headerValue, Client
HintsPreferences&, ResourceFetcher*); |
| 45 } // namespace blink | 45 } // namespace blink |
| 46 #endif | 46 #endif |
| 47 | 47 |
| OLD | NEW |