зеркало из https://github.com/mozilla/gecko-dev.git
Bug 617539 - Integrate nsIMarkupDocumentViewer_MOZILLA_2_0_BRANCH back into the main interface; r=smontagu
This commit is contained in:
Родитель
0d2c37b102
Коммит
95e5ecd7d4
|
@ -6937,9 +6937,9 @@ nsDocShell::RestoreFromHistory()
|
|||
mSavingOldViewer = CanSavePresentation(mLoadType, request, doc);
|
||||
}
|
||||
|
||||
nsCOMPtr<nsIMarkupDocumentViewer_MOZILLA_2_0_BRANCH> oldMUDV(
|
||||
nsCOMPtr<nsIMarkupDocumentViewer> oldMUDV(
|
||||
do_QueryInterface(mContentViewer));
|
||||
nsCOMPtr<nsIMarkupDocumentViewer_MOZILLA_2_0_BRANCH> newMUDV(
|
||||
nsCOMPtr<nsIMarkupDocumentViewer> newMUDV(
|
||||
do_QueryInterface(viewer));
|
||||
PRInt32 minFontSize = 0;
|
||||
float textZoom = 1.0f;
|
||||
|
@ -7589,10 +7589,10 @@ nsDocShell::SetupNewViewer(nsIContentViewer * aNewViewer)
|
|||
float pageZoom;
|
||||
PRBool styleDisabled;
|
||||
// |newMUDV| also serves as a flag to set the data from the above vars
|
||||
nsCOMPtr<nsIMarkupDocumentViewer_MOZILLA_2_0_BRANCH> newMUDV;
|
||||
nsCOMPtr<nsIMarkupDocumentViewer> newMUDV;
|
||||
|
||||
if (mContentViewer || parent) {
|
||||
nsCOMPtr<nsIMarkupDocumentViewer_MOZILLA_2_0_BRANCH> oldMUDV;
|
||||
nsCOMPtr<nsIMarkupDocumentViewer> oldMUDV;
|
||||
if (mContentViewer) {
|
||||
// Get any interesting state from old content viewer
|
||||
// XXX: it would be far better to just reuse the document viewer ,
|
||||
|
|
|
@ -52,7 +52,7 @@
|
|||
interface nsIDOMNode;
|
||||
|
||||
|
||||
[scriptable, uuid(00d3454c-e125-4cce-bfec-adfbf0975e05)]
|
||||
[scriptable, uuid(79286cd6-8293-4def-ba26-76422efc3d2a)]
|
||||
interface nsIMarkupDocumentViewer : nsISupports
|
||||
{
|
||||
|
||||
|
@ -146,11 +146,7 @@ interface nsIMarkupDocumentViewer : nsISupports
|
|||
* Use this attribute to access all the Bidi options in one operation
|
||||
*/
|
||||
attribute PRUint32 bidiOptions;
|
||||
};
|
||||
|
||||
[scriptable, uuid(83b28afd-75a7-4d13-9265-625e36861f04)]
|
||||
interface nsIMarkupDocumentViewer_MOZILLA_2_0_BRANCH : nsIMarkupDocumentViewer
|
||||
{
|
||||
/** The minimum font size */
|
||||
attribute long minFontSize;
|
||||
|
||||
|
|
|
@ -290,7 +290,7 @@ private:
|
|||
class DocumentViewerImpl : public nsIDocumentViewer,
|
||||
public nsIContentViewerEdit,
|
||||
public nsIContentViewerFile,
|
||||
public nsIMarkupDocumentViewer_MOZILLA_2_0_BRANCH,
|
||||
public nsIMarkupDocumentViewer,
|
||||
public nsIDocumentViewerPrint
|
||||
|
||||
#ifdef NS_PRINTING
|
||||
|
@ -335,9 +335,6 @@ public:
|
|||
// nsIMarkupDocumentViewer
|
||||
NS_DECL_NSIMARKUPDOCUMENTVIEWER
|
||||
|
||||
// nsIMarkupDocumentViewer_MOZILLA_2_0_BRANCH
|
||||
NS_DECL_NSIMARKUPDOCUMENTVIEWER_MOZILLA_2_0_BRANCH
|
||||
|
||||
#ifdef NS_PRINTING
|
||||
// nsIWebBrowserPrint
|
||||
NS_DECL_NSIWEBBROWSERPRINT
|
||||
|
@ -601,7 +598,6 @@ NS_INTERFACE_MAP_BEGIN(DocumentViewerImpl)
|
|||
NS_INTERFACE_MAP_ENTRY(nsIContentViewer)
|
||||
NS_INTERFACE_MAP_ENTRY(nsIDocumentViewer)
|
||||
NS_INTERFACE_MAP_ENTRY(nsIMarkupDocumentViewer)
|
||||
NS_INTERFACE_MAP_ENTRY(nsIMarkupDocumentViewer_MOZILLA_2_0_BRANCH)
|
||||
NS_INTERFACE_MAP_ENTRY(nsIContentViewerFile)
|
||||
NS_INTERFACE_MAP_ENTRY(nsIContentViewerEdit)
|
||||
NS_INTERFACE_MAP_ENTRY(nsIDocumentViewerPrint)
|
||||
|
@ -2749,7 +2745,7 @@ SetChildTextZoom(nsIMarkupDocumentViewer* aChild, void* aClosure)
|
|||
static void
|
||||
SetChildMinFontSize(nsIMarkupDocumentViewer* aChild, void* aClosure)
|
||||
{
|
||||
nsCOMPtr<nsIMarkupDocumentViewer_MOZILLA_2_0_BRANCH> branch =
|
||||
nsCOMPtr<nsIMarkupDocumentViewer> branch =
|
||||
do_QueryInterface(aChild);
|
||||
branch->SetMinFontSize(NS_PTR_TO_INT32(aClosure));
|
||||
}
|
||||
|
|
|
@ -502,7 +502,7 @@ nsPrintEngine::DoCommonPrint(PRBool aIsPrintPreview,
|
|||
if (aIsPrintPreview) {
|
||||
SetIsCreatingPrintPreview(PR_TRUE);
|
||||
SetIsPrintPreview(PR_TRUE);
|
||||
nsCOMPtr<nsIMarkupDocumentViewer_MOZILLA_2_0_BRANCH> viewer =
|
||||
nsCOMPtr<nsIMarkupDocumentViewer> viewer =
|
||||
do_QueryInterface(mDocViewerPrint);
|
||||
if (viewer) {
|
||||
viewer->SetTextZoom(1.0f);
|
||||
|
|
|
@ -650,7 +650,7 @@ let Content = {
|
|||
},
|
||||
|
||||
_setMinFontSize: function _setMinFontSize(aSize) {
|
||||
let viewer = docShell.contentViewer.QueryInterface(Ci.nsIMarkupDocumentViewer_MOZILLA_2_0_BRANCH);
|
||||
let viewer = docShell.contentViewer.QueryInterface(Ci.nsIMarkupDocumentViewer);
|
||||
if (viewer)
|
||||
viewer.minFontSize = aSize;
|
||||
}
|
||||
|
|
Загрузка…
Ссылка в новой задаче