blob: 253e6857d413df247510789d065b9253ef377408 [file] [log] [blame]
// 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.
#include "headless/lib/renderer/headless_print_render_frame_helper_delegate.h"
#include "base/command_line.h"
#include "headless/app/headless_shell_switches.h"
#include "third_party/blink/public/web/web_element.h"
namespace headless {
HeadlessPrintRenderFrameHelperDelegate::
HeadlessPrintRenderFrameHelperDelegate() = default;
HeadlessPrintRenderFrameHelperDelegate::
~HeadlessPrintRenderFrameHelperDelegate() = default;
blink::WebElement HeadlessPrintRenderFrameHelperDelegate::GetPdfElement(
blink::WebLocalFrame* frame) {
return blink::WebElement();
}
bool HeadlessPrintRenderFrameHelperDelegate::IsPrintPreviewEnabled() {
return false;
}
bool HeadlessPrintRenderFrameHelperDelegate::ShouldGenerateTaggedPDF() {
return base::CommandLine::ForCurrentProcess()->HasSwitch(
headless::switches::kExportTaggedPDF);
}
bool HeadlessPrintRenderFrameHelperDelegate::OverridePrint(
blink::WebLocalFrame* frame) {
return false;
}
} // namespace headless