Chromium Code Reviews| Index: third_party/WebKit/Source/modules/navigatorcontentutils/NavigatorContentUtils.h |
| diff --git a/third_party/WebKit/Source/modules/navigatorcontentutils/NavigatorContentUtils.h b/third_party/WebKit/Source/modules/navigatorcontentutils/NavigatorContentUtils.h |
| index 4ee3a807fa9bf6fcca136bedb9111791111d77b6..8ce5b1332dac0b16284ba3899ddc4509ecc48ceb 100644 |
| --- a/third_party/WebKit/Source/modules/navigatorcontentutils/NavigatorContentUtils.h |
| +++ b/third_party/WebKit/Source/modules/navigatorcontentutils/NavigatorContentUtils.h |
| @@ -27,7 +27,7 @@ |
| #ifndef NavigatorContentUtils_h |
| #define NavigatorContentUtils_h |
| -#include "core/frame/LocalFrame.h" |
| +#include "core/frame/Navigator.h" |
| #include "modules/ModulesExport.h" |
| #include "modules/navigatorcontentutils/NavigatorContentUtilsClient.h" |
| #include "platform/Supplementable.h" |
| @@ -37,18 +37,17 @@ |
| namespace blink { |
| class ExceptionState; |
| -class LocalFrame; |
| class Navigator; |
| class MODULES_EXPORT NavigatorContentUtils final |
| : public GarbageCollectedFinalized<NavigatorContentUtils>, |
| - public Supplement<LocalFrame> { |
| + public Supplement<Navigator> { |
| USING_GARBAGE_COLLECTED_MIXIN(NavigatorContentUtils); |
| public: |
| virtual ~NavigatorContentUtils(); |
| - static NavigatorContentUtils* from(LocalFrame&); |
| + static NavigatorContentUtils* from(Navigator&); |
| static const char* supplementName(); |
| static void registerProtocolHandler(Navigator&, |
| @@ -65,7 +64,8 @@ class MODULES_EXPORT NavigatorContentUtils final |
| const String& url, |
| ExceptionState&); |
| - static NavigatorContentUtils* create(NavigatorContentUtilsClient*); |
| + static void provideNavigatorContentUtilsTo(Navigator&, |
|
sof
2017/01/13 07:40:30
rename to provideTo() ?
|
| + NavigatorContentUtilsClient*); |
| DECLARE_VIRTUAL_TRACE(); |
| @@ -74,8 +74,9 @@ class MODULES_EXPORT NavigatorContentUtils final |
| } |
| private: |
| - explicit NavigatorContentUtils(NavigatorContentUtilsClient* client) |
| - : m_client(client) {} |
| + NavigatorContentUtils(Navigator& navigator, |
| + NavigatorContentUtilsClient* client) |
| + : Supplement<Navigator>(navigator), m_client(client) {} |
| NavigatorContentUtilsClient* client() { return m_client.get(); } |