Chromium Code Reviews| Index: third_party/WebKit/Source/core/loader/FrameClientHintsPreferencesContext.h |
| diff --git a/third_party/WebKit/Source/core/loader/FrameClientHintsPreferencesContext.h b/third_party/WebKit/Source/core/loader/FrameClientHintsPreferencesContext.h |
| new file mode 100644 |
| index 0000000000000000000000000000000000000000..ac9e015fe97fba6d75c9d92f0d100ae6a2ed393d |
| --- /dev/null |
| +++ b/third_party/WebKit/Source/core/loader/FrameClientHintsPreferencesContext.h |
| @@ -0,0 +1,32 @@ |
| +// Copyright 2016 The Chromium Authors. All rights reserved. |
| +// Use of this source code is governed by a BSD-style license that can be |
| +// found in the LICENSE file. |
| + |
| +#ifndef FrameClientHintsPreferencesContext_h |
| +#define FrameClientHintsPreferencesContext_h |
| + |
| +#include "core/fetch/ClientHintsPreferences.h" |
| +#include "core/frame/Frame.h" |
| +#include "platform/heap/Persistent.h" |
| +#include "wtf/Allocator.h" |
| + |
| +namespace blink { |
| + |
| +class FrameClientHintsPreferencesContext |
|
yhirano
2016/12/08 07:47:12
+final
tyoshino (SeeGerritForStatus)
2016/12/09 09:43:24
Done.
|
| + : public ClientHintsPreferences::Context { |
| + STACK_ALLOCATED(); |
| + |
| + public: |
| + explicit FrameClientHintsPreferencesContext(Frame*); |
| + |
| + void countClientHintsDPR() override; |
| + void countClientHintsResourceWidth() override; |
| + void countClientHintsViewportWidth() override; |
| + |
| + private: |
| + Persistent<Frame> m_frame; |
|
yhirano
2016/12/08 07:47:12
I think a STACK_ALLOCATED class can have an onheap
tyoshino (SeeGerritForStatus)
2016/12/09 09:43:24
Tried, but it seems we can't.
../../third_party/W
tyoshino (SeeGerritForStatus)
2016/12/09 09:46:38
Sorry I misunderstood the suggestion. Done
|
| +}; |
| + |
| +} // namespace blink |
| + |
| +#endif // FrameClientHintsPreferencesContext_h |