2010-11-17 02:33:56 +03:00
|
|
|
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
2012-05-21 15:12:37 +04:00
|
|
|
/* 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/. */
|
2016-12-01 01:56:00 +03:00
|
|
|
#ifndef nsDeviceContextAndroid_h__
|
|
|
|
#define nsDeviceContextAndroid_h__
|
|
|
|
|
2010-11-17 02:33:56 +03:00
|
|
|
#include "nsIDeviceContextSpec.h"
|
|
|
|
#include "nsCOMPtr.h"
|
|
|
|
|
2015-03-21 19:28:04 +03:00
|
|
|
class nsDeviceContextSpecAndroid final : public nsIDeviceContextSpec {
|
2014-08-26 23:07:59 +04:00
|
|
|
private:
|
|
|
|
~nsDeviceContextSpecAndroid() {}
|
|
|
|
|
2010-11-17 02:33:56 +03:00
|
|
|
public:
|
|
|
|
NS_DECL_ISUPPORTS
|
2013-05-30 22:26:02 +04:00
|
|
|
|
2018-02-09 08:22:43 +03:00
|
|
|
already_AddRefed<PrintTarget> MakePrintTarget() final;
|
2010-11-17 02:33:56 +03:00
|
|
|
|
|
|
|
NS_IMETHOD Init(nsIWidget* aWidget, nsIPrintSettings* aPS,
|
2015-08-15 05:06:20 +03:00
|
|
|
bool aIsPrintPreview) override;
|
2013-07-24 15:48:37 +04:00
|
|
|
NS_IMETHOD BeginDocument(const nsAString& aTitle,
|
2016-01-05 13:08:57 +03:00
|
|
|
const nsAString& aPrintToFileName,
|
2015-08-15 05:06:20 +03:00
|
|
|
int32_t aStartPage, int32_t aEndPage) override;
|
|
|
|
NS_IMETHOD EndDocument() override;
|
|
|
|
NS_IMETHOD BeginPage() override { return NS_OK; }
|
|
|
|
NS_IMETHOD EndPage() override { return NS_OK; }
|
2010-11-17 02:33:56 +03:00
|
|
|
|
|
|
|
private:
|
|
|
|
nsCOMPtr<nsIPrintSettings> mPrintSettings;
|
|
|
|
nsCOMPtr<nsIFile> mTempFile;
|
|
|
|
};
|
2016-12-01 01:56:00 +03:00
|
|
|
#endif // nsDeviceContextAndroid_h__
|