a82bcc7e3c
* remove printing related things from chromium_src * chore: add printing build flag and patch * fix: include PrintingService on other platforms too * fix: printing_handler is only needed on Windows * fix: format BUILD.gn properly * fix: rename printing build flag to avoid conflict with chromium * fix: place previously missed printing calls behind build flag * fix: accidentally renamed flag in patch file * fix: don't include all printing strings * fix: allow ShowItemInFolder and OpenItem to block, fixing a DCHECK crash * fix: make things compile, some changes got lost while rebasing * fix: remove rogue line from BUILD.gn * chore: update patch description * style: lint fix * chore: use chromium printing buildflag, move node related stuff out of patch * revert: remove ScopedAllowBlockingForTesting call * fix: fix my rebase blooper * fix: re-add header lost during rebase, update patch * fix: add <map> include, tweak the patch a bit * revert: remove rogue diff from patch * fix: clean up after rebase
42 lines
1.1 KiB
C++
42 lines
1.1 KiB
C++
// Copyright (c) 2015 GitHub, Inc.
|
|
// Use of this source code is governed by the MIT license that can be
|
|
// found in the LICENSE file.
|
|
|
|
#ifndef ATOM_UTILITY_ATOM_CONTENT_UTILITY_CLIENT_H_
|
|
#define ATOM_UTILITY_ATOM_CONTENT_UTILITY_CLIENT_H_
|
|
|
|
#include <memory>
|
|
#include <vector>
|
|
|
|
#include "base/compiler_specific.h"
|
|
#include "content/public/utility/content_utility_client.h"
|
|
#include "printing/buildflags/buildflags.h"
|
|
|
|
#if BUILDFLAG(ENABLE_PRINTING) && defined(OS_WIN)
|
|
#include "chrome/utility/printing_handler.h"
|
|
#endif
|
|
|
|
namespace atom {
|
|
|
|
class AtomContentUtilityClient : public content::ContentUtilityClient {
|
|
public:
|
|
AtomContentUtilityClient();
|
|
~AtomContentUtilityClient() override;
|
|
|
|
void UtilityThreadStarted() override;
|
|
bool OnMessageReceived(const IPC::Message& message) override;
|
|
void RegisterServices(StaticServiceMap* services) override;
|
|
|
|
private:
|
|
#if BUILDFLAG(ENABLE_PRINTING) && defined(OS_WIN)
|
|
std::unique_ptr<printing::PrintingHandler> printing_handler_;
|
|
#endif
|
|
|
|
bool elevated_;
|
|
|
|
DISALLOW_COPY_AND_ASSIGN(AtomContentUtilityClient);
|
|
};
|
|
|
|
} // namespace atom
|
|
|
|
#endif // ATOM_UTILITY_ATOM_CONTENT_UTILITY_CLIENT_H_
|