| Index: chrome/renderer/media/media_iph_impl.h
|
| diff --git a/chrome/renderer/media/media_iph_impl.h b/chrome/renderer/media/media_iph_impl.h
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..f4101b91e78438c05c4486ae45caeb845d6afb3f
|
| --- /dev/null
|
| +++ b/chrome/renderer/media/media_iph_impl.h
|
| @@ -0,0 +1,41 @@
|
| +// Copyright 2017 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 CHROME_RENDERER_MEDIA_MEDIA_IPH_IMPL_H_
|
| +#define CHROME_RENDERER_MEDIA_MEDIA_IPH_IMPL_H_
|
| +
|
| +#include "base/memory/weak_ptr.h"
|
| +#include "chrome/common/media_iph.mojom.h"
|
| +#include "services/service_manager/public/cpp/bind_source_info.h"
|
| +#include "third_party/WebKit/public/web/WebMediaIPH.h"
|
| +
|
| +namespace content {
|
| +class RenderFrame;
|
| +} // namespace content
|
| +
|
| +class MediaIPHImpl : public blink::WebMediaIPH {
|
| + public:
|
| + explicit MediaIPHImpl(content::RenderFrame* render_frame);
|
| + ~MediaIPHImpl() override;
|
| +
|
| + // blink::WebMediaIPH implementation.
|
| + void BindToClient(blink::WebMediaIPHClient*) override;
|
| + void ShowMediaDownloadIPH(const blink::WebRect&) override;
|
| + void HideMediaDownloadIPH() override;
|
| +
|
| + private:
|
| + class MediaIPHDelegateService;
|
| +
|
| + void CreateDelegateService(
|
| + const service_manager::BindSourceInfo& source_info,
|
| + chrome::mojom::MediaIPHDelegateServiceRequest request);
|
| + void IPHWidgetDismissed();
|
| +
|
| + content::RenderFrame* render_frame_;
|
| + bool iph_active_ = false;
|
| + blink::WebMediaIPHClient* client_ = nullptr;
|
| + base::WeakPtrFactory<MediaIPHImpl> weak_factory_;
|
| +};
|
| +
|
| +#endif // CHROME_RENDERER_MEDIA_MEDIA_IPH_IMPL_H_
|
|
|