2020-08-07 15:04:26 +03:00
|
|
|
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
|
|
|
/* This Source Code Form is subject to the terms of the Mozilla Public
|
|
|
|
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
|
|
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
|
|
|
|
|
|
|
#ifndef nsPrinterListCUPS_h__
|
|
|
|
#define nsPrinterListCUPS_h__
|
|
|
|
|
|
|
|
#include "nsPrinterListBase.h"
|
|
|
|
#include "nsStringFwd.h"
|
|
|
|
|
2020-12-24 05:49:02 +03:00
|
|
|
namespace mozilla {
|
|
|
|
template <typename T>
|
|
|
|
class Maybe;
|
|
|
|
} // namespace mozilla
|
|
|
|
|
2020-08-07 15:04:26 +03:00
|
|
|
class nsPrinterListCUPS final : public nsPrinterListBase {
|
2020-08-10 01:05:57 +03:00
|
|
|
NS_IMETHOD InitPrintSettingsFromPrinter(const nsAString&,
|
|
|
|
nsIPrintSettings*) final;
|
|
|
|
|
2020-08-10 02:29:59 +03:00
|
|
|
nsTArray<PrinterInfo> Printers() const final;
|
2020-08-10 01:05:57 +03:00
|
|
|
RefPtr<nsIPrinter> CreatePrinter(PrinterInfo) const final;
|
2020-12-24 05:49:02 +03:00
|
|
|
mozilla::Maybe<PrinterInfo> PrinterByName(nsString aPrinterName) const final;
|
|
|
|
mozilla::Maybe<PrinterInfo> PrinterBySystemName(
|
|
|
|
nsString aPrinterName) const final;
|
2020-08-20 14:59:46 +03:00
|
|
|
nsresult SystemDefaultPrinterName(nsAString&) const final;
|
2020-08-07 15:04:26 +03:00
|
|
|
|
|
|
|
private:
|
|
|
|
~nsPrinterListCUPS() override = default;
|
|
|
|
};
|
|
|
|
|
|
|
|
#endif
|