зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1769756 - Remove nsIWebBrowserPrint.currentPrintSettings. r=bobowen
Differential Revision: https://phabricator.services.mozilla.com/D146569
This commit is contained in:
Родитель
0d78c92de8
Коммит
1790ea2686
|
@ -3185,18 +3185,6 @@ nsDocumentViewer::GetDoingPrintPreview(bool* aDoingPrintPreview) {
|
|||
return NS_OK;
|
||||
}
|
||||
|
||||
NS_IMETHODIMP
|
||||
nsDocumentViewer::GetCurrentPrintSettings(
|
||||
nsIPrintSettings** aCurrentPrintSettings) {
|
||||
NS_ENSURE_ARG_POINTER(aCurrentPrintSettings);
|
||||
|
||||
*aCurrentPrintSettings = nullptr;
|
||||
NS_ENSURE_TRUE(mPrintJob, NS_ERROR_FAILURE);
|
||||
|
||||
*aCurrentPrintSettings = mPrintJob->GetCurrentPrintSettings().take();
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
NS_IMETHODIMP
|
||||
nsDocumentViewer::ExitPrintPreview() {
|
||||
NS_ENSURE_TRUE(mPrintJob, NS_ERROR_FAILURE);
|
||||
|
|
|
@ -571,16 +571,6 @@ int32_t nsPrintJob::GetPrintPreviewNumSheets() const {
|
|||
return numSheets;
|
||||
}
|
||||
|
||||
already_AddRefed<nsIPrintSettings> nsPrintJob::GetCurrentPrintSettings() {
|
||||
if (mPrt) {
|
||||
return do_AddRef(mPrt->mPrintSettings);
|
||||
}
|
||||
if (mPrtPreview) {
|
||||
return do_AddRef(mPrtPreview->mPrintSettings);
|
||||
}
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
//-----------------------------------------------------------------
|
||||
//-- Section: Pre-Reflow Methods
|
||||
//-----------------------------------------------------------------
|
||||
|
|
|
@ -129,7 +129,6 @@ class nsPrintJob final : public nsIWebProgressListener,
|
|||
// due to pages having been skipped in a page range or combined into a single
|
||||
// sheet via pages-per-sheet.)
|
||||
int32_t GetPrintPreviewNumSheets() const;
|
||||
already_AddRefed<nsIPrintSettings> GetCurrentPrintSettings();
|
||||
|
||||
// The setters here also update the DocViewer
|
||||
void SetIsPrinting(bool aIsPrinting);
|
||||
|
|
|
@ -46,15 +46,6 @@ interface nsIWebBrowserPrint : nsISupports
|
|||
const short PRINTPREVIEW_HOME = 3;
|
||||
const short PRINTPREVIEW_END = 4;
|
||||
|
||||
/**
|
||||
* Returns a pointer to the PrintSettings object that
|
||||
* that was passed into either "print" or "print preview"
|
||||
*
|
||||
* This enables any consumers of the interface to have access
|
||||
* to the "current" PrintSetting at later points in the execution
|
||||
*/
|
||||
readonly attribute nsIPrintSettings currentPrintSettings;
|
||||
|
||||
/**
|
||||
* Returns whether it is in Print mode
|
||||
*/
|
||||
|
|
Загрузка…
Ссылка в новой задаче