2015-07-16 23:40:01 +02:00
|
|
|
// Copyright 2014 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.
|
|
|
|
|
|
|
|
#include "libcef/browser/extensions/pdf_web_contents_helper_client.h"
|
|
|
|
|
2020-01-23 22:58:01 +01:00
|
|
|
#include "extensions/browser/guest_view/mime_handler_view/mime_handler_view_guest.h"
|
|
|
|
|
2015-07-16 23:40:01 +02:00
|
|
|
namespace extensions {
|
|
|
|
|
2017-05-17 11:29:28 +02:00
|
|
|
CefPDFWebContentsHelperClient::CefPDFWebContentsHelperClient() {}
|
2015-07-16 23:40:01 +02:00
|
|
|
|
2017-05-17 11:29:28 +02:00
|
|
|
CefPDFWebContentsHelperClient::~CefPDFWebContentsHelperClient() {}
|
2015-07-16 23:40:01 +02:00
|
|
|
|
|
|
|
void CefPDFWebContentsHelperClient::UpdateContentRestrictions(
|
|
|
|
content::WebContents* contents,
|
2017-05-17 11:29:28 +02:00
|
|
|
int content_restrictions) {}
|
2015-07-16 23:40:01 +02:00
|
|
|
|
|
|
|
void CefPDFWebContentsHelperClient::OnPDFHasUnsupportedFeature(
|
2017-05-17 11:29:28 +02:00
|
|
|
content::WebContents* contents) {}
|
2015-07-16 23:40:01 +02:00
|
|
|
|
2017-05-17 11:29:28 +02:00
|
|
|
void CefPDFWebContentsHelperClient::OnSaveURL(content::WebContents* contents) {}
|
2015-07-16 23:40:01 +02:00
|
|
|
|
2019-03-13 22:27:37 +01:00
|
|
|
void CefPDFWebContentsHelperClient::SetPluginCanSave(
|
|
|
|
content::WebContents* contents,
|
2020-01-23 22:58:01 +01:00
|
|
|
bool can_save) {
|
|
|
|
auto* guest_view =
|
|
|
|
extensions::MimeHandlerViewGuest::FromWebContents(contents);
|
|
|
|
if (guest_view)
|
|
|
|
guest_view->SetPluginCanSave(can_save);
|
|
|
|
}
|
2019-03-13 22:27:37 +01:00
|
|
|
|
2015-07-16 23:40:01 +02:00
|
|
|
} // namespace extensions
|