modules_initializer.h 2.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657
  1. // Copyright (c) 2014 The Chromium Authors. All rights reserved.
  2. // Use of this source code is governed by a BSD-style license that can be
  3. // found in the LICENSE file.
  4. #ifndef THIRD_PARTY_BLINK_RENDERER_MODULES_MODULES_INITIALIZER_H_
  5. #define THIRD_PARTY_BLINK_RENDERER_MODULES_MODULES_INITIALIZER_H_
  6. #include "third_party/blink/renderer/core/core_initializer.h"
  7. #include "third_party/blink/renderer/modules/modules_export.h"
  8. namespace blink {
  9. class MODULES_EXPORT ModulesInitializer : public CoreInitializer {
  10. public:
  11. void Initialize() override;
  12. void RegisterInterfaces(mojo::BinderMap&) override;
  13. protected:
  14. void InitLocalFrame(LocalFrame&) const override;
  15. void OnClearWindowObjectInMainWorld(Document&,
  16. const Settings&) const override;
  17. private:
  18. void InstallSupplements(LocalFrame&) const override;
  19. MediaControls* CreateMediaControls(HTMLMediaElement&,
  20. ShadowRoot&) const override;
  21. PictureInPictureController* CreatePictureInPictureController(
  22. Document&) const override;
  23. void InitInspectorAgentSession(DevToolsSession*,
  24. bool,
  25. InspectorDOMAgent*,
  26. InspectedFrames*,
  27. Page*) const override;
  28. std::unique_ptr<WebMediaPlayer> CreateWebMediaPlayer(
  29. WebLocalFrameClient*,
  30. HTMLMediaElement&,
  31. const WebMediaPlayerSource&,
  32. WebMediaPlayerClient*) const override;
  33. WebRemotePlaybackClient* CreateWebRemotePlaybackClient(
  34. HTMLMediaElement&) const override;
  35. void ProvideModulesToPage(Page&, WebViewClient*) const override;
  36. void ForceNextWebGLContextCreationToFail() const override;
  37. void CollectAllGarbageForAnimationAndPaintWorkletForTesting() const override;
  38. void CloneSessionStorage(
  39. Page* clone_from_page,
  40. const SessionStorageNamespaceId& clone_to_namespace) override;
  41. void DidChangeManifest(LocalFrame&) override;
  42. void NotifyOrientationChanged(LocalFrame&) override;
  43. };
  44. } // namespace blink
  45. #endif // THIRD_PARTY_BLINK_RENDERER_MODULES_MODULES_INITIALIZER_H_