diff --git a/mozilla/accessible/src/atk/nsAccessibleHyperText.cpp b/mozilla/accessible/src/atk/nsAccessibleHyperText.cpp index 1f5d07a410f..29a081d8a84 100644 --- a/mozilla/accessible/src/atk/nsAccessibleHyperText.cpp +++ b/mozilla/accessible/src/atk/nsAccessibleHyperText.cpp @@ -75,7 +75,7 @@ nsAccessibleHyperText::nsAccessibleHyperText(nsIDOMNode* aDomNode, nsIWeakRefere nsIFrame *parentFrame = nsAccessible::GetParentBlockFrame(frame); NS_ASSERTION(parentFrame, "Error: HyperText can't get parent block frame"); if (parentFrame) { - nsCOMPtr presContext; + nsCOMPtr presContext; shell->GetPresContext(getter_AddRefs(presContext)); nsIFrame* childFrame = parentFrame->GetFirstChild(nsnull); PRBool bSave = PR_FALSE; @@ -90,7 +90,7 @@ void nsAccessibleHyperText::Shutdown() mTextChildren = nsnull; } -PRBool nsAccessibleHyperText::GetAllTextChildren(nsIPresContext *aPresContext, nsIFrame *aCurFrame, nsIDOMNode* aNode, PRBool &bSave) +PRBool nsAccessibleHyperText::GetAllTextChildren(nsPresContext *aPresContext, nsIFrame *aCurFrame, nsIDOMNode* aNode, PRBool &bSave) { if (! aCurFrame) return PR_FALSE; diff --git a/mozilla/accessible/src/atk/nsAccessibleHyperText.h b/mozilla/accessible/src/atk/nsAccessibleHyperText.h index 002328ecd53..6c40091ad2b 100644 --- a/mozilla/accessible/src/atk/nsAccessibleHyperText.h +++ b/mozilla/accessible/src/atk/nsAccessibleHyperText.h @@ -65,7 +65,7 @@ protected: nsCOMPtr mTextChildren; PRInt32 mIndex; - PRBool GetAllTextChildren(nsIPresContext *aPresContext, nsIFrame *aCurFrame, nsIDOMNode* aNode, PRBool &bSave); + PRBool GetAllTextChildren(nsPresContext *aPresContext, nsIFrame *aCurFrame, nsIDOMNode* aNode, PRBool &bSave); nsIDOMNode* FindTextNodeByOffset(PRInt32 aOffset, PRInt32& aBeforeLength); nsresult GetTextHelper(EGetTextType aType, nsAccessibleTextBoundary aBoundaryType, PRInt32 aOffset, PRInt32 *aStartOffset, PRInt32 *aEndOffset, nsAString & aText); diff --git a/mozilla/accessible/src/atk/nsAccessibleText.cpp b/mozilla/accessible/src/atk/nsAccessibleText.cpp index 71c53951497..ce6452002ec 100644 --- a/mozilla/accessible/src/atk/nsAccessibleText.cpp +++ b/mozilla/accessible/src/atk/nsAccessibleText.cpp @@ -104,7 +104,7 @@ nsresult nsAccessibleText::GetSelections(nsISelectionController **aSelCon, nsISe // Get the selection and selection controller nsCOMPtr selCon; nsCOMPtr domSel; - nsCOMPtr context; + nsCOMPtr context; shell->GetPresContext(getter_AddRefs(context)); frame->GetSelectionController(context, getter_AddRefs(selCon)); if (selCon) @@ -648,7 +648,7 @@ NS_IMETHODIMP nsAccessibleText::GetCharacterExtents(PRInt32 aOffset, nsIPresShell *shell = doc->GetShellAt(0); NS_ENSURE_TRUE(shell, NS_ERROR_FAILURE); - nsCOMPtr context; + nsCOMPtr context; shell->GetPresContext(getter_AddRefs(context)); NS_ENSURE_TRUE(context, NS_ERROR_FAILURE); diff --git a/mozilla/accessible/src/base/nsAccessNode.cpp b/mozilla/accessible/src/base/nsAccessNode.cpp index ddfada60e9e..bda4d9977cb 100755 --- a/mozilla/accessible/src/base/nsAccessNode.cpp +++ b/mozilla/accessible/src/base/nsAccessNode.cpp @@ -53,7 +53,7 @@ #include "nsIFrame.h" #include "nsIPrefService.h" #include "nsIPrefBranch.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIPresShell.h" #include "nsIServiceManager.h" #include "nsIStringBundle.h" @@ -230,13 +230,13 @@ already_AddRefed nsAccessNode::GetPresShell() return resultShell; } -already_AddRefed nsAccessNode::GetPresContext() +already_AddRefed nsAccessNode::GetPresContext() { nsCOMPtr presShell(GetPresShell()); if (!presShell) { return nsnull; } - nsIPresContext *presContext; + nsPresContext *presContext; presShell->GetPresContext(&presContext); // Addref'd return presContext; } @@ -412,7 +412,7 @@ NS_IMETHODIMP nsAccessNode::GetComputedStyleValue(const nsAString& aPseudoElt, const nsAString& aPropertyName, nsAString& aValue) { nsCOMPtr domElement(do_QueryInterface(mDOMNode)); - nsCOMPtr presContext(GetPresContext()); + nsCOMPtr presContext(GetPresContext()); NS_ENSURE_TRUE(domElement && presContext, NS_ERROR_FAILURE); nsCOMPtr container = presContext->GetContainer(); diff --git a/mozilla/accessible/src/base/nsAccessNode.h b/mozilla/accessible/src/base/nsAccessNode.h index 8cc372879c5..fd032905394 100755 --- a/mozilla/accessible/src/base/nsAccessNode.h +++ b/mozilla/accessible/src/base/nsAccessNode.h @@ -53,7 +53,7 @@ #include "nsInterfaceHashtable.h" class nsIPresShell; -class nsIPresContext; +class nsPresContext; class nsIAccessibleDocument; class nsIFrame; class nsIDOMNodeList; @@ -122,7 +122,7 @@ class nsAccessNode: public nsIAccessNode, public nsPIAccessNode protected: nsresult MakeAccessNode(nsIDOMNode *aNode, nsIAccessNode **aAccessNode); already_AddRefed GetPresShell(); - already_AddRefed GetPresContext(); + already_AddRefed GetPresContext(); already_AddRefed GetDocAccessible(); virtual nsIFrame* GetFrame(); diff --git a/mozilla/accessible/src/base/nsAccessibilityService.cpp b/mozilla/accessible/src/base/nsAccessibilityService.cpp index 27a2f5d4b66..1f5f81d1414 100644 --- a/mozilla/accessible/src/base/nsAccessibilityService.cpp +++ b/mozilla/accessible/src/base/nsAccessibilityService.cpp @@ -65,7 +65,7 @@ #include "nsINameSpaceManager.h" #include "nsIObserverService.h" #include "nsIPluginInstance.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIPresShell.h" #include "nsITextContent.h" #include "nsIWebNavigation.h" @@ -523,7 +523,7 @@ nsAccessibilityService::CreateHTMLCheckboxAccessibleXBL(nsIDOMNode *aNode, nsIAc NS_IMETHODIMP nsAccessibilityService::CreateHTMLComboboxAccessible(nsIDOMNode* aDOMNode, nsISupports* aPresContext, nsIAccessible **_retval) { - nsCOMPtr presContext(do_QueryInterface(aPresContext)); + nsCOMPtr presContext(do_QueryInterface(aPresContext)); NS_ASSERTION(presContext,"Error non prescontext passed to accessible factory!!!"); nsCOMPtr weakShell = @@ -590,7 +590,7 @@ nsAccessibilityService::CreateHTMLGroupboxAccessible(nsISupports *aFrame, nsIAcc NS_IMETHODIMP nsAccessibilityService::CreateHTMLListboxAccessible(nsIDOMNode* aDOMNode, nsISupports* aPresContext, nsIAccessible **_retval) { - nsCOMPtr presContext(do_QueryInterface(aPresContext)); + nsCOMPtr presContext(do_QueryInterface(aPresContext)); NS_ASSERTION(presContext,"Error non prescontext passed to accessible factory!!!"); nsCOMPtr weakShell = @@ -701,7 +701,7 @@ nsAccessibilityService::CreateHTMLSelectOptionAccessible(nsIDOMNode* aDOMNode, nsISupports* aPresContext, nsIAccessible **_retval) { - nsCOMPtr presContext(do_QueryInterface(aPresContext)); + nsCOMPtr presContext(do_QueryInterface(aPresContext)); NS_ASSERTION(presContext,"Error non prescontext passed to accessible factory!!!"); nsCOMPtr weakShell = @@ -839,7 +839,7 @@ nsAccessibilityService::CreateHTMLTextAccessible(nsISupports *aFrame, nsIAccessi return NS_ERROR_FAILURE; nsCOMPtr presShell(do_QueryReferent(weakShell)); - nsCOMPtr presContext; + nsCOMPtr presContext; presShell->GetPresContext(getter_AddRefs(presContext)); nsIFrame* childFrame = parentFrame->GetFirstChild(nsnull); PRInt32 index = 0; diff --git a/mozilla/accessible/src/base/nsAccessible.cpp b/mozilla/accessible/src/base/nsAccessible.cpp index 4850d44a84b..6fed3334187 100644 --- a/mozilla/accessible/src/base/nsAccessible.cpp +++ b/mozilla/accessible/src/base/nsAccessible.cpp @@ -42,7 +42,7 @@ #include "nsIDocument.h" #include "nsIImageDocument.h" #include "nsIPresShell.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIContent.h" #include "nsIFrame.h" #include "nsIScrollableView.h" @@ -514,7 +514,7 @@ PRBool nsAccessible::IsPartiallyVisible(PRBool *aIsOffscreen) return PR_FALSE; } - nsCOMPtr presContext; + nsCOMPtr presContext; shell->GetPresContext(getter_AddRefs(presContext)); if (!presContext) return PR_FALSE; @@ -636,7 +636,7 @@ NS_IMETHODIMP nsAccessible::GetChildAtPoint(PRInt32 tx, PRInt32 ty, nsIAccessibl return NS_ERROR_FAILURE; } -void nsAccessible::GetScreenOrigin(nsIPresContext *aPresContext, nsIFrame *aFrame, nsRect *aRect) +void nsAccessible::GetScreenOrigin(nsPresContext *aPresContext, nsIFrame *aFrame, nsRect *aRect) { aRect->x = aRect->y = 0; @@ -803,7 +803,7 @@ NS_IMETHODIMP nsAccessible::GetBounds(PRInt32 *x, PRInt32 *y, PRInt32 *width, PR // Another frame, same node <- Example // Another frame, same node - nsCOMPtr presContext(GetPresContext()); + nsCOMPtr presContext(GetPresContext()); if (!presContext) { *x = *y = *width = *height = 0; @@ -940,7 +940,7 @@ NS_IMETHODIMP nsAccessible::TakeFocus() if (!content) { return NS_ERROR_FAILURE; } - content->SetFocus(nsCOMPtr(GetPresContext())); + content->SetFocus(nsCOMPtr(GetPresContext())); return NS_OK; } @@ -1418,7 +1418,7 @@ nsresult nsAccessible::GetParentBlockNode(nsIPresShell *aPresShell, nsIDOMNode * if (! parentFrame) return NS_ERROR_FAILURE; - nsCOMPtr presContext; + nsCOMPtr presContext; aPresShell->GetPresContext(getter_AddRefs(presContext)); nsIAtom* frameType = nsnull; while (frame && (frameType = frame->GetType()) != nsAccessibilityAtoms::textFrame) { @@ -1459,7 +1459,7 @@ nsIFrame* nsAccessible::GetParentBlockFrame(nsIFrame *aFrame) return frame; } -PRBool nsAccessible::FindTextFrame(PRInt32 &index, nsIPresContext *aPresContext, nsIFrame *aCurFrame, +PRBool nsAccessible::FindTextFrame(PRInt32 &index, nsPresContext *aPresContext, nsIFrame *aCurFrame, nsIFrame **aFirstTextFrame, const nsIFrame *aTextFrame) // Do a depth-first traversal to find the given text frame(aTextFrame)'s index of the block frame(aCurFrame) // it belongs to, also return the first text frame within the same block. diff --git a/mozilla/accessible/src/base/nsAccessible.h b/mozilla/accessible/src/base/nsAccessible.h index c5aee240dcc..e3cd783ae3f 100644 --- a/mozilla/accessible/src/base/nsAccessible.h +++ b/mozilla/accessible/src/base/nsAccessible.h @@ -79,7 +79,7 @@ public: #ifdef MOZ_ACCESSIBILITY_ATK static nsresult GetParentBlockNode(nsIPresShell *aPresShell, nsIDOMNode *aCurrentNode, nsIDOMNode **aBlockNode); static nsIFrame* GetParentBlockFrame(nsIFrame *aFrame); - static PRBool FindTextFrame(PRInt32 &index, nsIPresContext *aPresContext, nsIFrame *aCurFrame, + static PRBool FindTextFrame(PRInt32 &index, nsPresContext *aPresContext, nsIFrame *aCurFrame, nsIFrame **aFirstTextFrame, const nsIFrame *aTextFrame); #endif @@ -105,7 +105,7 @@ protected: static nsresult GetFullKeyName(const nsAString& aModifierName, const nsAString& aKeyName, nsAString& aStringOut); static nsresult GetTranslatedString(const nsAString& aKey, nsAString& aStringOut); void GetScrollOffset(nsRect *aRect); - void GetScreenOrigin(nsIPresContext *aPresContext, nsIFrame *aFrame, nsRect *aRect); + void GetScreenOrigin(nsPresContext *aPresContext, nsIFrame *aFrame, nsRect *aRect); nsresult AppendFlatStringFromSubtreeRecurse(nsIContent *aContent, nsAString *aFlatString); virtual void CacheChildren(PRBool aWalkAnonContent); diff --git a/mozilla/accessible/src/base/nsBaseWidgetAccessible.cpp b/mozilla/accessible/src/base/nsBaseWidgetAccessible.cpp index b314a7198df..e97f8204f3f 100644 --- a/mozilla/accessible/src/base/nsBaseWidgetAccessible.cpp +++ b/mozilla/accessible/src/base/nsBaseWidgetAccessible.cpp @@ -42,7 +42,7 @@ #include "nsAccessibleWrap.h" #include "nsGUIEvent.h" #include "nsILink.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIPresShell.h" #include "nsIServiceManager.h" @@ -162,7 +162,7 @@ NS_IMPL_ISUPPORTS_INHERITED0(nsLinkableAccessible, nsAccessible) NS_IMETHODIMP nsLinkableAccessible::TakeFocus() { if (IsALink()) { - mLinkContent->SetFocus(nsCOMPtr(GetPresContext())); + mLinkContent->SetFocus(nsCOMPtr(GetPresContext())); } return NS_OK; @@ -244,7 +244,7 @@ NS_IMETHODIMP nsLinkableAccessible::DoAction(PRUint8 index) // Action 0 (default action): Jump to link if (index == eAction_Jump) { if (IsALink()) { - nsCOMPtr presContext(GetPresContext()); + nsCOMPtr presContext(GetPresContext()); if (presContext) { nsMouseEvent linkClickEvent(NS_MOUSE_LEFT_CLICK); @@ -329,7 +329,7 @@ NS_IMETHODIMP nsGenericAccessible::TakeFocus() return NS_ERROR_FAILURE; // Node already shut down } - content->SetFocus(nsCOMPtr(GetPresContext())); + content->SetFocus(nsCOMPtr(GetPresContext())); return NS_OK; } diff --git a/mozilla/accessible/src/base/nsCaretAccessible.cpp b/mozilla/accessible/src/base/nsCaretAccessible.cpp index 92f1e546bab..1ed58a8e420 100644 --- a/mozilla/accessible/src/base/nsCaretAccessible.cpp +++ b/mozilla/accessible/src/base/nsCaretAccessible.cpp @@ -105,7 +105,7 @@ NS_IMETHODIMP nsCaretAccessible::AttachNewSelectionListener(nsIDOMNode *aCurrent nsIFrame *frame = nsnull; presShell->GetPrimaryFrameFor(content, &frame); - nsCOMPtr presContext; + nsCOMPtr presContext; presShell->GetPresContext(getter_AddRefs(presContext)); if (!frame || !presContext) return NS_ERROR_FAILURE; @@ -160,7 +160,7 @@ NS_IMETHODIMP nsCaretAccessible::NotifySelectionChanged(nsIDOMDocument *aDoc, ns nsIAccessibleEvent::EVENT_HIDE, this, nsnull); } - nsCOMPtr presContext; + nsCOMPtr presContext; presShell->GetPresContext(getter_AddRefs(presContext)); nsIViewManager* viewManager = presShell->GetViewManager(); if (!presContext || !viewManager) diff --git a/mozilla/accessible/src/base/nsDocAccessible.cpp b/mozilla/accessible/src/base/nsDocAccessible.cpp index fc6d5adb644..401546a3259 100644 --- a/mozilla/accessible/src/base/nsDocAccessible.cpp +++ b/mozilla/accessible/src/base/nsDocAccessible.cpp @@ -516,7 +516,7 @@ nsresult nsDocAccessible::AddEventListeners() } } - nsCOMPtr context; + nsCOMPtr context; presShell->GetPresContext(getter_AddRefs(context)); NS_ENSURE_TRUE(context, NS_ERROR_FAILURE); diff --git a/mozilla/accessible/src/html/nsHTMLAreaAccessible.cpp b/mozilla/accessible/src/html/nsHTMLAreaAccessible.cpp index a525f23bf5e..5819f14cd7e 100644 --- a/mozilla/accessible/src/html/nsHTMLAreaAccessible.cpp +++ b/mozilla/accessible/src/html/nsHTMLAreaAccessible.cpp @@ -114,7 +114,7 @@ NS_IMETHODIMP nsHTMLAreaAccessible::GetBounds(PRInt32 *x, PRInt32 *y, PRInt32 *w *x = *y = *width = *height = 0; - nsCOMPtr presContext(GetPresContext()); + nsCOMPtr presContext(GetPresContext()); NS_ENSURE_TRUE(presContext, NS_ERROR_FAILURE); nsCOMPtr ourContent(do_QueryInterface(mDOMNode)); diff --git a/mozilla/accessible/src/html/nsHTMLFormControlAccessible.cpp b/mozilla/accessible/src/html/nsHTMLFormControlAccessible.cpp index 718404f0ad0..9de909a5641 100644 --- a/mozilla/accessible/src/html/nsHTMLFormControlAccessible.cpp +++ b/mozilla/accessible/src/html/nsHTMLFormControlAccessible.cpp @@ -353,7 +353,7 @@ NS_IMETHODIMP nsHTMLTextFieldAccessible::GetState(PRUint32 *_retval) nsIFrame *frame = GetFrame(); if (frame) { - nsCOMPtr context(GetPresContext()); + nsCOMPtr context(GetPresContext()); NS_ENSURE_TRUE(context, NS_ERROR_FAILURE); nsCOMPtr selCon; frame->GetSelectionController(context,getter_AddRefs(selCon)); diff --git a/mozilla/accessible/src/html/nsHTMLSelectAccessible.cpp b/mozilla/accessible/src/html/nsHTMLSelectAccessible.cpp index 9adc488cc8a..0b2c6a176d2 100644 --- a/mozilla/accessible/src/html/nsHTMLSelectAccessible.cpp +++ b/mozilla/accessible/src/html/nsHTMLSelectAccessible.cpp @@ -113,7 +113,7 @@ void nsHTMLSelectableAccessible::iterator::CalcSelectionCount(PRInt32 *aSelectio void nsHTMLSelectableAccessible::iterator::AddAccessibleIfSelected(nsIAccessibilityService *aAccService, nsIMutableArray *aSelectedAccessibles, - nsIPresContext *aContext) + nsPresContext *aContext) { PRBool isSelected = PR_FALSE; nsCOMPtr tempAccess; @@ -132,7 +132,7 @@ void nsHTMLSelectableAccessible::iterator::AddAccessibleIfSelected(nsIAccessibil PRBool nsHTMLSelectableAccessible::iterator::GetAccessibleIfSelected(PRInt32 aIndex, nsIAccessibilityService *aAccService, - nsIPresContext *aContext, + nsPresContext *aContext, nsIAccessible **aAccessible) { PRBool isSelected = PR_FALSE; @@ -211,7 +211,7 @@ NS_IMETHODIMP nsHTMLSelectableAccessible::GetSelectedChildren(nsIArray **_retval if (!selectedAccessibles) return NS_ERROR_OUT_OF_MEMORY; - nsCOMPtr context(GetPresContext()); + nsCOMPtr context(GetPresContext()); if (!context) return NS_ERROR_FAILURE; @@ -237,7 +237,7 @@ NS_IMETHODIMP nsHTMLSelectableAccessible::RefSelection(PRInt32 aIndex, nsIAccess if (!accService) return NS_ERROR_FAILURE; - nsCOMPtr context(GetPresContext()); + nsCOMPtr context(GetPresContext()); if (!context) return NS_ERROR_FAILURE; @@ -1098,7 +1098,7 @@ NS_IMETHODIMP nsHTMLComboboxButtonAccessible::GetNumActions(PRUint8 *aNumActions NS_IMETHODIMP nsHTMLComboboxButtonAccessible::DoAction(PRUint8 aIndex) { nsIFrame* frame = nsAccessible::GetBoundsFrame(); - nsCOMPtr context(GetPresContext()); + nsCOMPtr context(GetPresContext()); if (!frame || !context) return NS_ERROR_FAILURE; @@ -1158,7 +1158,7 @@ void nsHTMLComboboxButtonAccessible::GetBoundsRect(nsRect& aBounds, nsIFrame** a // bounding frame is the ComboboxControlFrame nsIFrame *frame = nsAccessible::GetBoundsFrame(); *aBoundingFrame = frame; - nsCOMPtr context(GetPresContext()); + nsCOMPtr context(GetPresContext()); if (!frame || !context) return; diff --git a/mozilla/accessible/src/html/nsHTMLSelectAccessible.h b/mozilla/accessible/src/html/nsHTMLSelectAccessible.h index 8f6742be255..fcfff6fedad 100644 --- a/mozilla/accessible/src/html/nsHTMLSelectAccessible.h +++ b/mozilla/accessible/src/html/nsHTMLSelectAccessible.h @@ -104,8 +104,8 @@ protected: void Select(PRBool aSelect); void AddAccessibleIfSelected(nsIAccessibilityService *aAccService, nsIMutableArray *aSelectedAccessibles, - nsIPresContext *aContext); - PRBool GetAccessibleIfSelected(PRInt32 aIndex, nsIAccessibilityService *aAccService, nsIPresContext *aContext, nsIAccessible **_retval); + nsPresContext *aContext); + PRBool GetAccessibleIfSelected(PRInt32 aIndex, nsIAccessibilityService *aAccService, nsPresContext *aContext, nsIAccessible **_retval); PRBool Advance(); }; diff --git a/mozilla/accessible/src/html/nsHTMLTextAccessible.cpp b/mozilla/accessible/src/html/nsHTMLTextAccessible.cpp index b7842376b5c..23d4ef34277 100644 --- a/mozilla/accessible/src/html/nsHTMLTextAccessible.cpp +++ b/mozilla/accessible/src/html/nsHTMLTextAccessible.cpp @@ -42,7 +42,7 @@ #include "nsBulletFrame.h" #include "nsIAccessibleDocument.h" #include "nsIFrame.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIPresShell.h" #include "nsISelection.h" #include "nsISelectionController.h" @@ -82,7 +82,7 @@ NS_IMETHODIMP nsHTMLTextAccessible::GetState(PRUint32 *aState) return NS_ERROR_FAILURE; } - nsCOMPtr context; + nsCOMPtr context; shell->GetPresContext(getter_AddRefs(context)); nsCOMPtr content(do_QueryInterface(mDOMNode)); nsIFrame *frame = nsnull; diff --git a/mozilla/accessible/src/msaa/nsTextAccessibleWrap.cpp b/mozilla/accessible/src/msaa/nsTextAccessibleWrap.cpp index 269cccdd244..1851a697e26 100755 --- a/mozilla/accessible/src/msaa/nsTextAccessibleWrap.cpp +++ b/mozilla/accessible/src/msaa/nsTextAccessibleWrap.cpp @@ -44,7 +44,7 @@ #include "nsIAccessibleDocument.h" #include "nsIDOMRange.h" #include "nsIFrame.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIPresShell.h" #include "nsIRenderingContext.h" #include "nsISelection.h" @@ -172,7 +172,7 @@ STDMETHODIMP nsTextAccessibleWrap::scrollToSubstring( return E_FAIL; // This accessible has been shut down } - nsCOMPtr presContext; + nsCOMPtr presContext; presShell->GetPresContext(getter_AddRefs(presContext)); nsCOMPtr scrollToRange = do_CreateInstance(kRangeCID); nsCOMPtr selCon; @@ -200,7 +200,7 @@ STDMETHODIMP nsTextAccessibleWrap::scrollToSubstring( } nsIFrame* nsTextAccessibleWrap::GetPointFromOffset(nsIFrame *aContainingFrame, - nsIPresContext *aPresContext, + nsPresContext *aPresContext, nsIRenderingContext *aRendContext, PRInt32 aOffset, nsPoint& aOutPoint) @@ -226,7 +226,7 @@ nsresult nsTextAccessibleWrap::GetCharacterExtents(PRInt32 aStartOffset, PRInt32 nsCOMPtr presShell(GetPresShell()); NS_ENSURE_TRUE(presShell, NS_ERROR_FAILURE); - nsCOMPtr presContext; + nsCOMPtr presContext; presShell->GetPresContext(getter_AddRefs(presContext)); NS_ENSURE_TRUE(presContext, NS_ERROR_FAILURE); float t2p = presContext->TwipsToPixels(); diff --git a/mozilla/accessible/src/msaa/nsTextAccessibleWrap.h b/mozilla/accessible/src/msaa/nsTextAccessibleWrap.h index 1b7698395f6..5c44401bc9b 100755 --- a/mozilla/accessible/src/msaa/nsTextAccessibleWrap.h +++ b/mozilla/accessible/src/msaa/nsTextAccessibleWrap.h @@ -45,7 +45,7 @@ #include "nsRect.h" class nsIFrame; -class nsIPresContext; +class nsPresContext; class nsIRenderingContext; class nsTextAccessibleWrap : public nsTextAccessible, @@ -89,7 +89,7 @@ class nsTextAccessibleWrap : public nsTextAccessible, PRInt32* aWidth, PRInt32* aHeight); // Return child frame containing offset on success - nsIFrame* GetPointFromOffset(nsIFrame *aContainingFrame, nsIPresContext *aPresContext, + nsIFrame* GetPointFromOffset(nsIFrame *aContainingFrame, nsPresContext *aPresContext, nsIRenderingContext *aRenderingContext, PRInt32 aOffset, nsPoint& aOutPoint); }; diff --git a/mozilla/content/base/public/nsIContent.h b/mozilla/content/base/public/nsIContent.h index cf9d92c61dc..a5a003f5118 100644 --- a/mozilla/content/base/public/nsIContent.h +++ b/mozilla/content/base/public/nsIContent.h @@ -47,7 +47,7 @@ // Forward declarations class nsIAtom; class nsIDocument; -class nsIPresContext; +class nsPresContext; class nsVoidArray; class nsIDOMEvent; class nsIContent; @@ -379,7 +379,7 @@ public: * @param aEventStatus the status returned from the function. Generally * nsEventStatus_eIgnore */ - virtual nsresult HandleDOMEvent(nsIPresContext* aPresContext, + virtual nsresult HandleDOMEvent(nsPresContext* aPresContext, nsEvent* aEvent, nsIDOMEvent** aDOMEvent, PRUint32 aFlags, nsEventStatus* aEventStatus) = 0; @@ -416,7 +416,7 @@ public: * @param aPresContext the pres context * @see nsGenericHTMLElement::SetElementFocus() */ - virtual void SetFocus(nsIPresContext* aPresContext) + virtual void SetFocus(nsPresContext* aPresContext) { } @@ -431,7 +431,7 @@ public: * @param aPresContext the pres context * @see nsGenericHTMLElement::SetElementFocus() */ - virtual void RemoveFocus(nsIPresContext* aPresContext) + virtual void RemoveFocus(nsPresContext* aPresContext) { } diff --git a/mozilla/content/base/public/nsIDocument.h b/mozilla/content/base/public/nsIDocument.h index 9c75da3dc86..a9876bc6ee0 100644 --- a/mozilla/content/base/public/nsIDocument.h +++ b/mozilla/content/base/public/nsIDocument.h @@ -55,7 +55,7 @@ class nsIAtom; class nsIContent; -class nsIPresContext; +class nsPresContext; class nsIPresShell; class nsIStreamListener; @@ -296,7 +296,7 @@ public: * presentation context (presentation contexts must not be * shared among multiple presentation shells). */ - virtual nsresult CreateShell(nsIPresContext* aContext, + virtual nsresult CreateShell(nsPresContext* aContext, nsIViewManager* aViewManager, nsStyleSet* aStyleSet, nsIPresShell** aInstancePtrResult) = 0; @@ -517,7 +517,7 @@ public: virtual void StyleRuleRemoved(nsIStyleSheet* aStyleSheet, nsIStyleRule* aStyleRule) = 0; - virtual nsresult HandleDOMEvent(nsIPresContext* aPresContext, + virtual nsresult HandleDOMEvent(nsPresContext* aPresContext, nsEvent* aEvent, nsIDOMEvent** aDOMEvent, PRUint32 aFlags, nsEventStatus* aEventStatus) = 0; diff --git a/mozilla/content/base/public/nsIDocumentViewer.h b/mozilla/content/base/public/nsIDocumentViewer.h index 53603dc48a3..7b3629aff85 100644 --- a/mozilla/content/base/public/nsIDocumentViewer.h +++ b/mozilla/content/base/public/nsIDocumentViewer.h @@ -40,7 +40,7 @@ #include "nsIContentViewer.h" class nsIDocument; -class nsIPresContext; +class nsPresContext; class nsIPresShell; class nsIStyleSheet; @@ -62,9 +62,9 @@ public: NS_IMETHOD GetPresShell(nsIPresShell** aResult) = 0; - NS_IMETHOD GetPresContext(nsIPresContext** aResult) = 0; + NS_IMETHOD GetPresContext(nsPresContext** aResult) = 0; - NS_IMETHOD CreateDocumentViewerUsing(nsIPresContext* aPresContext, + NS_IMETHOD CreateDocumentViewerUsing(nsPresContext* aPresContext, nsIDocumentViewer** aResult) = 0; }; diff --git a/mozilla/content/base/public/nsIStyleRule.h b/mozilla/content/base/public/nsIStyleRule.h index 6c73c818efd..f45b83ae567 100644 --- a/mozilla/content/base/public/nsIStyleRule.h +++ b/mozilla/content/base/public/nsIStyleRule.h @@ -42,7 +42,7 @@ #include "nsISupports.h" class nsIStyleSheet; -class nsIPresContext; +class nsPresContext; class nsIContent; struct nsRuleData; diff --git a/mozilla/content/base/public/nsIStyleRuleProcessor.h b/mozilla/content/base/public/nsIStyleRuleProcessor.h index 6a54a626481..81e321cbf4a 100644 --- a/mozilla/content/base/public/nsIStyleRuleProcessor.h +++ b/mozilla/content/base/public/nsIStyleRuleProcessor.h @@ -40,13 +40,13 @@ #include #include "nsISupports.h" -#include "nsIPresContext.h" // for nsCompatability +#include "nsPresContext.h" // for nsCompatability #include "nsILinkHandler.h" #include "nsString.h" #include "nsChangeHint.h" class nsIStyleSheet; -class nsIPresContext; +class nsPresContext; class nsIContent; class nsIStyledContent; class nsISupportsArray; @@ -58,7 +58,7 @@ class nsRuleWalker; // nsCSSStyleSheet.cpp. struct RuleProcessorData { - RuleProcessorData(nsIPresContext* aPresContext, + RuleProcessorData(nsPresContext* aPresContext, nsIContent* aContent, nsRuleWalker* aRuleWalker, nsCompatibility* aCompat = nsnull); @@ -66,17 +66,17 @@ struct RuleProcessorData { // NOTE: not |virtual| ~RuleProcessorData(); - void* operator new(size_t sz, nsIPresContext* aContext) CPP_THROW_NEW { + void* operator new(size_t sz, nsPresContext* aContext) CPP_THROW_NEW { return aContext->AllocateFromShell(sz); } - void Destroy(nsIPresContext* aContext) { + void Destroy(nsPresContext* aContext) { this->~RuleProcessorData(); aContext->FreeToShell(sizeof(RuleProcessorData), this); }; const nsString* GetLang(); - nsIPresContext* mPresContext; + nsPresContext* mPresContext; nsIContent* mContent; // weak ref nsIContent* mParentContent; // if content, content->GetParent(); weak ref nsRuleWalker* mRuleWalker; // Used to add rules to our results. @@ -102,7 +102,7 @@ protected: }; struct ElementRuleProcessorData : public RuleProcessorData { - ElementRuleProcessorData(nsIPresContext* aPresContext, + ElementRuleProcessorData(nsPresContext* aPresContext, nsIContent* aContent, nsRuleWalker* aRuleWalker) : RuleProcessorData(aPresContext,aContent,aRuleWalker) @@ -113,7 +113,7 @@ struct ElementRuleProcessorData : public RuleProcessorData { }; struct PseudoRuleProcessorData : public RuleProcessorData { - PseudoRuleProcessorData(nsIPresContext* aPresContext, + PseudoRuleProcessorData(nsPresContext* aPresContext, nsIContent* aParentContent, nsIAtom* aPseudoTag, nsICSSPseudoComparator* aComparator, @@ -131,7 +131,7 @@ struct PseudoRuleProcessorData : public RuleProcessorData { }; struct StateRuleProcessorData : public RuleProcessorData { - StateRuleProcessorData(nsIPresContext* aPresContext, + StateRuleProcessorData(nsPresContext* aPresContext, nsIContent* aContent, PRInt32 aStateMask) : RuleProcessorData(aPresContext, aContent, nsnull), @@ -144,7 +144,7 @@ struct StateRuleProcessorData : public RuleProcessorData { }; struct AttributeRuleProcessorData : public RuleProcessorData { - AttributeRuleProcessorData(nsIPresContext* aPresContext, + AttributeRuleProcessorData(nsPresContext* aPresContext, nsIContent* aContent, nsIAtom* aAttribute, PRInt32 aModType) diff --git a/mozilla/content/base/public/nsIStyleSheet.h b/mozilla/content/base/public/nsIStyleSheet.h index 3827372b54b..2deca98e518 100644 --- a/mozilla/content/base/public/nsIStyleSheet.h +++ b/mozilla/content/base/public/nsIStyleSheet.h @@ -45,7 +45,7 @@ class nsString; class nsIURI; class nsIStyleRule; class nsISupportsArray; -class nsIPresContext; +class nsPresContext; class nsIContent; class nsIDocument; class nsIStyleRuleProcessor; diff --git a/mozilla/content/base/src/nsContentAreaDragDrop.cpp b/mozilla/content/base/src/nsContentAreaDragDrop.cpp index 7e4f97460c9..af7fcea78d2 100644 --- a/mozilla/content/base/src/nsContentAreaDragDrop.cpp +++ b/mozilla/content/base/src/nsContentAreaDragDrop.cpp @@ -87,7 +87,7 @@ #include "nsIImage.h" #include "nsIDocument.h" #include "nsIPresShell.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIScriptGlobalObject.h" #include "nsIDocShellTreeItem.h" #include "nsIFrame.h" diff --git a/mozilla/content/base/src/nsContentAreaDragDrop.h b/mozilla/content/base/src/nsContentAreaDragDrop.h index 826296ca5d2..ba7e48b9e87 100644 --- a/mozilla/content/base/src/nsContentAreaDragDrop.h +++ b/mozilla/content/base/src/nsContentAreaDragDrop.h @@ -52,7 +52,7 @@ class nsISelection; class nsITransferable; class nsIImage; class nsIPresShell; -class nsIPresContext; +class nsPresContext; class nsIContent; class nsIDocument; class nsIURI; diff --git a/mozilla/content/base/src/nsContentIterator.cpp b/mozilla/content/base/src/nsContentIterator.cpp index 80b4b4d4123..0eecda7f732 100644 --- a/mozilla/content/base/src/nsContentIterator.cpp +++ b/mozilla/content/base/src/nsContentIterator.cpp @@ -50,7 +50,7 @@ #include "nsISupportsArray.h" #include "nsIFocusTracker.h" #include "nsCOMPtr.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIComponentManager.h" #include "nsContentCID.h" #include "nsLayoutCID.h" diff --git a/mozilla/content/base/src/nsContentSink.cpp b/mozilla/content/base/src/nsContentSink.cpp index b55ab7968ef..0cbe0abbe24 100644 --- a/mozilla/content/base/src/nsContentSink.cpp +++ b/mozilla/content/base/src/nsContentSink.cpp @@ -55,7 +55,7 @@ #include "nsIParser.h" #include "nsContentErrors.h" #include "nsIPresShell.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIViewManager.h" #include "nsIScrollableView.h" #include "nsIContentViewer.h" @@ -942,7 +942,7 @@ nsContentSink::StartLayout(PRBool aIsFrameset) shell->BeginObservingDocument(); // Resize-reflow this time - nsCOMPtr cx; + nsCOMPtr cx; shell->GetPresContext(getter_AddRefs(cx)); nsRect r = cx->GetVisibleArea(); shell->InitialReflow(r.width, r.height); diff --git a/mozilla/content/base/src/nsDocument.cpp b/mozilla/content/base/src/nsDocument.cpp index b499b6ed9b7..b4412aea1a6 100644 --- a/mozilla/content/base/src/nsDocument.cpp +++ b/mozilla/content/base/src/nsDocument.cpp @@ -79,7 +79,7 @@ #include "nsDOMError.h" #include "nsIScrollableView.h" #include "nsIPresShell.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsContentUtils.h" #include "nsNodeInfoManager.h" #include "nsIXBLService.h" @@ -397,7 +397,7 @@ nsDOMImplementation::CreateDocument(const nsAString& aNamespaceURI, nsIDocShell *docShell = nsContentUtils::GetDocShellFromCaller(); if (docShell) { - nsCOMPtr presContext; + nsCOMPtr presContext; docShell->GetPresContext(getter_AddRefs(presContext)); if (presContext) { nsCOMPtr container = presContext->GetContainer(); @@ -1268,7 +1268,7 @@ nsDocument::TryChannelCharset(nsIChannel *aChannel, } nsresult -nsDocument::CreateShell(nsIPresContext* aContext, nsIViewManager* aViewManager, +nsDocument::CreateShell(nsPresContext* aContext, nsIViewManager* aViewManager, nsStyleSet* aStyleSet, nsIPresShell** aInstancePtrResult) { @@ -1280,7 +1280,7 @@ nsDocument::CreateShell(nsIPresContext* aContext, nsIViewManager* aViewManager, } nsresult -nsDocument::doCreateShell(nsIPresContext* aContext, +nsDocument::doCreateShell(nsPresContext* aContext, nsIViewManager* aViewManager, nsStyleSet* aStyleSet, nsCompatibility aCompatMode, nsIPresShell** aInstancePtrResult) @@ -1995,7 +1995,7 @@ nsDocument::EndLoad() nsIPresShell *shell = ancestor_doc->GetShellAt(0); if (shell) { - nsCOMPtr context; + nsCOMPtr context; shell->GetPresContext(getter_AddRefs(context)); if (context) { @@ -2788,7 +2788,7 @@ nsDocument::GetDefaultView(nsIDOMAbstractView** aDefaultView) mPresShells.ElementAt(0)); NS_ENSURE_TRUE(shell, NS_OK); - nsCOMPtr ctx; + nsCOMPtr ctx; nsresult rv = shell->GetPresContext(getter_AddRefs(ctx)); NS_ENSURE_TRUE(NS_SUCCEEDED(rv) && ctx, rv); @@ -2833,7 +2833,7 @@ nsDocument::SetTitle(const nsAString& aTitle) nsCOMPtr shell = NS_STATIC_CAST(nsIPresShell*, mPresShells[i]); - nsCOMPtr context; + nsCOMPtr context; nsresult rv = shell->GetPresContext(getter_AddRefs(context)); NS_ENSURE_SUCCESS(rv, rv); @@ -2986,7 +2986,7 @@ nsDocument::GetDir(nsAString& aDirection) { nsCOMPtr shell = (nsIPresShell*)mPresShells.SafeElementAt(0); if (shell) { - nsCOMPtr context; + nsCOMPtr context; shell->GetPresContext(getter_AddRefs(context)); if (context) { PRUint32 options = context->GetBidi(); @@ -3017,7 +3017,7 @@ nsDocument::SetDir(const nsAString& aDirection) return NS_OK; } - nsCOMPtr context; + nsCOMPtr context; shell->GetPresContext(getter_AddRefs(context)); NS_ENSURE_TRUE(context, NS_ERROR_UNEXPECTED); @@ -3788,7 +3788,7 @@ nsDocument::GetSystemEventGroup(nsIDOMEventGroup **aGroup) } nsresult -nsDocument::HandleDOMEvent(nsIPresContext* aPresContext, nsEvent* aEvent, +nsDocument::HandleDOMEvent(nsPresContext* aPresContext, nsEvent* aEvent, nsIDOMEvent** aDOMEvent, PRUint32 aFlags, nsEventStatus* aEventStatus) { @@ -3920,7 +3920,7 @@ nsDocument::DispatchEvent(nsIDOMEvent* aEvent, PRBool *_retval) return NS_ERROR_FAILURE; // Retrieve the context - nsCOMPtr presContext; + nsCOMPtr presContext; shell->GetPresContext(getter_AddRefs(presContext)); return presContext->EventStateManager()-> @@ -3984,7 +3984,7 @@ nsDocument::CreateEvent(const nsAString& aEventType, nsIDOMEvent** aReturn) // Obtain a presentation context nsIPresShell *shell = GetShellAt(0); - nsCOMPtr presContext; + nsCOMPtr presContext; if (shell) { // Retrieve the context diff --git a/mozilla/content/base/src/nsDocument.h b/mozilla/content/base/src/nsDocument.h index 4232aa746d4..75e8a456cc5 100644 --- a/mozilla/content/base/src/nsDocument.h +++ b/mozilla/content/base/src/nsDocument.h @@ -279,7 +279,7 @@ public: * it's presentation context (presentation context's must not be * shared among multiple presentation shell's). */ - virtual nsresult CreateShell(nsIPresContext* aContext, + virtual nsresult CreateShell(nsPresContext* aContext, nsIViewManager* aViewManager, nsStyleSet* aStyleSet, nsIPresShell** aInstancePtrResult); @@ -416,7 +416,7 @@ public: nsAString& Standalone); virtual PRBool IsScriptEnabled(); - virtual nsresult HandleDOMEvent(nsIPresContext* aPresContext, + virtual nsresult HandleDOMEvent(nsPresContext* aPresContext, nsEvent* aEvent, nsIDOMEvent** aDOMEvent, PRUint32 aFlags, nsEventStatus* aEventStatus); @@ -516,7 +516,7 @@ protected: PRInt32& aCharsetSource, nsACString& aCharset); - nsresult doCreateShell(nsIPresContext* aContext, + nsresult doCreateShell(nsPresContext* aContext, nsIViewManager* aViewManager, nsStyleSet* aStyleSet, nsCompatibility aCompatMode, nsIPresShell** aInstancePtrResult); diff --git a/mozilla/content/base/src/nsDocumentFragment.cpp b/mozilla/content/base/src/nsDocumentFragment.cpp index 670350f41eb..0b61d7f6453 100644 --- a/mozilla/content/base/src/nsDocumentFragment.cpp +++ b/mozilla/content/base/src/nsDocumentFragment.cpp @@ -155,7 +155,7 @@ public: *aPrefix = nsnull; return NS_ERROR_ILLEGAL_VALUE; } - virtual nsresult HandleDOMEvent(nsIPresContext* aPresContext, + virtual nsresult HandleDOMEvent(nsPresContext* aPresContext, nsEvent* aEvent, nsIDOMEvent** aDOMEvent, PRUint32 aFlags, nsEventStatus* aEventStatus) { diff --git a/mozilla/content/base/src/nsDocumentViewer.cpp b/mozilla/content/base/src/nsDocumentViewer.cpp index 31dcfe734fe..88279ed822b 100644 --- a/mozilla/content/base/src/nsDocumentViewer.cpp +++ b/mozilla/content/base/src/nsDocumentViewer.cpp @@ -50,7 +50,7 @@ #include "nsIDocumentViewerPrint.h" #include "nsIDocument.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIPresShell.h" #include "nsStyleSet.h" #include "nsIStyleSheet.h" @@ -308,7 +308,7 @@ class DocumentViewerImpl : public nsIDocumentViewer, friend class nsPrintEngine; public: - DocumentViewerImpl(nsIPresContext* aPresContext); + DocumentViewerImpl(nsPresContext* aPresContext); NS_DECL_AND_IMPL_ZEROING_OPERATOR_NEW @@ -322,8 +322,8 @@ public: NS_IMETHOD SetUAStyleSheet(nsIStyleSheet* aUAStyleSheet); NS_IMETHOD GetDocument(nsIDocument** aResult); NS_IMETHOD GetPresShell(nsIPresShell** aResult); - NS_IMETHOD GetPresContext(nsIPresContext** aResult); - NS_IMETHOD CreateDocumentViewerUsing(nsIPresContext* aPresContext, + NS_IMETHOD GetPresContext(nsPresContext** aResult); + NS_IMETHOD CreateDocumentViewerUsing(nsPresContext* aPresContext, nsIDocumentViewer** aResult); // nsIContentViewerEdit @@ -390,7 +390,7 @@ protected: nsCOMPtr mDocument; nsCOMPtr mWindow; // ??? should we really own it? nsCOMPtr mViewManager; - nsCOMPtr mPresContext; + nsCOMPtr mPresContext; nsCOMPtr mPresShell; nsCOMPtr mUAStyleSheet; @@ -495,7 +495,7 @@ void DocumentViewerImpl::PrepareToStartLoad() } // Note: operator new zeros our memory, so no need to init things to null. -DocumentViewerImpl::DocumentViewerImpl(nsIPresContext* aPresContext) +DocumentViewerImpl::DocumentViewerImpl(nsPresContext* aPresContext) : mPresContext(aPresContext), mHintCharsetSource(kCharsetUninitialized), mAllowPlugins(PR_TRUE), @@ -790,9 +790,9 @@ DocumentViewerImpl::InitInternal(nsIWidget* aParentWidget, if (aDoCreation) { if (aParentWidget && !mPresContext) { // Create presentation context - mPresContext = new nsIPresContext(GetIsCreatingPrintPreview() ? - nsIPresContext::eContext_PrintPreview : - nsIPresContext::eContext_Galley); + mPresContext = new nsPresContext(GetIsCreatingPrintPreview() ? + nsPresContext::eContext_PrintPreview : + nsPresContext::eContext_Galley); NS_ENSURE_TRUE(mPresContext, NS_ERROR_OUT_OF_MEMORY); nsresult rv = mPresContext->Init(aDeviceContext); @@ -1361,7 +1361,7 @@ DocumentViewerImpl::GetPresShell(nsIPresShell** aResult) } NS_IMETHODIMP -DocumentViewerImpl::GetPresContext(nsIPresContext** aResult) +DocumentViewerImpl::GetPresContext(nsPresContext** aResult) { NS_IF_ADDREF(*aResult = mPresContext); @@ -1490,7 +1490,7 @@ DocumentViewerImpl::Show(void) } NS_ASSERTION(!mPresContext, "Shouldn't have a prescontext if we have no shell!"); - mPresContext = new nsIPresContext(nsIPresContext::eContext_Galley); + mPresContext = new nsPresContext(nsPresContext::eContext_Galley); NS_ENSURE_TRUE(mPresContext, NS_ERROR_OUT_OF_MEMORY); rv = mPresContext->Init(mDeviceContext); @@ -1935,7 +1935,7 @@ nsresult DocumentViewerImpl::GetDocumentSelection(nsISelection **aSelection, } NS_IMETHODIMP -DocumentViewerImpl::CreateDocumentViewerUsing(nsIPresContext* aPresContext, +DocumentViewerImpl::CreateDocumentViewerUsing(nsPresContext* aPresContext, nsIDocumentViewer** aResult) { if (!mDocument) { @@ -2668,7 +2668,7 @@ NS_IMETHODIMP DocumentViewerImpl::SizeToContent() NS_ENSURE_SUCCESS(presShell->ResizeReflow(NS_UNCONSTRAINEDSIZE, NS_UNCONSTRAINEDSIZE), NS_ERROR_FAILURE); - nsCOMPtr presContext; + nsCOMPtr presContext; GetPresContext(getter_AddRefs(presContext)); NS_ENSURE_TRUE(presContext, NS_ERROR_FAILURE); diff --git a/mozilla/content/base/src/nsFrameLoader.cpp b/mozilla/content/base/src/nsFrameLoader.cpp index 70f1f655d62..da1c3edba13 100644 --- a/mozilla/content/base/src/nsFrameLoader.cpp +++ b/mozilla/content/base/src/nsFrameLoader.cpp @@ -40,7 +40,7 @@ #include "nsIDOMHTMLIFrameElement.h" #include "nsIDOMHTMLFrameElement.h" #include "nsIDOMWindow.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIPresShell.h" #include "nsIContent.h" #include "nsIDocument.h" diff --git a/mozilla/content/base/src/nsGeneratedIterator.cpp b/mozilla/content/base/src/nsGeneratedIterator.cpp index 57351361aa6..988bec81427 100644 --- a/mozilla/content/base/src/nsGeneratedIterator.cpp +++ b/mozilla/content/base/src/nsGeneratedIterator.cpp @@ -49,7 +49,7 @@ #include "nsISupportsArray.h" #include "nsIFocusTracker.h" #include "nsCOMPtr.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIComponentManager.h" #include "nsContentCID.h" #include "nsIPresShell.h" diff --git a/mozilla/content/base/src/nsGenericDOMDataNode.cpp b/mozilla/content/base/src/nsGenericDOMDataNode.cpp index 6284bdcd38c..dc7f0d144f8 100644 --- a/mozilla/content/base/src/nsGenericDOMDataNode.cpp +++ b/mozilla/content/base/src/nsGenericDOMDataNode.cpp @@ -695,7 +695,7 @@ nsGenericDOMDataNode::GetAttrCount() const } nsresult -nsGenericDOMDataNode::HandleDOMEvent(nsIPresContext* aPresContext, +nsGenericDOMDataNode::HandleDOMEvent(nsPresContext* aPresContext, nsEvent* aEvent, nsIDOMEvent** aDOMEvent, PRUint32 aFlags, nsEventStatus* aEventStatus) diff --git a/mozilla/content/base/src/nsGenericDOMDataNode.h b/mozilla/content/base/src/nsGenericDOMDataNode.h index 960ec164eef..26d9fb22012 100644 --- a/mozilla/content/base/src/nsGenericDOMDataNode.h +++ b/mozilla/content/base/src/nsGenericDOMDataNode.h @@ -195,7 +195,7 @@ public: virtual void List(FILE* out, PRInt32 aIndent) const; virtual void DumpContent(FILE* out, PRInt32 aIndent, PRBool aDumpAll) const; #endif - virtual nsresult HandleDOMEvent(nsIPresContext* aPresContext, + virtual nsresult HandleDOMEvent(nsPresContext* aPresContext, nsEvent* aEvent, nsIDOMEvent** aDOMEvent, PRUint32 aFlags, nsEventStatus* aEventStatus); diff --git a/mozilla/content/base/src/nsGenericElement.cpp b/mozilla/content/base/src/nsGenericElement.cpp index 1af3710504f..7730574d2f0 100644 --- a/mozilla/content/base/src/nsGenericElement.cpp +++ b/mozilla/content/base/src/nsGenericElement.cpp @@ -57,7 +57,7 @@ #include "nsNetUtil.h" #include "nsIFrame.h" #include "nsIPresShell.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsStyleConsts.h" #include "nsIView.h" #include "nsIViewManager.h" @@ -1790,7 +1790,7 @@ nsGenericElement::GetNodeInfo() const } nsresult -nsGenericElement::HandleDOMEvent(nsIPresContext* aPresContext, +nsGenericElement::HandleDOMEvent(nsPresContext* aPresContext, nsEvent* aEvent, nsIDOMEvent** aDOMEvent, PRUint32 aFlags, @@ -2356,7 +2356,7 @@ nsGenericElement::GetRangeList() const } void -nsGenericElement::SetFocus(nsIPresContext* aPresContext) +nsGenericElement::SetFocus(nsPresContext* aPresContext) { // Traditionally focusable elements can take focus as long as they don't set // the disabled attribute @@ -3061,7 +3061,7 @@ nsGenericElement::PostQueryInterface(REFNSIID aIID, void** aInstancePtr) //---------------------------------------------------------------------- nsresult -nsGenericElement::LeaveLink(nsIPresContext* aPresContext) +nsGenericElement::LeaveLink(nsPresContext* aPresContext) { nsILinkHandler *handler = aPresContext->GetLinkHandler(); if (!handler) { @@ -3072,7 +3072,7 @@ nsGenericElement::LeaveLink(nsIPresContext* aPresContext) } nsresult -nsGenericElement::TriggerLink(nsIPresContext* aPresContext, +nsGenericElement::TriggerLink(nsPresContext* aPresContext, nsLinkVerb aVerb, nsIURI* aOriginURI, nsIURI* aLinkURI, diff --git a/mozilla/content/base/src/nsGenericElement.h b/mozilla/content/base/src/nsGenericElement.h index 74526dfcd32..501fbd1bb79 100644 --- a/mozilla/content/base/src/nsGenericElement.h +++ b/mozilla/content/base/src/nsGenericElement.h @@ -385,14 +385,14 @@ public: virtual nsresult RangeAdd(nsIDOMRange* aRange); virtual void RangeRemove(nsIDOMRange* aRange); virtual const nsVoidArray *GetRangeList() const; - virtual nsresult HandleDOMEvent(nsIPresContext* aPresContext, + virtual nsresult HandleDOMEvent(nsPresContext* aPresContext, nsEvent* aEvent, nsIDOMEvent** aDOMEvent, PRUint32 aFlags, nsEventStatus* aEventStatus); virtual PRUint32 ContentID() const; virtual void SetContentID(PRUint32 aID); - virtual void SetFocus(nsIPresContext* aContext); + virtual void SetFocus(nsPresContext* aContext); virtual nsIContent *GetBindingParent() const; virtual nsresult SetBindingParent(nsIContent* aParent); virtual PRBool IsContentOfType(PRUint32 aFlags) const; @@ -563,7 +563,7 @@ public: * This would be false for loads from auto XLinks or from the * click() method if we ever implement it. */ - nsresult TriggerLink(nsIPresContext* aPresContext, + nsresult TriggerLink(nsPresContext* aPresContext, nsLinkVerb aVerb, nsIURI* aOriginURI, nsIURI* aLinkURI, @@ -573,7 +573,7 @@ public: /** * Do whatever needs to be done when the mouse leaves a link */ - nsresult LeaveLink(nsIPresContext* aPresContext); + nsresult LeaveLink(nsPresContext* aPresContext); /** * Take two text nodes and append the second to the first. diff --git a/mozilla/content/base/src/nsIDocumentViewerPrint.h b/mozilla/content/base/src/nsIDocumentViewerPrint.h index 5d927c8cadd..a568ede9a8c 100644 --- a/mozilla/content/base/src/nsIDocumentViewerPrint.h +++ b/mozilla/content/base/src/nsIDocumentViewerPrint.h @@ -39,7 +39,7 @@ #include "nsISupports.h" -class nsIPresContext; +class nsPresContext; class nsIPrintSettings; class nsPrintObject; class nsISelection; diff --git a/mozilla/content/base/src/nsImageLoadingContent.cpp b/mozilla/content/base/src/nsImageLoadingContent.cpp index 3c6c5eb04df..64792799602 100644 --- a/mozilla/content/base/src/nsImageLoadingContent.cpp +++ b/mozilla/content/base/src/nsImageLoadingContent.cpp @@ -56,7 +56,7 @@ #include "nsIEventQueue.h" #include "nsNetUtil.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIPresShell.h" #include "nsGUIEvent.h" #include "nsDummyLayoutRequest.h" @@ -603,7 +603,7 @@ class ImageEvent : public PLEvent, public nsDummyLayoutRequest { public: - ImageEvent(nsIPresContext* aPresContext, nsIContent* aContent, + ImageEvent(nsPresContext* aPresContext, nsIContent* aContent, const nsAString& aMessage, nsILoadGroup *aLoadGroup) : nsDummyLayoutRequest(nsnull), mPresContext(aPresContext), @@ -618,7 +618,7 @@ public: MOZ_COUNT_DTOR(ImageEvent); } - nsCOMPtr mPresContext; + nsCOMPtr mPresContext; nsCOMPtr mContent; nsString mMessage; nsCOMPtr mLoadGroup; @@ -687,7 +687,7 @@ nsImageLoadingContent::FireEvent(const nsAString& aEventType) nsIPresShell *shell = document->GetShellAt(0); NS_ENSURE_TRUE(shell, NS_ERROR_FAILURE); - nsCOMPtr presContext; + nsCOMPtr presContext; shell->GetPresContext(getter_AddRefs(presContext)); NS_ENSURE_TRUE(presContext, NS_ERROR_FAILURE); diff --git a/mozilla/content/base/src/nsPagePrintTimer.cpp b/mozilla/content/base/src/nsPagePrintTimer.cpp index 8bad0d90c42..20d36c68f27 100644 --- a/mozilla/content/base/src/nsPagePrintTimer.cpp +++ b/mozilla/content/base/src/nsPagePrintTimer.cpp @@ -111,7 +111,7 @@ nsPagePrintTimer::Notify(nsITimer *timer) void nsPagePrintTimer::Init(nsPrintEngine* aPrintEngine, nsIDocumentViewerPrint* aDocViewerPrint, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsIPrintSettings* aPrintSettings, nsPrintObject* aPO, PRUint32 aDelay) @@ -128,7 +128,7 @@ nsPagePrintTimer::Init(nsPrintEngine* aPrintEngine, nsresult nsPagePrintTimer::Start(nsPrintEngine* aPrintEngine, nsIDocumentViewerPrint* aDocViewerPrint, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsIPrintSettings* aPrintSettings, nsPrintObject* aPO, PRUint32 aDelay) diff --git a/mozilla/content/base/src/nsPagePrintTimer.h b/mozilla/content/base/src/nsPagePrintTimer.h index 85a3927ec93..d0495c0df17 100644 --- a/mozilla/content/base/src/nsPagePrintTimer.h +++ b/mozilla/content/base/src/nsPagePrintTimer.h @@ -43,7 +43,7 @@ // Interfaces #include "nsIDocumentViewerPrint.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIPrintSettings.h" // Other Includes @@ -72,14 +72,14 @@ public: void Init(nsPrintEngine* aPrintEngine, nsIDocumentViewerPrint* aDocViewerPrint, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsIPrintSettings* aPrintSettings, nsPrintObject* aPO, PRUint32 aDelay); nsresult Start(nsPrintEngine* aPrintEngine, nsIDocumentViewerPrint* aDocViewerPrint, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsIPrintSettings* aPrintSettings, nsPrintObject* aPO, PRUint32 aDelay); @@ -88,7 +88,7 @@ public: private: nsPrintEngine* mPrintEngine; nsCOMPtr mDocViewerPrint; - nsIPresContext* mPresContext; + nsPresContext* mPresContext; nsCOMPtr mPrintSettings; nsCOMPtr mTimer; PRUint32 mDelay; diff --git a/mozilla/content/base/src/nsPrintData.h b/mozilla/content/base/src/nsPrintData.h index 17f2ca8c2ae..8f58f59b1ac 100644 --- a/mozilla/content/base/src/nsPrintData.h +++ b/mozilla/content/base/src/nsPrintData.h @@ -69,7 +69,7 @@ class nsPagePrintTimer; class CachedPresentationObj { public: - CachedPresentationObj(nsIPresShell* aShell, nsIPresContext* aPC, + CachedPresentationObj(nsIPresShell* aShell, nsPresContext* aPC, nsIViewManager* aVM, nsIWidget* aW): mWindow(aW), mViewManager(aVM), mPresShell(aShell), mPresContext(aPC) { @@ -81,7 +81,7 @@ public: nsCOMPtr mWindow; nsCOMPtr mViewManager; nsCOMPtr mPresShell; - nsCOMPtr mPresContext; + nsCOMPtr mPresContext; }; //------------------------------------------------------------------------ diff --git a/mozilla/content/base/src/nsPrintEngine.cpp b/mozilla/content/base/src/nsPrintEngine.cpp index d87a84bde3e..868cfad576a 100644 --- a/mozilla/content/base/src/nsPrintEngine.cpp +++ b/mozilla/content/base/src/nsPrintEngine.cpp @@ -318,7 +318,7 @@ nsresult nsPrintEngine::Initialize(nsIDocumentViewer* aDocViewer, nsISupports* aContainer, nsIDocument* aDocument, nsIDeviceContext* aDevContext, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsIWidget* aWindow, nsIWidget* aParentWidget, FILE* aDebugFile) @@ -370,7 +370,7 @@ nsPrintEngine::Cancelled() //------------------------------------------------------- void nsPrintEngine::CachePresentation(nsIPresShell* aShell, - nsIPresContext* aPC, + nsPresContext* aPC, nsIViewManager* aVM, nsIWidget* aW) { @@ -381,7 +381,7 @@ nsPrintEngine::CachePresentation(nsIPresShell* aShell, //------------------------------------------------------- void nsPrintEngine::GetCachedPresentation(nsCOMPtr& aShell, - nsCOMPtr& aPC, + nsCOMPtr& aPC, nsCOMPtr& aVM, nsCOMPtr& aW) { @@ -394,7 +394,7 @@ nsPrintEngine::GetCachedPresentation(nsCOMPtr& aShell, //------------------------------------------------------------ void nsPrintEngine::GetNewPresentation(nsCOMPtr& aShell, - nsCOMPtr& aPC, + nsCOMPtr& aPC, nsCOMPtr& aVM, nsCOMPtr& aW) { @@ -541,10 +541,10 @@ static int RemoveFilesInDir(const char * aDir); static void GetDocTitleAndURL(nsPrintObject* aPO, char *& aDocStr, char *& aURLStr); static void DumpPrintObjectsTree(nsPrintObject * aPO, int aLevel, FILE* aFD); static void DumpPrintObjectsList(nsVoidArray * aDocList); -static void RootFrameList(nsIPresContext* aPresContext, FILE* out, PRInt32 aIndent); +static void RootFrameList(nsPresContext* aPresContext, FILE* out, PRInt32 aIndent); static void DumpViews(nsIDocShell* aDocShell, FILE* out); static void DumpLayoutData(char* aTitleStr, char* aURLStr, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsIDeviceContext * aDC, nsIFrame * aRootFrame, nsIWebShell * aWebShell, FILE* aFD); #endif @@ -2561,9 +2561,9 @@ nsPrintEngine::ReflowPrintObject(nsPrintObject * aPO, PRBool aDoCalcShrink) // create the PresContext PRBool containerIsSet = PR_FALSE; - aPO->mPresContext = new nsIPresContext(mIsCreatingPrintPreview ? - nsIPresContext::eContext_PrintPreview: - nsIPresContext::eContext_Print); + aPO->mPresContext = new nsPresContext(mIsCreatingPrintPreview ? + nsPresContext::eContext_PrintPreview: + nsPresContext::eContext_Print); NS_ENSURE_TRUE(aPO->mPresContext, NS_ERROR_OUT_OF_MEMORY); aPO->mPresContext->SetPrintSettings(mPrt->mPrintSettings); @@ -3064,7 +3064,7 @@ nsPrintEngine::DoPrint(nsPrintObject * aPO, PRBool aDoSyncPrinting, PRBool& aDon nsIWebShell* webShell = aPO->mWebShell.get(); nsIPresShell* poPresShell = aPO->mPresShell; - nsIPresContext* poPresContext = aPO->mPresContext; + nsPresContext* poPresContext = aPO->mPresContext; nsIView* poRootView = aPO->mRootView; NS_ASSERTION(webShell, "The WebShell can't be NULL!"); @@ -3304,7 +3304,7 @@ nsPrintEngine::DoPrint(nsPrintObject * aPO, PRBool aDoSyncPrinting, PRBool& aDon return NS_ERROR_FAILURE; } - if (poPresContext->Type() != nsIPresContext::eContext_PrintPreview) { + if (poPresContext->Type() != nsPresContext::eContext_PrintPreview) { nscoord sheight = seqFrame->GetSize().height; nsRect r = poRootView->GetBounds(); @@ -3407,7 +3407,7 @@ nsPrintEngine::ElipseLongString(PRUnichar *& aStr, const PRUint32 aLen, PRBool a //------------------------------------------------------- PRBool -nsPrintEngine::PrintPage(nsIPresContext* aPresContext, +nsPrintEngine::PrintPage(nsPresContext* aPresContext, nsIPrintSettings* aPrintSettings, nsPrintObject* aPO, PRBool& aInRange) @@ -3618,7 +3618,7 @@ nsPrintEngine::DoProgressForSeparateFrames() * Find by checking content's tag type */ nsIFrame * -nsPrintEngine::FindFrameByType(nsIPresContext* aPresContext, +nsPrintEngine::FindFrameByType(nsPresContext* aPresContext, nsIFrame * aParentFrame, nsIAtom * aType, nsRect& aRect, @@ -3652,7 +3652,7 @@ nsPrintEngine::FindFrameByType(nsIPresContext* aPresContext, * Find by checking frames type */ nsresult -nsPrintEngine::FindSelectionBoundsWithList(nsIPresContext* aPresContext, +nsPrintEngine::FindSelectionBoundsWithList(nsPresContext* aPresContext, nsIRenderingContext& aRC, nsIAtom* aList, nsIFrame * aParentFrame, @@ -3698,7 +3698,7 @@ nsPrintEngine::FindSelectionBoundsWithList(nsIPresContext* aPresContext, //------------------------------------------------------- // Find the Frame that is XMost nsresult -nsPrintEngine::FindSelectionBounds(nsIPresContext* aPresContext, +nsPrintEngine::FindSelectionBounds(nsPresContext* aPresContext, nsIRenderingContext& aRC, nsIFrame * aParentFrame, nsRect& aRect, @@ -3729,7 +3729,7 @@ nsPrintEngine::FindSelectionBounds(nsIPresContext* aPresContext, */ nsresult nsPrintEngine::GetPageRangeForSelection(nsIPresShell * aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsIRenderingContext& aRC, nsISelection* aSelection, nsIPageSequenceFrame* aPageSeqFrame, @@ -4471,7 +4471,7 @@ nsPrintEngine::FinishPrintPreview() // Turning off the scaling of twips so any of the UI scrollbars // will not get scaled - if (mPresContext->Type() == nsIPresContext::eContext_PrintPreview) { + if (mPresContext->Type() == nsPresContext::eContext_PrintPreview) { mPresContext->SetScalingOfTwips(PR_FALSE); mDeviceContext->SetCanonicalPixelScale(mPrtPreview->mOrigDCScale); } @@ -4488,7 +4488,7 @@ nsPrintEngine::FinishPrintPreview() /*=============== Timer Related Code ======================*/ nsresult -nsPrintEngine::StartPagePrintTimer(nsIPresContext * aPresContext, +nsPrintEngine::StartPagePrintTimer(nsPresContext * aPresContext, nsIPrintSettings* aPrintSettings, nsPrintObject* aPOect, PRUint32 aDelay) @@ -4660,7 +4660,7 @@ int RemoveFilesInDir(const char * aDir) /** --------------------------------------------------- * Dumps Frames for Printing */ -static void RootFrameList(nsIPresContext* aPresContext, FILE* out, PRInt32 aIndent) +static void RootFrameList(nsPresContext* aPresContext, FILE* out, PRInt32 aIndent) { if (!aPresContext || !out) return; @@ -4682,7 +4682,7 @@ static void RootFrameList(nsIPresContext* aPresContext, FILE* out, PRInt32 aInde * Dumps Frames for Printing */ static void DumpFrames(FILE* out, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsIRenderingContext * aRendContext, nsIFrame * aFrame, PRInt32 aLevel) @@ -4764,7 +4764,7 @@ DumpViews(nsIDocShell* aDocShell, FILE* out) */ void DumpLayoutData(char* aTitleStr, char* aURLStr, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsIDeviceContext * aDC, nsIFrame * aRootFrame, nsIWebShell * aWebShell, @@ -4777,7 +4777,7 @@ void DumpLayoutData(char* aTitleStr, } #ifdef NS_PRINT_PREVIEW - if (aPresContext->Type() == nsIPresContext::eContext_PrintPreview) { + if (aPresContext->Type() == nsPresContext::eContext_PrintPreview) { return; } #endif diff --git a/mozilla/content/base/src/nsPrintEngine.h b/mozilla/content/base/src/nsPrintEngine.h index af303563ef7..e92029352ab 100644 --- a/mozilla/content/base/src/nsPrintEngine.h +++ b/mozilla/content/base/src/nsPrintEngine.h @@ -119,7 +119,7 @@ public: nsISupports* aContainer, nsIDocument* aDocument, nsIDeviceContext* aDevContext, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsIWidget* aWindow, nsIWidget* aParentWidget, FILE* aDebugFile); @@ -159,7 +159,7 @@ public: void InstallPrintPreviewListener(); // nsIDocumentViewerPrint Printing Methods - PRBool PrintPage(nsIPresContext* aPresContext, + PRBool PrintPage(nsPresContext* aPresContext, nsIPrintSettings* aPrintSettings, nsPrintObject* aPOect, PRBool& aInRange); PRBool DonePrintingPages(nsPrintObject* aPO, nsresult aResult); @@ -209,7 +209,7 @@ public: // Timer Methods - nsresult StartPagePrintTimer(nsIPresContext * aPresContext, + nsresult StartPagePrintTimer(nsPresContext * aPresContext, nsIPrintSettings* aPrintSettings, nsPrintObject* aPO, PRUint32 aDelay); @@ -252,7 +252,7 @@ public: nsresult ShowDocList(PRBool aShow); void GetNewPresentation(nsCOMPtr& aShell, - nsCOMPtr& aPC, + nsCOMPtr& aPC, nsCOMPtr& aVM, nsCOMPtr& aW); @@ -270,10 +270,10 @@ public: { mIsCachingPresentation = aDoCache; } - void CachePresentation(nsIPresShell* aShell, nsIPresContext* aPC, + void CachePresentation(nsIPresShell* aShell, nsPresContext* aPC, nsIViewManager* aVM, nsIWidget* aW); void GetCachedPresentation(nsCOMPtr& aShell, - nsCOMPtr& aPC, + nsCOMPtr& aPC, nsCOMPtr& aVM, nsCOMPtr& aW); @@ -324,7 +324,7 @@ protected: nsIFrame*& aSeqFrame, PRInt32& aCount); - static nsresult FindSelectionBoundsWithList(nsIPresContext* aPresContext, + static nsresult FindSelectionBoundsWithList(nsPresContext* aPresContext, nsIRenderingContext& aRC, nsIAtom* aList, nsIFrame * aParentFrame, @@ -334,7 +334,7 @@ protected: nsIFrame *& aEndFrame, nsRect& aEndRect); - static nsresult FindSelectionBounds(nsIPresContext* aPresContext, + static nsresult FindSelectionBounds(nsPresContext* aPresContext, nsIRenderingContext& aRC, nsIFrame * aParentFrame, nsRect& aRect, @@ -344,7 +344,7 @@ protected: nsRect& aEndRect); static nsresult GetPageRangeForSelection(nsIPresShell * aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsIRenderingContext& aRC, nsISelection* aSelection, nsIPageSequenceFrame* aPageSeqFrame, @@ -355,7 +355,7 @@ protected: PRInt32& aEndPageNum, nsRect& aEndRect); - static nsIFrame * FindFrameByType(nsIPresContext* aPresContext, + static nsIFrame * FindFrameByType(nsPresContext* aPresContext, nsIFrame * aParentFrame, nsIAtom * aType, nsRect& aRect, @@ -369,7 +369,7 @@ protected: nsIDocumentViewer* mDocViewer; // [WEAK] it owns me! nsISupports* mContainer; // [WEAK] it owns me! nsIDeviceContext* mDeviceContext; // not ref counted - nsIPresContext* mPresContext; // not ref counted + nsPresContext* mPresContext; // not ref counted nsCOMPtr mWindow; nsPrintData* mPrt; diff --git a/mozilla/content/base/src/nsPrintObject.h b/mozilla/content/base/src/nsPrintObject.h index 970fb164dda..4d2ab42b1cc 100644 --- a/mozilla/content/base/src/nsPrintObject.h +++ b/mozilla/content/base/src/nsPrintObject.h @@ -41,7 +41,7 @@ #include "nsCOMPtr.h" #include "nsAutoPtr.h" #include "nsIContent.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIPresShell.h" #include "nsStyleSet.h" #include "nsIViewManager.h" @@ -76,11 +76,11 @@ public: nsCOMPtr mWebShell; nsCOMPtr mDocShell; nsCOMPtr mDisplayPresShell; - nsCOMPtr mDisplayPresContext; + nsCOMPtr mDisplayPresContext; nsCOMPtr mDocument; PrintObjectType mFrameType; - nsCOMPtr mPresContext; + nsCOMPtr mPresContext; nsStyleSet *mStyleSet; nsCOMPtr mPresShell; nsCOMPtr mViewManager; diff --git a/mozilla/content/base/src/nsRuleNode.cpp b/mozilla/content/base/src/nsRuleNode.cpp index ba4d0181f1b..d97df250622 100644 --- a/mozilla/content/base/src/nsRuleNode.cpp +++ b/mozilla/content/base/src/nsRuleNode.cpp @@ -80,19 +80,19 @@ public: mNext->Destroy(mNext->mRuleNode->mPresContext); } - void* operator new(size_t sz, nsIPresContext* aContext) CPP_THROW_NEW { + void* operator new(size_t sz, nsPresContext* aContext) CPP_THROW_NEW { return aContext->AllocateFromShell(sz); }; void operator delete(void* aPtr) {} // Does nothing. The arena will free us up when the rule tree // dies. - void Destroy(nsIPresContext* aContext) { + void Destroy(nsPresContext* aContext) { this->~nsRuleList(); aContext->FreeToShell(sizeof(nsRuleList), this); } // Destroy this node, but not its rule node or the rest of the list. - nsRuleList* DestroySelf(nsIPresContext* aContext) { + nsRuleList* DestroySelf(nsPresContext* aContext) { nsRuleList *next = mNext; MOZ_COUNT_DTOR(nsRuleList); // hack aContext->FreeToShell(sizeof(nsRuleList), this); @@ -189,7 +189,7 @@ nsString& Unquote(nsString& aString) nscoord CalcLength(const nsCSSValue& aValue, const nsFont* aFont, nsStyleContext* aStyleContext, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, PRBool& aInherited) { NS_ASSERTION(aValue.IsLengthUnit(), "not a length unit"); @@ -260,7 +260,7 @@ nscoord CalcLength(const nsCSSValue& aValue, static PRBool SetCoord(const nsCSSValue& aValue, nsStyleCoord& aCoord, const nsStyleCoord& aParentCoord, PRInt32 aMask, nsStyleContext* aStyleContext, - nsIPresContext* aPresContext, PRBool& aInherited) + nsPresContext* aPresContext, PRBool& aInherited) { PRBool result = PR_TRUE; if (aValue.GetUnit() == eCSSUnit_Null) { @@ -310,7 +310,7 @@ static PRBool SetCoord(const nsCSSValue& aValue, nsStyleCoord& aCoord, } static PRBool SetColor(const nsCSSValue& aValue, const nscolor aParentColor, - nsIPresContext* aPresContext, nscolor& aResult, PRBool& aInherited) + nsPresContext* aPresContext, nscolor& aResult, PRBool& aInherited) { PRBool result = PR_FALSE; nsCSSUnit unit = aValue.GetUnit(); @@ -365,7 +365,7 @@ static PRBool SetColor(const nsCSSValue& aValue, const nscolor aParentColor, // Overloaded new operator. Initializes the memory to 0 and relies on an arena // (which comes from the presShell) to perform the allocation. void* -nsRuleNode::operator new(size_t sz, nsIPresContext* aPresContext) CPP_THROW_NEW +nsRuleNode::operator new(size_t sz, nsPresContext* aPresContext) CPP_THROW_NEW { // Check the recycle list first. return aPresContext->AllocateFromShell(sz); @@ -384,14 +384,14 @@ nsRuleNode::Destroy() mPresContext->FreeToShell(sizeof(nsRuleNode), this); } -nsRuleNode* nsRuleNode::CreateRootNode(nsIPresContext* aPresContext) +nsRuleNode* nsRuleNode::CreateRootNode(nsPresContext* aPresContext) { return new (aPresContext) nsRuleNode(aPresContext, nsnull, nsnull); } nsILanguageAtomService* nsRuleNode::gLangService = nsnull; -nsRuleNode::nsRuleNode(nsIPresContext* aContext, nsIStyleRule* aRule, nsRuleNode* aParent) +nsRuleNode::nsRuleNode(nsPresContext* aContext, nsIStyleRule* aRule, nsRuleNode* aParent) : mPresContext(aContext), mParent(aParent), mRule(aRule), @@ -1375,7 +1375,7 @@ nsRuleNode::WalkRuleTree(const nsStyleStructID aSID, } static PRBool -IsChrome(nsIPresContext* aPresContext) +IsChrome(nsPresContext* aPresContext) { PRBool isChrome = PR_FALSE; nsCOMPtr container = aPresContext->GetContainer(); @@ -1620,7 +1620,7 @@ nsRuleNode::AdjustLogicalBoxProp(nsStyleContext* aContext, } /* static */ void -nsRuleNode::SetFont(nsIPresContext* aPresContext, nsStyleContext* aContext, +nsRuleNode::SetFont(nsPresContext* aPresContext, nsStyleContext* aContext, nscoord aMinFontSize, PRBool aUseDocumentFonts, PRBool aIsGeneric, const nsRuleDataFont& aFontData, const nsFont& aDefaultFont, const nsStyleFont* aParentFont, @@ -1873,7 +1873,7 @@ nsRuleNode::SetFont(nsIPresContext* aPresContext, nsStyleContext* aContext, // up to the root where default values come from the presentation context) // - re-apply cascading rules from there without caching intermediate values /* static */ void -nsRuleNode::SetGenericFont(nsIPresContext* aPresContext, +nsRuleNode::SetGenericFont(nsPresContext* aPresContext, nsStyleContext* aContext, const nsRuleDataFont& aFontData, PRUint8 aGenericFontID, nscoord aMinFontSize, @@ -4300,7 +4300,7 @@ nsRuleNode::ComputeColumnData(nsStyleStruct* aStartStruct, #ifdef MOZ_SVG static void SetSVGPaint(const nsCSSValue& aValue, const nsStyleSVGPaint& parentPaint, - nsIPresContext* aPresContext, nsStyleSVGPaint& aResult, PRBool& aInherited) + nsPresContext* aPresContext, nsStyleSVGPaint& aResult, PRBool& aInherited) { if (aValue.GetUnit() == eCSSUnit_Inherit) { aResult = parentPaint; @@ -4326,7 +4326,7 @@ SetSVGOpacity(const nsCSSValue& aValue, float parentOpacity, float& opacity, PRB static void SetSVGLength(const nsCSSValue& aValue, float parentLength, float& length, - nsStyleContext* aContext, nsIPresContext* aPresContext, PRBool& aInherited) + nsStyleContext* aContext, nsPresContext* aPresContext, PRBool& aInherited) { nsStyleCoord coord; PRBool dummy; diff --git a/mozilla/content/base/src/nsSelection.cpp b/mozilla/content/base/src/nsSelection.cpp index c4b4f6b0436..e7164e86ff9 100644 --- a/mozilla/content/base/src/nsSelection.cpp +++ b/mozilla/content/base/src/nsSelection.cpp @@ -82,7 +82,7 @@ static NS_DEFINE_CID(kFrameTraversalCID, NS_FRAMETRAVERSAL_CID); #include "nsContentUtils.h" //included for desired x position; -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIPresShell.h" #include "nsICaret.h" @@ -194,7 +194,7 @@ public: NS_DECL_NSISELECTIONPRIVATE // utility methods for scrolling the selection into view - nsresult GetPresContext(nsIPresContext **aPresContext); + nsresult GetPresContext(nsPresContext **aPresContext); nsresult GetPresShell(nsIPresShell **aPresShell); nsresult GetRootScrollableView(nsIScrollableView **aScrollableView); nsresult GetFrameToScrolledViewOffsets(nsIScrollableView *aScrollableView, nsIFrame *aFrame, nscoord *aXOffset, nscoord *aYOffset); @@ -207,7 +207,7 @@ public: nsresult AddItem(nsIDOMRange *aRange); nsresult RemoveItem(nsIDOMRange *aRange); - nsresult Clear(nsIPresContext* aPresContext); + nsresult Clear(nsPresContext* aPresContext); // methods for convenience. Note, these don't addref nsIDOMNode* FetchAnchorNode(); //where did the selection begin PRInt32 FetchAnchorOffset(); @@ -237,13 +237,13 @@ public: NS_IMETHOD GetOriginalAnchorPoint(nsIDOMNode **aNode, PRInt32 *aOffset); NS_IMETHOD LookUpSelection(nsIContent *aContent, PRInt32 aContentOffset, PRInt32 aContentLength, SelectionDetails **aReturnDetails, SelectionType aType, PRBool aSlowCheck); - NS_IMETHOD Repaint(nsIPresContext* aPresContext); + NS_IMETHOD Repaint(nsPresContext* aPresContext); - nsresult StartAutoScrollTimer(nsIPresContext *aPresContext, nsIView *aView, nsPoint& aPoint, PRUint32 aDelay); + nsresult StartAutoScrollTimer(nsPresContext *aPresContext, nsIView *aView, nsPoint& aPoint, PRUint32 aDelay); nsresult StopAutoScrollTimer(); - nsresult DoAutoScrollView(nsIPresContext *aPresContext, nsIView *aView, nsPoint& aPoint, PRBool aScrollParentViews); - nsresult ScrollPointIntoClipView(nsIPresContext *aPresContext, nsIView *aView, nsPoint& aPoint, PRBool *aDidScroll); - nsresult ScrollPointIntoView(nsIPresContext *aPresContext, nsIView *aView, nsPoint& aPoint, PRBool aScrollParentViews, PRBool *aDidScroll); + nsresult DoAutoScrollView(nsPresContext *aPresContext, nsIView *aView, nsPoint& aPoint, PRBool aScrollParentViews); + nsresult ScrollPointIntoClipView(nsPresContext *aPresContext, nsIView *aView, nsPoint& aPoint, PRBool *aDidScroll); + nsresult ScrollPointIntoView(nsPresContext *aPresContext, nsIView *aView, nsPoint& aPoint, PRBool aScrollParentViews, PRBool *aDidScroll); nsresult GetViewAncestorOffset(nsIView *aView, nsIView *aAncestorView, nscoord *aXOffset, nscoord *aYOffset); nsresult GetClosestScrollableView(nsIView *aView, nsIScrollableView **aScrollableView); @@ -258,8 +258,8 @@ private: void setAnchorFocusRange(PRInt32 aIndex); //pass in index into FrameSelection - NS_IMETHOD selectFrames(nsIPresContext* aPresContext, nsIContentIterator *aInnerIter, nsIContent *aContent, nsIDOMRange *aRange, nsIPresShell *aPresShell, PRBool aFlags); - NS_IMETHOD selectFrames(nsIPresContext* aPresContext, nsIDOMRange *aRange, PRBool aSelect); + NS_IMETHOD selectFrames(nsPresContext* aPresContext, nsIContentIterator *aInnerIter, nsIContent *aContent, nsIDOMRange *aRange, nsIPresShell *aPresShell, PRBool aFlags); + NS_IMETHOD selectFrames(nsPresContext* aPresContext, nsIDOMRange *aRange, PRBool aSelect); nsresult getTableCellLocationFromRange(nsIDOMRange *aRange, PRInt32 *aSelectionType, PRInt32 *aRow, PRInt32 *aCol); nsresult addTableCellRange(nsIDOMRange *aRange, PRBool *aDidAddRange); @@ -316,12 +316,12 @@ public: NS_IMETHOD ShutDown(); NS_IMETHOD HandleTextEvent(nsGUIEvent *aGUIEvent); - NS_IMETHOD HandleKeyEvent(nsIPresContext* aPresContext, nsGUIEvent *aGuiEvent); + NS_IMETHOD HandleKeyEvent(nsPresContext* aPresContext, nsGUIEvent *aGuiEvent); NS_IMETHOD HandleClick(nsIContent *aNewFocus, PRUint32 aContentOffset, PRUint32 aContentEndOffset, PRBool aContinueSelection, PRBool aMultipleSelection,PRBool aHint); - NS_IMETHOD HandleDrag(nsIPresContext *aPresContext, nsIFrame *aFrame, nsPoint& aPoint); + NS_IMETHOD HandleDrag(nsPresContext *aPresContext, nsIFrame *aFrame, nsPoint& aPoint); NS_IMETHOD HandleTableSelection(nsIContent *aParentContent, PRInt32 aContentOffset, PRInt32 aTarget, nsMouseEvent *aMouseEvent); - NS_IMETHOD StartAutoScrollTimer(nsIPresContext *aPresContext, nsIView *aView, nsPoint& aPoint, PRUint32 aDelay); + NS_IMETHOD StartAutoScrollTimer(nsPresContext *aPresContext, nsIView *aView, nsPoint& aPoint, PRUint32 aDelay); NS_IMETHOD StopAutoScrollTimer(); NS_IMETHOD EnableFrameNotification(PRBool aEnable){mNotifyFrames = aEnable; return NS_OK;} NS_IMETHOD LookUpSelection(nsIContent *aContent, PRInt32 aContentOffset, PRInt32 aContentLength, @@ -334,7 +334,7 @@ public: NS_IMETHOD GetSelection(SelectionType aType, nsISelection **aDomSelection); NS_IMETHOD ScrollSelectionIntoView(SelectionType aType, SelectionRegion aRegion, PRBool aIsSynchronous); - NS_IMETHOD RepaintSelection(nsIPresContext* aPresContext, SelectionType aType); + NS_IMETHOD RepaintSelection(nsPresContext* aPresContext, SelectionType aType); NS_IMETHOD GetFrameForNodeOffset(nsIContent *aNode, PRInt32 aOffset, HINT aHint, nsIFrame **aReturnFrame, PRInt32 *aReturnOffset); NS_IMETHOD CommonPageMove(PRBool aForward, PRBool aExtend, nsIScrollableView *aScrollableView, nsIFrameSelection *aFrameSel); @@ -357,14 +357,14 @@ public: NS_IMETHOD GetLimiter(nsIContent **aLimiterContent); NS_IMETHOD SetMouseDoubleDown(PRBool aDoubleDown); NS_IMETHOD GetMouseDoubleDown(PRBool *aDoubleDown); - NS_IMETHOD GetPrevNextBidiLevels(nsIPresContext *aPresContext, + NS_IMETHOD GetPrevNextBidiLevels(nsPresContext *aPresContext, nsIContent *aNode, PRUint32 aContentOffset, nsIFrame **aPrevFrame, nsIFrame **aNextFrame, PRUint8 *aPrevLevel, PRUint8 *aNextLevel); - NS_IMETHOD GetFrameFromLevel(nsIPresContext *aPresContext, + NS_IMETHOD GetFrameFromLevel(nsPresContext *aPresContext, nsIFrame *aFrameIn, nsDirection aDirection, PRUint8 aBidiLevel, @@ -387,17 +387,17 @@ private: NS_IMETHOD TakeFocus(nsIContent *aNewFocus, PRUint32 aContentOffset, PRUint32 aContentEndOffset, PRBool aContinueSelection, PRBool aMultipleSelection); - void BidiLevelFromMove(nsIPresContext* aContext, + void BidiLevelFromMove(nsPresContext* aContext, nsIPresShell* aPresShell, nsIContent *aNode, PRUint32 aContentOffset, PRUint32 aKeycode); void BidiLevelFromClick(nsIContent *aNewFocus, PRUint32 aContentOffset); #ifdef VISUALSELECTION - NS_IMETHOD VisualSelectFrames(nsIPresContext* aContext, + NS_IMETHOD VisualSelectFrames(nsPresContext* aContext, nsIFrame* aCurrentFrame, nsPeekOffsetStruct aPos); - NS_IMETHOD VisualSequence(nsIPresContext *aPresContext, + NS_IMETHOD VisualSequence(nsPresContext *aPresContext, nsIFrame* aSelectFrame, nsIFrame* aCurrentFrame, nsPeekOffsetStruct* aPos, @@ -407,7 +407,7 @@ private: PRInt32 aOffset, PRInt32 aEdge, PRBool aMultipleSelection); - NS_IMETHOD SelectLines(nsIPresContext *aPresContext, + NS_IMETHOD SelectLines(nsPresContext *aPresContext, nsDirection aSelectionDirection, nsIDOMNode *aAnchorNode, nsIFrame* aAnchorFrame, @@ -443,8 +443,8 @@ private: void SetDesiredX(nscoord aX); //set the mDesiredX nsresult GetRootForContentSubtree(nsIContent *aContent, nsIContent **aParent); - nsresult GetGlobalViewOffsetsFromFrame(nsIPresContext *aPresContext, nsIFrame *aFrame, nscoord *offsetX, nscoord *offsetY); - nsresult ConstrainFrameAndPointToAnchorSubtree(nsIPresContext *aPresContext, nsIFrame *aFrame, nsPoint& aPoint, nsIFrame **aRetFrame, nsPoint& aRetPoint); + nsresult GetGlobalViewOffsetsFromFrame(nsPresContext *aPresContext, nsIFrame *aFrame, nscoord *offsetX, nscoord *offsetY); + nsresult ConstrainFrameAndPointToAnchorSubtree(nsPresContext *aPresContext, nsIFrame *aFrame, nsPoint& aPoint, nsIFrame **aRetFrame, nsPoint& aRetPoint); PRUint32 GetBatching(){return mBatching;} PRBool GetNotifyFrames(){return mNotifyFrames;} @@ -561,7 +561,7 @@ public: mTimer->Cancel(); } - nsresult Start(nsIPresContext *aPresContext, nsIView *aView, nsPoint &aPoint) + nsresult Start(nsPresContext *aPresContext, nsIView *aView, nsPoint &aPoint) { mView = aView; mPresContext = aPresContext; @@ -625,7 +625,7 @@ private: nsTypedSelection *mSelection; nsCOMPtr mTimer; nsIView *mView; - nsIPresContext *mPresContext; + nsPresContext *mPresContext; nsPoint mPoint; PRUint32 mDelay; }; @@ -964,7 +964,7 @@ nsSelection::FetchDesiredX(nscoord &aDesiredX) //the x position requested by the return NS_OK; } - nsCOMPtr context; + nsCOMPtr context; nsresult result = mTracker->GetPresContext(getter_AddRefs(context)); if (NS_FAILED(result)) return result; @@ -1060,7 +1060,7 @@ nsSelection::GetRootForContentSubtree(nsIContent *aContent, nsIContent **aParent } nsresult -nsSelection::GetGlobalViewOffsetsFromFrame(nsIPresContext *aPresContext, nsIFrame *aFrame, nscoord *offsetX, nscoord *offsetY) +nsSelection::GetGlobalViewOffsetsFromFrame(nsPresContext *aPresContext, nsIFrame *aFrame, nscoord *offsetX, nscoord *offsetY) { // // The idea here is to figure out what the offset of aFrame's view @@ -1101,7 +1101,7 @@ nsSelection::GetGlobalViewOffsetsFromFrame(nsIPresContext *aPresContext, nsIFram } nsresult -nsSelection::ConstrainFrameAndPointToAnchorSubtree(nsIPresContext *aPresContext, nsIFrame *aFrame, nsPoint& aPoint, nsIFrame **aRetFrame, nsPoint& aRetPoint) +nsSelection::ConstrainFrameAndPointToAnchorSubtree(nsPresContext *aPresContext, nsIFrame *aFrame, nsPoint& aPoint, nsIFrame **aRetFrame, nsPoint& aRetPoint) { // // The whole point of this method is to return a frame and point that @@ -1360,7 +1360,7 @@ nsSelection::HandleTextEvent(nsGUIEvent *aGUIEvent) nsresult nsSelection::MoveCaret(PRUint32 aKeycode, PRBool aContinue, nsSelectionAmount aAmount) { - nsCOMPtr context; + nsCOMPtr context; nsresult result = mTracker->GetPresContext(getter_AddRefs(context)); if (NS_FAILED(result) || !context) return result?result:NS_ERROR_FAILURE; @@ -1566,7 +1566,7 @@ nsSelection::MoveCaret(PRUint32 aKeycode, PRBool aContinue, nsSelectionAmount aA * focus DomNode, it is invalid? The answer now is yes. */ NS_IMETHODIMP -nsSelection::HandleKeyEvent(nsIPresContext* aPresContext, nsGUIEvent *aGuiEvent) +nsSelection::HandleKeyEvent(nsPresContext* aPresContext, nsGUIEvent *aGuiEvent) { if (!aGuiEvent) return NS_ERROR_NULL_POINTER; @@ -1709,7 +1709,7 @@ FindLineContaining(nsIFrame* aFrame, nsIFrame** aBlock, PRInt32* aLine) } NS_IMETHODIMP -nsSelection::VisualSequence(nsIPresContext *aPresContext, +nsSelection::VisualSequence(nsPresContext *aPresContext, nsIFrame* aSelectFrame, nsIFrame* aCurrentFrame, nsPeekOffsetStruct* aPos, @@ -1778,7 +1778,7 @@ nsSelection::SelectToEdge(nsIFrame *aFrame, nsIContent *aContent, PRInt32 aOffse } NS_IMETHODIMP -nsSelection::SelectLines(nsIPresContext *aPresContext, +nsSelection::SelectLines(nsPresContext *aPresContext, nsDirection aSelectionDirection, nsIDOMNode *aAnchorNode, nsIFrame* aAnchorFrame, @@ -1881,7 +1881,7 @@ nsSelection::SelectLines(nsIPresContext *aPresContext, } NS_IMETHODIMP -nsSelection::VisualSelectFrames(nsIPresContext *aPresContext, +nsSelection::VisualSelectFrames(nsPresContext *aPresContext, nsIFrame* aCurrentFrame, nsPeekOffsetStruct aPos) { @@ -2082,7 +2082,7 @@ nsSelection::VisualSelectFrames(nsIPresContext *aPresContext, #endif // VISUALSELECTION NS_IMETHODIMP -nsSelection::GetPrevNextBidiLevels(nsIPresContext *aPresContext, +nsSelection::GetPrevNextBidiLevels(nsPresContext *aPresContext, nsIContent *aNode, PRUint32 aContentOffset, nsIFrame **aPrevFrame, @@ -2253,7 +2253,7 @@ nsSelection::GetPrevNextBidiLevels(nsIPresContext *aPresContext, } -NS_IMETHODIMP nsSelection::GetFrameFromLevel(nsIPresContext *aPresContext, +NS_IMETHODIMP nsSelection::GetFrameFromLevel(nsPresContext *aPresContext, nsIFrame *aFrameIn, nsDirection aDirection, PRUint8 aBidiLevel, @@ -2344,7 +2344,7 @@ nsSelection::MaintainSelection() * @param aContentOffset is the new caret position, as an offset into aNode * @param aKeycode is the keyboard event that moved the caret to the new position */ -void nsSelection::BidiLevelFromMove(nsIPresContext* aContext, +void nsSelection::BidiLevelFromMove(nsPresContext* aContext, nsIPresShell* aPresShell, nsIContent *aNode, PRUint32 aContentOffset, @@ -2392,7 +2392,7 @@ void nsSelection::BidiLevelFromMove(nsIPresContext* aContext, */ void nsSelection::BidiLevelFromClick(nsIContent *aNode, PRUint32 aContentOffset) { - nsCOMPtr context; + nsCOMPtr context; nsresult result = mTracker->GetPresContext(getter_AddRefs(context)); if (NS_FAILED(result) || !context) return; @@ -2497,7 +2497,7 @@ nsSelection::HandleClick(nsIContent *aNewFocus, PRUint32 aContentOffset, } NS_IMETHODIMP -nsSelection::HandleDrag(nsIPresContext *aPresContext, nsIFrame *aFrame, nsPoint& aPoint) +nsSelection::HandleDrag(nsPresContext *aPresContext, nsIFrame *aFrame, nsPoint& aPoint) { if (!aPresContext || !aFrame) return NS_ERROR_NULL_POINTER; @@ -2572,7 +2572,7 @@ nsSelection::HandleDrag(nsIPresContext *aPresContext, nsIFrame *aFrame, nsPoint& } NS_IMETHODIMP -nsSelection::StartAutoScrollTimer(nsIPresContext *aPresContext, nsIView *aView, nsPoint& aPoint, PRUint32 aDelay) +nsSelection::StartAutoScrollTimer(nsPresContext *aPresContext, nsIView *aView, nsPoint& aPoint, PRUint32 aDelay) { PRInt8 index = GetIndexFromSelectionType(nsISelectionController::SELECTION_NORMAL); return mDomSelections[index]->StartAutoScrollTimer(aPresContext, aView, aPoint, aDelay); @@ -2647,7 +2647,7 @@ nsSelection::TakeFocus(nsIContent *aNewFocus, PRUint32 aContentOffset, //if we are no longer inside same table ,cell then switch to table selection mode. // BUT only do this in an editor - nsCOMPtr presContext; + nsCOMPtr presContext; nsresult result = mTracker->GetPresContext(getter_AddRefs(presContext)); if (NS_FAILED(result) || !presContext) return result?result:NS_ERROR_FAILURE; @@ -2807,7 +2807,7 @@ nsSelection::ScrollSelectionIntoView(SelectionType aType, SelectionRegion aRegio } NS_IMETHODIMP -nsSelection::RepaintSelection(nsIPresContext* aPresContext, SelectionType aType) +nsSelection::RepaintSelection(nsPresContext* aPresContext, SelectionType aType) { PRInt8 index = GetIndexFromSelectionType(aType); if (index < 0) @@ -2960,7 +2960,7 @@ nsSelection::CommonPageMove(PRBool aForward, return result; nsRect viewRect = clipView->GetBounds(); - nsCOMPtr context; + nsCOMPtr context; result = mTracker->GetPresContext(getter_AddRefs(context)); if (NS_FAILED(result)) @@ -4720,7 +4720,7 @@ nsTypedSelection::RemoveItem(nsIDOMRange *aItem) nsresult -nsTypedSelection::Clear(nsIPresContext* aPresContext) +nsTypedSelection::Clear(nsPresContext* aPresContext) { setAnchorFocusRange(-1); // Get an iterator @@ -4831,7 +4831,7 @@ nsTypedSelection::GetPrimaryFrameForFocusNode(nsIFrame **aReturnFrame, PRInt32 * //select all content children of aContent NS_IMETHODIMP -nsTypedSelection::selectFrames(nsIPresContext* aPresContext, +nsTypedSelection::selectFrames(nsPresContext* aPresContext, nsIContentIterator *aInnerIter, nsIContent *aContent, nsIDOMRange *aRange, @@ -4926,7 +4926,7 @@ nsTypedSelection::selectFrames(nsIPresContext* aPresContext, //the idea of this helper method is to select, deselect "top to bottom" traversing through the frames NS_IMETHODIMP -nsTypedSelection::selectFrames(nsIPresContext* aPresContext, nsIDOMRange *aRange, PRBool aFlags) +nsTypedSelection::selectFrames(nsPresContext* aPresContext, nsIDOMRange *aRange, PRBool aFlags) { if (!mFrameSelection) return NS_OK;//nothing to do @@ -5137,7 +5137,7 @@ nsTypedSelection::LookUpSelection(nsIContent *aContent, PRInt32 aContentOffset, } NS_IMETHODIMP -nsTypedSelection::Repaint(nsIPresContext* aPresContext) +nsTypedSelection::Repaint(nsPresContext* aPresContext) { PRInt32 arrCount = mRangeArray.Count(); @@ -5225,7 +5225,7 @@ nsTypedSelection::GetCachedFrameOffset(nsIFrame *aFrame, PRInt32 inOffset, nsPoi } nsresult -nsTypedSelection::StartAutoScrollTimer(nsIPresContext *aPresContext, nsIView *aView, nsPoint& aPoint, PRUint32 aDelay) +nsTypedSelection::StartAutoScrollTimer(nsPresContext *aPresContext, nsIView *aView, nsPoint& aPoint, PRUint32 aDelay) { nsresult result; if (!mFrameSelection) @@ -5308,7 +5308,7 @@ nsTypedSelection::GetClosestScrollableView(nsIView *aView, nsIScrollableView **a } nsresult -nsTypedSelection::ScrollPointIntoClipView(nsIPresContext *aPresContext, nsIView *aView, nsPoint& aPoint, PRBool *aDidScroll) +nsTypedSelection::ScrollPointIntoClipView(nsPresContext *aPresContext, nsIView *aView, nsPoint& aPoint, PRBool *aDidScroll) { nsresult result; @@ -5470,7 +5470,7 @@ nsTypedSelection::ScrollPointIntoClipView(nsIPresContext *aPresContext, nsIView } nsresult -nsTypedSelection::ScrollPointIntoView(nsIPresContext *aPresContext, nsIView *aView, nsPoint& aPoint, PRBool aScrollParentViews, PRBool *aDidScroll) +nsTypedSelection::ScrollPointIntoView(nsPresContext *aPresContext, nsIView *aView, nsPoint& aPoint, PRBool aScrollParentViews, PRBool *aDidScroll) { if (!aPresContext || !aView || !aDidScroll) return NS_ERROR_NULL_POINTER; @@ -5603,7 +5603,7 @@ nsTypedSelection::ScrollPointIntoView(nsIPresContext *aPresContext, nsIView *aVi } nsresult -nsTypedSelection::DoAutoScrollView(nsIPresContext *aPresContext, nsIView *aView, nsPoint& aPoint, PRBool aScrollParentViews) +nsTypedSelection::DoAutoScrollView(nsPresContext *aPresContext, nsIView *aView, nsPoint& aPoint, PRBool aScrollParentViews) { if (!aPresContext || !aView) return NS_ERROR_NULL_POINTER; @@ -5685,7 +5685,7 @@ nsTypedSelection::RemoveAllRanges() { if (!mFrameSelection) return NS_OK;//nothing to do - nsCOMPtr presContext; + nsCOMPtr presContext; GetPresContext(getter_AddRefs(presContext)); @@ -5732,7 +5732,7 @@ nsTypedSelection::AddRange(nsIDOMRange* aRange) } setAnchorFocusRange(count -1); - nsCOMPtr presContext; + nsCOMPtr presContext; GetPresContext(getter_AddRefs(presContext)); selectFrames(presContext, aRange, PR_TRUE); @@ -5750,7 +5750,7 @@ nsTypedSelection::RemoveRange(nsIDOMRange* aRange) return NS_ERROR_INVALID_ARG; RemoveItem(aRange); - nsCOMPtr presContext; + nsCOMPtr presContext; GetPresContext(getter_AddRefs(presContext)); selectFrames(presContext, aRange, PR_FALSE); if (aRange == mAnchorFocusRange.get()) @@ -5784,7 +5784,7 @@ nsTypedSelection::Collapse(nsIDOMNode* aParentNode, PRInt32 aOffset) // Delete all of the current ranges if (NS_FAILED(SetOriginalAnchorPoint(aParentNode,aOffset))) return NS_ERROR_FAILURE; //??? - nsCOMPtr presContext; + nsCOMPtr presContext; GetPresContext(getter_AddRefs(presContext)); Clear(presContext); @@ -6340,7 +6340,7 @@ nsTypedSelection::Extend(nsIDOMNode* aParentNode, PRInt32 aOffset) if (result2 == 0) //not selecting anywhere return NS_OK; - nsCOMPtr presContext; + nsCOMPtr presContext; GetPresContext(getter_AddRefs(presContext)); if ((result1 == 0 && result3 < 0) || (result1 <= 0 && result2 < 0)){//a1,2 a,1,2 //select from 1 to 2 unless they are collapsed @@ -6710,7 +6710,7 @@ nsTypedSelection::ContainsNode(nsIDOMNode* aNode, PRBool aRecursive, PRBool* aYe nsresult -nsTypedSelection::GetPresContext(nsIPresContext **aPresContext) +nsTypedSelection::GetPresContext(nsPresContext **aPresContext) { if (!mFrameSelection) return NS_ERROR_FAILURE;//nothing to do @@ -6741,7 +6741,7 @@ nsTypedSelection::GetPresShell(nsIPresShell **aPresShell) if (!tracker) return NS_ERROR_NULL_POINTER; - nsCOMPtr presContext; + nsCOMPtr presContext; rv = tracker->GetPresContext(getter_AddRefs(presContext)); @@ -6833,7 +6833,7 @@ nsTypedSelection::GetFrameToScrolledViewOffsets(nsIScrollableView *aScrollableVi if (!tracker) return NS_ERROR_NULL_POINTER; - nsCOMPtr presContext; + nsCOMPtr presContext; tracker->GetPresContext(getter_AddRefs(presContext)); aFrame->GetOffsetFromView(presContext, offset, &closestView); @@ -6875,7 +6875,7 @@ nsTypedSelection::GetPointFromOffset(nsIFrame *aFrame, PRInt32 aContentOffset, n if (!tracker) return NS_ERROR_NULL_POINTER; - nsCOMPtr presContext; + nsCOMPtr presContext; rv = tracker->GetPresContext(getter_AddRefs(presContext)); @@ -7000,7 +7000,7 @@ nsTypedSelection::GetSelectionRegionRectAndScrollableView(SelectionRegion aRegio // Get the frame's scrollable view. // - nsCOMPtr presContext; + nsCOMPtr presContext; result = GetPresContext(getter_AddRefs(presContext)); @@ -7547,7 +7547,7 @@ nsTypedSelection::SelectionLanguageChange(PRBool aLangRTL) PRInt32 frameStart, frameEnd; focusFrame->GetOffsets(frameStart, frameEnd); - nsCOMPtr context; + nsCOMPtr context; PRUint8 levelBefore, levelAfter; result = GetPresContext(getter_AddRefs(context)); if (NS_FAILED(result) || !context) diff --git a/mozilla/content/base/src/nsStyleContext.cpp b/mozilla/content/base/src/nsStyleContext.cpp index d27fd1cd962..80b6503a85d 100644 --- a/mozilla/content/base/src/nsStyleContext.cpp +++ b/mozilla/content/base/src/nsStyleContext.cpp @@ -39,7 +39,7 @@ #include "nsStyleConsts.h" #include "nsString.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIStyleRule.h" #include "nsISupportsArray.h" #include "nsCRT.h" @@ -65,7 +65,7 @@ nsStyleContext::nsStyleContext(nsStyleContext* aParent, nsIAtom* aPseudoTag, nsRuleNode* aRuleNode, - nsIPresContext* aPresContext) + nsPresContext* aPresContext) : mParent((nsStyleContext*)aParent), mChild(nsnull), mEmptyChild(nsnull), @@ -92,7 +92,7 @@ nsStyleContext::~nsStyleContext() { NS_ASSERTION((nsnull == mChild) && (nsnull == mEmptyChild), "destructing context with children"); - nsIPresContext *presContext = mRuleNode->GetPresContext(); + nsPresContext *presContext = mRuleNode->GetPresContext(); presContext->PresShell()->StyleSet()-> NotifyStyleContextDestroyed(presContext, this); @@ -288,7 +288,7 @@ nsStyleContext::GetUniqueStyleData(const nsStyleStructID& aSID) return NS_CONST_CAST(nsStyleStruct*, current); nsStyleStruct* result; - nsIPresContext *presContext = PresContext(); + nsPresContext *presContext = PresContext(); switch (aSID) { #define UNIQUE_CASE(c_) \ @@ -334,7 +334,7 @@ nsStyleContext::SetStyle(nsStyleStructID aSID, nsStyleStruct* aStruct) char* resetOrInherit = NS_REINTERPRET_CAST(char*, *NS_REINTERPRET_CAST(void**, resetOrInheritSlot)); if (!resetOrInherit) { - nsIPresContext *presContext = mRuleNode->GetPresContext(); + nsPresContext *presContext = mRuleNode->GetPresContext(); if (mCachedStyleData.IsReset(aSID)) { mCachedStyleData.mResetData = new (presContext) nsResetStyleData; resetOrInherit = NS_REINTERPRET_CAST(char*, mCachedStyleData.mResetData); @@ -350,7 +350,7 @@ nsStyleContext::SetStyle(nsStyleStructID aSID, nsStyleStruct* aStruct) } void -nsStyleContext::ApplyStyleFixups(nsIPresContext* aPresContext) +nsStyleContext::ApplyStyleFixups(nsPresContext* aPresContext) { // See if we have any text decorations. // First see if our parent has text decorations. If our parent does, then we inherit the bit. @@ -402,7 +402,7 @@ nsStyleContext::ApplyStyleFixups(nsIPresContext* aPresContext) } void -nsStyleContext::ClearStyleData(nsIPresContext* aPresContext) +nsStyleContext::ClearStyleData(nsPresContext* aPresContext) { // First we need to clear out all of our style data. if (mCachedStyleData.mResetData || mCachedStyleData.mInheritedData) @@ -622,7 +622,7 @@ static void IndentBy(FILE* out, PRInt32 aIndent) { while (--aIndent >= 0) fputs(" ", out); } // virtual -void nsStyleContext::DumpRegressionData(nsIPresContext* aPresContext, FILE* out, PRInt32 aIndent) +void nsStyleContext::DumpRegressionData(nsPresContext* aPresContext, FILE* out, PRInt32 aIndent) { nsAutoString str; @@ -886,7 +886,7 @@ void nsStyleContext::DumpRegressionData(nsIPresContext* aPresContext, FILE* out, // Overloaded new operator. Initializes the memory to 0 and relies on an arena // (which comes from the presShell) to perform the allocation. void* -nsStyleContext::operator new(size_t sz, nsIPresContext* aPresContext) CPP_THROW_NEW +nsStyleContext::operator new(size_t sz, nsPresContext* aPresContext) CPP_THROW_NEW { // Check the recycle list first. return aPresContext->AllocateFromShell(sz); @@ -898,7 +898,7 @@ void nsStyleContext::Destroy() { // Get the pres context from our rule node. - nsCOMPtr presContext = mRuleNode->GetPresContext(); + nsCOMPtr presContext = mRuleNode->GetPresContext(); // Call our destructor. this->~nsStyleContext(); @@ -912,7 +912,7 @@ already_AddRefed NS_NewStyleContext(nsStyleContext* aParentContext, nsIAtom* aPseudoTag, nsRuleNode* aRuleNode, - nsIPresContext* aPresContext) + nsPresContext* aPresContext) { nsStyleContext* context = new (aPresContext) nsStyleContext(aParentContext, aPseudoTag, aRuleNode, aPresContext); diff --git a/mozilla/content/base/src/nsStyleSet.cpp b/mozilla/content/base/src/nsStyleSet.cpp index d61bbc6d694..8c93219afe6 100644 --- a/mozilla/content/base/src/nsStyleSet.cpp +++ b/mozilla/content/base/src/nsStyleSet.cpp @@ -62,7 +62,7 @@ nsStyleSet::nsStyleSet() } nsresult -nsStyleSet::Init(nsIPresContext *aPresContext) +nsStyleSet::Init(nsPresContext *aPresContext) { if (!gQuirkURI) { static const char kQuirk_href[] = "resource://gre/res/quirk.css"; @@ -301,7 +301,7 @@ nsStyleSet::EnableQuirkStyleSheet(PRBool aEnable) } struct RulesMatchingData : public ElementRuleProcessorData { - RulesMatchingData(nsIPresContext* aPresContext, + RulesMatchingData(nsPresContext* aPresContext, nsIContent* aContent, nsRuleWalker* aRuleWalker) : ElementRuleProcessorData(aPresContext, aContent, aRuleWalker), @@ -327,7 +327,7 @@ EnumRulesMatching(nsIStyleRuleProcessor* aProcessor, void* aData) * |aParentContext| could itself be a shared context.) */ already_AddRefed -nsStyleSet::GetContext(nsIPresContext* aPresContext, +nsStyleSet::GetContext(nsPresContext* aPresContext, nsStyleContext* aParentContext, nsIAtom* aPseudoTag) { @@ -507,7 +507,7 @@ nsStyleSet::WalkRuleProcessors(nsIStyleRuleProcessor::EnumFunc aFunc, (*aFunc)(mRuleProcessors[eOverrideSheet], aData); } -PRBool nsStyleSet::BuildDefaultStyleData(nsIPresContext* aPresContext) +PRBool nsStyleSet::BuildDefaultStyleData(nsPresContext* aPresContext) { NS_ASSERTION(!mDefaultStyleData.mResetData && !mDefaultStyleData.mInheritedData, @@ -545,7 +545,7 @@ nsStyleSet::ResolveStyleFor(nsIContent* aContent, nsStyleContext* aParentContext) { nsStyleContext* result = nsnull; - nsIPresContext* presContext = PresContext(); + nsPresContext* presContext = PresContext(); NS_ASSERTION(aContent, "must have content"); NS_ASSERTION(aContent->IsContentOfType(nsIContent::eELEMENT), @@ -575,7 +575,7 @@ already_AddRefed nsStyleSet::ResolveStyleForNonElement(nsStyleContext* aParentContext) { nsStyleContext* result = nsnull; - nsIPresContext *presContext = PresContext(); + nsPresContext *presContext = PresContext(); if (presContext) { if (mRuleProcessors[eAgentSheet] || @@ -596,7 +596,7 @@ nsStyleSet::ResolveStyleForNonElement(nsStyleContext* aParentContext) struct PseudoRulesMatchingData : public PseudoRuleProcessorData { - PseudoRulesMatchingData(nsIPresContext* aPresContext, + PseudoRulesMatchingData(nsPresContext* aPresContext, nsIContent* aParentContent, nsIAtom* aPseudoTag, nsICSSPseudoComparator* aComparator, @@ -625,7 +625,7 @@ nsStyleSet::ResolvePseudoStyleFor(nsIContent* aParentContent, nsICSSPseudoComparator* aComparator) { nsStyleContext* result = nsnull; - nsIPresContext *presContext = PresContext(); + nsPresContext *presContext = PresContext(); NS_ASSERTION(aPseudoTag, "must have pseudo tag"); NS_ASSERTION(!aParentContent || @@ -660,7 +660,7 @@ nsStyleSet::ProbePseudoStyleFor(nsIContent* aParentContent, nsStyleContext* aParentContext) { nsStyleContext* result = nsnull; - nsIPresContext *presContext = PresContext(); + nsPresContext *presContext = PresContext(); NS_ASSERTION(aPseudoTag, "must have pseudo tag"); NS_ASSERTION(!aParentContent || @@ -707,14 +707,14 @@ nsStyleSet::ProbePseudoStyleFor(nsIContent* aParentContent, } void -nsStyleSet::BeginShutdown(nsIPresContext* aPresContext) +nsStyleSet::BeginShutdown(nsPresContext* aPresContext) { mInShutdown = 1; mRoots.Clear(); // no longer valid, since we won't keep it up to date } void -nsStyleSet::Shutdown(nsIPresContext* aPresContext) +nsStyleSet::Shutdown(nsPresContext* aPresContext) { delete mRuleWalker; mRuleWalker = nsnull; @@ -728,7 +728,7 @@ nsStyleSet::Shutdown(nsIPresContext* aPresContext) static const PRInt32 kGCInterval = 1000; void -nsStyleSet::NotifyStyleContextDestroyed(nsIPresContext* aPresContext, +nsStyleSet::NotifyStyleContextDestroyed(nsPresContext* aPresContext, nsStyleContext* aStyleContext) { if (mInShutdown) @@ -761,7 +761,7 @@ nsStyleSet::NotifyStyleContextDestroyed(nsIPresContext* aPresContext, } void -nsStyleSet::ClearStyleData(nsIPresContext* aPresContext) +nsStyleSet::ClearStyleData(nsPresContext* aPresContext) { mRuleTree->ClearStyleData(); @@ -771,7 +771,7 @@ nsStyleSet::ClearStyleData(nsIPresContext* aPresContext) } already_AddRefed -nsStyleSet::ReParentStyleContext(nsIPresContext* aPresContext, +nsStyleSet::ReParentStyleContext(nsPresContext* aPresContext, nsStyleContext* aStyleContext, nsStyleContext* aNewParentContext) { @@ -799,7 +799,7 @@ nsStyleSet::ReParentStyleContext(nsIPresContext* aPresContext, } struct StatefulData : public StateRuleProcessorData { - StatefulData(nsIPresContext* aPresContext, + StatefulData(nsPresContext* aPresContext, nsIContent* aContent, PRInt32 aStateMask) : StateRuleProcessorData(aPresContext, aContent, aStateMask), mMedium(aPresContext->Medium()), @@ -821,7 +821,7 @@ static PRBool SheetHasStatefulStyle(nsIStyleRuleProcessor* aProcessor, // Test if style is dependent on content state nsReStyleHint -nsStyleSet::HasStateDependentStyle(nsIPresContext* aPresContext, +nsStyleSet::HasStateDependentStyle(nsPresContext* aPresContext, nsIContent* aContent, PRInt32 aStateMask) { @@ -844,7 +844,7 @@ nsStyleSet::HasStateDependentStyle(nsIPresContext* aPresContext, } struct AttributeData : public AttributeRuleProcessorData { - AttributeData(nsIPresContext* aPresContext, + AttributeData(nsPresContext* aPresContext, nsIContent* aContent, nsIAtom* aAttribute, PRInt32 aModType) : AttributeRuleProcessorData(aPresContext, aContent, aAttribute, aModType), mMedium(aPresContext->Medium()), @@ -866,7 +866,7 @@ SheetHasAttributeStyle(nsIStyleRuleProcessor* aProcessor, void *aData) // Test if style is dependent on content state nsReStyleHint -nsStyleSet::HasAttributeDependentStyle(nsIPresContext* aPresContext, +nsStyleSet::HasAttributeDependentStyle(nsPresContext* aPresContext, nsIContent* aContent, nsIAtom* aAttribute, PRInt32 aModType) diff --git a/mozilla/content/base/src/nsStyleSet.h b/mozilla/content/base/src/nsStyleSet.h index 81bdf407669..e1adee2c93e 100644 --- a/mozilla/content/base/src/nsStyleSet.h +++ b/mozilla/content/base/src/nsStyleSet.h @@ -60,14 +60,14 @@ class nsStyleSet // Initialize the object. You must check the return code and not use // the nsStyleSet if Init() fails. - nsresult Init(nsIPresContext *aPresContext); + nsresult Init(nsPresContext *aPresContext); // For getting the cached default data in case we hit out-of-memory. // To be used only by nsRuleNode. nsCachedStyleData* DefaultStyleData() { return &mDefaultStyleData; } // clear out all of the computed style data - void ClearStyleData(nsIPresContext *aPresContext); + void ClearStyleData(nsPresContext *aPresContext); // enable / disable the Quirk style sheet void EnableQuirkStyleSheet(PRBool aEnable); @@ -107,30 +107,30 @@ class nsStyleSet // Begin ignoring style context destruction, to avoid lots of unnecessary // work on document teardown. - void BeginShutdown(nsIPresContext* aPresContext); + void BeginShutdown(nsPresContext* aPresContext); // Free all of the data associated with this style set. - void Shutdown(nsIPresContext* aPresContext); + void Shutdown(nsPresContext* aPresContext); // Notification that a style context is being destroyed. - void NotifyStyleContextDestroyed(nsIPresContext* aPresContext, + void NotifyStyleContextDestroyed(nsPresContext* aPresContext, nsStyleContext* aStyleContext); // Get a new style context that lives in a different parent // The new context will be the same as the old if the new parent is the // same as the old parent. already_AddRefed - ReParentStyleContext(nsIPresContext* aPresContext, + ReParentStyleContext(nsPresContext* aPresContext, nsStyleContext* aStyleContext, nsStyleContext* aNewParentContext); // Test if style is dependent on content state - nsReStyleHint HasStateDependentStyle(nsIPresContext* aPresContext, + nsReStyleHint HasStateDependentStyle(nsPresContext* aPresContext, nsIContent* aContent, PRInt32 aStateMask); // Test if style is dependent on the presence of an attribute. - nsReStyleHint HasAttributeDependentStyle(nsIPresContext* aPresContext, + nsReStyleHint HasAttributeDependentStyle(nsPresContext* aPresContext, nsIContent* aContent, nsIAtom* aAttribute, PRInt32 aModType); @@ -190,7 +190,7 @@ class nsStyleSet nsStyleSet& operator=(const nsStyleSet& aCopy); // Returns false on out-of-memory. - PRBool BuildDefaultStyleData(nsIPresContext* aPresContext); + PRBool BuildDefaultStyleData(nsPresContext* aPresContext); // Update the rule processor list after a change to the style sheet list. nsresult GatherRuleProcessors(sheetType aType); @@ -222,11 +222,11 @@ class nsStyleSet void WalkRuleProcessors(nsIStyleRuleProcessor::EnumFunc aFunc, RuleProcessorData* aData); - already_AddRefed GetContext(nsIPresContext* aPresContext, + already_AddRefed GetContext(nsPresContext* aPresContext, nsStyleContext* aParentContext, nsIAtom* aPseudoTag); - nsIPresContext* PresContext() { return mRuleTree->GetPresContext(); } + nsPresContext* PresContext() { return mRuleTree->GetPresContext(); } static nsIURI *gQuirkURI; diff --git a/mozilla/content/events/public/nsIEventListenerManager.h b/mozilla/content/events/public/nsIEventListenerManager.h index 4e47a586506..14504df3898 100644 --- a/mozilla/content/events/public/nsIEventListenerManager.h +++ b/mozilla/content/events/public/nsIEventListenerManager.h @@ -42,7 +42,7 @@ #include "nsISupports.h" #include "nsVoidArray.h" -class nsIPresContext; +class nsPresContext; class nsIDOMEventListener; class nsIScriptContext; class nsIDOMEventTarget; @@ -130,7 +130,7 @@ public: * Event flags live in nsGUIEvent.h * @param an event listener */ - NS_IMETHOD HandleEvent(nsIPresContext* aPresContext, + NS_IMETHOD HandleEvent(nsPresContext* aPresContext, nsEvent* aEvent, nsIDOMEvent** aDOMEvent, nsIDOMEventTarget* aCurrentTarget, @@ -142,7 +142,7 @@ public: * (used rarely in the situation where methods on the event need to be * invoked prior to the processing of the event). */ - NS_IMETHOD CreateEvent(nsIPresContext* aPresContext, + NS_IMETHOD CreateEvent(nsPresContext* aPresContext, nsEvent* aEvent, const nsAString& aEventType, nsIDOMEvent** aDOMEvent) = 0; diff --git a/mozilla/content/events/public/nsIEventStateManager.h b/mozilla/content/events/public/nsIEventStateManager.h index 32e53144dba..3d30dd81824 100644 --- a/mozilla/content/events/public/nsIEventStateManager.h +++ b/mozilla/content/events/public/nsIEventStateManager.h @@ -43,7 +43,7 @@ #include "nsVoidArray.h" class nsIContent; -class nsIPresContext; +class nsPresContext; class nsIDOMEvent; class nsIFrame; class nsIView; @@ -66,13 +66,13 @@ public: NS_IMETHOD Init() = 0; - NS_IMETHOD PreHandleEvent(nsIPresContext* aPresContext, + NS_IMETHOD PreHandleEvent(nsPresContext* aPresContext, nsEvent *aEvent, nsIFrame* aTargetFrame, nsEventStatus* aStatus, nsIView* aView) = 0; - NS_IMETHOD PostHandleEvent(nsIPresContext* aPresContext, + NS_IMETHOD PostHandleEvent(nsPresContext* aPresContext, nsEvent *aEvent, nsIFrame* aTargetFrame, nsEventStatus* aStatus, @@ -83,7 +83,7 @@ public: NS_IMETHOD SetCurrentEvent(nsEvent *aEvent) = 0; NS_IMETHOD GetCurrentEvent(nsEvent **aEvent) = 0; // 0 if none - NS_IMETHOD SetPresContext(nsIPresContext* aPresContext) = 0; + NS_IMETHOD SetPresContext(nsPresContext* aPresContext) = 0; NS_IMETHOD ClearFrameRefs(nsIFrame* aFrame) = 0; NS_IMETHOD GetEventTarget(nsIFrame **aFrame) = 0; diff --git a/mozilla/content/events/public/nsIPrivateDOMEvent.h b/mozilla/content/events/public/nsIPrivateDOMEvent.h index 400cc0ffa40..686cad07a82 100644 --- a/mozilla/content/events/public/nsIPrivateDOMEvent.h +++ b/mozilla/content/events/public/nsIPrivateDOMEvent.h @@ -41,7 +41,7 @@ #include "nsEvent.h" #include "nsISupports.h" -class nsIPresContext; +class nsPresContext; /* * Event listener manager interface. @@ -72,10 +72,10 @@ public: nsresult NS_NewDOMUIEvent(nsIDOMEvent** aInstancePtrResult, - nsIPresContext* aPresContext, const nsAString& aEventType, + nsPresContext* aPresContext, const nsAString& aEventType, nsEvent *aEvent); nsresult -NS_NewDOMMutationEvent(nsIDOMEvent** aResult, nsIPresContext* aPresContext, +NS_NewDOMMutationEvent(nsIDOMEvent** aResult, nsPresContext* aPresContext, nsEvent* aEvent); #endif // nsIPrivateDOMEvent_h__ diff --git a/mozilla/content/events/src/nsDOMEvent.cpp b/mozilla/content/events/src/nsDOMEvent.cpp index d49146b60e4..4713ea95b44 100644 --- a/mozilla/content/events/src/nsDOMEvent.cpp +++ b/mozilla/content/events/src/nsDOMEvent.cpp @@ -146,7 +146,7 @@ nsDOMEvent::operator delete(void* aPtr) -nsDOMEvent::nsDOMEvent(nsIPresContext* aPresContext, nsEvent* aEvent, +nsDOMEvent::nsDOMEvent(nsPresContext* aPresContext, nsEvent* aEvent, const nsAString& aEventType) { @@ -1554,7 +1554,7 @@ const char* nsDOMEvent::GetEventName(PRUint32 aEventType) nsresult NS_NewDOMUIEvent(nsIDOMEvent** aInstancePtrResult, - nsIPresContext* aPresContext, const nsAString& aEventType, + nsPresContext* aPresContext, const nsAString& aEventType, nsEvent *aEvent) { nsDOMEvent* it = new nsDOMEvent(aPresContext, aEvent, aEventType); diff --git a/mozilla/content/events/src/nsDOMEvent.h b/mozilla/content/events/src/nsDOMEvent.h index 676e792e3b9..c1122879ddf 100644 --- a/mozilla/content/events/src/nsDOMEvent.h +++ b/mozilla/content/events/src/nsDOMEvent.h @@ -51,7 +51,7 @@ #include "nsIDOMEvent.h" #include "nsCOMPtr.h" #include "nsIDOMEventTarget.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsPoint.h" #include "nsGUIEvent.h" @@ -127,7 +127,7 @@ public: eDOMEvents_DOMFocusOut }; - nsDOMEvent(nsIPresContext* aPresContext, nsEvent* aEvent, + nsDOMEvent(nsPresContext* aPresContext, nsEvent* aEvent, const nsAString& aEventType); virtual ~nsDOMEvent(); @@ -222,7 +222,7 @@ protected: nsPoint GetScreenPoint(); nsEvent* mEvent; - nsCOMPtr mPresContext; + nsCOMPtr mPresContext; nsCOMPtr mTarget; nsCOMPtr mCurrentTarget; nsCOMPtr mOriginalTarget; diff --git a/mozilla/content/events/src/nsDOMMutationEvent.cpp b/mozilla/content/events/src/nsDOMMutationEvent.cpp index 8a4347cc222..36a4567bbb6 100644 --- a/mozilla/content/events/src/nsDOMMutationEvent.cpp +++ b/mozilla/content/events/src/nsDOMMutationEvent.cpp @@ -41,7 +41,7 @@ #include "nsMutationEvent.h" #include "nsContentUtils.h" -class nsIPresContext; +class nsPresContext; class nsDOMMutationEvent : public nsDOMEvent, public nsIDOMMutationEvent { @@ -50,13 +50,13 @@ class nsDOMMutationEvent : public nsDOMEvent, public nsIDOMMutationEvent NS_DECL_ISUPPORTS_INHERITED - nsDOMMutationEvent(nsIPresContext* aPresContext, + nsDOMMutationEvent(nsPresContext* aPresContext, nsEvent* aEvent); ~nsDOMMutationEvent(); }; -nsDOMMutationEvent::nsDOMMutationEvent(nsIPresContext* aPresContext, +nsDOMMutationEvent::nsDOMMutationEvent(nsPresContext* aPresContext, nsEvent* aEvent) :nsDOMEvent(aPresContext, aEvent, NS_LITERAL_STRING("MutationEvents")) { @@ -170,7 +170,7 @@ nsDOMMutationEvent::InitMutationEvent(const nsAString& aTypeArg, PRBool aCanBubb } nsresult NS_NewDOMMutationEvent(nsIDOMEvent** aInstancePtrResult, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsEvent *aEvent) { nsDOMMutationEvent* it = new nsDOMMutationEvent(aPresContext, aEvent); diff --git a/mozilla/content/events/src/nsEventListenerManager.cpp b/mozilla/content/events/src/nsEventListenerManager.cpp index 7169947b763..7c524843373 100644 --- a/mozilla/content/events/src/nsEventListenerManager.cpp +++ b/mozilla/content/events/src/nsEventListenerManager.cpp @@ -1521,7 +1521,7 @@ nsEventListenerManager::HandleEventSubType(nsListenerStruct* aListenerStruct, * @param an event listener */ -nsresult nsEventListenerManager::HandleEvent(nsIPresContext* aPresContext, +nsresult nsEventListenerManager::HandleEvent(nsPresContext* aPresContext, nsEvent* aEvent, nsIDOMEvent** aDOMEvent, nsIDOMEventTarget* aCurrentTarget, @@ -1620,7 +1620,7 @@ nsresult nsEventListenerManager::HandleEvent(nsIPresContext* aPresContext, */ NS_IMETHODIMP -nsEventListenerManager::CreateEvent(nsIPresContext* aPresContext, +nsEventListenerManager::CreateEvent(nsPresContext* aPresContext, nsEvent* aEvent, const nsAString& aEventType, nsIDOMEvent** aDOMEvent) @@ -1886,7 +1886,7 @@ nsEventListenerManager::DispatchEvent(nsIDOMEvent* aEvent, PRBool *_retval) } // Retrieve the context - nsCOMPtr aPresContext; + nsCOMPtr aPresContext; shell->GetPresContext(getter_AddRefs(aPresContext)); return aPresContext->EventStateManager()->DispatchNewEvent(mTarget, aEvent, @@ -1965,7 +1965,7 @@ nsEventListenerManager::GetSystemEventGroup(nsIDOMEventGroup **aGroup) } nsresult -nsEventListenerManager::FixContextMenuEvent(nsIPresContext* aPresContext, +nsEventListenerManager::FixContextMenuEvent(nsPresContext* aPresContext, nsIDOMEventTarget* aCurrentTarget, nsEvent* aEvent, nsIDOMEvent** aDOMEvent) @@ -2025,7 +2025,7 @@ nsEventListenerManager::FixContextMenuEvent(nsIPresContext* aPresContext, } void nsEventListenerManager::GetCoordinatesFor(nsIDOMElement *aCurrentEl, - nsIPresContext *aPresContext, + nsPresContext *aPresContext, nsIPresShell *aPresShell, nsPoint& aTargetPt) { diff --git a/mozilla/content/events/src/nsEventListenerManager.h b/mozilla/content/events/src/nsEventListenerManager.h index c847d803d34..65d48132ed6 100644 --- a/mozilla/content/events/src/nsEventListenerManager.h +++ b/mozilla/content/events/src/nsEventListenerManager.h @@ -138,14 +138,14 @@ public: NS_IMETHOD CaptureEvent(PRInt32 aEventTypes); NS_IMETHOD ReleaseEvent(PRInt32 aEventTypes); - NS_IMETHOD HandleEvent(nsIPresContext* aPresContext, + NS_IMETHOD HandleEvent(nsPresContext* aPresContext, nsEvent* aEvent, nsIDOMEvent** aDOMEvent, nsIDOMEventTarget* aCurrentTarget, PRUint32 aFlags, nsEventStatus* aEventStatus); - NS_IMETHOD CreateEvent(nsIPresContext* aPresContext, + NS_IMETHOD CreateEvent(nsPresContext* aPresContext, nsEvent* aEvent, const nsAString& aEventType, nsIDOMEvent** aDOMEvent); @@ -216,11 +216,11 @@ protected: nsresult FlipCaptureBit(PRInt32 aEventTypes, PRBool aInitCapture); nsVoidArray* GetListenersByType(EventArrayType aType, nsHashKey* aKey, PRBool aCreate); EventArrayType GetTypeForIID(const nsIID& aIID); - nsresult FixContextMenuEvent(nsIPresContext* aPresContext, + nsresult FixContextMenuEvent(nsPresContext* aPresContext, nsIDOMEventTarget* aCurrentTarget, nsEvent* aEvent, nsIDOMEvent** aDOMEvent); - void GetCoordinatesFor(nsIDOMElement *aCurrentEl, nsIPresContext *aPresContext, + void GetCoordinatesFor(nsIDOMElement *aCurrentEl, nsPresContext *aPresContext, nsIPresShell *aPresShell, nsPoint& aTargetPt); nsresult GetDOM2EventGroup(nsIDOMEventGroup** aGroup); diff --git a/mozilla/content/events/src/nsEventStateManager.cpp b/mozilla/content/events/src/nsEventStateManager.cpp index ce3c558e44b..dd3665fa1d5 100644 --- a/mozilla/content/events/src/nsEventStateManager.cpp +++ b/mozilla/content/events/src/nsEventStateManager.cpp @@ -45,7 +45,7 @@ #include "nsIDocument.h" #include "nsIFrame.h" #include "nsIWidget.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIPresShell.h" #include "nsDOMEvent.h" #include "nsHTMLAtoms.h" @@ -140,7 +140,7 @@ static NS_DEFINE_CID(kLookAndFeelCID, NS_LOOKANDFEEL_CID); nsIContent * gLastFocusedContent = 0; // Strong reference nsIDocument * gLastFocusedDocument = 0; // Strong reference -nsIPresContext* gLastFocusedPresContext = 0; // Weak reference +nsPresContext* gLastFocusedPresContext = 0; // Weak reference enum nsTextfieldSelectModel { eTextfieldSelect_unset = -1, @@ -423,7 +423,7 @@ SetFrameExternalReference(nsIFrame* aFrame) } NS_IMETHODIMP -nsEventStateManager::PreHandleEvent(nsIPresContext* aPresContext, +nsEventStateManager::PreHandleEvent(nsPresContext* aPresContext, nsEvent *aEvent, nsIFrame* aTargetFrame, nsEventStatus* aStatus, @@ -597,7 +597,7 @@ nsEventStateManager::PreHandleEvent(nsIPresContext* aPresContext, if (doc) { nsIPresShell *shell = doc->GetShellAt(0); if (shell) { - nsCOMPtr oldPresContext; + nsCOMPtr oldPresContext; shell->GetPresContext(getter_AddRefs(oldPresContext)); nsCOMPtr esm; @@ -731,7 +731,7 @@ nsEventStateManager::PreHandleEvent(nsIPresContext* aPresContext, if (doc) { nsIPresShell *shell = doc->GetShellAt(0); if (shell) { - nsCOMPtr oldPresContext; + nsCOMPtr oldPresContext; shell->GetPresContext(getter_AddRefs(oldPresContext)); nsCOMPtr esm = @@ -821,7 +821,7 @@ nsEventStateManager::PreHandleEvent(nsIPresContext* aPresContext, if (shell) { if (focusedElement) { nsCOMPtr focusContent = do_QueryInterface(focusedElement); - nsCOMPtr context; + nsCOMPtr context; shell->GetPresContext(getter_AddRefs(context)); focusContent->SetFocus(context); } @@ -886,7 +886,7 @@ nsEventStateManager::PreHandleEvent(nsIPresContext* aPresContext, if (gLastFocusedContent) { nsIPresShell *shell = gLastFocusedDocument->GetShellAt(0); if (shell) { - nsCOMPtr oldPresContext; + nsCOMPtr oldPresContext; shell->GetPresContext(getter_AddRefs(oldPresContext)); nsCOMPtr focusedElement; @@ -965,7 +965,7 @@ nsEventStateManager::PreHandleEvent(nsIPresContext* aPresContext, // 0 -- childCount - 1 stands for the child docShell's offset // which bubbles up the access key handling void -nsEventStateManager::HandleAccessKey(nsIPresContext* aPresContext, +nsEventStateManager::HandleAccessKey(nsPresContext* aPresContext, nsKeyEvent *aEvent, nsEventStatus* aStatus, PRInt32 aChildOffset, @@ -1076,7 +1076,7 @@ nsEventStateManager::HandleAccessKey(nsIPresContext* aPresContext, nsCOMPtr subShellItem; nsCOMPtr subPS; - nsCOMPtr subPC; + nsCOMPtr subPC; docShell->GetChildAt(counter, getter_AddRefs(subShellItem)); nsCOMPtr subDS = do_QueryInterface(subShellItem); @@ -1121,7 +1121,7 @@ nsEventStateManager::HandleAccessKey(nsIPresContext* aPresContext, docShell->GetChildOffset(&myOffset); nsCOMPtr parentPS; - nsCOMPtr parentPC; + nsCOMPtr parentPC; parentDS->GetPresShell(getter_AddRefs(parentPS)); NS_ASSERTION(parentPS, "Our PresShell exists but the parent's does not?"); @@ -1150,7 +1150,7 @@ nsEventStateManager::HandleAccessKey(nsIPresContext* aPresContext, // a drag. // void -nsEventStateManager::CreateClickHoldTimer(nsIPresContext* inPresContext, +nsEventStateManager::CreateClickHoldTimer(nsPresContext* inPresContext, nsGUIEvent* inMouseDownEvent) { // just to be anal (er, safe) @@ -1363,7 +1363,7 @@ nsEventStateManager::FireContextClick() // want to cancel the drag gesture if the context-click event is handled. // void -nsEventStateManager::BeginTrackingDragGesture(nsIPresContext* aPresContext, +nsEventStateManager::BeginTrackingDragGesture(nsPresContext* aPresContext, nsGUIEvent* inDownEvent, nsIFrame* inDownFrame) { @@ -1405,7 +1405,7 @@ nsEventStateManager::StopTrackingDragGesture() // void nsEventStateManager::GetSelection(nsIFrame* inFrame, - nsIPresContext* inPresContext, + nsPresContext* inPresContext, nsIFrameSelection** outSelection) { *outSelection = nsnull; @@ -1448,7 +1448,7 @@ nsEventStateManager::GetSelection(nsIFrame* inFrame, // Do we need to do anything about this? Let's wait and see. // void -nsEventStateManager::GenerateDragGesture(nsIPresContext* aPresContext, +nsEventStateManager::GenerateDragGesture(nsPresContext* aPresContext, nsGUIEvent *aEvent) { NS_WARN_IF_FALSE(aPresContext, "This shouldn't happen."); @@ -1574,7 +1574,7 @@ nsEventStateManager::ChangeTextSize(PRInt32 change) nsIPresShell *presShell = doc->GetShellAt(0); if(!presShell) return NS_ERROR_FAILURE; - nsCOMPtr presContext; + nsCOMPtr presContext; presShell->GetPresContext(getter_AddRefs(presContext)); if(!presContext) return NS_ERROR_FAILURE; @@ -1633,7 +1633,7 @@ nsEventStateManager::DoScrollTextsize(nsIFrame *aTargetFrame, // nsresult -nsEventStateManager::DoScrollText(nsIPresContext* aPresContext, +nsEventStateManager::DoScrollText(nsPresContext* aPresContext, nsIFrame* aTargetFrame, nsInputEvent* aEvent, PRInt32 aNumLines, @@ -1786,7 +1786,7 @@ nsEventStateManager::DoScrollText(nsIPresContext* aPresContext, if (passToParent) { nsresult rv; nsIFrame* newFrame = nsnull; - nsCOMPtr newPresContext; + nsCOMPtr newPresContext; rv = GetParentScrollingView(aEvent, aPresContext, newFrame, *getter_AddRefs(newPresContext)); @@ -1802,9 +1802,9 @@ nsEventStateManager::DoScrollText(nsIPresContext* aPresContext, nsresult nsEventStateManager::GetParentScrollingView(nsInputEvent *aEvent, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsIFrame* &targetOuterFrame, - nsIPresContext* &presCtxOuter) + nsPresContext* &presCtxOuter) { targetOuterFrame = nsnull; @@ -1849,7 +1849,7 @@ nsEventStateManager::GetParentScrollingView(nsInputEvent *aEvent, } NS_IMETHODIMP -nsEventStateManager::PostHandleEvent(nsIPresContext* aPresContext, +nsEventStateManager::PostHandleEvent(nsPresContext* aPresContext, nsEvent *aEvent, nsIFrame* aTargetFrame, nsEventStatus* aStatus, @@ -2284,7 +2284,7 @@ nsEventStateManager::PostHandleEvent(nsIPresContext* aPresContext, } NS_IMETHODIMP -nsEventStateManager::SetPresContext(nsIPresContext* aPresContext) +nsEventStateManager::SetPresContext(nsPresContext* aPresContext) { if (aPresContext == nsnull) { // A pres context is going away. Make sure we do cleanup. @@ -2366,7 +2366,7 @@ nsEventStateManager::CheckDisabled(nsIContent* aContent) } void -nsEventStateManager::UpdateCursor(nsIPresContext* aPresContext, +nsEventStateManager::UpdateCursor(nsPresContext* aPresContext, nsEvent* aEvent, nsIFrame* aTargetFrame, nsEventStatus* aStatus) { @@ -2532,7 +2532,7 @@ nsEventStateManager::AfterDispatchEvent() } void -nsEventStateManager::DispatchMouseEvent(nsIPresContext* aPresContext, +nsEventStateManager::DispatchMouseEvent(nsPresContext* aPresContext, nsGUIEvent* aEvent, PRUint32 aMessage, nsIContent* aTargetContent, nsIFrame*& aTargetFrame, @@ -2577,7 +2577,7 @@ nsEventStateManager::DispatchMouseEvent(nsIPresContext* aPresContext, void nsEventStateManager::MaybeDispatchMouseEventToIframe( - nsIPresContext* aPresContext, nsGUIEvent* aEvent, PRUint32 aMessage) + nsPresContext* aPresContext, nsGUIEvent* aEvent, PRUint32 aMessage) { // Check to see if we're an IFRAME and if so dispatch the given event // (mouseover / mouseout) to the IFRAME element above us. This will result @@ -2614,7 +2614,7 @@ nsEventStateManager::MaybeDispatchMouseEventToIframe( void -nsEventStateManager::GenerateMouseEnterExit(nsIPresContext* aPresContext, +nsEventStateManager::GenerateMouseEnterExit(nsPresContext* aPresContext, nsGUIEvent* aEvent) { // Hold onto old target content through the event and reset after. @@ -2731,7 +2731,7 @@ nsEventStateManager::GenerateMouseEnterExit(nsIPresContext* aPresContext, } void -nsEventStateManager::GenerateDragDropEnterExit(nsIPresContext* aPresContext, +nsEventStateManager::GenerateDragDropEnterExit(nsPresContext* aPresContext, nsGUIEvent* aEvent) { //Hold onto old target content through the event and reset after. @@ -2863,7 +2863,7 @@ nsEventStateManager::GenerateDragDropEnterExit(nsIPresContext* aPresContext, } nsresult -nsEventStateManager::SetClickCount(nsIPresContext* aPresContext, +nsEventStateManager::SetClickCount(nsPresContext* aPresContext, nsMouseEvent *aEvent, nsEventStatus* aStatus) { @@ -2921,7 +2921,7 @@ nsEventStateManager::SetClickCount(nsIPresContext* aPresContext, } nsresult -nsEventStateManager::CheckForAndDispatchClick(nsIPresContext* aPresContext, +nsEventStateManager::CheckForAndDispatchClick(nsPresContext* aPresContext, nsMouseEvent *aEvent, nsEventStatus* aStatus) { @@ -3037,7 +3037,7 @@ PrintDocTree(nsIDocShellTreeNode * aParentNode, int aLevel) parentAsItem->GetItemType(&type); nsCOMPtr presShell; parentAsDocShell->GetPresShell(getter_AddRefs(presShell)); - nsCOMPtr presContext; + nsCOMPtr presContext; parentAsDocShell->GetPresContext(getter_AddRefs(presContext)); nsCOMPtr doc; presShell->GetDocument(getter_AddRefs(doc)); @@ -3332,7 +3332,7 @@ nsEventStateManager::ShiftFocusInternal(PRBool aForward, nsIContent* aStart) nsIContent *docContent = parent_doc->FindContentForSubDocument(mDocument); - nsCOMPtr parentPC; + nsCOMPtr parentPC; parentShell->GetPresContext(getter_AddRefs(parentPC)); nsIEventStateManager *parentESM = parentPC->EventStateManager(); @@ -3977,7 +3977,7 @@ nsEventStateManager::SetContentState(nsIContent *aContent, PRInt32 aState) } nsresult -nsEventStateManager::SendFocusBlur(nsIPresContext* aPresContext, +nsEventStateManager::SendFocusBlur(nsPresContext* aPresContext, nsIContent *aContent, PRBool aEnsureWindowHasFocus) { @@ -4023,7 +4023,7 @@ nsEventStateManager::SendFocusBlur(nsIPresContext* aPresContext, if (shell) { kungFuDeathGrip = shell->GetViewManager(); - nsCOMPtr oldPresContext; + nsCOMPtr oldPresContext; shell->GetPresContext(getter_AddRefs(oldPresContext)); //fire blur @@ -4421,7 +4421,7 @@ nsEventStateManager::DispatchNewEvent(nsISupports* aTarget, nsIDOMEvent* aEvent, } void -nsEventStateManager::EnsureDocument(nsIPresContext* aPresContext) +nsEventStateManager::EnsureDocument(nsPresContext* aPresContext) { if (!mDocument) EnsureDocument(aPresContext->PresShell()); @@ -4435,7 +4435,7 @@ nsEventStateManager::EnsureDocument(nsIPresShell* aPresShell) } void -nsEventStateManager::FlushPendingEvents(nsIPresContext* aPresContext) +nsEventStateManager::FlushPendingEvents(nsPresContext* aPresContext) { NS_PRECONDITION(nsnull != aPresContext, "nsnull ptr"); nsIPresShell *shell = aPresContext->GetPresShell(); @@ -5068,7 +5068,7 @@ nsEventStateManager::TabIntoDocument(nsIDocShell* aDocShell, else { aDocShell->SetHasFocus(PR_FALSE); - nsCOMPtr pc; + nsCOMPtr pc; aDocShell->GetPresContext(getter_AddRefs(pc)); if (pc) { nsIEventStateManager *docESM = pc->EventStateManager(); diff --git a/mozilla/content/events/src/nsEventStateManager.h b/mozilla/content/events/src/nsEventStateManager.h index 99999058ba2..dcd70ea00e3 100644 --- a/mozilla/content/events/src/nsEventStateManager.h +++ b/mozilla/content/events/src/nsEventStateManager.h @@ -89,7 +89,7 @@ public: * PostHandleEvent. Any centralized event processing which must occur before * DOM or frame event handling should occur here as well. */ - NS_IMETHOD PreHandleEvent(nsIPresContext* aPresContext, + NS_IMETHOD PreHandleEvent(nsPresContext* aPresContext, nsEvent *aEvent, nsIFrame* aTargetFrame, nsEventStatus* aStatus, @@ -100,7 +100,7 @@ public: * also contain any centralized event processing which must occur after * DOM and frame processing. */ - NS_IMETHOD PostHandleEvent(nsIPresContext* aPresContext, + NS_IMETHOD PostHandleEvent(nsPresContext* aPresContext, nsEvent *aEvent, nsIFrame* aTargetFrame, nsEventStatus* aStatus, @@ -111,7 +111,7 @@ public: NS_IMETHOD SetCurrentEvent(nsEvent *aEvent) { mCurrentEvent = aEvent; return NS_OK; } - NS_IMETHOD SetPresContext(nsIPresContext* aPresContext); + NS_IMETHOD SetPresContext(nsPresContext* aPresContext); NS_IMETHOD ClearFrameRefs(nsIFrame* aFrame); NS_IMETHOD GetEventTarget(nsIFrame **aFrame); @@ -149,22 +149,22 @@ public: protected: friend class CurrentEventShepherd; - void UpdateCursor(nsIPresContext* aPresContext, nsEvent* aEvent, nsIFrame* aTargetFrame, nsEventStatus* aStatus); + void UpdateCursor(nsPresContext* aPresContext, nsEvent* aEvent, nsIFrame* aTargetFrame, nsEventStatus* aStatus); /** * Turn a GUI mouse event into a mouse event targeted at the specified * content and frame. This will fix the frame if it goes away during the * event, as well. */ - void DispatchMouseEvent(nsIPresContext* aPresContext, + void DispatchMouseEvent(nsPresContext* aPresContext, nsGUIEvent* aEvent, PRUint32 aMessage, nsIContent* aTargetContent, nsIFrame*& aTargetFrame, nsIContent* aRelatedContent); - void MaybeDispatchMouseEventToIframe(nsIPresContext* aPresContext, nsGUIEvent* aEvent, PRUint32 aMessage); - void GenerateMouseEnterExit(nsIPresContext* aPresContext, nsGUIEvent* aEvent); - void GenerateDragDropEnterExit(nsIPresContext* aPresContext, nsGUIEvent* aEvent); - nsresult SetClickCount(nsIPresContext* aPresContext, nsMouseEvent *aEvent, nsEventStatus* aStatus); - nsresult CheckForAndDispatchClick(nsIPresContext* aPresContext, nsMouseEvent *aEvent, nsEventStatus* aStatus); + void MaybeDispatchMouseEventToIframe(nsPresContext* aPresContext, nsGUIEvent* aEvent, PRUint32 aMessage); + void GenerateMouseEnterExit(nsPresContext* aPresContext, nsGUIEvent* aEvent); + void GenerateDragDropEnterExit(nsPresContext* aPresContext, nsGUIEvent* aEvent); + nsresult SetClickCount(nsPresContext* aPresContext, nsMouseEvent *aEvent, nsEventStatus* aStatus); + nsresult CheckForAndDispatchClick(nsPresContext* aPresContext, nsMouseEvent *aEvent, nsEventStatus* aStatus); PRBool ChangeFocus(nsIContent* aFocus, PRInt32 aFocusedWith); nsresult GetNextTabbableContent(nsIContent* aRootContent, nsIContent* aStartContent, @@ -176,11 +176,11 @@ protected: void TabIndexFrom(nsIContent *aFrom, PRInt32 *aOutIndex); PRInt32 GetNextTabIndex(nsIContent* aParent, PRBool foward); - nsresult SendFocusBlur(nsIPresContext* aPresContext, nsIContent *aContent, PRBool aEnsureWindowHasFocus); + nsresult SendFocusBlur(nsPresContext* aPresContext, nsIContent *aContent, PRBool aEnsureWindowHasFocus); PRBool CheckDisabled(nsIContent* aContent); void EnsureDocument(nsIPresShell* aPresShell); - void EnsureDocument(nsIPresContext* aPresContext); - void FlushPendingEvents(nsIPresContext* aPresContext); + void EnsureDocument(nsPresContext* aPresContext); + void FlushPendingEvents(nsPresContext* aPresContext); nsIFocusController* GetFocusControllerForDocument(nsIDocument* aDocument); typedef enum { @@ -188,7 +188,7 @@ protected: eAccessKeyProcessingUp, eAccessKeyProcessingDown } ProcessingAccessKeyState; - void HandleAccessKey(nsIPresContext* aPresContext, nsKeyEvent* aEvent, nsEventStatus* aStatus, PRInt32 aChildOffset, ProcessingAccessKeyState aAccessKeyState); + void HandleAccessKey(nsPresContext* aPresContext, nsKeyEvent* aEvent, nsEventStatus* aStatus, PRInt32 aChildOffset, ProcessingAccessKeyState aAccessKeyState); //--------------------------------------------- // DocShell Focus Traversal Methods @@ -210,10 +210,10 @@ protected: // These functions are for mousewheel scrolling nsIScrollableView* GetNearestScrollingView(nsIView* aView); nsresult GetParentScrollingView(nsInputEvent* aEvent, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsIFrame* &targetOuterFrame, - nsIPresContext* &presCtxOuter); - nsresult DoScrollText(nsIPresContext* aPresContext, + nsPresContext* &presCtxOuter); + nsresult DoScrollText(nsPresContext* aPresContext, nsIFrame* aTargetFrame, nsInputEvent* aEvent, PRInt32 aNumLines, @@ -227,9 +227,9 @@ protected: // end mousewheel functions // routines for the d&d gesture tracking state machine - void BeginTrackingDragGesture ( nsIPresContext* aPresContext, nsGUIEvent* inDownEvent, nsIFrame* inDownFrame ) ; + void BeginTrackingDragGesture ( nsPresContext* aPresContext, nsGUIEvent* inDownEvent, nsIFrame* inDownFrame ) ; void StopTrackingDragGesture ( ) ; - void GenerateDragGesture ( nsIPresContext* aPresContext, nsGUIEvent *aEvent ) ; + void GenerateDragGesture ( nsPresContext* aPresContext, nsGUIEvent *aEvent ) ; PRBool IsTrackingDragGesture ( ) const { return mIsTrackingDragGesture; } PRBool mSuppressFocusChange; // Used only for Ender text fields to suppress a focus firing on mouse down @@ -241,7 +241,7 @@ protected: // Return the location of the caret nsresult GetDocSelectionLocation(nsIContent **startContent, nsIContent **endContent, nsIFrame **startFrame, PRUint32 *startOffset); - void GetSelection ( nsIFrame* inFrame, nsIPresContext* inPresContext, nsIFrameSelection** outSelection ) ; + void GetSelection ( nsIFrame* inFrame, nsPresContext* inPresContext, nsIFrameSelection** outSelection ) ; // To be called before and after you fire an event, to update booleans and // such @@ -287,7 +287,7 @@ protected: nsCOMPtr mFirstMouseOverEventElement; nsCOMPtr mFirstMouseOutEventElement; - nsIPresContext* mPresContext; // Not refcnted + nsPresContext* mPresContext; // Not refcnted nsCOMPtr mDocument; // Doesn't necessarily need to be owner PRUint32 mLClickCount; @@ -322,7 +322,7 @@ protected: #ifdef CLICK_HOLD_CONTEXT_MENUS enum { kClickHoldDelay = 500 } ; // 500ms == 1/2 second - void CreateClickHoldTimer ( nsIPresContext* aPresContext, nsGUIEvent* inMouseDownEvent ) ; + void CreateClickHoldTimer ( nsPresContext* aPresContext, nsGUIEvent* inMouseDownEvent ) ; void KillClickHoldTimer ( ) ; void FireContextClick ( ) ; static void sClickHoldCallback ( nsITimer* aTimer, void* aESM ) ; @@ -332,7 +332,7 @@ protected: // things because we're alerted to when they are going away in ClearFrameRefs(). nsPoint mEventPoint, mEventRefPoint; nsIWidget* mEventDownWidget; // [WEAK] - nsIPresContext* mEventPresContext; // [WEAK] + nsPresContext* mEventPresContext; // [WEAK] nsCOMPtr mClickHoldTimer; #endif diff --git a/mozilla/content/html/content/public/nsIFormControl.h b/mozilla/content/html/content/public/nsIFormControl.h index b6d8726902c..e1e6e4f7daa 100644 --- a/mozilla/content/html/content/public/nsIFormControl.h +++ b/mozilla/content/html/content/public/nsIFormControl.h @@ -39,7 +39,7 @@ #include "nsISupports.h" class nsIDOMHTMLFormElement; -class nsIPresContext; +class nsPresContext; class nsIPresState; class nsIContent; class nsString; diff --git a/mozilla/content/html/content/public/nsIFormSubmission.h b/mozilla/content/html/content/public/nsIFormSubmission.h index e1eb77ad0ec..79df20d9454 100644 --- a/mozilla/content/html/content/public/nsIFormSubmission.h +++ b/mozilla/content/html/content/public/nsIFormSubmission.h @@ -43,7 +43,7 @@ class nsACString; class nsIURI; class nsIInputStream; class nsIHTMLContent; -class nsIPresContext; +class nsPresContext; class nsIContent; class nsIFormControl; class nsIDOMHTMLElement; @@ -83,7 +83,7 @@ public: * @param aRequest (out param) the Request for the submission */ virtual nsresult SubmitTo(nsIURI* aActionURL, const nsAString& aTarget, - nsIContent* aSource, nsIPresContext* aPresContext, + nsIContent* aSource, nsPresContext* aPresContext, nsIDocShell** aDocShell, nsIRequest** aRequest) = 0; @@ -130,7 +130,7 @@ public: * @param aFormSubmission the form submission object (out param) */ nsresult GetSubmissionFromForm(nsIHTMLContent* aForm, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsIFormSubmission** aFormSubmission); diff --git a/mozilla/content/html/content/public/nsIHTMLContent.h b/mozilla/content/html/content/public/nsIHTMLContent.h index 6f03613083c..ad766d219e3 100644 --- a/mozilla/content/html/content/public/nsIHTMLContent.h +++ b/mozilla/content/html/content/public/nsIHTMLContent.h @@ -42,7 +42,7 @@ class nsString; class nsIFrame; class nsIStyleRule; -class nsIPresContext; +class nsPresContext; class nsMappedAttributes; class nsIURI; struct nsRuleData; diff --git a/mozilla/content/html/content/public/nsISelectElement.idl b/mozilla/content/html/content/public/nsISelectElement.idl index 8d88ba4e703..22a750a1cbf 100644 --- a/mozilla/content/html/content/public/nsISelectElement.idl +++ b/mozilla/content/html/content/public/nsISelectElement.idl @@ -39,7 +39,7 @@ interface nsIContent; interface nsIDOMHTMLOptionElement; -interface nsIPresContext; +interface nsPresContext; interface nsIPresState; /** diff --git a/mozilla/content/html/content/src/nsFormSubmission.cpp b/mozilla/content/html/content/src/nsFormSubmission.cpp index 4d7ad4eb019..bc494bb771b 100644 --- a/mozilla/content/html/content/src/nsFormSubmission.cpp +++ b/mozilla/content/html/content/src/nsFormSubmission.cpp @@ -38,7 +38,7 @@ #include "nsIFormSubmission.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsCOMPtr.h" #include "nsIForm.h" #include "nsILinkHandler.h" @@ -112,7 +112,7 @@ public: // nsIFormSubmission // virtual nsresult SubmitTo(nsIURI* aActionURI, const nsAString& aTarget, - nsIContent* aSource, nsIPresContext* aPresContext, + nsIContent* aSource, nsPresContext* aPresContext, nsIDocShell** aDocShell, nsIRequest** aRequest); /** @@ -196,7 +196,7 @@ public: * @param aEncoder the returned encoder [OUT] */ static nsresult GetEncoder(nsIHTMLContent* aForm, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, const nsACString& aCharset, nsISaveAsCharset** aEncoder); /** @@ -1151,7 +1151,7 @@ SendJSWarning(nsIHTMLContent* aContent, nsresult GetSubmissionFromForm(nsIHTMLContent* aForm, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsIFormSubmission** aFormSubmission) { nsresult rv = NS_OK; @@ -1225,7 +1225,7 @@ GetSubmissionFromForm(nsIHTMLContent* aForm, nsresult nsFormSubmission::SubmitTo(nsIURI* aActionURI, const nsAString& aTarget, - nsIContent* aSource, nsIPresContext* aPresContext, + nsIContent* aSource, nsPresContext* aPresContext, nsIDocShell** aDocShell, nsIRequest** aRequest) { nsresult rv; @@ -1327,7 +1327,7 @@ nsFormSubmission::GetSubmitCharset(nsIHTMLContent* aForm, // static nsresult nsFormSubmission::GetEncoder(nsIHTMLContent* aForm, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, const nsACString& aCharset, nsISaveAsCharset** aEncoder) { diff --git a/mozilla/content/html/content/src/nsGenericHTMLElement.cpp b/mozilla/content/html/content/src/nsGenericHTMLElement.cpp index 79aa75d5dbd..a5f49b51190 100644 --- a/mozilla/content/html/content/src/nsGenericHTMLElement.cpp +++ b/mozilla/content/html/content/src/nsGenericHTMLElement.cpp @@ -79,7 +79,7 @@ #include "nsIScrollableViewProvider.h" #include "nsRange.h" #include "nsIPresShell.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIDocShell.h" #include "nsIView.h" #include "nsIViewManager.h" @@ -596,7 +596,7 @@ nsGenericHTMLElement::GetOffsetRect(nsRect& aRect, nsIContent** aOffsetParent) } // Get the Presentation Context from the Shell - nsCOMPtr context; + nsCOMPtr context; presShell->GetPresContext(getter_AddRefs(context)); if (!context) { @@ -970,7 +970,7 @@ nsGenericHTMLElement::GetScrollInfo(nsIScrollableView **aScrollableView, } // Get the presentation context - nsCOMPtr presContext; + nsCOMPtr presContext; presShell->GetPresContext(getter_AddRefs(presContext)); if (!presContext) { return; @@ -1357,7 +1357,7 @@ IsArea(nsIContent *aContent) } nsresult -nsGenericHTMLElement::HandleDOMEventForAnchors(nsIPresContext* aPresContext, +nsGenericHTMLElement::HandleDOMEventForAnchors(nsPresContext* aPresContext, nsEvent* aEvent, nsIDOMEvent** aDOMEvent, PRUint32 aFlags, @@ -2359,7 +2359,7 @@ nsGenericHTMLElement::RestoreFormControlState(nsIHTMLContent* aContent, // XXX This creates a dependency between content and frames nsresult nsGenericHTMLElement::GetPresContext(nsIHTMLContent* aContent, - nsIPresContext** aPresContext) + nsPresContext** aPresContext) { // Get the document nsIDocument* doc = aContent->GetDocument(); @@ -3589,7 +3589,7 @@ nsGenericHTMLFrameElement::SetAttr(PRInt32 aNameSpaceID, nsIAtom* aName, } NS_IMETHODIMP -nsGenericHTMLFrameElement::HandleChromeEvent(nsIPresContext* aPresContext, +nsGenericHTMLFrameElement::HandleChromeEvent(nsPresContext* aPresContext, nsEvent* aEvent, nsIDOMEvent** aDOMEvent, PRUint32 aFlags, @@ -3603,7 +3603,7 @@ nsGenericHTMLFrameElement::HandleChromeEvent(nsIPresContext* aPresContext, void nsGenericHTMLElement::SetElementFocus(PRBool aDoFocus) { - nsCOMPtr presContext; + nsCOMPtr presContext; GetPresContext(this, getter_AddRefs(presContext)); if (!presContext) return; @@ -3638,7 +3638,7 @@ nsGenericHTMLElement::Focus() } void -nsGenericHTMLElement::RemoveFocus(nsIPresContext *aPresContext) +nsGenericHTMLElement::RemoveFocus(nsPresContext *aPresContext) { if (!aPresContext) return; @@ -3688,7 +3688,7 @@ nsGenericHTMLElement::RegUnRegAccessKey(PRBool aDoReg) } // We have an access key, so get the ESM from the pres context. - nsCOMPtr presContext; + nsCOMPtr presContext; GetPresContext(this, getter_AddRefs(presContext)); if (presContext) { diff --git a/mozilla/content/html/content/src/nsGenericHTMLElement.h b/mozilla/content/html/content/src/nsGenericHTMLElement.h index cd7f077d6f0..6850a541cf4 100644 --- a/mozilla/content/html/content/src/nsGenericHTMLElement.h +++ b/mozilla/content/html/content/src/nsGenericHTMLElement.h @@ -189,14 +189,14 @@ public: virtual void DumpContent(FILE* out, PRInt32 aIndent,PRBool aDumpAll) const; #endif virtual PRBool IsContentOfType(PRUint32 aFlags) const; - virtual void RemoveFocus(nsIPresContext *aPresContext); + virtual void RemoveFocus(nsPresContext *aPresContext); virtual PRBool IsFocusable(PRInt32 *aTabIndex = nsnull); /** * Standard anchor HandleDOMEvent, used by A, AREA and LINK (parameters * are the same as HandleDOMEvent) */ - nsresult HandleDOMEventForAnchors(nsIPresContext* aPresContext, + nsresult HandleDOMEventForAnchors(nsPresContext* aPresContext, nsEvent* aEvent, nsIDOMEvent** aDOMEvent, PRUint32 aFlags, @@ -629,7 +629,7 @@ public: * @param aPresContext the presentation context [OUT] */ static nsresult GetPresContext(nsIHTMLContent* aContent, - nsIPresContext** aPresContext); + nsPresContext** aPresContext); // Form Helper Routines /** diff --git a/mozilla/content/html/content/src/nsHTMLAnchorElement.cpp b/mozilla/content/html/content/src/nsHTMLAnchorElement.cpp index a2855377621..e441b19d405 100644 --- a/mozilla/content/html/content/src/nsHTMLAnchorElement.cpp +++ b/mozilla/content/html/content/src/nsHTMLAnchorElement.cpp @@ -48,7 +48,7 @@ #include "nsILink.h" #include "nsHTMLAtoms.h" #include "nsStyleConsts.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIEventStateManager.h" #include "nsIURL.h" #include "nsIEventStateManager.h" @@ -101,10 +101,10 @@ public: virtual void SetDocument(nsIDocument* aDocument, PRBool aDeep, PRBool aCompileEventHandlers); - virtual void SetFocus(nsIPresContext* aPresContext); + virtual void SetFocus(nsPresContext* aPresContext); virtual PRBool IsFocusable(PRBool *aTabIndex = nsnull); - virtual nsresult HandleDOMEvent(nsIPresContext* aPresContext, + virtual nsresult HandleDOMEvent(nsPresContext* aPresContext, nsEvent* aEvent, nsIDOMEvent** aDOMEvent, PRUint32 aFlags, nsEventStatus* aEventStatus); @@ -205,7 +205,7 @@ nsHTMLAnchorElement::Focus() } void -nsHTMLAnchorElement::SetFocus(nsIPresContext* aPresContext) +nsHTMLAnchorElement::SetFocus(nsPresContext* aPresContext) { if (!aPresContext) { return; @@ -262,7 +262,7 @@ nsHTMLAnchorElement::IsFocusable(PRInt32 *aTabIndex) } nsresult -nsHTMLAnchorElement::HandleDOMEvent(nsIPresContext* aPresContext, +nsHTMLAnchorElement::HandleDOMEvent(nsPresContext* aPresContext, nsEvent* aEvent, nsIDOMEvent** aDOMEvent, PRUint32 aFlags, diff --git a/mozilla/content/html/content/src/nsHTMLAppletElement.cpp b/mozilla/content/html/content/src/nsHTMLAppletElement.cpp index 428e6dd92c8..35627e76ce0 100644 --- a/mozilla/content/html/content/src/nsHTMLAppletElement.cpp +++ b/mozilla/content/html/content/src/nsHTMLAppletElement.cpp @@ -41,7 +41,7 @@ #include "nsGenericHTMLElement.h" #include "nsHTMLAtoms.h" #include "nsStyleConsts.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIDocument.h" #include "nsLayoutAtoms.h" diff --git a/mozilla/content/html/content/src/nsHTMLAreaElement.cpp b/mozilla/content/html/content/src/nsHTMLAreaElement.cpp index af0194d133d..ce9330cc89a 100644 --- a/mozilla/content/html/content/src/nsHTMLAreaElement.cpp +++ b/mozilla/content/html/content/src/nsHTMLAreaElement.cpp @@ -44,7 +44,7 @@ #include "nsIPresShell.h" #include "nsHTMLAtoms.h" #include "nsStyleConsts.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIEventStateManager.h" #include "nsIURL.h" #include "nsNetUtil.h" @@ -83,11 +83,11 @@ public: NS_IMETHOD SetLinkState(nsLinkState aState); NS_IMETHOD GetHrefURI(nsIURI** aURI); - virtual nsresult HandleDOMEvent(nsIPresContext* aPresContext, + virtual nsresult HandleDOMEvent(nsPresContext* aPresContext, nsEvent* aEvent, nsIDOMEvent** aDOMEvent, PRUint32 aFlags, nsEventStatus* aEventStatus); - virtual void SetFocus(nsIPresContext* aPresContext); + virtual void SetFocus(nsPresContext* aPresContext); virtual void SetDocument(nsIDocument* aDocument, PRBool aDeep, PRBool aCompileEventHandlers); @@ -165,7 +165,7 @@ nsHTMLAreaElement::SetTarget(const nsAString& aValue) } nsresult -nsHTMLAreaElement::HandleDOMEvent(nsIPresContext* aPresContext, +nsHTMLAreaElement::HandleDOMEvent(nsPresContext* aPresContext, nsEvent* aEvent, nsIDOMEvent** aDOMEvent, PRUint32 aFlags, @@ -176,7 +176,7 @@ nsHTMLAreaElement::HandleDOMEvent(nsIPresContext* aPresContext, } void -nsHTMLAreaElement::SetFocus(nsIPresContext* aPresContext) +nsHTMLAreaElement::SetFocus(nsPresContext* aPresContext) { if (!aPresContext) return; diff --git a/mozilla/content/html/content/src/nsHTMLBRElement.cpp b/mozilla/content/html/content/src/nsHTMLBRElement.cpp index df6ec05588a..81184196fd6 100644 --- a/mozilla/content/html/content/src/nsHTMLBRElement.cpp +++ b/mozilla/content/html/content/src/nsHTMLBRElement.cpp @@ -40,7 +40,7 @@ #include "nsGenericHTMLElement.h" #include "nsHTMLAtoms.h" #include "nsStyleConsts.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsMappedAttributes.h" #include "nsRuleData.h" diff --git a/mozilla/content/html/content/src/nsHTMLBodyElement.cpp b/mozilla/content/html/content/src/nsHTMLBodyElement.cpp index 74cad154ad8..352cafe93ce 100644 --- a/mozilla/content/html/content/src/nsHTMLBodyElement.cpp +++ b/mozilla/content/html/content/src/nsHTMLBodyElement.cpp @@ -43,7 +43,7 @@ #include "nsGenericHTMLElement.h" #include "nsHTMLAtoms.h" #include "nsStyleConsts.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIPresShell.h" #include "nsIDocument.h" #include "nsIHTMLDocument.h" @@ -334,7 +334,7 @@ nsHTMLBodyElement::Get##func_(nsAString& aColor) \ if (NS_CONTENT_ATTR_NOT_THERE == \ GetAttr(kNameSpaceID_None, nsHTMLAtoms::attr_, color)) { \ \ - nsCOMPtr presContext; \ + nsCOMPtr presContext; \ GetPresContext(this, getter_AddRefs(presContext)); \ \ if (presContext) { \ diff --git a/mozilla/content/html/content/src/nsHTMLButtonElement.cpp b/mozilla/content/html/content/src/nsHTMLButtonElement.cpp index b9f1a9af9f4..59d182375dd 100644 --- a/mozilla/content/html/content/src/nsHTMLButtonElement.cpp +++ b/mozilla/content/html/content/src/nsHTMLButtonElement.cpp @@ -43,7 +43,7 @@ #include "nsHTMLAtoms.h" #include "nsIPresShell.h" #include "nsStyleConsts.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIFormControl.h" #include "nsIForm.h" #include "nsIFormSubmission.h" @@ -97,7 +97,7 @@ public: nsIContent* aSubmitElement); // nsIContent overrides... - virtual void SetFocus(nsIPresContext* aPresContext); + virtual void SetFocus(nsPresContext* aPresContext); virtual PRBool IsFocusable(PRInt32 *aTabIndex = nsnull); virtual PRBool ParseAttribute(nsIAtom* aAttribute, const nsAString& aValue, @@ -105,7 +105,7 @@ public: NS_IMETHOD AttributeToString(nsIAtom* aAttribute, const nsHTMLValue& aValue, nsAString& aResult) const; - virtual nsresult HandleDOMEvent(nsIPresContext* aPresContext, + virtual nsresult HandleDOMEvent(nsPresContext* aPresContext, nsEvent* aEvent, nsIDOMEvent** aDOMEvent, PRUint32 aFlags, nsEventStatus* aEventStatus); @@ -203,7 +203,7 @@ nsHTMLButtonElement::Click() if (mDocument) { nsIPresShell *shell = doc->GetShellAt(0); if (shell) { - nsCOMPtr context; + nsCOMPtr context; shell->GetPresContext(getter_AddRefs(context)); if (context) { nsEventStatus status = nsEventStatus_eIgnore; @@ -232,7 +232,7 @@ nsHTMLButtonElement::IsFocusable(PRInt32 *aTabIndex) } void -nsHTMLButtonElement::SetFocus(nsIPresContext* aPresContext) +nsHTMLButtonElement::SetFocus(nsPresContext* aPresContext) { if (!aPresContext) return; @@ -295,7 +295,7 @@ nsHTMLButtonElement::AttributeToString(nsIAtom* aAttribute, } nsresult -nsHTMLButtonElement::HandleDOMEvent(nsIPresContext* aPresContext, +nsHTMLButtonElement::HandleDOMEvent(nsPresContext* aPresContext, nsEvent* aEvent, nsIDOMEvent** aDOMEvent, PRUint32 aFlags, diff --git a/mozilla/content/html/content/src/nsHTMLDelElement.cpp b/mozilla/content/html/content/src/nsHTMLDelElement.cpp index 8ae11c61430..160b6da9355 100644 --- a/mozilla/content/html/content/src/nsHTMLDelElement.cpp +++ b/mozilla/content/html/content/src/nsHTMLDelElement.cpp @@ -40,7 +40,7 @@ #include "nsGenericHTMLElement.h" #include "nsHTMLAtoms.h" #include "nsStyleConsts.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" class nsHTMLModElement : public nsGenericHTMLElement, diff --git a/mozilla/content/html/content/src/nsHTMLDivElement.cpp b/mozilla/content/html/content/src/nsHTMLDivElement.cpp index 0ab809dd486..9f9427f71b0 100644 --- a/mozilla/content/html/content/src/nsHTMLDivElement.cpp +++ b/mozilla/content/html/content/src/nsHTMLDivElement.cpp @@ -40,7 +40,7 @@ #include "nsGenericHTMLElement.h" #include "nsHTMLAtoms.h" #include "nsStyleConsts.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsMappedAttributes.h" // XXX support missing nav attributes? gutter, cols, width diff --git a/mozilla/content/html/content/src/nsHTMLFieldSetElement.cpp b/mozilla/content/html/content/src/nsHTMLFieldSetElement.cpp index 19b2bffed5c..632d1aeca16 100644 --- a/mozilla/content/html/content/src/nsHTMLFieldSetElement.cpp +++ b/mozilla/content/html/content/src/nsHTMLFieldSetElement.cpp @@ -41,7 +41,7 @@ #include "nsGenericHTMLElement.h" #include "nsHTMLAtoms.h" #include "nsStyleConsts.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIForm.h" #include "nsIFormControl.h" diff --git a/mozilla/content/html/content/src/nsHTMLFontElement.cpp b/mozilla/content/html/content/src/nsHTMLFontElement.cpp index 3fbb28dbc53..818536cefe6 100644 --- a/mozilla/content/html/content/src/nsHTMLFontElement.cpp +++ b/mozilla/content/html/content/src/nsHTMLFontElement.cpp @@ -42,7 +42,7 @@ #include "nsHTMLAtoms.h" #include "nsIDeviceContext.h" #include "nsStyleConsts.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsMappedAttributes.h" #include "nsCSSStruct.h" #include "nsRuleData.h" diff --git a/mozilla/content/html/content/src/nsHTMLFormElement.cpp b/mozilla/content/html/content/src/nsHTMLFormElement.cpp index 8ee0668a16d..ecdbbb6122f 100644 --- a/mozilla/content/html/content/src/nsHTMLFormElement.cpp +++ b/mozilla/content/html/content/src/nsHTMLFormElement.cpp @@ -47,7 +47,7 @@ #include "nsGenericHTMLElement.h" #include "nsHTMLAtoms.h" #include "nsStyleConsts.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIDocument.h" #include "nsIPresShell.h" #include "nsIFrame.h" @@ -164,7 +164,7 @@ public: NS_IMETHOD AttributeToString(nsIAtom* aAttribute, const nsHTMLValue& aValue, nsAString& aResult) const; - virtual nsresult HandleDOMEvent(nsIPresContext* aPresContext, + virtual nsresult HandleDOMEvent(nsPresContext* aPresContext, nsEvent* aEvent, nsIDOMEvent** aDOMEvent, PRUint32 aFlags, nsEventStatus* aEventStatus); @@ -199,7 +199,7 @@ public: PRInt32* retval); protected: - nsresult DoSubmitOrReset(nsIPresContext* aPresContext, + nsresult DoSubmitOrReset(nsPresContext* aPresContext, nsEvent* aEvent, PRInt32 aMessage); nsresult DoReset(); @@ -215,7 +215,7 @@ protected: * @param aPresContext the presentation context * @param aEvent the DOM event that was passed to us for the submit */ - nsresult DoSubmit(nsIPresContext* aPresContext, nsEvent* aEvent); + nsresult DoSubmit(nsPresContext* aPresContext, nsEvent* aEvent); /** * Prepare the submission object (called by DoSubmit) @@ -224,7 +224,7 @@ protected: * @param aFormSubmission the submission object * @param aEvent the DOM event that was passed to us for the submit */ - nsresult BuildSubmission(nsIPresContext* aPresContext, + nsresult BuildSubmission(nsPresContext* aPresContext, nsCOMPtr& aFormSubmission, nsEvent* aEvent); /** @@ -233,7 +233,7 @@ protected: * @param aPresContext the presentation context * @param aFormSubmission the submission object */ - nsresult SubmitSubmission(nsIPresContext* aPresContext, + nsresult SubmitSubmission(nsPresContext* aPresContext, nsIFormSubmission* aFormSubmission); /** * Walk over the form elements and call SubmitNamesValues() on them to get @@ -564,7 +564,7 @@ nsHTMLFormElement::Submit() { // Send the submit event nsresult rv = NS_OK; - nsCOMPtr presContext; + nsCOMPtr presContext; GetPresContext(this, getter_AddRefs(presContext)); if (presContext) { if (mPendingSubmission) { @@ -585,7 +585,7 @@ nsHTMLFormElement::Reset() { // Send the reset event nsresult rv = NS_OK; - nsCOMPtr presContext; + nsCOMPtr presContext; GetPresContext(this, getter_AddRefs(presContext)); if (presContext) { // Calling HandleDOMEvent() directly so that reset() will work even if @@ -669,7 +669,7 @@ nsHTMLFormElement::SetDocument(nsIDocument* aDocument, PRBool aDeep, nsresult -nsHTMLFormElement::HandleDOMEvent(nsIPresContext* aPresContext, +nsHTMLFormElement::HandleDOMEvent(nsPresContext* aPresContext, nsEvent* aEvent, nsIDOMEvent** aDOMEvent, PRUint32 aFlags, @@ -756,7 +756,7 @@ nsHTMLFormElement::HandleDOMEvent(nsIPresContext* aPresContext, } nsresult -nsHTMLFormElement::DoSubmitOrReset(nsIPresContext* aPresContext, +nsHTMLFormElement::DoSubmitOrReset(nsPresContext* aPresContext, nsEvent* aEvent, PRInt32 aMessage) { @@ -804,7 +804,7 @@ nsHTMLFormElement::DoReset() } nsresult -nsHTMLFormElement::DoSubmit(nsIPresContext* aPresContext, nsEvent* aEvent) +nsHTMLFormElement::DoSubmit(nsPresContext* aPresContext, nsEvent* aEvent) { NS_ASSERTION(!mIsSubmitting, "Either two people are trying to submit or the " "previous submit was not properly cancelled by the DocShell"); @@ -841,7 +841,7 @@ nsHTMLFormElement::DoSubmit(nsIPresContext* aPresContext, nsEvent* aEvent) } nsresult -nsHTMLFormElement::BuildSubmission(nsIPresContext* aPresContext, +nsHTMLFormElement::BuildSubmission(nsPresContext* aPresContext, nsCOMPtr& aFormSubmission, nsEvent* aEvent) { @@ -873,7 +873,7 @@ nsHTMLFormElement::BuildSubmission(nsIPresContext* aPresContext, } nsresult -nsHTMLFormElement::SubmitSubmission(nsIPresContext* aPresContext, +nsHTMLFormElement::SubmitSubmission(nsPresContext* aPresContext, nsIFormSubmission* aFormSubmission) { nsresult rv; @@ -1207,7 +1207,7 @@ nsHTMLFormElement::FlushPendingSubmission() // // preform the submission with the stored pending submission // - nsCOMPtr presContext; + nsCOMPtr presContext; GetPresContext(this, getter_AddRefs(presContext)); SubmitSubmission(presContext, mPendingSubmission); diff --git a/mozilla/content/html/content/src/nsHTMLFrameSetElement.cpp b/mozilla/content/html/content/src/nsHTMLFrameSetElement.cpp index 7950d1d45b2..f3ed1a49b7c 100644 --- a/mozilla/content/html/content/src/nsHTMLFrameSetElement.cpp +++ b/mozilla/content/html/content/src/nsHTMLFrameSetElement.cpp @@ -40,7 +40,7 @@ #include "nsGenericHTMLElement.h" #include "nsHTMLAtoms.h" #include "nsStyleConsts.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIFrameSetElement.h" #include "nsIHTMLDocument.h" #include "nsIDocument.h" diff --git a/mozilla/content/html/content/src/nsHTMLHRElement.cpp b/mozilla/content/html/content/src/nsHTMLHRElement.cpp index 755a0d69501..1a68f2533c0 100644 --- a/mozilla/content/html/content/src/nsHTMLHRElement.cpp +++ b/mozilla/content/html/content/src/nsHTMLHRElement.cpp @@ -41,7 +41,7 @@ #include "nsGenericHTMLElement.h" #include "nsHTMLAtoms.h" #include "nsStyleConsts.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsMappedAttributes.h" #include "nsRuleData.h" diff --git a/mozilla/content/html/content/src/nsHTMLHeadElement.cpp b/mozilla/content/html/content/src/nsHTMLHeadElement.cpp index e5f0c5839f3..bc0f8e7039a 100644 --- a/mozilla/content/html/content/src/nsHTMLHeadElement.cpp +++ b/mozilla/content/html/content/src/nsHTMLHeadElement.cpp @@ -40,7 +40,7 @@ #include "nsGenericHTMLElement.h" #include "nsHTMLAtoms.h" #include "nsStyleConsts.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" class nsHTMLHeadElement : public nsGenericHTMLElement, diff --git a/mozilla/content/html/content/src/nsHTMLHeadingElement.cpp b/mozilla/content/html/content/src/nsHTMLHeadingElement.cpp index 012ce662bda..232d25f4f17 100644 --- a/mozilla/content/html/content/src/nsHTMLHeadingElement.cpp +++ b/mozilla/content/html/content/src/nsHTMLHeadingElement.cpp @@ -40,7 +40,7 @@ #include "nsGenericHTMLElement.h" #include "nsHTMLAtoms.h" #include "nsStyleConsts.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsMappedAttributes.h" #include "nsRuleData.h" diff --git a/mozilla/content/html/content/src/nsHTMLHtmlElement.cpp b/mozilla/content/html/content/src/nsHTMLHtmlElement.cpp index 7f49a557985..bf0c747cfb6 100644 --- a/mozilla/content/html/content/src/nsHTMLHtmlElement.cpp +++ b/mozilla/content/html/content/src/nsHTMLHtmlElement.cpp @@ -40,7 +40,7 @@ #include "nsGenericHTMLElement.h" #include "nsHTMLAtoms.h" #include "nsStyleConsts.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIDocument.h" diff --git a/mozilla/content/html/content/src/nsHTMLIFrameElement.cpp b/mozilla/content/html/content/src/nsHTMLIFrameElement.cpp index 2f633eed0e0..20e82fbb8bf 100644 --- a/mozilla/content/html/content/src/nsHTMLIFrameElement.cpp +++ b/mozilla/content/html/content/src/nsHTMLIFrameElement.cpp @@ -38,7 +38,7 @@ #include "nsIHTMLContent.h" #include "nsGenericHTMLElement.h" #include "nsHTMLAtoms.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIPresShell.h" #include "nsIDocument.h" #include "nsMappedAttributes.h" diff --git a/mozilla/content/html/content/src/nsHTMLImageElement.cpp b/mozilla/content/html/content/src/nsHTMLImageElement.cpp index 50227f4dbaa..0f5526a3940 100644 --- a/mozilla/content/html/content/src/nsHTMLImageElement.cpp +++ b/mozilla/content/html/content/src/nsHTMLImageElement.cpp @@ -42,7 +42,7 @@ #include "nsImageLoadingContent.h" #include "nsHTMLAtoms.h" #include "nsStyleConsts.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIPresShell.h" #include "nsMappedAttributes.h" #include "nsIJSNativeInitializer.h" @@ -126,7 +126,7 @@ public: nsChangeHint& aHint) const; NS_IMETHOD_(PRBool) IsAttributeMapped(const nsIAtom* aAttribute) const; NS_IMETHOD GetAttributeMappingFunction(nsMapRuleToAttributesFunc& aMapRuleFunc) const; - virtual nsresult HandleDOMEvent(nsIPresContext* aPresContext, + virtual nsresult HandleDOMEvent(nsPresContext* aPresContext, nsEvent* aEvent, nsIDOMEvent** aDOMEvent, PRUint32 aFlags, nsEventStatus* aEventStatus); @@ -270,7 +270,7 @@ nsHTMLImageElement::GetXY() } // Get the Presentation Context from the Shell - nsCOMPtr context; + nsCOMPtr context; presShell->GetPresContext(getter_AddRefs(context)); if (!context) { @@ -355,7 +355,7 @@ nsHTMLImageElement::GetWidthHeight() size.height -= margin.top + margin.bottom; size.width -= margin.left + margin.right; - nsCOMPtr context; + nsCOMPtr context; GetPresContext(this, getter_AddRefs(context)); if (context) { @@ -509,7 +509,7 @@ nsHTMLImageElement::GetAttributeMappingFunction(nsMapRuleToAttributesFunc& aMapR nsresult -nsHTMLImageElement::HandleDOMEvent(nsIPresContext* aPresContext, +nsHTMLImageElement::HandleDOMEvent(nsPresContext* aPresContext, nsEvent* aEvent, nsIDOMEvent** aDOMEvent, PRUint32 aFlags, nsEventStatus* aEventStatus) diff --git a/mozilla/content/html/content/src/nsHTMLInputElement.cpp b/mozilla/content/html/content/src/nsHTMLInputElement.cpp index 883239f42f8..1c21f47b7bd 100644 --- a/mozilla/content/html/content/src/nsHTMLInputElement.cpp +++ b/mozilla/content/html/content/src/nsHTMLInputElement.cpp @@ -55,7 +55,7 @@ #include "nsGenericHTMLElement.h" #include "nsHTMLAtoms.h" #include "nsStyleConsts.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsMappedAttributes.h" #include "nsIFormControl.h" #include "nsIForm.h" @@ -174,7 +174,7 @@ public: virtual PRBool AllowDrop(); // nsIContent - virtual void SetFocus(nsIPresContext* aPresContext); + virtual void SetFocus(nsPresContext* aPresContext); virtual PRBool IsFocusable(PRInt32 *aTabIndex = nsnull); virtual PRBool ParseAttribute(nsIAtom* aAttribute, @@ -188,7 +188,7 @@ public: nsChangeHint& aHint) const; NS_IMETHOD_(PRBool) IsAttributeMapped(const nsIAtom* aAttribute) const; NS_IMETHOD GetAttributeMappingFunction(nsMapRuleToAttributesFunc& aMapRuleFunc) const; - virtual nsresult HandleDOMEvent(nsIPresContext* aPresContext, + virtual nsresult HandleDOMEvent(nsPresContext* aPresContext, nsEvent* aEvent, nsIDOMEvent** aDOMEvent, PRUint32 aFlags, nsEventStatus* aEventStatus); @@ -248,7 +248,7 @@ protected: nsresult GetSelectionRange(PRInt32* aSelectionStart, PRInt32* aSelectionEnd); //Helper method #ifdef ACCESSIBILITY - nsresult FireEventForAccessibility(nsIPresContext* aPresContext, + nsresult FireEventForAccessibility(nsPresContext* aPresContext, const nsAString& aEventType); #endif @@ -273,7 +273,7 @@ protected: void AfterSetAttr(PRInt32 aNameSpaceID, nsIAtom* aName, const nsAString* aValue, PRBool aNotify); - void SelectAll(nsIPresContext* aPresContext); + void SelectAll(nsPresContext* aPresContext); PRBool IsImage() const { nsAutoString tmp; @@ -316,7 +316,7 @@ protected: * MaybeSubmitForm looks for a submit input or a single text control * and submits the form if either is present. */ - nsresult MaybeSubmitForm(nsIPresContext* aPresContext); + nsresult MaybeSubmitForm(nsPresContext* aPresContext); nsCOMPtr mControllers; @@ -702,7 +702,7 @@ nsHTMLInputElement::SetValueInternal(const nsAString& aValue, } // If the frame owns the value, set the value in the frame if (frameOwnsValue) { - nsCOMPtr presContext; + nsCOMPtr presContext; GetPresContext(this, getter_AddRefs(presContext)); formControlFrame->SetProperty(presContext, nsHTMLAtoms::value, aValue); return NS_OK; @@ -902,7 +902,7 @@ nsHTMLInputElement::GetRadioGroupContainer() } nsresult -nsHTMLInputElement::MaybeSubmitForm(nsIPresContext* aPresContext) +nsHTMLInputElement::MaybeSubmitForm(nsPresContext* aPresContext) { if (!mForm) { // Nothing to do here. @@ -979,7 +979,7 @@ nsHTMLInputElement::SetCheckedInternal(PRBool aChecked, PRBool aNotify) // nsIFrame* frame = GetPrimaryFrame(PR_FALSE); if (frame) { - nsCOMPtr presContext; + nsCOMPtr presContext; GetPresContext(this, getter_AddRefs(presContext)); if (mType == NS_FORM_INPUT_CHECKBOX) { @@ -1014,7 +1014,7 @@ nsHTMLInputElement::FireOnChange() // // Since the value is changing, send out an onchange event (bug 23571) // - nsCOMPtr presContext; + nsCOMPtr presContext; GetPresContext(this, getter_AddRefs(presContext)); nsEventStatus status = nsEventStatus_eIgnore; nsEvent event(NS_FORM_CHANGE); @@ -1038,7 +1038,7 @@ nsHTMLInputElement::Focus() } void -nsHTMLInputElement::SetFocus(nsIPresContext* aPresContext) +nsHTMLInputElement::SetFocus(nsPresContext* aPresContext) { if (!aPresContext) return; @@ -1099,7 +1099,7 @@ nsHTMLInputElement::Select() // XXX Bug? We have to give the input focus before contents can be // selected - nsCOMPtr presContext; + nsCOMPtr presContext; GetPresContext(this, getter_AddRefs(presContext)); // If the window is not active, do not allow the select to bring the @@ -1160,7 +1160,7 @@ nsHTMLInputElement::Select() } void -nsHTMLInputElement::SelectAll(nsIPresContext* aPresContext) +nsHTMLInputElement::SelectAll(nsPresContext* aPresContext) { nsIFormControlFrame* formControlFrame = GetFormControlFrame(PR_TRUE); @@ -1196,7 +1196,7 @@ nsHTMLInputElement::Click() mType == NS_FORM_INPUT_IMAGE)) { nsCOMPtr doc = mDocument; // Strong in case the event kills it - nsCOMPtr context; + nsCOMPtr context; nsIPresShell *shell = doc->GetShellAt(0); @@ -1221,7 +1221,7 @@ nsHTMLInputElement::Click() } nsresult -nsHTMLInputElement::HandleDOMEvent(nsIPresContext* aPresContext, +nsHTMLInputElement::HandleDOMEvent(nsPresContext* aPresContext, nsEvent* aEvent, nsIDOMEvent** aDOMEvent, PRUint32 aFlags, @@ -2035,7 +2035,7 @@ nsHTMLInputElement::GetPhonetic(nsAString& aPhonetic) #ifdef ACCESSIBILITY nsresult -nsHTMLInputElement::FireEventForAccessibility(nsIPresContext* aPresContext, +nsHTMLInputElement::FireEventForAccessibility(nsPresContext* aPresContext, const nsAString& aEventType) { nsCOMPtr event; diff --git a/mozilla/content/html/content/src/nsHTMLLIElement.cpp b/mozilla/content/html/content/src/nsHTMLLIElement.cpp index 681c26d5361..e297a41fcbc 100644 --- a/mozilla/content/html/content/src/nsHTMLLIElement.cpp +++ b/mozilla/content/html/content/src/nsHTMLLIElement.cpp @@ -40,7 +40,7 @@ #include "nsGenericHTMLElement.h" #include "nsHTMLAtoms.h" #include "nsStyleConsts.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsMappedAttributes.h" #include "nsRuleData.h" diff --git a/mozilla/content/html/content/src/nsHTMLLabelElement.cpp b/mozilla/content/html/content/src/nsHTMLLabelElement.cpp index dfdc7b1e294..f42bfd3ebfc 100644 --- a/mozilla/content/html/content/src/nsHTMLLabelElement.cpp +++ b/mozilla/content/html/content/src/nsHTMLLabelElement.cpp @@ -42,7 +42,7 @@ #include "nsGenericHTMLElement.h" #include "nsHTMLAtoms.h" #include "nsStyleConsts.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIFormControl.h" #include "nsIForm.h" #include "nsIDOMHTMLDocument.h" @@ -85,11 +85,11 @@ public: // nsIContent virtual void SetDocument(nsIDocument* aDocument, PRBool aDeep, PRBool aCompileEventHandlers); - virtual nsresult HandleDOMEvent(nsIPresContext* aPresContext, + virtual nsresult HandleDOMEvent(nsPresContext* aPresContext, nsEvent* aEvent, nsIDOMEvent** aDOMEvent, PRUint32 aFlags, nsEventStatus* aEventStatus); - virtual void SetFocus(nsIPresContext* aContext); + virtual void SetFocus(nsPresContext* aContext); nsresult SetAttr(PRInt32 aNameSpaceID, nsIAtom* aName, const nsAString& aValue, PRBool aNotify) { @@ -177,7 +177,7 @@ nsHTMLLabelElement::SetDocument(nsIDocument* aDocument, PRBool aDeep, } static PRBool -EventTargetIn(nsIPresContext *aPresContext, nsEvent *aEvent, +EventTargetIn(nsPresContext *aPresContext, nsEvent *aEvent, nsIContent *aChild, nsIContent *aStop) { nsCOMPtr c; @@ -199,7 +199,7 @@ EventTargetIn(nsIPresContext *aPresContext, nsEvent *aEvent, } nsresult -nsHTMLLabelElement::HandleDOMEvent(nsIPresContext* aPresContext, +nsHTMLLabelElement::HandleDOMEvent(nsPresContext* aPresContext, nsEvent* aEvent, nsIDOMEvent** aDOMEvent, PRUint32 aFlags, @@ -259,7 +259,7 @@ nsHTMLLabelElement::HandleDOMEvent(nsIPresContext* aPresContext, } void -nsHTMLLabelElement::SetFocus(nsIPresContext* aContext) +nsHTMLLabelElement::SetFocus(nsPresContext* aContext) { // Since we don't have '-moz-user-focus: normal', the only time // |SetFocus| will be called is when the accesskey is activated. diff --git a/mozilla/content/html/content/src/nsHTMLLegendElement.cpp b/mozilla/content/html/content/src/nsHTMLLegendElement.cpp index 99fcfff8d8b..b8fc18210fe 100644 --- a/mozilla/content/html/content/src/nsHTMLLegendElement.cpp +++ b/mozilla/content/html/content/src/nsHTMLLegendElement.cpp @@ -41,7 +41,7 @@ #include "nsGenericHTMLElement.h" #include "nsHTMLAtoms.h" #include "nsStyleConsts.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIForm.h" #include "nsIFormControl.h" diff --git a/mozilla/content/html/content/src/nsHTMLLinkElement.cpp b/mozilla/content/html/content/src/nsHTMLLinkElement.cpp index a93638d6b6c..ac8e9a4b729 100644 --- a/mozilla/content/html/content/src/nsHTMLLinkElement.cpp +++ b/mozilla/content/html/content/src/nsHTMLLinkElement.cpp @@ -42,7 +42,7 @@ #include "nsILink.h" #include "nsHTMLAtoms.h" #include "nsStyleConsts.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIDOMStyleSheet.h" #include "nsIStyleSheet.h" #include "nsIStyleSheetLinkingElement.h" @@ -102,7 +102,7 @@ public: virtual nsresult UnsetAttr(PRInt32 aNameSpaceID, nsIAtom* aAttribute, PRBool aNotify); - virtual nsresult HandleDOMEvent(nsIPresContext* aPresContext, + virtual nsresult HandleDOMEvent(nsPresContext* aPresContext, nsEvent* aEvent, nsIDOMEvent** aDOMEvent, PRUint32 aFlags, nsEventStatus* aEventStatus); @@ -275,7 +275,7 @@ nsHTMLLinkElement::UnsetAttr(PRInt32 aNameSpaceID, nsIAtom* aAttribute, } nsresult -nsHTMLLinkElement::HandleDOMEvent(nsIPresContext* aPresContext, +nsHTMLLinkElement::HandleDOMEvent(nsPresContext* aPresContext, nsEvent* aEvent, nsIDOMEvent** aDOMEvent, PRUint32 aFlags, diff --git a/mozilla/content/html/content/src/nsHTMLMapElement.cpp b/mozilla/content/html/content/src/nsHTMLMapElement.cpp index 0f1f8dad2ea..a7c0900c9da 100644 --- a/mozilla/content/html/content/src/nsHTMLMapElement.cpp +++ b/mozilla/content/html/content/src/nsHTMLMapElement.cpp @@ -40,7 +40,7 @@ #include "nsGenericHTMLElement.h" #include "nsHTMLAtoms.h" #include "nsStyleConsts.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsContentList.h" #include "nsIDocument.h" #include "nsIHTMLDocument.h" diff --git a/mozilla/content/html/content/src/nsHTMLMetaElement.cpp b/mozilla/content/html/content/src/nsHTMLMetaElement.cpp index 5b7c4286a55..b062577888b 100644 --- a/mozilla/content/html/content/src/nsHTMLMetaElement.cpp +++ b/mozilla/content/html/content/src/nsHTMLMetaElement.cpp @@ -40,7 +40,7 @@ #include "nsGenericHTMLElement.h" #include "nsHTMLAtoms.h" #include "nsStyleConsts.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" class nsHTMLMetaElement : public nsGenericHTMLElement, diff --git a/mozilla/content/html/content/src/nsHTMLOListElement.cpp b/mozilla/content/html/content/src/nsHTMLOListElement.cpp index d0f8bfc1904..dd98f867fad 100644 --- a/mozilla/content/html/content/src/nsHTMLOListElement.cpp +++ b/mozilla/content/html/content/src/nsHTMLOListElement.cpp @@ -42,7 +42,7 @@ #include "nsGenericHTMLElement.h" #include "nsHTMLAtoms.h" #include "nsStyleConsts.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsMappedAttributes.h" #include "nsRuleData.h" diff --git a/mozilla/content/html/content/src/nsHTMLOptGroupElement.cpp b/mozilla/content/html/content/src/nsHTMLOptGroupElement.cpp index 53013644df0..a8d5e3a7009 100644 --- a/mozilla/content/html/content/src/nsHTMLOptGroupElement.cpp +++ b/mozilla/content/html/content/src/nsHTMLOptGroupElement.cpp @@ -40,7 +40,7 @@ #include "nsGenericHTMLElement.h" #include "nsHTMLAtoms.h" #include "nsStyleConsts.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIFrame.h" #include "nsIFormControlFrame.h" @@ -80,7 +80,7 @@ public: PRBool aDeepSetDocument); virtual nsresult RemoveChildAt(PRUint32 aIndex, PRBool aNotify); - virtual nsresult HandleDOMEvent(nsIPresContext* aPresContext, + virtual nsresult HandleDOMEvent(nsPresContext* aPresContext, nsEvent* aEvent, nsIDOMEvent** aDOMEvent, PRUint32 aFlags, nsEventStatus* aEventStatus); @@ -128,7 +128,7 @@ NS_IMPL_STRING_ATTR(nsHTMLOptGroupElement, Label, label) nsresult -nsHTMLOptGroupElement::HandleDOMEvent(nsIPresContext* aPresContext, +nsHTMLOptGroupElement::HandleDOMEvent(nsPresContext* aPresContext, nsEvent* aEvent, nsIDOMEvent** aDOMEvent, PRUint32 aFlags, diff --git a/mozilla/content/html/content/src/nsHTMLOptionElement.cpp b/mozilla/content/html/content/src/nsHTMLOptionElement.cpp index 40f5cb16358..37679a56075 100644 --- a/mozilla/content/html/content/src/nsHTMLOptionElement.cpp +++ b/mozilla/content/html/content/src/nsHTMLOptionElement.cpp @@ -45,7 +45,7 @@ #include "nsGenericHTMLElement.h" #include "nsHTMLAtoms.h" #include "nsStyleConsts.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIFormControl.h" #include "nsIForm.h" #include "nsIDOMText.h" diff --git a/mozilla/content/html/content/src/nsHTMLParagraphElement.cpp b/mozilla/content/html/content/src/nsHTMLParagraphElement.cpp index 55f8066251b..3070ce186c7 100644 --- a/mozilla/content/html/content/src/nsHTMLParagraphElement.cpp +++ b/mozilla/content/html/content/src/nsHTMLParagraphElement.cpp @@ -40,7 +40,7 @@ #include "nsGenericHTMLElement.h" #include "nsHTMLAtoms.h" #include "nsStyleConsts.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsMappedAttributes.h" #include "nsRuleData.h" diff --git a/mozilla/content/html/content/src/nsHTMLPreElement.cpp b/mozilla/content/html/content/src/nsHTMLPreElement.cpp index 66be0877600..e8f0b948943 100644 --- a/mozilla/content/html/content/src/nsHTMLPreElement.cpp +++ b/mozilla/content/html/content/src/nsHTMLPreElement.cpp @@ -40,7 +40,7 @@ #include "nsGenericHTMLElement.h" #include "nsHTMLAtoms.h" #include "nsStyleConsts.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsMappedAttributes.h" #include "nsRuleData.h" #include "nsCSSStruct.h" diff --git a/mozilla/content/html/content/src/nsHTMLScriptElement.cpp b/mozilla/content/html/content/src/nsHTMLScriptElement.cpp index 7ae5560d9b8..a26e557771f 100644 --- a/mozilla/content/html/content/src/nsHTMLScriptElement.cpp +++ b/mozilla/content/html/content/src/nsHTMLScriptElement.cpp @@ -40,7 +40,7 @@ #include "nsGenericHTMLElement.h" #include "nsHTMLAtoms.h" #include "nsStyleConsts.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsITextContent.h" #include "nsIDocument.h" #include "nsIScriptLoader.h" @@ -551,7 +551,7 @@ nsHTMLScriptElement::ScriptAvailable(nsresult aResult, const nsAString& aScript) { if (!aIsInline && NS_FAILED(aResult)) { - nsCOMPtr presContext; + nsCOMPtr presContext; GetPresContext(this, getter_AddRefs(presContext)); nsEventStatus status = nsEventStatus_eIgnore; @@ -587,7 +587,7 @@ nsHTMLScriptElement::ScriptEvaluated(nsresult aResult, { nsresult rv = NS_OK; if (!aIsInline) { - nsCOMPtr presContext; + nsCOMPtr presContext; GetPresContext(this, getter_AddRefs(presContext)); nsEventStatus status = nsEventStatus_eIgnore; diff --git a/mozilla/content/html/content/src/nsHTMLSelectElement.cpp b/mozilla/content/html/content/src/nsHTMLSelectElement.cpp index cbe33994619..433d4df3fa1 100644 --- a/mozilla/content/html/content/src/nsHTMLSelectElement.cpp +++ b/mozilla/content/html/content/src/nsHTMLSelectElement.cpp @@ -47,7 +47,7 @@ #include "nsGenericHTMLElement.h" #include "nsHTMLAtoms.h" #include "nsStyleConsts.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsMappedAttributes.h" #include "nsIForm.h" #include "nsIFormSubmission.h" @@ -217,12 +217,12 @@ public: PRBool aDeepSetDocument); virtual nsresult RemoveChildAt(PRUint32 aIndex, PRBool aNotify); - virtual nsresult HandleDOMEvent(nsIPresContext* aPresContext, + virtual nsresult HandleDOMEvent(nsPresContext* aPresContext, nsEvent* aEvent, nsIDOMEvent** aDOMEvent, PRUint32 aFlags, nsEventStatus* aEventStatus); - virtual void SetFocus(nsIPresContext* aPresContext); + virtual void SetFocus(nsPresContext* aPresContext); virtual PRBool IsFocusable(PRInt32 *aTabIndex = nsnull); // Overriden nsIFormControl methods @@ -284,7 +284,7 @@ protected: * @param aNotify whether to notify the style system and such */ void OnOptionSelected(nsISelectControlFrame* aSelectFrame, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, PRInt32 aIndex, PRBool aSelected, PRBool aNotify); @@ -530,7 +530,7 @@ nsHTMLSelectElement::InsertOptionsIntoList(nsIContent* aOptions, // get into the right state once it's created. nsISelectControlFrame* selectFrame = GetSelectFrame(); - nsCOMPtr presContext; + nsCOMPtr presContext; if (selectFrame) { GetPresContext(this, getter_AddRefs(presContext)); } @@ -619,7 +619,7 @@ nsHTMLSelectElement::RemoveOptionsFromList(nsIContent* aOptions, // Tell the widget we removed the options nsISelectControlFrame* selectFrame = GetSelectFrame(); if (selectFrame) { - nsCOMPtr presContext; + nsCOMPtr presContext; GetPresContext(this, getter_AddRefs(presContext)); for (int i = aListIndex; i < aListIndex + numRemoved; ++i) { selectFrame->RemoveOption(presContext, i); @@ -1153,7 +1153,7 @@ nsHTMLSelectElement::IsOptionSelectedByIndex(PRInt32 aIndex) void nsHTMLSelectElement::OnOptionSelected(nsISelectControlFrame* aSelectFrame, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, PRInt32 aIndex, PRBool aSelected, PRBool aNotify) @@ -1263,7 +1263,7 @@ nsHTMLSelectElement::SetOptionsSelectedByIndex(PRInt32 aStartIndex, nsISelectControlFrame *selectFrame = nsnull; PRBool did_get_frame = PR_FALSE; - nsCOMPtr presContext; + nsCOMPtr presContext; GetPresContext(this, getter_AddRefs(presContext)); if (aIsSelected) { @@ -1597,7 +1597,7 @@ nsHTMLSelectElement::Focus() } void -nsHTMLSelectElement::SetFocus(nsIPresContext* aPresContext) +nsHTMLSelectElement::SetFocus(nsPresContext* aPresContext) { if (!aPresContext) return; @@ -1772,7 +1772,7 @@ nsHTMLSelectElement::GetAttributeMappingFunction(nsMapRuleToAttributesFunc& aMap nsresult -nsHTMLSelectElement::HandleDOMEvent(nsIPresContext* aPresContext, +nsHTMLSelectElement::HandleDOMEvent(nsPresContext* aPresContext, nsEvent* aEvent, nsIDOMEvent** aDOMEvent, PRUint32 aFlags, diff --git a/mozilla/content/html/content/src/nsHTMLSharedElement.cpp b/mozilla/content/html/content/src/nsHTMLSharedElement.cpp index ab7c967c124..75047606699 100644 --- a/mozilla/content/html/content/src/nsHTMLSharedElement.cpp +++ b/mozilla/content/html/content/src/nsHTMLSharedElement.cpp @@ -48,7 +48,7 @@ #include "nsImageLoadingContent.h" #include "nsHTMLAtoms.h" #include "nsStyleConsts.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsRuleData.h" #include "nsMappedAttributes.h" #include "nsStyleContext.h" diff --git a/mozilla/content/html/content/src/nsHTMLSpanElement.cpp b/mozilla/content/html/content/src/nsHTMLSpanElement.cpp index ef7877a7aee..d9ea486a0cc 100644 --- a/mozilla/content/html/content/src/nsHTMLSpanElement.cpp +++ b/mozilla/content/html/content/src/nsHTMLSpanElement.cpp @@ -40,7 +40,7 @@ #include "nsGenericHTMLElement.h" #include "nsHTMLAtoms.h" #include "nsStyleConsts.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIAtom.h" #include "nsRuleData.h" diff --git a/mozilla/content/html/content/src/nsHTMLStyleElement.cpp b/mozilla/content/html/content/src/nsHTMLStyleElement.cpp index 48aa50454cf..679599c1912 100644 --- a/mozilla/content/html/content/src/nsHTMLStyleElement.cpp +++ b/mozilla/content/html/content/src/nsHTMLStyleElement.cpp @@ -42,7 +42,7 @@ #include "nsGenericHTMLElement.h" #include "nsHTMLAtoms.h" #include "nsStyleConsts.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIDOMStyleSheet.h" #include "nsIStyleSheet.h" #include "nsStyleLinkElement.h" diff --git a/mozilla/content/html/content/src/nsHTMLTableCaptionElement.cpp b/mozilla/content/html/content/src/nsHTMLTableCaptionElement.cpp index 2c288c355d2..33b8e020c8b 100644 --- a/mozilla/content/html/content/src/nsHTMLTableCaptionElement.cpp +++ b/mozilla/content/html/content/src/nsHTMLTableCaptionElement.cpp @@ -40,7 +40,7 @@ #include "nsGenericHTMLElement.h" #include "nsHTMLAtoms.h" #include "nsStyleConsts.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsMappedAttributes.h" #include "nsRuleData.h" diff --git a/mozilla/content/html/content/src/nsHTMLTableCellElement.cpp b/mozilla/content/html/content/src/nsHTMLTableCellElement.cpp index 95dc9bcfbcf..94dc59f29f0 100644 --- a/mozilla/content/html/content/src/nsHTMLTableCellElement.cpp +++ b/mozilla/content/html/content/src/nsHTMLTableCellElement.cpp @@ -43,7 +43,7 @@ #include "nsGenericHTMLElement.h" #include "nsHTMLAtoms.h" #include "nsStyleConsts.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsRuleData.h" #include "nsIDocument.h" diff --git a/mozilla/content/html/content/src/nsHTMLTableColElement.cpp b/mozilla/content/html/content/src/nsHTMLTableColElement.cpp index b8a64356ac2..050f742387a 100644 --- a/mozilla/content/html/content/src/nsHTMLTableColElement.cpp +++ b/mozilla/content/html/content/src/nsHTMLTableColElement.cpp @@ -41,7 +41,7 @@ #include "nsGenericHTMLElement.h" #include "nsHTMLAtoms.h" #include "nsStyleConsts.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsRuleData.h" // use the same protection as ancient code did diff --git a/mozilla/content/html/content/src/nsHTMLTableElement.cpp b/mozilla/content/html/content/src/nsHTMLTableElement.cpp index 5f93f3362a4..9513164f899 100644 --- a/mozilla/content/html/content/src/nsHTMLTableElement.cpp +++ b/mozilla/content/html/content/src/nsHTMLTableElement.cpp @@ -47,7 +47,7 @@ #include "nsGenericHTMLElement.h" #include "nsHTMLAtoms.h" #include "nsStyleConsts.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsHTMLParts.h" #include "nsRuleData.h" #include "nsStyleContext.h" diff --git a/mozilla/content/html/content/src/nsHTMLTableRowElement.cpp b/mozilla/content/html/content/src/nsHTMLTableRowElement.cpp index 07251ebda2a..c9bbc87e0bf 100644 --- a/mozilla/content/html/content/src/nsHTMLTableRowElement.cpp +++ b/mozilla/content/html/content/src/nsHTMLTableRowElement.cpp @@ -46,7 +46,7 @@ #include "nsContentList.h" #include "nsHTMLAtoms.h" #include "nsStyleConsts.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsHTMLParts.h" #include "nsRuleData.h" diff --git a/mozilla/content/html/content/src/nsHTMLTableSectionElement.cpp b/mozilla/content/html/content/src/nsHTMLTableSectionElement.cpp index a6ad8ca278d..fe23d5887d4 100644 --- a/mozilla/content/html/content/src/nsHTMLTableSectionElement.cpp +++ b/mozilla/content/html/content/src/nsHTMLTableSectionElement.cpp @@ -42,7 +42,7 @@ #include "nsHTMLAtoms.h" #include "nsHTMLParts.h" #include "nsStyleConsts.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsContentList.h" #include "nsRuleData.h" #include "nsDOMError.h" diff --git a/mozilla/content/html/content/src/nsHTMLTextAreaElement.cpp b/mozilla/content/html/content/src/nsHTMLTextAreaElement.cpp index a94bedf1c71..a52747cc6e7 100644 --- a/mozilla/content/html/content/src/nsHTMLTextAreaElement.cpp +++ b/mozilla/content/html/content/src/nsHTMLTextAreaElement.cpp @@ -51,7 +51,7 @@ #include "nsGenericHTMLElement.h" #include "nsHTMLAtoms.h" #include "nsStyleConsts.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsMappedAttributes.h" #include "nsIFormControlFrame.h" #include "nsITextControlFrame.h" @@ -125,11 +125,11 @@ public: PRInt32 aModType, nsChangeHint& aHint) const; NS_IMETHOD_(PRBool) IsAttributeMapped(const nsIAtom* aAttribute) const; - virtual nsresult HandleDOMEvent(nsIPresContext* aPresContext, + virtual nsresult HandleDOMEvent(nsPresContext* aPresContext, nsEvent* aEvent, nsIDOMEvent** aDOMEvent, PRUint32 aFlags, nsEventStatus* aEventStatus); - virtual void SetFocus(nsIPresContext* aPresContext); + virtual void SetFocus(nsPresContext* aPresContext); virtual nsresult GetInnerHTML(nsAString& aInnerHTML); virtual nsresult SetInnerHTML(const nsAString& aInnerHTML); @@ -149,7 +149,7 @@ protected: created by a parser */ PRPackedBool mDoneAddingChildren; - NS_IMETHOD SelectAll(nsIPresContext* aPresContext); + NS_IMETHOD SelectAll(nsPresContext* aPresContext); /** * Get the value, whether it is from the content or the frame. * @param aValue the value [out] @@ -232,7 +232,7 @@ nsHTMLTextAreaElement::Focus() } void -nsHTMLTextAreaElement::SetFocus(nsIPresContext* aPresContext) +nsHTMLTextAreaElement::SetFocus(nsPresContext* aPresContext) { if (!aPresContext) return; @@ -276,7 +276,7 @@ nsHTMLTextAreaElement::Select() // selected // Just like SetFocus() but without the ScrollIntoView()! - nsCOMPtr presContext; + nsCOMPtr presContext; GetPresContext(this, getter_AddRefs(presContext)); nsEventStatus status = nsEventStatus_eIgnore; @@ -303,7 +303,7 @@ nsHTMLTextAreaElement::Select() } NS_IMETHODIMP -nsHTMLTextAreaElement::SelectAll(nsIPresContext* aPresContext) +nsHTMLTextAreaElement::SelectAll(nsPresContext* aPresContext) { nsIFormControlFrame* formControlFrame = GetFormControlFrame(PR_TRUE); @@ -401,7 +401,7 @@ nsHTMLTextAreaElement::SetValueInternal(const nsAString& aValue, textControlFrame->OwnsValue(&frameOwnsValue); } if (frameOwnsValue) { - nsCOMPtr presContext; + nsCOMPtr presContext; GetPresContext(this, getter_AddRefs(presContext)); formControlFrame->SetProperty(presContext, nsHTMLAtoms::value, aValue); @@ -548,7 +548,7 @@ nsHTMLTextAreaElement::GetAttributeMappingFunction(nsMapRuleToAttributesFunc& aM nsresult -nsHTMLTextAreaElement::HandleDOMEvent(nsIPresContext* aPresContext, +nsHTMLTextAreaElement::HandleDOMEvent(nsPresContext* aPresContext, nsEvent* aEvent, nsIDOMEvent** aDOMEvent, PRUint32 aFlags, diff --git a/mozilla/content/html/content/src/nsHTMLTitleElement.cpp b/mozilla/content/html/content/src/nsHTMLTitleElement.cpp index 901dc5eb4ab..1695788483e 100644 --- a/mozilla/content/html/content/src/nsHTMLTitleElement.cpp +++ b/mozilla/content/html/content/src/nsHTMLTitleElement.cpp @@ -40,7 +40,7 @@ #include "nsGenericHTMLElement.h" #include "nsHTMLAtoms.h" #include "nsStyleConsts.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIDOMText.h" #include "nsIDocument.h" #include "nsIDOMHTMLDocument.h" diff --git a/mozilla/content/html/document/src/nsHTMLDocument.cpp b/mozilla/content/html/document/src/nsHTMLDocument.cpp index 39041b97617..32889736101 100644 --- a/mozilla/content/html/document/src/nsHTMLDocument.cpp +++ b/mozilla/content/html/document/src/nsHTMLDocument.cpp @@ -52,7 +52,7 @@ #include "nsHTMLAtoms.h" #include "nsLayoutAtoms.h" #include "nsIPresShell.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIHTMLContent.h" #include "nsIDOMNode.h" // for Find #include "nsIDOMNodeList.h" @@ -407,7 +407,7 @@ nsHTMLDocument::GetAttrSheetType() } nsresult -nsHTMLDocument::CreateShell(nsIPresContext* aContext, +nsHTMLDocument::CreateShell(nsPresContext* aContext, nsIViewManager* aViewManager, nsStyleSet* aStyleSet, nsIPresShell** aInstancePtrResult) @@ -753,7 +753,7 @@ nsHTMLDocument::StartDocumentLoad(const char* aCommand, nsCOMPtr dcInfo; docShell->GetDocumentCharsetInfo(getter_AddRefs(dcInfo)); - nsCOMPtr cx; + nsCOMPtr cx; docShell->GetPresContext(getter_AddRefs(cx)); if(cx){ mTexttype = GET_BIDI_OPTION_TEXTTYPE(cx->GetBidi()); @@ -1100,7 +1100,7 @@ nsHTMLDocument::SetCompatibilityMode(nsCompatibility aMode) } nsCOMPtr shell = (nsIPresShell*)mPresShells.SafeElementAt(0); if (shell) { - nsCOMPtr pc; + nsCOMPtr pc; shell->GetPresContext(getter_AddRefs(pc)); if (pc) { pc->SetCompatibilityMode(mCompatMode); @@ -2499,7 +2499,7 @@ nsHTMLDocument::GetPixelDimensions(nsIPresShell* aShell, nsresult rv = aShell->GetPrimaryFrameFor(body, &frame); if (NS_SUCCEEDED(rv) && frame) { nsSize size; - nsCOMPtr presContext; + nsCOMPtr presContext; aShell->GetPresContext(getter_AddRefs(presContext)); nsIView* view = frame->GetView(); @@ -2524,7 +2524,7 @@ nsHTMLDocument::GetPixelDimensions(nsIPresShell* aShell, } // Convert from twips to pixels - nsCOMPtr context; + nsCOMPtr context; rv = aShell->GetPresContext(getter_AddRefs(context)); if (NS_SUCCEEDED(rv)) { @@ -2795,7 +2795,7 @@ nsHTMLDocument::GetSelection(nsAString& aReturn) return NS_OK; } - nsCOMPtr cx; + nsCOMPtr cx; shell->GetPresContext(getter_AddRefs(cx)); NS_ENSURE_TRUE(cx, NS_OK); @@ -3548,7 +3548,7 @@ nsHTMLDocument::SetDesignMode(const nsAString & aDesignMode) nsCOMPtr shell = (nsIPresShell*)mPresShells.SafeElementAt(0); NS_ENSURE_TRUE(shell, NS_ERROR_FAILURE); - nsCOMPtr cx; + nsCOMPtr cx; shell->GetPresContext(getter_AddRefs(cx)); NS_ENSURE_TRUE(cx, NS_ERROR_FAILURE); diff --git a/mozilla/content/html/document/src/nsHTMLDocument.h b/mozilla/content/html/document/src/nsHTMLDocument.h index b564cc3d6c6..3ff0e760270 100644 --- a/mozilla/content/html/document/src/nsHTMLDocument.h +++ b/mozilla/content/html/document/src/nsHTMLDocument.h @@ -86,7 +86,7 @@ public: virtual void ResetToURI(nsIURI* aURI, nsILoadGroup* aLoadGroup); virtual nsStyleSet::sheetType GetAttrSheetType(); - virtual nsresult CreateShell(nsIPresContext* aContext, + virtual nsresult CreateShell(nsPresContext* aContext, nsIViewManager* aViewManager, nsStyleSet* aStyleSet, nsIPresShell** aInstancePtrResult); diff --git a/mozilla/content/html/document/src/nsImageDocument.cpp b/mozilla/content/html/document/src/nsImageDocument.cpp index 16a606ba9ec..a7a582e7388 100644 --- a/mozilla/content/html/document/src/nsImageDocument.cpp +++ b/mozilla/content/html/document/src/nsImageDocument.cpp @@ -53,7 +53,7 @@ #include "imgIContainer.h" #include "imgIDecoderObserver.h" #include "nsIPresShell.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsStyleContext.h" #include "nsAutoPtr.h" #include "nsMediaDocument.h" @@ -556,7 +556,7 @@ nsImageDocument::CheckOverflowing() return NS_OK; } - nsCOMPtr context; + nsCOMPtr context; shell->GetPresContext(getter_AddRefs(context)); nsRect visibleArea = context->GetVisibleArea(); diff --git a/mozilla/content/html/document/src/nsMediaDocument.cpp b/mozilla/content/html/document/src/nsMediaDocument.cpp index 73bafde483e..cdd674fb6df 100644 --- a/mozilla/content/html/document/src/nsMediaDocument.cpp +++ b/mozilla/content/html/document/src/nsMediaDocument.cpp @@ -39,7 +39,7 @@ #include "nsMediaDocument.h" #include "nsHTMLAtoms.h" #include "nsRect.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIPresShell.h" #include "nsIScrollable.h" #include "nsIViewManager.h" @@ -282,7 +282,7 @@ nsMediaDocument::StartLayout() shell->BeginObservingDocument(); // Initial-reflow this time. - nsCOMPtr context; + nsCOMPtr context; shell->GetPresContext(getter_AddRefs(context)); nsRect visibleArea = context->GetVisibleArea(); shell->InitialReflow(visibleArea.width, visibleArea.height); diff --git a/mozilla/content/html/style/public/nsICSSLoader.h b/mozilla/content/html/style/public/nsICSSLoader.h index 76671b1ef7e..4a3a924b086 100644 --- a/mozilla/content/html/style/public/nsICSSLoader.h +++ b/mozilla/content/html/style/public/nsICSSLoader.h @@ -46,7 +46,7 @@ class nsIAtom; class nsIURI; class nsICSSParser; class nsICSSStyleSheet; -class nsIPresContext; +class nsPresContext; class nsIContent; class nsIParser; class nsIDocument; diff --git a/mozilla/content/html/style/public/nsStyleUtil.h b/mozilla/content/html/style/public/nsStyleUtil.h index 0c08498647a..5774c0788a7 100644 --- a/mozilla/content/html/style/public/nsStyleUtil.h +++ b/mozilla/content/html/style/public/nsStyleUtil.h @@ -38,7 +38,7 @@ #define nsStyleUtil_h___ #include "nsCoord.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsILinkHandler.h" // for nsLinkState struct nsStyleBackground; @@ -56,21 +56,21 @@ public: static float GetScalingFactor(PRInt32 aScaler); static nscoord CalcFontPointSize(PRInt32 aHTMLSize, PRInt32 aBasePointSize, - float aScalingFactor, nsIPresContext* aPresContext, + float aScalingFactor, nsPresContext* aPresContext, nsFontSizeType aFontSizeType = eFontSize_HTML); static nscoord FindNextSmallerFontSize(nscoord aFontSize, PRInt32 aBasePointSize, - float aScalingFactor, nsIPresContext* aPresContext, + float aScalingFactor, nsPresContext* aPresContext, nsFontSizeType aFontSizeType = eFontSize_HTML); static nscoord FindNextLargerFontSize(nscoord aFontSize, PRInt32 aBasePointSize, - float aScalingFactor, nsIPresContext* aPresContext, + float aScalingFactor, nsPresContext* aPresContext, nsFontSizeType aFontSizeType = eFontSize_HTML); static PRInt32 ConstrainFontWeight(PRInt32 aWeight); - static PRBool IsHTMLLink(nsIContent *aContent, nsIAtom *aTag, nsIPresContext *aPresContext, nsLinkState *aState); - static PRBool IsSimpleXlink(nsIContent *aContent, nsIPresContext *aPresContext, nsLinkState *aState); + static PRBool IsHTMLLink(nsIContent *aContent, nsIAtom *aTag, nsPresContext *aPresContext, nsLinkState *aState); + static PRBool IsSimpleXlink(nsIContent *aContent, nsPresContext *aPresContext, nsLinkState *aState); }; diff --git a/mozilla/content/html/style/src/nsCSSRule.h b/mozilla/content/html/style/src/nsCSSRule.h index 366c97d0e8f..575987534b8 100644 --- a/mozilla/content/html/style/src/nsCSSRule.h +++ b/mozilla/content/html/style/src/nsCSSRule.h @@ -41,7 +41,7 @@ class nsIStyleSheet; class nsICSSStyleSheet; -class nsIPresContext; +class nsPresContext; struct nsRuleData; class nsICSSGroupRule; diff --git a/mozilla/content/html/style/src/nsCSSRuleProcessor.h b/mozilla/content/html/style/src/nsCSSRuleProcessor.h index 95430f45192..5e6c88ca1b3 100644 --- a/mozilla/content/html/style/src/nsCSSRuleProcessor.h +++ b/mozilla/content/html/style/src/nsCSSRuleProcessor.h @@ -82,7 +82,7 @@ public: nsReStyleHint* aResult); protected: - RuleCascadeData* GetRuleCascade(nsIPresContext* aPresContext, nsIAtom* aMedium); + RuleCascadeData* GetRuleCascade(nsPresContext* aPresContext, nsIAtom* aMedium); nsCOMArray mSheets; diff --git a/mozilla/content/html/style/src/nsCSSStyleRule.cpp b/mozilla/content/html/style/src/nsCSSStyleRule.cpp index 0c1b5f6a39a..d94047c0b23 100644 --- a/mozilla/content/html/style/src/nsCSSStyleRule.cpp +++ b/mozilla/content/html/style/src/nsCSSStyleRule.cpp @@ -45,7 +45,7 @@ #include "nsICSSParser.h" #include "nsICSSLoader.h" #include "nsIURL.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIDocument.h" #include "nsIDeviceContext.h" #include "nsIAtom.h" diff --git a/mozilla/content/html/style/src/nsCSSStyleSheet.cpp b/mozilla/content/html/style/src/nsCSSStyleSheet.cpp index ef5ec04c101..76dcf1d59d9 100644 --- a/mozilla/content/html/style/src/nsCSSStyleSheet.cpp +++ b/mozilla/content/html/style/src/nsCSSStyleSheet.cpp @@ -60,7 +60,7 @@ #include "nsIMediaList.h" #include "nsIStyledContent.h" #include "nsIDocument.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIEventStateManager.h" #include "nsHTMLAtoms.h" #include "nsLayoutAtoms.h" @@ -2967,7 +2967,7 @@ NS_IMPL_ISUPPORTS1(nsCSSRuleProcessor, nsIStyleRuleProcessor) MOZ_DECL_CTOR_COUNTER(RuleProcessorData) -RuleProcessorData::RuleProcessorData(nsIPresContext* aPresContext, +RuleProcessorData::RuleProcessorData(nsPresContext* aPresContext, nsIContent* aContent, nsRuleWalker* aRuleWalker, nsCompatibility* aCompat /*= nsnull*/) @@ -4197,7 +4197,7 @@ static void PutRulesInList(nsObjectHashtable* aRuleArrays, } RuleCascadeData* -nsCSSRuleProcessor::GetRuleCascade(nsIPresContext* aPresContext, +nsCSSRuleProcessor::GetRuleCascade(nsPresContext* aPresContext, nsIAtom* aMedium) { RuleCascadeData **cascadep = &mRuleCascades; diff --git a/mozilla/content/html/style/src/nsComputedDOMStyle.cpp b/mozilla/content/html/style/src/nsComputedDOMStyle.cpp index 5dfdb339ed1..10bf12865a0 100644 --- a/mozilla/content/html/style/src/nsComputedDOMStyle.cpp +++ b/mozilla/content/html/style/src/nsComputedDOMStyle.cpp @@ -55,7 +55,7 @@ #include "nsLayoutAtoms.h" #include "nsThemeConstants.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIDocument.h" #include "nsCSSPseudoElements.h" @@ -194,7 +194,7 @@ nsComputedDOMStyle::Init(nsIDOMElement *aElement, } } - nsCOMPtr presCtx; + nsCOMPtr presCtx; aPresShell->GetPresContext(getter_AddRefs(presCtx)); @@ -615,7 +615,7 @@ nsComputedDOMStyle::GetFontFamily(nsIFrame *aFrame, if (font) { nsCOMPtr presShell = do_QueryReferent(mPresShellWeak); NS_ASSERTION(presShell, "pres shell is required"); - nsCOMPtr presContext; + nsCOMPtr presContext; presShell->GetPresContext(getter_AddRefs(presContext)); NS_ASSERTION(presContext, "pres context is required"); @@ -2783,7 +2783,7 @@ nsComputedDOMStyle::GetAbsoluteOffset(PRUint8 aSide, nsIFrame* aFrame, // scrollbars. We have to do some extra work. nsCOMPtr presShell = do_QueryReferent(mPresShellWeak); NS_ASSERTION(presShell, "Must have a presshell!"); - nsCOMPtr presContext; + nsCOMPtr presContext; presShell->GetPresContext(getter_AddRefs(presContext)); // the first child in the default frame list is what we want nsIFrame* scrollingChild = container->GetFirstChild(nsnull); diff --git a/mozilla/content/html/style/src/nsHTMLCSSStyleSheet.cpp b/mozilla/content/html/style/src/nsHTMLCSSStyleSheet.cpp index df2ce33f833..b9d4ee0b2fb 100644 --- a/mozilla/content/html/style/src/nsHTMLCSSStyleSheet.cpp +++ b/mozilla/content/html/style/src/nsHTMLCSSStyleSheet.cpp @@ -47,7 +47,7 @@ #include "nsIFrame.h" #include "nsICSSStyleRule.h" #include "nsIStyleRuleProcessor.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIDocument.h" #include "nsCOMPtr.h" #include "nsRuleWalker.h" diff --git a/mozilla/content/html/style/src/nsHTMLStyleSheet.cpp b/mozilla/content/html/style/src/nsHTMLStyleSheet.cpp index adf110eef83..4ee656544e3 100644 --- a/mozilla/content/html/style/src/nsHTMLStyleSheet.cpp +++ b/mozilla/content/html/style/src/nsHTMLStyleSheet.cpp @@ -54,7 +54,7 @@ #include "nsIFrame.h" #include "nsStyleContext.h" #include "nsHTMLAtoms.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIEventStateManager.h" #include "nsIDocument.h" #include "nsIPresShell.h" @@ -498,7 +498,7 @@ nsHTMLStyleSheet::~nsHTMLStyleSheet() NS_IMPL_ISUPPORTS2(nsHTMLStyleSheet, nsIStyleSheet, nsIStyleRuleProcessor) -static nsresult GetBodyColor(nsIPresContext* aPresContext, nscolor* aColor) +static nsresult GetBodyColor(nsPresContext* aPresContext, nscolor* aColor) { nsCOMPtr doc; nsIPresShell *shell = aPresContext->PresShell(); diff --git a/mozilla/content/html/style/src/nsInspectorCSSUtils.cpp b/mozilla/content/html/style/src/nsInspectorCSSUtils.cpp index ac4fdf67843..7c44694a9ad 100644 --- a/mozilla/content/html/style/src/nsInspectorCSSUtils.cpp +++ b/mozilla/content/html/style/src/nsInspectorCSSUtils.cpp @@ -162,7 +162,7 @@ nsInspectorCSSUtils::GetStyleContextForContent(nsIContent* aContent, if (parent) parentContext = GetStyleContextForContent(parent, nsnull, aPresShell); - nsCOMPtr presContext; + nsCOMPtr presContext; aPresShell->GetPresContext(getter_AddRefs(presContext)); if (!presContext) return nsnull; diff --git a/mozilla/content/html/style/src/nsRuleData.h b/mozilla/content/html/style/src/nsRuleData.h index d387aef80c1..38060f44c20 100644 --- a/mozilla/content/html/style/src/nsRuleData.h +++ b/mozilla/content/html/style/src/nsRuleData.h @@ -46,7 +46,7 @@ struct nsRuleData { nsStyleStructID mSID; PRPackedBool mCanStoreInRuleTree; - nsIPresContext* mPresContext; + nsPresContext* mPresContext; nsStyleContext* mStyleContext; nsPostResolveFunc mPostResolveCallback; nsRuleDataFont* mFontData; // Should always be stack-allocated! We don't own these structures! @@ -67,7 +67,7 @@ struct nsRuleData nsRuleDataColumn* mColumnData; - nsRuleData(const nsStyleStructID& aSID, nsIPresContext* aContext, nsStyleContext* aStyleContext) + nsRuleData(const nsStyleStructID& aSID, nsPresContext* aContext, nsStyleContext* aStyleContext) :mSID(aSID), mPresContext(aContext), mStyleContext(aStyleContext), mPostResolveCallback(nsnull), mFontData(nsnull), mDisplayData(nsnull), mMarginData(nsnull), mListData(nsnull), mPositionData(nsnull), mTableData(nsnull), mColorData(nsnull), mContentData(nsnull), mTextData(nsnull), diff --git a/mozilla/content/html/style/src/nsStyleUtil.cpp b/mozilla/content/html/style/src/nsStyleUtil.cpp index a7b1be92aeb..bc06cf08f53 100644 --- a/mozilla/content/html/style/src/nsStyleUtil.cpp +++ b/mozilla/content/html/style/src/nsStyleUtil.cpp @@ -118,7 +118,7 @@ float nsStyleUtil::GetScalingFactor(PRInt32 aScaler) nscoord nsStyleUtil::CalcFontPointSize(PRInt32 aHTMLSize, PRInt32 aBasePointSize, - float aScalingFactor, nsIPresContext* aPresContext, + float aScalingFactor, nsPresContext* aPresContext, nsFontSizeType aFontSizeType) { #define sFontSizeTableMin 9 @@ -255,7 +255,7 @@ nsStyleUtil::CalcFontPointSize(PRInt32 aHTMLSize, PRInt32 aBasePointSize, //------------------------------------------------------------------------------ nscoord nsStyleUtil::FindNextSmallerFontSize(nscoord aFontSize, PRInt32 aBasePointSize, - float aScalingFactor, nsIPresContext* aPresContext, + float aScalingFactor, nsPresContext* aPresContext, nsFontSizeType aFontSizeType) { PRInt32 index; @@ -323,7 +323,7 @@ nscoord nsStyleUtil::FindNextSmallerFontSize(nscoord aFontSize, PRInt32 aBasePoi //------------------------------------------------------------------------------ nscoord nsStyleUtil::FindNextLargerFontSize(nscoord aFontSize, PRInt32 aBasePointSize, - float aScalingFactor, nsIPresContext* aPresContext, + float aScalingFactor, nsPresContext* aPresContext, nsFontSizeType aFontSizeType) { PRInt32 index; @@ -416,7 +416,7 @@ nsStyleUtil::ConstrainFontWeight(PRInt32 aWeight) /*static*/ -PRBool nsStyleUtil::IsHTMLLink(nsIContent *aContent, nsIAtom *aTag, nsIPresContext *aPresContext, nsLinkState *aState) +PRBool nsStyleUtil::IsHTMLLink(nsIContent *aContent, nsIAtom *aTag, nsPresContext *aPresContext, nsLinkState *aState) { NS_ASSERTION(aContent && aState, "null arg in IsHTMLLink"); @@ -470,7 +470,7 @@ PRBool nsStyleUtil::IsHTMLLink(nsIContent *aContent, nsIAtom *aTag, nsIPresConte } /*static*/ -PRBool nsStyleUtil::IsSimpleXlink(nsIContent *aContent, nsIPresContext *aPresContext, nsLinkState *aState) +PRBool nsStyleUtil::IsSimpleXlink(nsIContent *aContent, nsPresContext *aPresContext, nsLinkState *aState) { // XXX PERF This function will cause serious performance problems on // pages with lots of XLinks. We should be caching the visited diff --git a/mozilla/content/shared/public/nsFrameManager.h b/mozilla/content/shared/public/nsFrameManager.h index fd74a76bdba..20706d74976 100644 --- a/mozilla/content/shared/public/nsFrameManager.h +++ b/mozilla/content/shared/public/nsFrameManager.h @@ -296,12 +296,12 @@ private: friend struct CantRenderReplacedElementEvent; NS_HIDDEN_(nsIPresShell*) GetPresShell() const { return mPresShell; } - NS_HIDDEN_(nsIPresContext*) GetPresContext() const { + NS_HIDDEN_(nsPresContext*) GetPresContext() const { return mPresShell->GetPresContext(); } NS_HIDDEN_(nsChangeHint) - ReResolveStyleContext(nsIPresContext *aPresContext, + ReResolveStyleContext(nsPresContext *aPresContext, nsIFrame *aFrame, nsIContent *aParentContent, nsStyleChangeList *aChangeList, @@ -312,9 +312,9 @@ private: FindPostedEventFor(nsIFrame* aFrame); NS_HIDDEN_(void) DequeuePostedEventFor(nsIFrame* aFrame); - NS_HIDDEN_(void) DestroyPropertyList(nsIPresContext* aPresContext); + NS_HIDDEN_(void) DestroyPropertyList(nsPresContext* aPresContext); NS_HIDDEN_(PropertyList*) GetPropertyListFor(nsIAtom* aPropertyName) const; - NS_HIDDEN_(void) RemoveAllPropertiesFor(nsIPresContext *aPresContext, + NS_HIDDEN_(void) RemoveAllPropertiesFor(nsPresContext *aPresContext, nsIFrame *aFrame); static NS_HIDDEN_(void) diff --git a/mozilla/content/shared/public/nsRuleNode.h b/mozilla/content/shared/public/nsRuleNode.h index ac53ba835e1..d8e926b669c 100644 --- a/mozilla/content/shared/public/nsRuleNode.h +++ b/mozilla/content/shared/public/nsRuleNode.h @@ -39,7 +39,7 @@ #ifndef nsRuleNode_h___ #define nsRuleNode_h___ -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsStyleStruct.h" class nsStyleContext; @@ -69,7 +69,7 @@ struct nsInheritedStyleData #undef STYLE_STRUCT_INHERITED #undef STYLE_STRUCT_RESET - void* operator new(size_t sz, nsIPresContext* aContext) CPP_THROW_NEW { + void* operator new(size_t sz, nsPresContext* aContext) CPP_THROW_NEW { return aContext->AllocateFromShell(sz); }; @@ -85,7 +85,7 @@ struct nsInheritedStyleData #undef STYLE_STRUCT_RESET }; - void Destroy(PRUint32 aBits, nsIPresContext* aContext) { + void Destroy(PRUint32 aBits, nsPresContext* aContext) { #define STYLE_STRUCT_INHERITED(name, checkdata_cb, ctor_args) \ if (m##name##Data && !(aBits & NS_STYLE_INHERIT_BIT(name))) \ m##name##Data->Destroy(aContext); @@ -126,7 +126,7 @@ struct nsResetStyleData #undef STYLE_STRUCT_INHERITED }; - void* operator new(size_t sz, nsIPresContext* aContext) CPP_THROW_NEW { + void* operator new(size_t sz, nsPresContext* aContext) CPP_THROW_NEW { return aContext->AllocateFromShell(sz); } @@ -142,7 +142,7 @@ struct nsResetStyleData #undef STYLE_STRUCT_INHERITED }; - void Destroy(PRUint32 aBits, nsIPresContext* aContext) { + void Destroy(PRUint32 aBits, nsPresContext* aContext) { #define STYLE_STRUCT_RESET(name, checkdata_cb, ctor_args) \ if (m##name##Data && !(aBits & NS_STYLE_INHERIT_BIT(name))) \ m##name##Data->Destroy(aContext); @@ -226,7 +226,7 @@ struct nsCachedStyleData mInheritedData->ClearInheritedData(aBits); } - NS_HIDDEN_(void) Destroy(PRUint32 aBits, nsIPresContext* aContext) { + NS_HIDDEN_(void) Destroy(PRUint32 aBits, nsPresContext* aContext) { if (mResetData) mResetData->Destroy(aBits, aContext); if (mInheritedData) @@ -272,7 +272,7 @@ public: }; private: - nsIPresContext* mPresContext; // Our pres context. + nsPresContext* mPresContext; // Our pres context. nsRuleNode* mParent; // A pointer to the parent node in the tree. // This enables us to walk backwards from the @@ -354,7 +354,7 @@ friend struct nsRuleList; public: // Overloaded new operator. Initializes the memory to 0 and relies on an arena // (which comes from the presShell) to perform the allocation. - NS_HIDDEN_(void*) operator new(size_t sz, nsIPresContext* aContext) CPP_THROW_NEW; + NS_HIDDEN_(void*) operator new(size_t sz, nsPresContext* aContext) CPP_THROW_NEW; NS_HIDDEN_(void) Destroy(); static NS_HIDDEN_(nsILanguageAtomService*) gLangService; @@ -508,7 +508,7 @@ protected: #endif // helpers for |ComputeFontData| that need access to |mNoneBits|: - static NS_HIDDEN_(void) SetFont(nsIPresContext* aPresContext, + static NS_HIDDEN_(void) SetFont(nsPresContext* aPresContext, nsStyleContext* aContext, nscoord aMinFontSize, PRBool aUseDocumentFonts, @@ -518,7 +518,7 @@ protected: const nsStyleFont* aParentFont, nsStyleFont* aFont, PRBool& aInherited); - static NS_HIDDEN_(void) SetGenericFont(nsIPresContext* aPresContext, + static NS_HIDDEN_(void) SetGenericFont(nsPresContext* aPresContext, nsStyleContext* aContext, const nsRuleDataFont& aFontData, PRUint8 aGenericFontID, @@ -571,11 +571,11 @@ protected: #endif public: - nsRuleNode(nsIPresContext* aPresContext, nsIStyleRule* aRule, + nsRuleNode(nsPresContext* aPresContext, nsIStyleRule* aRule, nsRuleNode* aParent) NS_HIDDEN; virtual ~nsRuleNode() NS_HIDDEN; - static NS_HIDDEN_(nsRuleNode*) CreateRootNode(nsIPresContext* aPresContext); + static NS_HIDDEN_(nsRuleNode*) CreateRootNode(nsPresContext* aPresContext); NS_HIDDEN_(nsresult) Transition(nsIStyleRule* aRule, nsRuleNode** aResult); nsRuleNode* GetParent() const { return mParent; } @@ -584,7 +584,7 @@ public: // NOTE: Does not |AddRef|. nsIStyleRule* GetRule() const { return mRule; } // NOTE: Does not |AddRef|. - nsIPresContext* GetPresContext() const { return mPresContext; } + nsPresContext* GetPresContext() const { return mPresContext; } NS_HIDDEN_(nsresult) ClearStyleData(); NS_HIDDEN_(const nsStyleStruct*) GetStyleData(nsStyleStructID aSID, diff --git a/mozilla/content/shared/public/nsStyleContext.h b/mozilla/content/shared/public/nsStyleContext.h index e008e89a4ed..d6525e33aac 100644 --- a/mozilla/content/shared/public/nsStyleContext.h +++ b/mozilla/content/shared/public/nsStyleContext.h @@ -43,16 +43,16 @@ #include "nsRuleNode.h" #include "nsIAtom.h" -class nsIPresContext; +class nsPresContext; class nsStyleContext { public: nsStyleContext(nsStyleContext* aParent, nsIAtom* aPseudoTag, - nsRuleNode* aRuleNode, nsIPresContext* aPresContext) NS_HIDDEN; + nsRuleNode* aRuleNode, nsPresContext* aPresContext) NS_HIDDEN; ~nsStyleContext() NS_HIDDEN; - NS_HIDDEN_(void*) operator new(size_t sz, nsIPresContext* aPresContext) CPP_THROW_NEW; + NS_HIDDEN_(void*) operator new(size_t sz, nsPresContext* aPresContext) CPP_THROW_NEW; NS_HIDDEN_(void) Destroy(); nsrefcnt AddRef() { @@ -71,7 +71,7 @@ public: return mRefCnt; } - nsIPresContext* PresContext() const { return mRuleNode->GetPresContext(); } + nsPresContext* PresContext() const { return mRuleNode->GetPresContext(); } nsStyleContext* GetParent() const { return mParent; } @@ -140,12 +140,12 @@ public: NS_HIDDEN_(nsStyleStruct*) GetUniqueStyleData(const nsStyleStructID& aSID); - NS_HIDDEN_(void) ClearStyleData(nsIPresContext* aPresContext); + NS_HIDDEN_(void) ClearStyleData(nsPresContext* aPresContext); NS_HIDDEN_(nsChangeHint) CalcStyleDifference(nsStyleContext* aOther); #ifdef DEBUG - NS_HIDDEN_(void) DumpRegressionData(nsIPresContext* aPresContext, FILE* out, + NS_HIDDEN_(void) DumpRegressionData(nsPresContext* aPresContext, FILE* out, PRInt32 aIndent); NS_HIDDEN_(void) List(FILE* out, PRInt32 aIndent); @@ -155,7 +155,7 @@ protected: NS_HIDDEN_(void) AppendChild(nsStyleContext* aChild); NS_HIDDEN_(void) RemoveChild(nsStyleContext* aChild); - NS_HIDDEN_(void) ApplyStyleFixups(nsIPresContext* aPresContext); + NS_HIDDEN_(void) ApplyStyleFixups(nsPresContext* aPresContext); nsStyleContext* mParent; nsStyleContext* mChild; @@ -185,5 +185,5 @@ NS_HIDDEN_(already_AddRefed) NS_NewStyleContext(nsStyleContext* aParentContext, nsIAtom* aPseudoTag, nsRuleNode* aRuleNode, - nsIPresContext* aPresContext); + nsPresContext* aPresContext); #endif diff --git a/mozilla/content/shared/public/nsStyleStruct.h b/mozilla/content/shared/public/nsStyleStruct.h index 034d3c27e4f..7ce91f8d309 100644 --- a/mozilla/content/shared/public/nsStyleStruct.h +++ b/mozilla/content/shared/public/nsStyleStruct.h @@ -46,7 +46,7 @@ #include "nsStyleCoord.h" #include "nsStyleConsts.h" #include "nsChangeHint.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIPresShell.h" #include "nsCOMPtr.h" #include "nsIAtom.h" @@ -98,7 +98,7 @@ struct nsStyleFont : public nsStyleStruct { nsStyleFont(void); nsStyleFont(const nsFont& aFont); nsStyleFont(const nsStyleFont& aStyleFont); - nsStyleFont(nsIPresContext *aPresContext); + nsStyleFont(nsPresContext *aPresContext); ~nsStyleFont(void) {}; NS_DEFINE_STATIC_STYLESTRUCTID_ACCESSOR(eStyleStruct_Font) @@ -106,11 +106,11 @@ struct nsStyleFont : public nsStyleStruct { nsChangeHint CalcDifference(const nsStyleFont& aOther) const; static nsChangeHint CalcFontDifference(const nsFont& aFont1, const nsFont& aFont2); - static nscoord ZoomText(nsIPresContext* aPresContext, nscoord aSize); - static nscoord UnZoomText(nsIPresContext* aPresContext, nscoord aSize); + static nscoord ZoomText(nsPresContext* aPresContext, nscoord aSize); + static nscoord UnZoomText(nsPresContext* aPresContext, nscoord aSize); - void* operator new(size_t sz, nsIPresContext* aContext) CPP_THROW_NEW; - void Destroy(nsIPresContext* aContext); + void* operator new(size_t sz, nsPresContext* aContext) CPP_THROW_NEW; + void Destroy(nsPresContext* aContext); PRUint8 mFlags; // [inherited] See nsStyleConsts.h nsFont mFont; // [inherited] @@ -121,7 +121,7 @@ struct nsStyleFont : public nsStyleStruct { }; struct nsStyleColor : public nsStyleStruct { - nsStyleColor(nsIPresContext* aPresContext); + nsStyleColor(nsPresContext* aPresContext); nsStyleColor(const nsStyleColor& aOther); ~nsStyleColor(void) {}; @@ -129,10 +129,10 @@ struct nsStyleColor : public nsStyleStruct { nsChangeHint CalcDifference(const nsStyleColor& aOther) const; - void* operator new(size_t sz, nsIPresContext* aContext) CPP_THROW_NEW { + void* operator new(size_t sz, nsPresContext* aContext) CPP_THROW_NEW { return aContext->AllocateFromShell(sz); } - void Destroy(nsIPresContext* aContext) { + void Destroy(nsPresContext* aContext) { this->~nsStyleColor(); aContext->FreeToShell(sizeof(nsStyleColor), this); }; @@ -143,16 +143,16 @@ struct nsStyleColor : public nsStyleStruct { }; struct nsStyleBackground : public nsStyleStruct { - nsStyleBackground(nsIPresContext* aPresContext); + nsStyleBackground(nsPresContext* aPresContext); nsStyleBackground(const nsStyleBackground& aOther); ~nsStyleBackground(); NS_DEFINE_STATIC_STYLESTRUCTID_ACCESSOR(eStyleStruct_Background) - void* operator new(size_t sz, nsIPresContext* aContext) CPP_THROW_NEW { + void* operator new(size_t sz, nsPresContext* aContext) CPP_THROW_NEW { return aContext->AllocateFromShell(sz); } - void Destroy(nsIPresContext* aContext) { + void Destroy(nsPresContext* aContext) { this->~nsStyleBackground(); aContext->FreeToShell(sizeof(nsStyleBackground), this); }; @@ -207,8 +207,8 @@ struct nsStyleMargin: public nsStyleStruct { NS_DEFINE_STATIC_STYLESTRUCTID_ACCESSOR(eStyleStruct_Margin) - void* operator new(size_t sz, nsIPresContext* aContext) CPP_THROW_NEW; - void Destroy(nsIPresContext* aContext); + void* operator new(size_t sz, nsPresContext* aContext) CPP_THROW_NEW; + void Destroy(nsPresContext* aContext); void RecalcData(); nsChangeHint CalcDifference(const nsStyleMargin& aOther) const; @@ -240,8 +240,8 @@ struct nsStylePadding: public nsStyleStruct { NS_DEFINE_STATIC_STYLESTRUCTID_ACCESSOR(eStyleStruct_Padding) - void* operator new(size_t sz, nsIPresContext* aContext) CPP_THROW_NEW; - void Destroy(nsIPresContext* aContext); + void* operator new(size_t sz, nsPresContext* aContext) CPP_THROW_NEW; + void Destroy(nsPresContext* aContext); void RecalcData(); nsChangeHint CalcDifference(const nsStylePadding& aOther) const; @@ -305,7 +305,7 @@ struct nsBorderColors { struct nsStyleBorder: public nsStyleStruct { nsStyleBorder() :mBorderColors(nsnull) {}; - nsStyleBorder(nsIPresContext* aContext); + nsStyleBorder(nsPresContext* aContext); nsStyleBorder(const nsStyleBorder& aBorder); ~nsStyleBorder(void) { if (mBorderColors) { @@ -317,8 +317,8 @@ struct nsStyleBorder: public nsStyleStruct { NS_DEFINE_STATIC_STYLESTRUCTID_ACCESSOR(eStyleStruct_Border) - void* operator new(size_t sz, nsIPresContext* aContext) CPP_THROW_NEW; - void Destroy(nsIPresContext* aContext); + void* operator new(size_t sz, nsPresContext* aContext) CPP_THROW_NEW; + void Destroy(nsPresContext* aContext); PRBool IsBorderSideVisible(PRUint8 aSide) const; void RecalcData(); @@ -477,16 +477,16 @@ protected: struct nsStyleOutline: public nsStyleStruct { - nsStyleOutline(nsIPresContext* aPresContext); + nsStyleOutline(nsPresContext* aPresContext); nsStyleOutline(const nsStyleOutline& aOutline); ~nsStyleOutline(void) {}; NS_DEFINE_STATIC_STYLESTRUCTID_ACCESSOR(eStyleStruct_Outline) - void* operator new(size_t sz, nsIPresContext* aContext) CPP_THROW_NEW { + void* operator new(size_t sz, nsPresContext* aContext) CPP_THROW_NEW { return aContext->AllocateFromShell(sz); } - void Destroy(nsIPresContext* aContext) { + void Destroy(nsPresContext* aContext) { this->~nsStyleOutline(); aContext->FreeToShell(sizeof(nsStyleOutline), this); }; @@ -566,10 +566,10 @@ struct nsStyleList : public nsStyleStruct { NS_DEFINE_STATIC_STYLESTRUCTID_ACCESSOR(eStyleStruct_List) - void* operator new(size_t sz, nsIPresContext* aContext) CPP_THROW_NEW { + void* operator new(size_t sz, nsPresContext* aContext) CPP_THROW_NEW { return aContext->AllocateFromShell(sz); } - void Destroy(nsIPresContext* aContext) { + void Destroy(nsPresContext* aContext) { this->~nsStyleList(); aContext->FreeToShell(sizeof(nsStyleList), this); }; @@ -589,10 +589,10 @@ struct nsStylePosition : public nsStyleStruct { NS_DEFINE_STATIC_STYLESTRUCTID_ACCESSOR(eStyleStruct_Position) - void* operator new(size_t sz, nsIPresContext* aContext) CPP_THROW_NEW { + void* operator new(size_t sz, nsPresContext* aContext) CPP_THROW_NEW { return aContext->AllocateFromShell(sz); } - void Destroy(nsIPresContext* aContext) { + void Destroy(nsPresContext* aContext) { this->~nsStylePosition(); aContext->FreeToShell(sizeof(nsStylePosition), this); }; @@ -617,10 +617,10 @@ struct nsStyleTextReset : public nsStyleStruct { NS_DEFINE_STATIC_STYLESTRUCTID_ACCESSOR(eStyleStruct_TextReset) - void* operator new(size_t sz, nsIPresContext* aContext) CPP_THROW_NEW { + void* operator new(size_t sz, nsPresContext* aContext) CPP_THROW_NEW { return aContext->AllocateFromShell(sz); } - void Destroy(nsIPresContext* aContext) { + void Destroy(nsPresContext* aContext) { this->~nsStyleTextReset(); aContext->FreeToShell(sizeof(nsStyleTextReset), this); }; @@ -640,10 +640,10 @@ struct nsStyleText : public nsStyleStruct { NS_DEFINE_STATIC_STYLESTRUCTID_ACCESSOR(eStyleStruct_Text) - void* operator new(size_t sz, nsIPresContext* aContext) CPP_THROW_NEW { + void* operator new(size_t sz, nsPresContext* aContext) CPP_THROW_NEW { return aContext->AllocateFromShell(sz); } - void Destroy(nsIPresContext* aContext) { + void Destroy(nsPresContext* aContext) { this->~nsStyleText(); aContext->FreeToShell(sizeof(nsStyleText), this); }; @@ -666,16 +666,16 @@ struct nsStyleText : public nsStyleStruct { }; struct nsStyleVisibility : public nsStyleStruct { - nsStyleVisibility(nsIPresContext* aPresContext); + nsStyleVisibility(nsPresContext* aPresContext); nsStyleVisibility(const nsStyleVisibility& aVisibility); ~nsStyleVisibility() {}; NS_DEFINE_STATIC_STYLESTRUCTID_ACCESSOR(eStyleStruct_Visibility) - void* operator new(size_t sz, nsIPresContext* aContext) CPP_THROW_NEW { + void* operator new(size_t sz, nsPresContext* aContext) CPP_THROW_NEW { return aContext->AllocateFromShell(sz); } - void Destroy(nsIPresContext* aContext) { + void Destroy(nsPresContext* aContext) { this->~nsStyleVisibility(); aContext->FreeToShell(sizeof(nsStyleVisibility), this); }; @@ -703,10 +703,10 @@ struct nsStyleDisplay : public nsStyleStruct { NS_DEFINE_STATIC_STYLESTRUCTID_ACCESSOR(eStyleStruct_Display) - void* operator new(size_t sz, nsIPresContext* aContext) CPP_THROW_NEW { + void* operator new(size_t sz, nsPresContext* aContext) CPP_THROW_NEW { return aContext->AllocateFromShell(sz); } - void Destroy(nsIPresContext* aContext) { + void Destroy(nsPresContext* aContext) { this->~nsStyleDisplay(); aContext->FreeToShell(sizeof(nsStyleDisplay), this); }; @@ -756,10 +756,10 @@ struct nsStyleTable: public nsStyleStruct { NS_DEFINE_STATIC_STYLESTRUCTID_ACCESSOR(eStyleStruct_Table) - void* operator new(size_t sz, nsIPresContext* aContext) CPP_THROW_NEW { + void* operator new(size_t sz, nsPresContext* aContext) CPP_THROW_NEW { return aContext->AllocateFromShell(sz); } - void Destroy(nsIPresContext* aContext) { + void Destroy(nsPresContext* aContext) { this->~nsStyleTable(); aContext->FreeToShell(sizeof(nsStyleTable), this); }; @@ -774,16 +774,16 @@ struct nsStyleTable: public nsStyleStruct { }; struct nsStyleTableBorder: public nsStyleStruct { - nsStyleTableBorder(nsIPresContext* aContext); + nsStyleTableBorder(nsPresContext* aContext); nsStyleTableBorder(const nsStyleTableBorder& aOther); ~nsStyleTableBorder(void); NS_DEFINE_STATIC_STYLESTRUCTID_ACCESSOR(eStyleStruct_TableBorder) - void* operator new(size_t sz, nsIPresContext* aContext) CPP_THROW_NEW { + void* operator new(size_t sz, nsPresContext* aContext) CPP_THROW_NEW { return aContext->AllocateFromShell(sz); } - void Destroy(nsIPresContext* aContext) { + void Destroy(nsPresContext* aContext) { this->~nsStyleTableBorder(); aContext->FreeToShell(sizeof(nsStyleTableBorder), this); }; @@ -842,10 +842,10 @@ struct nsStyleQuotes : public nsStyleStruct { NS_DEFINE_STATIC_STYLESTRUCTID_ACCESSOR(eStyleStruct_Quotes) - void* operator new(size_t sz, nsIPresContext* aContext) CPP_THROW_NEW { + void* operator new(size_t sz, nsPresContext* aContext) CPP_THROW_NEW { return aContext->AllocateFromShell(sz); } - void Destroy(nsIPresContext* aContext) { + void Destroy(nsPresContext* aContext) { this->~nsStyleQuotes(); aContext->FreeToShell(sizeof(nsStyleQuotes), this); }; @@ -912,10 +912,10 @@ struct nsStyleContent: public nsStyleStruct { NS_DEFINE_STATIC_STYLESTRUCTID_ACCESSOR(eStyleStruct_Content) - void* operator new(size_t sz, nsIPresContext* aContext) CPP_THROW_NEW { + void* operator new(size_t sz, nsPresContext* aContext) CPP_THROW_NEW { return aContext->AllocateFromShell(sz); } - void Destroy(nsIPresContext* aContext) { + void Destroy(nsPresContext* aContext) { this->~nsStyleContent(); aContext->FreeToShell(sizeof(nsStyleContent), this); }; @@ -1024,10 +1024,10 @@ struct nsStyleUIReset: public nsStyleStruct { NS_DEFINE_STATIC_STYLESTRUCTID_ACCESSOR(eStyleStruct_UIReset) - void* operator new(size_t sz, nsIPresContext* aContext) CPP_THROW_NEW { + void* operator new(size_t sz, nsPresContext* aContext) CPP_THROW_NEW { return aContext->AllocateFromShell(sz); } - void Destroy(nsIPresContext* aContext) { + void Destroy(nsPresContext* aContext) { this->~nsStyleUIReset(); aContext->FreeToShell(sizeof(nsStyleUIReset), this); }; @@ -1046,10 +1046,10 @@ struct nsStyleUserInterface: public nsStyleStruct { NS_DEFINE_STATIC_STYLESTRUCTID_ACCESSOR(eStyleStruct_UserInterface) - void* operator new(size_t sz, nsIPresContext* aContext) CPP_THROW_NEW { + void* operator new(size_t sz, nsPresContext* aContext) CPP_THROW_NEW { return aContext->AllocateFromShell(sz); } - void Destroy(nsIPresContext* aContext) { + void Destroy(nsPresContext* aContext) { this->~nsStyleUserInterface(); aContext->FreeToShell(sizeof(nsStyleUserInterface), this); }; @@ -1070,10 +1070,10 @@ struct nsStyleXUL : public nsStyleStruct { NS_DEFINE_STATIC_STYLESTRUCTID_ACCESSOR(eStyleStruct_XUL) - void* operator new(size_t sz, nsIPresContext* aContext) CPP_THROW_NEW { + void* operator new(size_t sz, nsPresContext* aContext) CPP_THROW_NEW { return aContext->AllocateFromShell(sz); } - void Destroy(nsIPresContext* aContext) { + void Destroy(nsPresContext* aContext) { this->~nsStyleXUL(); aContext->FreeToShell(sizeof(nsStyleXUL), this); }; @@ -1095,10 +1095,10 @@ struct nsStyleColumn : public nsStyleStruct { NS_DEFINE_STATIC_STYLESTRUCTID_ACCESSOR(eStyleStruct_Column) - void* operator new(size_t sz, nsIPresContext* aContext) CPP_THROW_NEW { + void* operator new(size_t sz, nsPresContext* aContext) CPP_THROW_NEW { return aContext->AllocateFromShell(sz); } - void Destroy(nsIPresContext* aContext) { + void Destroy(nsPresContext* aContext) { this->~nsStyleColumn(); aContext->FreeToShell(sizeof(nsStyleColumn), this); }; @@ -1130,10 +1130,10 @@ struct nsStyleSVG : public nsStyleStruct { NS_DEFINE_STATIC_STYLESTRUCTID_ACCESSOR(eStyleStruct_SVG) - void* operator new(size_t sz, nsIPresContext* aContext) CPP_THROW_NEW { + void* operator new(size_t sz, nsPresContext* aContext) CPP_THROW_NEW { return aContext->AllocateFromShell(sz); } - void Destroy(nsIPresContext* aContext) { + void Destroy(nsPresContext* aContext) { this->~nsStyleSVG(); aContext->FreeToShell(sizeof(nsStyleSVG), this); }; @@ -1164,10 +1164,10 @@ struct nsStyleSVGReset : public nsStyleStruct { NS_DEFINE_STATIC_STYLESTRUCTID_ACCESSOR(eStyleStruct_SVGReset) - void* operator new(size_t sz, nsIPresContext* aContext) CPP_THROW_NEW { + void* operator new(size_t sz, nsPresContext* aContext) CPP_THROW_NEW { return aContext->AllocateFromShell(sz); } - void Destroy(nsIPresContext* aContext) { + void Destroy(nsPresContext* aContext) { this->~nsStyleSVGReset(); aContext->FreeToShell(sizeof(nsStyleSVGReset), this); }; diff --git a/mozilla/content/shared/src/nsStyleStruct.cpp b/mozilla/content/shared/src/nsStyleStruct.cpp index 9ff48068335..6d09458461c 100644 --- a/mozilla/content/shared/src/nsStyleStruct.cpp +++ b/mozilla/content/shared/src/nsStyleStruct.cpp @@ -40,7 +40,7 @@ #include "nsStyleConsts.h" #include "nsString.h" #include "nsUnitConversion.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIDeviceContext.h" #include "nsIStyleRule.h" #include "nsISupportsArray.h" @@ -201,7 +201,7 @@ nsStyleFont::nsStyleFont(const nsStyleFont& aSrc) } -nsStyleFont::nsStyleFont(nsIPresContext* aPresContext) +nsStyleFont::nsStyleFont(nsPresContext* aPresContext) : mFlags(NS_STYLE_FONT_DEFAULT), mFont(*(aPresContext->GetDefaultFont(kPresContext_DefaultVariableFont_ID))) { @@ -209,7 +209,7 @@ nsStyleFont::nsStyleFont(nsIPresContext* aPresContext) } void* -nsStyleFont::operator new(size_t sz, nsIPresContext* aContext) CPP_THROW_NEW { +nsStyleFont::operator new(size_t sz, nsPresContext* aContext) CPP_THROW_NEW { void* result = aContext->AllocateFromShell(sz); if (result) memset(result, 0, sz); @@ -217,7 +217,7 @@ nsStyleFont::operator new(size_t sz, nsIPresContext* aContext) CPP_THROW_NEW { } void -nsStyleFont::Destroy(nsIPresContext* aContext) { +nsStyleFont::Destroy(nsPresContext* aContext) { this->~nsStyleFont(); aContext->FreeToShell(sizeof(nsStyleFont), this); } @@ -231,7 +231,7 @@ nsChangeHint nsStyleFont::CalcDifference(const nsStyleFont& aOther) const } inline float -TextZoomFor(nsIPresContext* aPresContext) +TextZoomFor(nsPresContext* aPresContext) { float textZoom; aPresContext->DeviceContext()->GetTextZoom(textZoom); @@ -239,13 +239,13 @@ TextZoomFor(nsIPresContext* aPresContext) } /* static */ nscoord -nsStyleFont::ZoomText(nsIPresContext *aPresContext, nscoord aSize) +nsStyleFont::ZoomText(nsPresContext *aPresContext, nscoord aSize) { return nscoord(float(aSize) * TextZoomFor(aPresContext)); } /* static */ nscoord -nsStyleFont::UnZoomText(nsIPresContext *aPresContext, nscoord aSize) +nsStyleFont::UnZoomText(nsPresContext *aPresContext, nscoord aSize) { return nscoord(float(aSize) / TextZoomFor(aPresContext)); } @@ -315,7 +315,7 @@ nsStyleMargin::nsStyleMargin(const nsStyleMargin& aSrc) { } void* -nsStyleMargin::operator new(size_t sz, nsIPresContext* aContext) CPP_THROW_NEW { +nsStyleMargin::operator new(size_t sz, nsPresContext* aContext) CPP_THROW_NEW { void* result = aContext->AllocateFromShell(sz); if (result) memset(result, 0, sz); @@ -323,7 +323,7 @@ nsStyleMargin::operator new(size_t sz, nsIPresContext* aContext) CPP_THROW_NEW { } void -nsStyleMargin::Destroy(nsIPresContext* aContext) { +nsStyleMargin::Destroy(nsPresContext* aContext) { this->~nsStyleMargin(); aContext->FreeToShell(sizeof(nsStyleMargin), this); } @@ -372,7 +372,7 @@ nsStylePadding::nsStylePadding(const nsStylePadding& aSrc) { } void* -nsStylePadding::operator new(size_t sz, nsIPresContext* aContext) CPP_THROW_NEW { +nsStylePadding::operator new(size_t sz, nsPresContext* aContext) CPP_THROW_NEW { void* result = aContext->AllocateFromShell(sz); if (result) memset(result, 0, sz); @@ -380,7 +380,7 @@ nsStylePadding::operator new(size_t sz, nsIPresContext* aContext) CPP_THROW_NEW } void -nsStylePadding::Destroy(nsIPresContext* aContext) { +nsStylePadding::Destroy(nsPresContext* aContext) { this->~nsStylePadding(); aContext->FreeToShell(sizeof(nsStylePadding), this); } @@ -417,7 +417,7 @@ nsStylePadding::CalcPaddingFor(const nsIFrame* aFrame, nsMargin& aPadding) const } } -nsStyleBorder::nsStyleBorder(nsIPresContext* aPresContext) +nsStyleBorder::nsStyleBorder(nsPresContext* aPresContext) { // XXX support mBorderWidths until deprecated methods are removed float pixelsToTwips = 20.0f; @@ -470,7 +470,7 @@ nsStyleBorder::nsStyleBorder(const nsStyleBorder& aSrc) } void* -nsStyleBorder::operator new(size_t sz, nsIPresContext* aContext) CPP_THROW_NEW { +nsStyleBorder::operator new(size_t sz, nsPresContext* aContext) CPP_THROW_NEW { void* result = aContext->AllocateFromShell(sz); if (result) memset(result, 0, sz); @@ -478,7 +478,7 @@ nsStyleBorder::operator new(size_t sz, nsIPresContext* aContext) CPP_THROW_NEW { } void -nsStyleBorder::Destroy(nsIPresContext* aContext) { +nsStyleBorder::Destroy(nsPresContext* aContext) { this->~nsStyleBorder(); aContext->FreeToShell(sizeof(nsStyleBorder), this); } @@ -598,7 +598,7 @@ nsStyleBorder::CalcBorderFor(const nsIFrame* aFrame, PRUint8 aSide, nscoord& aWi aWidth = CalcSideFor(aFrame, coord, NS_SPACING_BORDER, aSide, mBorderWidths, 3); } -nsStyleOutline::nsStyleOutline(nsIPresContext* aPresContext) +nsStyleOutline::nsStyleOutline(nsPresContext* aPresContext) { // XXX support mBorderWidths until deprecated methods are removed float pixelsToTwips = 20.0f; @@ -959,7 +959,7 @@ nsChangeHint nsStyleTable::CalcDifference(const nsStyleTable& aOther) const // ----------------------- // nsStyleTableBorder -nsStyleTableBorder::nsStyleTableBorder(nsIPresContext* aPresContext) +nsStyleTableBorder::nsStyleTableBorder(nsPresContext* aPresContext) { mBorderCollapse = NS_STYLE_BORDER_SEPARATE; @@ -1008,7 +1008,7 @@ nsChangeHint nsStyleTableBorder::CalcDifference(const nsStyleTableBorder& aOther // nsStyleColor // -nsStyleColor::nsStyleColor(nsIPresContext* aPresContext) +nsStyleColor::nsStyleColor(nsPresContext* aPresContext) { mColor = aPresContext->DefaultColor(); } @@ -1029,7 +1029,7 @@ nsChangeHint nsStyleColor::CalcDifference(const nsStyleColor& aOther) const // nsStyleBackground // -nsStyleBackground::nsStyleBackground(nsIPresContext* aPresContext) +nsStyleBackground::nsStyleBackground(nsPresContext* aPresContext) : mBackgroundFlags(NS_STYLE_BG_COLOR_TRANSPARENT | NS_STYLE_BG_IMAGE_NONE), mBackgroundAttachment(NS_STYLE_BG_ATTACHMENT_SCROLL), mBackgroundClip(NS_STYLE_BG_CLIP_BORDER), @@ -1162,7 +1162,7 @@ nsChangeHint nsStyleDisplay::CalcDifference(const nsStyleDisplay& aOther) const // nsStyleVisibility // -nsStyleVisibility::nsStyleVisibility(nsIPresContext* aPresContext) +nsStyleVisibility::nsStyleVisibility(nsPresContext* aPresContext) { PRUint32 bidiOptions = aPresContext->GetBidi(); if (GET_BIDI_OPTION_DIRECTION(bidiOptions) == IBMBIDI_TEXTDIRECTION_RTL) diff --git a/mozilla/content/svg/content/src/nsSVGSVGElement.cpp b/mozilla/content/svg/content/src/nsSVGSVGElement.cpp index 3de4f6c9c45..ff7e56e79a1 100644 --- a/mozilla/content/svg/content/src/nsSVGSVGElement.cpp +++ b/mozilla/content/svg/content/src/nsSVGSVGElement.cpp @@ -45,7 +45,7 @@ #include "nsCOMPtr.h" #include "nsIPresShell.h" #include "nsIDocument.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsISVGViewportRect.h" #include "nsSVGAnimatedRect.h" #include "nsSVGAnimatedPreserveAspectRatio.h" @@ -432,7 +432,7 @@ nsSVGSVGElement::GetPixelUnitToMillimeterX(float *aPixelUnitToMillimeterX) if (!presShell) return NS_OK; // Get the Presentation Context from the Shell - nsCOMPtr context; + nsCOMPtr context; presShell->GetPresContext(getter_AddRefs(context)); if (!context) return NS_OK; @@ -462,7 +462,7 @@ nsSVGSVGElement::GetScreenPixelToMillimeterX(float *aScreenPixelToMillimeterX) if (!presShell) return NS_OK; // Get the Presentation Context from the Shell - nsCOMPtr context; + nsCOMPtr context; presShell->GetPresContext(getter_AddRefs(context)); if (!context) return NS_OK; @@ -1213,7 +1213,7 @@ void nsSVGSVGElement::GetScreenPosition(PRInt32 &x, PRInt32 &y) return; } - nsCOMPtr context; + nsCOMPtr context; presShell->GetPresContext(getter_AddRefs(context)); if (!context) { NS_ERROR("couldn't get prescontext"); diff --git a/mozilla/content/svg/content/src/nsSVGScriptElement.cpp b/mozilla/content/svg/content/src/nsSVGScriptElement.cpp index d149573fa21..bb13192ea91 100644 --- a/mozilla/content/svg/content/src/nsSVGScriptElement.cpp +++ b/mozilla/content/svg/content/src/nsSVGScriptElement.cpp @@ -49,7 +49,7 @@ #include "nsIScriptLoader.h" #include "nsIScriptLoaderObserver.h" #include "nsIPresShell.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsGUIEvent.h" #include "nsIDOMText.h" @@ -228,7 +228,7 @@ nsSVGScriptElement::ScriptAvailable(nsresult aResult, const nsAString& aScript) { if (!aIsInline && NS_FAILED(aResult)) { - nsCOMPtr presContext; + nsCOMPtr presContext; if (mDocument) { nsIPresShell *presShell = mDocument->GetShellAt(0); if (presShell) @@ -268,7 +268,7 @@ nsSVGScriptElement::ScriptEvaluated(nsresult aResult, { nsresult rv = NS_OK; if (!aIsInline) { - nsCOMPtr presContext; + nsCOMPtr presContext; if (mDocument) { nsIPresShell *presShell = mDocument->GetShellAt(0); if (presShell) diff --git a/mozilla/content/xbl/src/nsXBLDocumentInfo.cpp b/mozilla/content/xbl/src/nsXBLDocumentInfo.cpp index b237d951d54..e29e2c0f4a8 100644 --- a/mozilla/content/xbl/src/nsXBLDocumentInfo.cpp +++ b/mozilla/content/xbl/src/nsXBLDocumentInfo.cpp @@ -74,7 +74,7 @@ public: virtual void SetOpenerWindow(nsIDOMWindowInternal *aOpener); virtual void SetGlobalObjectOwner(nsIScriptGlobalObjectOwner* aOwner); virtual nsIScriptGlobalObjectOwner *GetGlobalObjectOwner(); - virtual nsresult HandleDOMEvent(nsIPresContext* aPresContext, + virtual nsresult HandleDOMEvent(nsPresContext* aPresContext, nsEvent* aEvent, nsIDOMEvent** aDOMEvent, PRUint32 aFlags, @@ -264,7 +264,7 @@ nsXBLDocGlobalObject::GetGlobalObjectOwner() nsresult -nsXBLDocGlobalObject::HandleDOMEvent(nsIPresContext* aPresContext, +nsXBLDocGlobalObject::HandleDOMEvent(nsPresContext* aPresContext, nsEvent* aEvent, nsIDOMEvent** aDOMEvent, PRUint32 aFlags, diff --git a/mozilla/content/xml/content/src/nsXMLElement.cpp b/mozilla/content/xml/content/src/nsXMLElement.cpp index 48404027806..242202f8bc6 100644 --- a/mozilla/content/xml/content/src/nsXMLElement.cpp +++ b/mozilla/content/xml/content/src/nsXMLElement.cpp @@ -61,7 +61,7 @@ #include "nsStyleConsts.h" #include "nsIPresShell.h" #include "nsGUIEvent.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIDOMCSSStyleDeclaration.h" #include "nsIDOMViewCSS.h" #include "nsIXBLService.h" @@ -150,7 +150,7 @@ nsXMLElement::SetAttr(PRInt32 aNameSpaceID, nsIAtom* aName, nsIAtom* aPrefix, } static nsresult -DocShellToPresContext(nsIDocShell *aShell, nsIPresContext **aPresContext) +DocShellToPresContext(nsIDocShell *aShell, nsPresContext **aPresContext) { *aPresContext = nsnull; @@ -261,7 +261,7 @@ nsXMLElement::MaybeTriggerAutoLink(nsIDocShell *aShell) mDocument, base); if (NS_SUCCEEDED(rv)) { - nsCOMPtr pc; + nsCOMPtr pc; rv = DocShellToPresContext(aShell, getter_AddRefs(pc)); if (NS_SUCCEEDED(rv)) { rv = TriggerLink(pc, verb, base, uri, @@ -279,7 +279,7 @@ nsXMLElement::MaybeTriggerAutoLink(nsIDocShell *aShell) } nsresult -nsXMLElement::HandleDOMEvent(nsIPresContext* aPresContext, +nsXMLElement::HandleDOMEvent(nsPresContext* aPresContext, nsEvent* aEvent, nsIDOMEvent** aDOMEvent, PRUint32 aFlags, diff --git a/mozilla/content/xml/content/src/nsXMLElement.h b/mozilla/content/xml/content/src/nsXMLElement.h index 1fb7a074be2..9ce61da316f 100644 --- a/mozilla/content/xml/content/src/nsXMLElement.h +++ b/mozilla/content/xml/content/src/nsXMLElement.h @@ -81,7 +81,7 @@ public: virtual nsresult SetAttr(PRInt32 aNameSpaceID, nsIAtom* aName, nsIAtom* aPrefix, const nsAString& aValue, PRBool aNotify); - virtual nsresult HandleDOMEvent(nsIPresContext* aPresContext, + virtual nsresult HandleDOMEvent(nsPresContext* aPresContext, nsEvent* aEvent, nsIDOMEvent** aDOMEvent, PRUint32 aFlags, nsEventStatus* aEventStatus); diff --git a/mozilla/content/xml/document/src/nsXMLContentSink.cpp b/mozilla/content/xml/document/src/nsXMLContentSink.cpp index ec5aab0e06f..4c8ba67f5aa 100644 --- a/mozilla/content/xml/document/src/nsXMLContentSink.cpp +++ b/mozilla/content/xml/document/src/nsXMLContentSink.cpp @@ -53,7 +53,7 @@ #include "nsIContent.h" #include "nsITextContent.h" #include "nsIStyleSheetLinkingElement.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIPresShell.h" #include "nsIViewManager.h" #include "nsIDOMComment.h" diff --git a/mozilla/content/xml/document/src/nsXMLDocument.cpp b/mozilla/content/xml/document/src/nsXMLDocument.cpp index bbbe38dab9a..0ffda938211 100644 --- a/mozilla/content/xml/document/src/nsXMLDocument.cpp +++ b/mozilla/content/xml/document/src/nsXMLDocument.cpp @@ -43,7 +43,7 @@ #include "nsIXMLContent.h" #include "nsIXMLContentSink.h" #include "nsIPresShell.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIContent.h" #include "nsIContentViewerContainer.h" #include "nsIContentViewer.h" diff --git a/mozilla/content/xul/content/src/nsXULElement.cpp b/mozilla/content/xul/content/src/nsXULElement.cpp index dcb6d7b1be2..b72f53f87fc 100644 --- a/mozilla/content/xul/content/src/nsXULElement.cpp +++ b/mozilla/content/xul/content/src/nsXULElement.cpp @@ -2011,7 +2011,7 @@ nsXULElement::UnregisterAccessKey(const nsAString& aOldValue) } if (validElement) { - nsCOMPtr presContext; + nsCOMPtr presContext; shell->GetPresContext(getter_AddRefs(presContext)); presContext->EventStateManager()-> @@ -2622,7 +2622,7 @@ nsXULElement::List(FILE* out, PRInt32 aIndent) const #endif nsresult -nsXULElement::HandleDOMEvent(nsIPresContext* aPresContext, nsEvent* aEvent, +nsXULElement::HandleDOMEvent(nsPresContext* aPresContext, nsEvent* aEvent, nsIDOMEvent** aDOMEvent, PRUint32 aFlags, nsEventStatus* aEventStatus) { @@ -3710,7 +3710,7 @@ nsXULElement::Focus() nsIPresShell *shell = mDocument->GetShellAt(0); // Retrieve the context - nsCOMPtr presContext; + nsCOMPtr presContext; shell->GetPresContext(getter_AddRefs(presContext)); // Set focus @@ -3733,7 +3733,7 @@ nsXULElement::Blur() nsIPresShell *shell = mDocument->GetShellAt(0); // Retrieve the context - nsCOMPtr presContext; + nsCOMPtr presContext; shell->GetPresContext(getter_AddRefs(presContext)); // Set focus @@ -3753,7 +3753,7 @@ nsXULElement::Click() nsCOMPtr doc = mDocument; // Strong just in case if (doc) { PRUint32 numShells = doc->GetNumberOfShells(); - nsCOMPtr context; + nsCOMPtr context; for (PRUint32 i = 0; i < numShells; ++i) { nsIPresShell *shell = doc->GetShellAt(i); @@ -3790,7 +3790,7 @@ nsXULElement::DoCommand() nsCOMPtr doc = mDocument; // strong just in case if (doc) { PRUint32 numShells = doc->GetNumberOfShells(); - nsCOMPtr context; + nsCOMPtr context; for (PRUint32 i = 0; i < numShells; ++i) { nsIPresShell *shell = doc->GetShellAt(i); @@ -3809,7 +3809,7 @@ nsXULElement::DoCommand() // nsIFocusableContent interface and helpers void -nsXULElement::SetFocus(nsIPresContext* aPresContext) +nsXULElement::SetFocus(nsPresContext* aPresContext) { nsAutoString disabled; GetAttribute(NS_LITERAL_STRING("disabled"), disabled); @@ -3821,7 +3821,7 @@ nsXULElement::SetFocus(nsIPresContext* aPresContext) } void -nsXULElement::RemoveFocus(nsIPresContext* aPresContext) +nsXULElement::RemoveFocus(nsPresContext* aPresContext) { } @@ -3889,7 +3889,7 @@ nsXULElement::AddPopupListener(nsIAtom* aName) // nsXULElement::nsIChromeEventHandler //***************************************************************************** -NS_IMETHODIMP nsXULElement::HandleChromeEvent(nsIPresContext* aPresContext, +NS_IMETHODIMP nsXULElement::HandleChromeEvent(nsPresContext* aPresContext, nsEvent* aEvent, nsIDOMEvent** aDOMEvent, PRUint32 aFlags, nsEventStatus* aEventStatus) { @@ -4024,7 +4024,7 @@ nsXULElement::HideWindowChrome(PRBool aShouldHide) nsIFrame* frame = nsnull; shell->GetPrimaryFrameFor(content, &frame); - nsCOMPtr presContext; + nsCOMPtr presContext; shell->GetPresContext(getter_AddRefs(presContext)); if (frame && presContext) { diff --git a/mozilla/content/xul/content/src/nsXULElement.h b/mozilla/content/xul/content/src/nsXULElement.h index 279e0c84004..8d51e3d9dba 100644 --- a/mozilla/content/xul/content/src/nsXULElement.h +++ b/mozilla/content/xul/content/src/nsXULElement.h @@ -473,7 +473,7 @@ public: { } #endif - virtual nsresult HandleDOMEvent(nsIPresContext* aPresContext, + virtual nsresult HandleDOMEvent(nsPresContext* aPresContext, nsEvent* aEvent, nsIDOMEvent** aDOMEvent, PRUint32 aFlags, @@ -485,8 +485,8 @@ public: virtual nsresult RangeAdd(nsIDOMRange* aRange); virtual void RangeRemove(nsIDOMRange* aRange); virtual const nsVoidArray *GetRangeList() const; - virtual void SetFocus(nsIPresContext* aPresContext); - virtual void RemoveFocus(nsIPresContext* aPresContext); + virtual void SetFocus(nsPresContext* aPresContext); + virtual void RemoveFocus(nsPresContext* aPresContext); virtual nsIContent *GetBindingParent() const; virtual nsresult SetBindingParent(nsIContent* aParent); diff --git a/mozilla/content/xul/content/src/nsXULPopupListener.cpp b/mozilla/content/xul/content/src/nsXULPopupListener.cpp index 231000c89d5..cfb189deaa9 100644 --- a/mozilla/content/xul/content/src/nsXULPopupListener.cpp +++ b/mozilla/content/xul/content/src/nsXULPopupListener.cpp @@ -75,7 +75,7 @@ #include "nsIPopupBoxObject.h" // for event firing in context menus -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIPresShell.h" #include "nsIEventStateManager.h" @@ -329,7 +329,7 @@ XULPopupListenerImpl::FireFocusOnTargetContent(nsIDOMNode* aTargetNode) rv = aTargetNode->GetOwnerDocument(getter_AddRefs(domDoc)); if(NS_SUCCEEDED(rv) && domDoc) { - nsCOMPtr context; + nsCOMPtr context; nsCOMPtr tempdoc = do_QueryInterface(domDoc); // Get nsIDOMElement for targetNode diff --git a/mozilla/content/xul/document/src/nsXULCommandDispatcher.cpp b/mozilla/content/xul/document/src/nsXULCommandDispatcher.cpp index b1c6c74fe29..e826cfb1762 100644 --- a/mozilla/content/xul/document/src/nsXULCommandDispatcher.cpp +++ b/mozilla/content/xul/document/src/nsXULCommandDispatcher.cpp @@ -54,7 +54,7 @@ #include "nsIDOMWindowInternal.h" #include "nsIDOMXULElement.h" #include "nsIDocument.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIPresShell.h" #include "nsIScriptGlobalObject.h" #include "nsPIDOMWindow.h" @@ -377,7 +377,7 @@ nsXULCommandDispatcher::UpdateCommands(const nsAString& aEventName) nsIPresShell *shell = document->GetShellAt(i); // Retrieve the context in which our DOM event will fire. - nsCOMPtr context; + nsCOMPtr context; rv = shell->GetPresContext(getter_AddRefs(context)); if (NS_FAILED(rv)) return rv; diff --git a/mozilla/content/xul/document/src/nsXULDocument.cpp b/mozilla/content/xul/document/src/nsXULDocument.cpp index ba120f1ca67..c3afb8d6bf8 100644 --- a/mozilla/content/xul/document/src/nsXULDocument.cpp +++ b/mozilla/content/xul/document/src/nsXULDocument.cpp @@ -1061,7 +1061,7 @@ nsXULDocument::ExecuteOnBroadcastHandlerFor(nsIContent* aBroadcaster, nsCOMPtr shell = NS_STATIC_CAST(nsIPresShell*, mPresShells[j]); - nsCOMPtr aPresContext; + nsCOMPtr aPresContext; shell->GetPresContext(getter_AddRefs(aPresContext)); // Handle the DOM event @@ -1201,7 +1201,7 @@ nsXULDocument::ContentRemoved(nsIContent* aContainer, } nsresult -nsXULDocument::HandleDOMEvent(nsIPresContext* aPresContext, +nsXULDocument::HandleDOMEvent(nsPresContext* aPresContext, nsEvent* aEvent, nsIDOMEvent** aDOMEvent, PRUint32 aFlags, @@ -1610,7 +1610,7 @@ nsXULDocument::GetPixelDimensions(nsIPresShell* aShell, PRInt32* aWidth, } // Convert from twips to pixels - nsCOMPtr context; + nsCOMPtr context; result = aShell->GetPresContext(getter_AddRefs(context)); if (NS_SUCCEEDED(result)) { @@ -2121,7 +2121,7 @@ nsXULDocument::StartLayout(void) nsIPresShell *shell = GetShellAt(i); // Resize-reflow this time - nsCOMPtr cx; + nsCOMPtr cx; shell->GetPresContext(getter_AddRefs(cx)); NS_ASSERTION(cx != nsnull, "no pres context"); if (! cx) diff --git a/mozilla/content/xul/document/src/nsXULDocument.h b/mozilla/content/xul/document/src/nsXULDocument.h index 76fa470f8d3..31fe3ca3d61 100644 --- a/mozilla/content/xul/document/src/nsXULDocument.h +++ b/mozilla/content/xul/document/src/nsXULDocument.h @@ -125,7 +125,7 @@ public: virtual void AttributeChanged(nsIContent* aElement, PRInt32 aNameSpaceID, nsIAtom* aAttribute, PRInt32 aModType); - virtual nsresult HandleDOMEvent(nsIPresContext* aPresContext, + virtual nsresult HandleDOMEvent(nsPresContext* aPresContext, nsEvent* aEvent, nsIDOMEvent** aDOMEvent, PRUint32 aFlags, diff --git a/mozilla/content/xul/document/src/nsXULPrototypeDocument.cpp b/mozilla/content/xul/document/src/nsXULPrototypeDocument.cpp index 1ec6da928a5..ed69b297006 100644 --- a/mozilla/content/xul/document/src/nsXULPrototypeDocument.cpp +++ b/mozilla/content/xul/document/src/nsXULPrototypeDocument.cpp @@ -96,7 +96,7 @@ public: virtual void SetOpenerWindow(nsIDOMWindowInternal *aOpener); virtual void SetGlobalObjectOwner(nsIScriptGlobalObjectOwner* aOwner); virtual nsIScriptGlobalObjectOwner *GetGlobalObjectOwner(); - virtual nsresult HandleDOMEvent(nsIPresContext* aPresContext, + virtual nsresult HandleDOMEvent(nsPresContext* aPresContext, nsEvent* aEvent, nsIDOMEvent** aDOMEvent, PRUint32 aFlags, @@ -891,7 +891,7 @@ nsXULPDGlobalObject::GetGlobalObjectOwner() nsresult -nsXULPDGlobalObject::HandleDOMEvent(nsIPresContext* aPresContext, +nsXULPDGlobalObject::HandleDOMEvent(nsPresContext* aPresContext, nsEvent* aEvent, nsIDOMEvent** aDOMEvent, PRUint32 aFlags, diff --git a/mozilla/docshell/base/nsDocShell.cpp b/mozilla/docshell/base/nsDocShell.cpp index 516b13a5589..7888015707d 100644 --- a/mozilla/docshell/base/nsDocShell.cpp +++ b/mozilla/docshell/base/nsDocShell.cpp @@ -1196,7 +1196,7 @@ nsresult nsDocShell::FindTarget(const PRUnichar *aWindowTarget, } NS_IMETHODIMP -nsDocShell::GetEldestPresContext(nsIPresContext** aPresContext) +nsDocShell::GetEldestPresContext(nsPresContext** aPresContext) { nsresult rv = NS_OK; @@ -1221,7 +1221,7 @@ nsDocShell::GetEldestPresContext(nsIPresContext** aPresContext) } NS_IMETHODIMP -nsDocShell::GetPresContext(nsIPresContext ** aPresContext) +nsDocShell::GetPresContext(nsPresContext ** aPresContext) { nsresult rv = NS_OK; @@ -1248,7 +1248,7 @@ nsDocShell::GetPresShell(nsIPresShell ** aPresShell) NS_ENSURE_ARG_POINTER(aPresShell); *aPresShell = nsnull; - nsCOMPtr presContext; + nsCOMPtr presContext; (void) GetPresContext(getter_AddRefs(presContext)); if (presContext) { @@ -1266,7 +1266,7 @@ nsDocShell::GetEldestPresShell(nsIPresShell** aPresShell) NS_ENSURE_ARG_POINTER(aPresShell); *aPresShell = nsnull; - nsCOMPtr presContext; + nsCOMPtr presContext; (void) GetEldestPresContext(getter_AddRefs(presContext)); if (presContext) { @@ -1954,7 +1954,7 @@ PrintDocTree(nsIDocShellTreeNode * aParentNode, int aLevel) parentAsItem->GetItemType(&type); nsCOMPtr presShell; parentAsDocShell->GetPresShell(getter_AddRefs(presShell)); - nsCOMPtr presContext; + nsCOMPtr presContext; parentAsDocShell->GetPresContext(getter_AddRefs(presContext)); nsCOMPtr doc; presShell->GetDocument(getter_AddRefs(doc)); @@ -3265,7 +3265,7 @@ nsDocShell::GetPositionAndSize(PRInt32 * x, PRInt32 * y, PRInt32 * cx, NS_IMETHODIMP nsDocShell::Repaint(PRBool aForce) { - nsCOMPtr context; + nsCOMPtr context; GetPresContext(getter_AddRefs(context)); NS_ENSURE_TRUE(context, NS_ERROR_FAILURE); diff --git a/mozilla/docshell/base/nsDocShell.h b/mozilla/docshell/base/nsDocShell.h index 54331ef10f1..c2501973f1f 100644 --- a/mozilla/docshell/base/nsDocShell.h +++ b/mozilla/docshell/base/nsDocShell.h @@ -243,7 +243,7 @@ protected: nsIStreamListener ** aContentHandler, nsIContentViewer ** aViewer); NS_IMETHOD SetupNewViewer(nsIContentViewer * aNewViewer); - NS_IMETHOD GetEldestPresContext(nsIPresContext** aPresContext); + NS_IMETHOD GetEldestPresContext(nsPresContext** aPresContext); void GetCurrentDocumentOwner(nsISupports ** aOwner); virtual nsresult DoURILoad(nsIURI * aURI, nsIURI * aReferrer, diff --git a/mozilla/docshell/base/nsIDocShell.idl b/mozilla/docshell/base/nsIDocShell.idl index 58dbba11d29..c0951be65a6 100644 --- a/mozilla/docshell/base/nsIDocShell.idl +++ b/mozilla/docshell/base/nsIDocShell.idl @@ -41,7 +41,7 @@ #include "nsISupports.idl" %{ C++ -class nsIPresContext; +class nsPresContext; class nsIPresShell; %} @@ -49,7 +49,7 @@ class nsIPresShell; * The nsIDocShell interface. */ -[ptr] native nsIPresContext(nsIPresContext); +[ptr] native nsPresContext(nsPresContext); [ptr] native nsIPresShell(nsIPresShell); interface nsIURI; @@ -177,7 +177,7 @@ interface nsIDocShell : nsISupports /** * Presentation context for the currently loaded document. This may be null. */ - [noscript] readonly attribute nsIPresContext presContext; + [noscript] readonly attribute nsPresContext presContext; /** * Presentation shell for the currently loaded document. This may be null. diff --git a/mozilla/docshell/base/nsWebShell.cpp b/mozilla/docshell/base/nsWebShell.cpp index 307e2bcbf5b..65662653c01 100644 --- a/mozilla/docshell/base/nsWebShell.cpp +++ b/mozilla/docshell/base/nsWebShell.cpp @@ -59,7 +59,7 @@ #include "nsIScriptGlobalObject.h" #include "nsIScriptGlobalObjectOwner.h" #include "nsIDOMEvent.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIComponentManager.h" #include "nsIEventQueueService.h" #include "nsCRT.h" diff --git a/mozilla/docshell/build/win32.order b/mozilla/docshell/build/win32.order index 1119870cdcf..23b82352b90 100644 --- a/mozilla/docshell/build/win32.order +++ b/mozilla/docshell/build/win32.order @@ -26,7 +26,7 @@ ?Release@nsDSURIContentListener@@UAGKXZ ; 1227 ?GetTreeOwner@nsDocShell@@UAGIPAPAVnsIDocShellTreeOwner@@@Z ; 982 ?EnsureContentListener@nsDocShell@@MAGIXZ ; 948 -?GetPresContext@nsDocShell@@UAGIPAPAVnsIPresContext@@@Z ; 894 +?GetPresContext@nsDocShell@@UAGIPAPAVnsPresContext@@@Z ; 894 ?GetPresShell@nsDocShell@@UAGIPAPAVnsIPresShell@@@Z ; 873 ?GetAppType@nsDocShell@@UAGIPAI@Z ; 808 ?GetAllowJavascript@nsDocShell@@UAGIPAH@Z ; 808 diff --git a/mozilla/dom/public/nsIScriptGlobalObject.h b/mozilla/dom/public/nsIScriptGlobalObject.h index f36fb8003e7..e495cf8bb2b 100644 --- a/mozilla/dom/public/nsIScriptGlobalObject.h +++ b/mozilla/dom/public/nsIScriptGlobalObject.h @@ -44,7 +44,7 @@ class nsIScriptContext; class nsIDOMDocument; class nsIDOMEvent; -class nsIPresContext; +class nsPresContext; class nsIDocShell; class nsIDOMWindowInternal; class nsIScriptGlobalObjectOwner; @@ -89,7 +89,7 @@ public: */ virtual nsIScriptGlobalObjectOwner *GetGlobalObjectOwner() = 0; - virtual nsresult HandleDOMEvent(nsIPresContext* aPresContext, + virtual nsresult HandleDOMEvent(nsPresContext* aPresContext, nsEvent* aEvent, nsIDOMEvent** aDOMEvent, PRUint32 aFlags, diff --git a/mozilla/dom/src/base/nsDOMClassInfo.cpp b/mozilla/dom/src/base/nsDOMClassInfo.cpp index 5bb4b58402a..509686b9665 100644 --- a/mozilla/dom/src/base/nsDOMClassInfo.cpp +++ b/mozilla/dom/src/base/nsDOMClassInfo.cpp @@ -4881,7 +4881,7 @@ nsElementSH::PostCreate(nsIXPConnectWrappedNative *wrapper, JSContext *cx, } // Get the computed -moz-binding directly from the style context - nsCOMPtr pctx; + nsCOMPtr pctx; shell->GetPresContext(getter_AddRefs(pctx)); NS_ENSURE_TRUE(pctx, NS_ERROR_UNEXPECTED); diff --git a/mozilla/dom/src/base/nsDOMWindowUtils.cpp b/mozilla/dom/src/base/nsDOMWindowUtils.cpp index 634a018d316..480eebd78df 100644 --- a/mozilla/dom/src/base/nsDOMWindowUtils.cpp +++ b/mozilla/dom/src/base/nsDOMWindowUtils.cpp @@ -36,7 +36,7 @@ * ***** END LICENSE BLOCK ***** */ #include "nsIDocShell.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsDOMWindowUtils.h" #include "nsGlobalWindow.h" @@ -65,7 +65,7 @@ nsDOMWindowUtils::GetImageAnimationMode(PRUint16 *aMode) { if (mWindow) { nsIDocShell *docShell = mWindow->GetDocShell(); if (docShell) { - nsCOMPtr presContext; + nsCOMPtr presContext; docShell->GetPresContext(getter_AddRefs(presContext)); if (presContext) { *aMode = presContext->ImageAnimationMode(); @@ -82,7 +82,7 @@ nsDOMWindowUtils::SetImageAnimationMode(PRUint16 aMode) { if (mWindow) { nsIDocShell *docShell = mWindow->GetDocShell(); if (docShell) { - nsCOMPtr presContext; + nsCOMPtr presContext; docShell->GetPresContext(getter_AddRefs(presContext)); if (presContext) { presContext->SetImageAnimationMode(aMode); diff --git a/mozilla/dom/src/base/nsFocusController.cpp b/mozilla/dom/src/base/nsFocusController.cpp index 15d6996c8ca..26b42f823cc 100644 --- a/mozilla/dom/src/base/nsFocusController.cpp +++ b/mozilla/dom/src/base/nsFocusController.cpp @@ -48,7 +48,7 @@ #include "nsIDOMNSEvent.h" #include "nsIDOMWindowInternal.h" #include "nsIDocument.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIPresShell.h" #include "nsIScriptGlobalObject.h" #include "nsPIDOMWindow.h" @@ -264,7 +264,7 @@ nsFocusController::MoveFocus(PRBool aForward, nsIDOMElement* aElt) return NS_OK; // Retrieve the context - nsCOMPtr presContext; + nsCOMPtr presContext; shell->GetPresContext(getter_AddRefs(presContext)); // Make this ESM shift the focus per our instructions. diff --git a/mozilla/dom/src/base/nsGlobalWindow.cpp b/mozilla/dom/src/base/nsGlobalWindow.cpp index dbf4d60c2f3..f4c2a5dc4da 100644 --- a/mozilla/dom/src/base/nsGlobalWindow.cpp +++ b/mozilla/dom/src/base/nsGlobalWindow.cpp @@ -771,7 +771,7 @@ GlobalWindowImpl::GetGlobalObjectOwner() } nsresult -GlobalWindowImpl::HandleDOMEvent(nsIPresContext* aPresContext, +GlobalWindowImpl::HandleDOMEvent(nsPresContext* aPresContext, nsEvent* aEvent, nsIDOMEvent** aDOMEvent, PRUint32 aFlags, @@ -2984,7 +2984,7 @@ GlobalWindowImpl::CheckForAbusePoint() nsCOMPtr presShell; mDocShell->GetPresShell(getter_AddRefs(presShell)); if (presShell) { - nsCOMPtr presContext; + nsCOMPtr presContext; presShell->GetPresContext(getter_AddRefs(presContext)); if (presContext) presContext->EventStateManager()->GetCurrentEvent(¤tEvent); @@ -4069,7 +4069,7 @@ GlobalWindowImpl::DispatchEvent(nsIDOMEvent* aEvent, PRBool* _retval) } // Retrieve the context - nsCOMPtr aPresContext; + nsCOMPtr aPresContext; shell->GetPresContext(getter_AddRefs(aPresContext)); aPresContext->EventStateManager()-> DispatchNewEvent(NS_STATIC_CAST(nsIScriptGlobalObject*, this), @@ -5471,7 +5471,7 @@ GlobalWindowImpl::GetScrollInfo(nsIScrollableView **aScrollableView, // date. FlushPendingNotifications(Flush_Layout); - nsCOMPtr presContext; + nsCOMPtr presContext; mDocShell->GetPresContext(getter_AddRefs(presContext)); if (presContext) { *aP2T = presContext->PixelsToTwips(); @@ -5761,7 +5761,7 @@ nsGlobalChromeWindow::SetCursor(const nsAString& aCursor) else return NS_OK; - nsCOMPtr presContext; + nsCOMPtr presContext; mDocShell->GetPresContext(getter_AddRefs(presContext)); if (presContext) { // Need root widget. diff --git a/mozilla/dom/src/base/nsGlobalWindow.h b/mozilla/dom/src/base/nsGlobalWindow.h index fa51b5340bb..a79e6981287 100644 --- a/mozilla/dom/src/base/nsGlobalWindow.h +++ b/mozilla/dom/src/base/nsGlobalWindow.h @@ -91,7 +91,7 @@ class nsIDOMBarProp; class nsIDocument; class nsIContent; -class nsIPresContext; +class nsPresContext; class nsIDOMEvent; class nsIScrollableView; @@ -144,7 +144,7 @@ public: virtual void SetOpenerWindow(nsIDOMWindowInternal *aOpener); virtual void SetGlobalObjectOwner(nsIScriptGlobalObjectOwner* aOwner); virtual nsIScriptGlobalObjectOwner *GetGlobalObjectOwner(); - virtual nsresult HandleDOMEvent(nsIPresContext* aPresContext, + virtual nsresult HandleDOMEvent(nsPresContext* aPresContext, nsEvent* aEvent, nsIDOMEvent** aDOMEvent, PRUint32 aFlags, nsEventStatus* aEventStatus); diff --git a/mozilla/dom/src/base/nsGlobalWindowCommands.cpp b/mozilla/dom/src/base/nsGlobalWindowCommands.cpp index 589308fb942..0cd857e21a2 100644 --- a/mozilla/dom/src/base/nsGlobalWindowCommands.cpp +++ b/mozilla/dom/src/base/nsGlobalWindowCommands.cpp @@ -50,7 +50,7 @@ #include "nsIDOMWindow.h" #include "nsIPresShell.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIScriptGlobalObject.h" #include "nsIDocShell.h" #include "nsISelectionController.h" @@ -235,7 +235,7 @@ nsSelectionCommandsBase::GetEventStateManagerForWindow(nsIDOMWindow *aWindow, GetPresShellFromWindow(aWindow, getter_AddRefs(presShell)); if (presShell) { - nsCOMPtr presContext; + nsCOMPtr presContext; presShell->GetPresContext(getter_AddRefs(presContext)); if (presContext) { NS_ADDREF(*aEventStateManager = presContext->EventStateManager()); diff --git a/mozilla/dom/src/base/nsJSEnvironment.cpp b/mozilla/dom/src/base/nsJSEnvironment.cpp index 7c1dbcc252f..921b4008f0f 100644 --- a/mozilla/dom/src/base/nsJSEnvironment.cpp +++ b/mozilla/dom/src/base/nsJSEnvironment.cpp @@ -61,7 +61,7 @@ #include "nsJSUtils.h" #include "nsIDocShell.h" #include "nsIDocShellTreeItem.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIConsoleService.h" #include "nsIScriptError.h" #include "nsIInterfaceRequestor.h" @@ -180,7 +180,7 @@ NS_ScriptErrorReporter(JSContext *cx, static PRInt32 errorDepth; // Recursion prevention ++errorDepth; - nsCOMPtr presContext; + nsCOMPtr presContext; docShell->GetPresContext(getter_AddRefs(presContext)); if (presContext && errorDepth < 2) { diff --git a/mozilla/dom/src/base/nsScreen.cpp b/mozilla/dom/src/base/nsScreen.cpp index cc2450ac28e..982739493ef 100644 --- a/mozilla/dom/src/base/nsScreen.cpp +++ b/mozilla/dom/src/base/nsScreen.cpp @@ -42,7 +42,7 @@ #include "nsIScriptGlobalObject.h" #include "nsIDocShell.h" #include "nsIDeviceContext.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsCOMPtr.h" #include "nsIDocumentViewer.h" #include "nsIDocumentLoader.h" @@ -208,7 +208,7 @@ ScreenImpl::GetDeviceContext() if(!docViewer) return nsnull; - nsCOMPtr presContext; + nsCOMPtr presContext; docViewer->GetPresContext(getter_AddRefs(presContext)); nsIDeviceContext* context = nsnull; diff --git a/mozilla/dom/src/base/nsWindowRoot.cpp b/mozilla/dom/src/base/nsWindowRoot.cpp index 4b7734bb6f8..3248f0d810c 100644 --- a/mozilla/dom/src/base/nsWindowRoot.cpp +++ b/mozilla/dom/src/base/nsWindowRoot.cpp @@ -44,7 +44,7 @@ #include "nsIDocument.h" #include "nsIEventListenerManager.h" #include "nsIPresShell.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsLayoutCID.h" #include "nsContentCID.h" #include "nsIEventStateManager.h" @@ -102,7 +102,7 @@ nsWindowRoot::DispatchEvent(nsIDOMEvent* aEvt, PRBool *_retval) nsIPresShell *shell = doc->GetShellAt(0); // Retrieve the context - nsCOMPtr aPresContext; + nsCOMPtr aPresContext; shell->GetPresContext(getter_AddRefs(aPresContext)); return aPresContext->EventStateManager()-> @@ -203,7 +203,7 @@ nsWindowRoot::GetSystemEventGroup(nsIDOMEventGroup **aGroup) return NS_ERROR_FAILURE; } -NS_IMETHODIMP nsWindowRoot::HandleChromeEvent(nsIPresContext* aPresContext, +NS_IMETHODIMP nsWindowRoot::HandleChromeEvent(nsPresContext* aPresContext, nsEvent* aEvent, nsIDOMEvent** aDOMEvent, PRUint32 aFlags, nsEventStatus* aEventStatus) { diff --git a/mozilla/dom/src/base/nsWindowRoot.h b/mozilla/dom/src/base/nsWindowRoot.h index b3f25d3e725..e8c3556b3e3 100644 --- a/mozilla/dom/src/base/nsWindowRoot.h +++ b/mozilla/dom/src/base/nsWindowRoot.h @@ -64,7 +64,7 @@ public: NS_DECL_NSIDOMEVENTTARGET NS_DECL_NSIDOM3EVENTTARGET - NS_IMETHOD HandleChromeEvent(nsIPresContext* aPresContext, + NS_IMETHOD HandleChromeEvent(nsPresContext* aPresContext, nsEvent* aEvent, nsIDOMEvent** aDOMEvent, PRUint32 aFlags, nsEventStatus* aEventStatus); diff --git a/mozilla/editor/composer/src/nsComposerDocumentCommands.cpp b/mozilla/editor/composer/src/nsComposerDocumentCommands.cpp index d9986b19b69..8064ccec7f1 100644 --- a/mozilla/editor/composer/src/nsComposerDocumentCommands.cpp +++ b/mozilla/editor/composer/src/nsComposerDocumentCommands.cpp @@ -49,7 +49,7 @@ #include "nsIDocument.h" #include "nsISelectionController.h" #include "nsIPresShell.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIDocShell.h" #include "nsIURI.h" @@ -66,7 +66,7 @@ static nsresult -GetPresContextFromEditor(nsIEditor *aEditor, nsIPresContext **aResult) +GetPresContextFromEditor(nsIEditor *aEditor, nsPresContext **aResult) { NS_ENSURE_ARG_POINTER(aResult); *aResult = nsnull; @@ -80,7 +80,7 @@ GetPresContextFromEditor(nsIEditor *aEditor, nsIPresContext **aResult) nsCOMPtr presShell = do_QueryInterface(selCon); if (!presShell) return NS_ERROR_FAILURE; - nsCOMPtr presContext; + nsCOMPtr presContext; rv = presShell->GetPresContext(getter_AddRefs(presContext)); if (NS_FAILED(rv)) return rv; *aResult = presContext; @@ -116,7 +116,7 @@ nsSetDocumentOptionsCommand::DoCommandParams(const char *aCommandName, nsCOMPtr editor = do_QueryInterface(refCon); if (!editor) return NS_ERROR_INVALID_ARG; - nsCOMPtr presContext; + nsCOMPtr presContext; nsresult rv = GetPresContextFromEditor(editor, getter_AddRefs(presContext)); if (NS_FAILED(rv)) return rv; if (!presContext) return NS_ERROR_FAILURE; @@ -167,7 +167,7 @@ nsSetDocumentOptionsCommand::GetCommandStateParams(const char *aCommandName, NS_ENSURE_SUCCESS(rv, rv); // get pres context - nsCOMPtr presContext; + nsCOMPtr presContext; rv = GetPresContextFromEditor(editor, getter_AddRefs(presContext)); if (NS_FAILED(rv)) return rv; if (!presContext) return NS_ERROR_FAILURE; diff --git a/mozilla/editor/composer/src/nsEditingSession.cpp b/mozilla/editor/composer/src/nsEditingSession.cpp index dd0dd950e92..fd640ca6200 100644 --- a/mozilla/editor/composer/src/nsEditingSession.cpp +++ b/mozilla/editor/composer/src/nsEditingSession.cpp @@ -78,7 +78,7 @@ #include "nsIDOMNSDocument.h" #include "nsIScriptContext.h" #include "imgIContainer.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #if DEBUG //#define NOISY_DOC_LOADING 1 @@ -395,7 +395,7 @@ nsEditingSession::SetupEditorOnWindow(nsIDOMWindow *aWindow) if (!presShell) return NS_ERROR_FAILURE; // Disable animation of images in this document: - nsCOMPtr presContext; + nsCOMPtr presContext; rv = presShell->GetPresContext(getter_AddRefs(presContext)); if (NS_FAILED(rv)) return rv; if (!presContext) return NS_ERROR_FAILURE; diff --git a/mozilla/editor/libeditor/base/nsEditor.cpp b/mozilla/editor/libeditor/base/nsEditor.cpp index c2313cb1efd..1ad151078be 100644 --- a/mozilla/editor/libeditor/base/nsEditor.cpp +++ b/mozilla/editor/libeditor/base/nsEditor.cpp @@ -58,7 +58,7 @@ #include "nsITransactionManager.h" #include "nsIAbsorbingTransaction.h" #include "nsIPresShell.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIViewManager.h" #include "nsISelection.h" #include "nsISelectionPrivate.h" diff --git a/mozilla/editor/libeditor/html/nsHTMLDataTransfer.cpp b/mozilla/editor/libeditor/html/nsHTMLDataTransfer.cpp index ecb9744e183..a44ce9e1210 100644 --- a/mozilla/editor/libeditor/html/nsHTMLDataTransfer.cpp +++ b/mozilla/editor/libeditor/html/nsHTMLDataTransfer.cpp @@ -84,7 +84,7 @@ #include "nsIDocumentEncoder.h" #include "nsIDOMDocumentFragment.h" #include "nsIPresShell.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIParser.h" #include "nsParserCIID.h" #include "nsIImage.h" diff --git a/mozilla/editor/libeditor/html/nsHTMLEditor.cpp b/mozilla/editor/libeditor/html/nsHTMLEditor.cpp index 067db688f37..ec9742e2537 100644 --- a/mozilla/editor/libeditor/html/nsHTMLEditor.cpp +++ b/mozilla/editor/libeditor/html/nsHTMLEditor.cpp @@ -93,7 +93,7 @@ #include "nsIDocumentEncoder.h" #include "nsIDOMDocumentFragment.h" #include "nsIPresShell.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsParserCIID.h" #include "nsIImage.h" #include "nsAOLCiter.h" @@ -267,7 +267,7 @@ NS_IMETHODIMP nsHTMLEditor::Init(nsIDOMDocument *aDoc, mHTMLCSSUtils->Init(this); // disable links - nsCOMPtr context; + nsCOMPtr context; aPresShell->GetPresContext(getter_AddRefs(context)); if (!context) return NS_ERROR_NULL_POINTER; if (!(mFlags & eEditorPlaintextMask)) @@ -5959,7 +5959,7 @@ nsHTMLEditor::GetElementOrigin(nsIDOMElement * aElement, PRInt32 & aX, PRInt32 & ps->GetPrimaryFrameFor(content, &frame); float t2p; - nsCOMPtr pcontext; + nsCOMPtr pcontext; ps->GetPresContext(getter_AddRefs(pcontext)); t2p = pcontext->TwipsToPixels(); diff --git a/mozilla/editor/libeditor/html/nsHTMLObjectResizer.cpp b/mozilla/editor/libeditor/html/nsHTMLObjectResizer.cpp index 359f5bbef76..e23baa8b6db 100644 --- a/mozilla/editor/libeditor/html/nsHTMLObjectResizer.cpp +++ b/mozilla/editor/libeditor/html/nsHTMLObjectResizer.cpp @@ -64,7 +64,7 @@ #include "nsIPrefService.h" #include "nsIServiceManager.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsILookAndFeel.h" #include "nsWidgetsCID.h" diff --git a/mozilla/editor/libeditor/text/nsEditorEventListeners.cpp b/mozilla/editor/libeditor/text/nsEditorEventListeners.cpp index dbf668b7abb..7b4e54b24d9 100644 --- a/mozilla/editor/libeditor/text/nsEditorEventListeners.cpp +++ b/mozilla/editor/libeditor/text/nsEditorEventListeners.cpp @@ -54,7 +54,7 @@ #include "nsIPrefBranch.h" #include "nsIPrefService.h" #include "nsILookAndFeel.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #ifdef USE_HACK_REPAINT // for repainting hack only #include "nsIView.h" @@ -971,7 +971,7 @@ IsTargetFocused(nsIDOMEventTarget* aTarget) if (!shell) return PR_FALSE; - nsCOMPtr presContext; + nsCOMPtr presContext; shell->GetPresContext(getter_AddRefs(presContext)); if (!presContext) return PR_FALSE; diff --git a/mozilla/editor/libeditor/text/nsTextEditRulesBidi.cpp b/mozilla/editor/libeditor/text/nsTextEditRulesBidi.cpp index 60589fcb61b..774e0eee2ea 100644 --- a/mozilla/editor/libeditor/text/nsTextEditRulesBidi.cpp +++ b/mozilla/editor/libeditor/text/nsTextEditRulesBidi.cpp @@ -40,7 +40,7 @@ #include "nsIDOMNode.h" #include "nsIContent.h" #include "nsIPresShell.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIFrame.h" // Test for distance between caret and text that will be deleted @@ -60,7 +60,7 @@ nsTextEditRules::CheckBidiLevelForDeletion(nsIDOMNode *aSelNode, if (!shell) return NS_ERROR_NULL_POINTER; - nsCOMPtr context; + nsCOMPtr context; res = shell->GetPresContext(getter_AddRefs(context)); if (NS_FAILED(res)) return res; diff --git a/mozilla/embedding/browser/activex/src/control/StdAfx.h b/mozilla/embedding/browser/activex/src/control/StdAfx.h index 66914f8f71a..e76a97591c4 100644 --- a/mozilla/embedding/browser/activex/src/control/StdAfx.h +++ b/mozilla/embedding/browser/activex/src/control/StdAfx.h @@ -95,7 +95,7 @@ #include "nsIPresShell.h" #include "nsCOMPtr.h" #include "nsISelection.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIPrompt.h" #include "nsIEditor.h" #include "nsIEditingSession.h" diff --git a/mozilla/embedding/browser/webBrowser/nsDocShellTreeOwner.cpp b/mozilla/embedding/browser/webBrowser/nsDocShellTreeOwner.cpp index ef656b79208..f9f84de64e9 100644 --- a/mozilla/embedding/browser/webBrowser/nsDocShellTreeOwner.cpp +++ b/mozilla/embedding/browser/webBrowser/nsDocShellTreeOwner.cpp @@ -58,7 +58,7 @@ #include "nsISimpleEnumerator.h" // Interfaces needed to be included -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIContextMenuListener.h" #include "nsIContextMenuListener2.h" #include "nsITooltipListener.h" @@ -89,7 +89,7 @@ #include "nsIContent.h" #include "imgIContainer.h" #include "nsContextMenuInfo.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" // // GetEventReceiver @@ -467,7 +467,7 @@ nsDocShellTreeOwner::SizeShellTo(nsIDocShellTreeItem* aShellItem, Set the preferred size on the aShellItem. */ - nsCOMPtr presContext; + nsCOMPtr presContext; mWebBrowser->mDocShell->GetPresContext(getter_AddRefs(presContext)); NS_ENSURE_TRUE(presContext, NS_ERROR_FAILURE); diff --git a/mozilla/embedding/components/find/src/nsWebBrowserFind.cpp b/mozilla/embedding/components/find/src/nsWebBrowserFind.cpp index da6250de938..4dd495602bf 100644 --- a/mozilla/embedding/components/find/src/nsWebBrowserFind.cpp +++ b/mozilla/embedding/components/find/src/nsWebBrowserFind.cpp @@ -58,7 +58,7 @@ #include "nsIEnumerator.h" #include "nsIDocShellTreeItem.h" #include "nsIPresShell.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIEventStateManager.h" #include "nsIDocument.h" #include "nsIDOMDocument.h" @@ -390,7 +390,7 @@ FocusElementButNotDocument(nsIDocument* aDocument, nsIContent* aContent) focusController->SetFocusedElement(newFocusedElement); nsIPresShell* presShell = aDocument->GetShellAt(0); - nsCOMPtr presContext; + nsCOMPtr presContext; presShell->GetPresContext(getter_AddRefs(presContext)); nsIEventStateManager* esm = presContext->EventStateManager(); @@ -457,7 +457,7 @@ void nsWebBrowserFind::SetSelectionAndScroll(nsIDOMWindow* aWindow, FocusElementButNotDocument(doc, content); } else { - nsCOMPtr presContext; + nsCOMPtr presContext; presShell->GetPresContext(getter_AddRefs(presContext)); PRBool isSelectionWithFocus; presContext->EventStateManager()-> @@ -835,7 +835,7 @@ nsWebBrowserFind::GetFrameSelection(nsIDOMWindow* aWindow, // text input controls have their independent selection controllers // that we must use when they have focus. - nsCOMPtr presContext; + nsCOMPtr presContext; presShell->GetPresContext(getter_AddRefs(presContext)); nsIFrame *frame = nsnull; diff --git a/mozilla/extensions/inspector/base/src/inFlasher.cpp b/mozilla/extensions/inspector/base/src/inFlasher.cpp index 8864caf0f13..e1469e9ec86 100644 --- a/mozilla/extensions/inspector/base/src/inFlasher.cpp +++ b/mozilla/extensions/inspector/base/src/inFlasher.cpp @@ -167,7 +167,7 @@ inFlasher::DrawElementOutline(nsIDOMElement* aElement) if (!window) return NS_OK; nsCOMPtr presShell = inLayoutUtils::GetPresShellFor(window); - nsCOMPtr presContext; + nsCOMPtr presContext; presShell->GetPresContext(getter_AddRefs(presContext)); float p2t; diff --git a/mozilla/extensions/inspector/base/src/inLayoutUtils.cpp b/mozilla/extensions/inspector/base/src/inLayoutUtils.cpp index 2b67f393250..c88b25e59fc 100644 --- a/mozilla/extensions/inspector/base/src/inLayoutUtils.cpp +++ b/mozilla/extensions/inspector/base/src/inLayoutUtils.cpp @@ -50,7 +50,7 @@ #include "nsIPresShell.h" #include "nsIViewManager.h" #include "nsIWidget.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsXULAtoms.h" #include "nsHTMLAtoms.h" @@ -125,7 +125,7 @@ inLayoutUtils::GetEventStateManagerFor(nsIDOMElement *aElement) nsIPresShell *shell = doc->GetShellAt(0); NS_ASSERTION(shell, "No pres shell"); - nsCOMPtr presContext; + nsCOMPtr presContext; shell->GetPresContext(getter_AddRefs(presContext)); NS_ASSERTION(presContext, "No pres context"); @@ -133,7 +133,7 @@ inLayoutUtils::GetEventStateManagerFor(nsIDOMElement *aElement) } nsPoint -inLayoutUtils::GetClientOrigin(nsIPresContext* aPresContext, +inLayoutUtils::GetClientOrigin(nsPresContext* aPresContext, nsIFrame* aFrame) { nsPoint result(0,0); @@ -171,7 +171,7 @@ inLayoutUtils::GetScreenOrigin(nsIDOMElement* aElement) // Flush all pending notifications so that our frames are uptodate doc->FlushPendingNotifications(Flush_Layout); - nsCOMPtr presContext; + nsCOMPtr presContext; presShell->GetPresContext(getter_AddRefs(presContext)); if (presContext) { diff --git a/mozilla/extensions/inspector/base/src/inLayoutUtils.h b/mozilla/extensions/inspector/base/src/inLayoutUtils.h index 76bce35ba0a..74d513dc4b4 100644 --- a/mozilla/extensions/inspector/base/src/inLayoutUtils.h +++ b/mozilla/extensions/inspector/base/src/inLayoutUtils.h @@ -69,7 +69,7 @@ public: * @param aPresContext the presentation context * @return the offset */ - static nsPoint GetClientOrigin(nsIPresContext* aPresContext, + static nsPoint GetClientOrigin(nsPresContext* aPresContext, nsIFrame* aFrame); static nsRect& GetScreenOrigin(nsIDOMElement* aElement); diff --git a/mozilla/extensions/layout-debug/src/nsLayoutDebuggingTools.cpp b/mozilla/extensions/layout-debug/src/nsLayoutDebuggingTools.cpp index 3393b23e885..c60d629273f 100644 --- a/mozilla/extensions/layout-debug/src/nsLayoutDebuggingTools.cpp +++ b/mozilla/extensions/layout-debug/src/nsLayoutDebuggingTools.cpp @@ -89,14 +89,14 @@ pres_shell(nsIDocShell *aDocShell) } #if 0 // not currently needed -static already_AddRefed +static already_AddRefed pres_context(nsIDocShell *aDocShell) { nsCOMPtr dv = do_QueryInterface(nsCOMPtr(doc_viewer(aDocShell))); if (!dv) return nsnull; - nsIPresContext *result = nsnull; + nsPresContext *result = nsnull; dv->GetPresContext(result); return result; } @@ -429,7 +429,7 @@ DumpFramesRecur(nsIDocShell* aDocShell, FILE* out) nsIFrame* root; shell->GetRootFrame(&root); if (root) { - nsCOMPtr presContext; + nsCOMPtr presContext; shell->GetPresContext(getter_AddRefs(presContext)); nsIFrameDebug* fdbg; diff --git a/mozilla/extensions/layout-debug/src/nsRegressionTester.cpp b/mozilla/extensions/layout-debug/src/nsRegressionTester.cpp index 2d6b21c88b3..261715f47d0 100644 --- a/mozilla/extensions/layout-debug/src/nsRegressionTester.cpp +++ b/mozilla/extensions/layout-debug/src/nsRegressionTester.cpp @@ -124,7 +124,7 @@ nsRegressionTester::DumpFrameModel(nsIDOMWindow *aWindowToDump, nsILocalFile *aD if (NS_FAILED(rv)) return rv; } - nsCOMPtr presContext; + nsCOMPtr presContext; presShell->GetPresContext(getter_AddRefs(presContext)); fdbg->DumpRegressionData(presContext, fp, 0, dumpStyle); diff --git a/mozilla/extensions/typeaheadfind/src/nsTypeAheadFind.cpp b/mozilla/extensions/typeaheadfind/src/nsTypeAheadFind.cpp index 5945d100573..31875f2d3b7 100644 --- a/mozilla/extensions/typeaheadfind/src/nsTypeAheadFind.cpp +++ b/mozilla/extensions/typeaheadfind/src/nsTypeAheadFind.cpp @@ -923,7 +923,7 @@ nsTypeAheadFind::HandleChar(PRUnichar aChar) // If not, make sure the selection is in sync with the focus, so we can // start our search from there. nsCOMPtr focusedContent; - nsCOMPtr presContext; + nsCOMPtr presContext; nsCOMPtr presShell(do_QueryReferent(mFocusedWeakShell)); NS_ENSURE_TRUE(presShell, NS_OK); presShell->GetPresContext(getter_AddRefs(presContext)); @@ -1209,7 +1209,7 @@ nsTypeAheadFind::FindItNow(nsIPresShell *aPresShell, } } - nsCOMPtr presContext; + nsCOMPtr presContext; presShell->GetPresContext(getter_AddRefs(presContext)); if (!presContext) { @@ -1448,7 +1448,7 @@ nsTypeAheadFind::GetSearchContainers(nsISupports *aContainer, PRBool aIsFirstVisiblePreferred, PRBool aCanUseDocSelection, nsIPresShell **aPresShell, - nsIPresContext **aPresContext) + nsPresContext **aPresContext) { NS_ENSURE_ARG_POINTER(aContainer); NS_ENSURE_ARG_POINTER(aPresShell); @@ -1462,7 +1462,7 @@ nsTypeAheadFind::GetSearchContainers(nsISupports *aContainer, return NS_ERROR_FAILURE; } - nsCOMPtr presContext; + nsCOMPtr presContext; nsCOMPtr presShell; docShell->GetPresShell(getter_AddRefs(presShell)); @@ -1719,7 +1719,7 @@ nsTypeAheadFind::FindNext(PRBool aFindBackwards, nsISupportsInterfacePointer *aC nsCOMPtr typeAheadPresShell(do_QueryReferent(mFocusedWeakShell)); NS_ENSURE_TRUE(typeAheadPresShell, NS_OK); - nsCOMPtr presContext; + nsCOMPtr presContext; typeAheadPresShell->GetPresContext(getter_AddRefs(presContext)); NS_ENSURE_TRUE(presContext, NS_OK); @@ -2492,9 +2492,9 @@ nsTypeAheadFind::GetTargetIfTypeAheadOkay(nsIDOMEvent *aEvent, return NS_OK; } - nsCOMPtr presContext; + nsCOMPtr presContext; presShell->GetPresContext(getter_AddRefs(presContext)); - if (presContext->Type() == nsIPresContext::eContext_PrintPreview) { + if (presContext->Type() == nsPresContext::eContext_PrintPreview) { // Typeaheadfind is not designed to work in print preview. // You can't navigate through the links there. if (lastShell != presShell) { @@ -2518,7 +2518,7 @@ nsTypeAheadFind::GetSelection(nsIPresShell *aPresShell, // if aCurrentNode is nsnull, get selection for document *aDOMSel = nsnull; - nsCOMPtr presContext; + nsCOMPtr presContext; aPresShell->GetPresContext(getter_AddRefs(presContext)); nsIFrame *frame = nsnull; @@ -2536,7 +2536,7 @@ nsTypeAheadFind::GetSelection(nsIPresShell *aPresShell, PRBool nsTypeAheadFind::IsRangeVisible(nsIPresShell *aPresShell, - nsIPresContext *aPresContext, + nsPresContext *aPresContext, nsIDOMRange *aRange, PRBool aMustBeInViewPort, PRBool aGetTopVisibleLeaf, nsIDOMRange **aFirstVisibleRange) @@ -2719,7 +2719,7 @@ nsTypeAheadFind::DisplayStatus(PRBool aSuccess, nsIContent *aFocusedContent, return; } - nsCOMPtr presContext; + nsCOMPtr presContext; presShell->GetPresContext(getter_AddRefs(presContext)); if (!presContext) { return; @@ -2989,7 +2989,7 @@ nsTypeAheadController::EnsureContentWindow(nsIDOMWindowInternal *aFocusedWin, NS_ENSURE_TRUE(doc, NS_ERROR_FAILURE); nsCOMPtr docShell(do_QueryInterface(container)); - nsCOMPtr presContext; + nsCOMPtr presContext; docShell->GetPresContext(getter_AddRefs(presContext)); NS_ENSURE_TRUE(presContext, NS_ERROR_FAILURE); diff --git a/mozilla/extensions/typeaheadfind/src/nsTypeAheadFind.h b/mozilla/extensions/typeaheadfind/src/nsTypeAheadFind.h index f0992e7f9c1..61a47ab5317 100644 --- a/mozilla/extensions/typeaheadfind/src/nsTypeAheadFind.h +++ b/mozilla/extensions/typeaheadfind/src/nsTypeAheadFind.h @@ -57,7 +57,7 @@ #include "nsWeakReference.h" #include "nsIAppStartupNotifier.h" #include "nsIPresShell.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsISelection.h" #include "nsIDOMRange.h" #include "nsIDOMWindow.h" @@ -168,7 +168,7 @@ protected: // Get selection and selection controller for current pres shell void GetSelection(nsIPresShell *aPresShell, nsISelectionController **aSelCon, nsISelection **aDomSel); - PRBool IsRangeVisible(nsIPresShell *aPresShell, nsIPresContext *aPresContext, + PRBool IsRangeVisible(nsIPresShell *aPresShell, nsPresContext *aPresContext, nsIDOMRange *aRange, PRBool aMustBeVisible, PRBool aGetTopVisibleLeaf, nsIDOMRange **aNewRange); @@ -179,7 +179,7 @@ protected: PRBool aIsFirstVisiblePreferred, PRBool aCanUseDocSelection, nsIPresShell **aPresShell, - nsIPresContext **aPresContext); + nsPresContext **aPresContext); void DisplayStatus(PRBool aSuccess, nsIContent *aFocusedContent, PRBool aClearStatus, const PRUnichar *aText = nsnull); nsresult GetTranslatedString(const nsAString& aKey, nsAString& aStringOut); diff --git a/mozilla/extensions/xmlterm/base/mozXMLTermShell.cpp b/mozilla/extensions/xmlterm/base/mozXMLTermShell.cpp index 1126e72deed..0b07c1d7762 100644 --- a/mozilla/extensions/xmlterm/base/mozXMLTermShell.cpp +++ b/mozilla/extensions/xmlterm/base/mozXMLTermShell.cpp @@ -52,7 +52,7 @@ #include "nsIDocShell.h" #include "nsIPresShell.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIScriptGlobalObject.h" #include "nsIServiceManager.h" diff --git a/mozilla/extensions/xmlterm/base/mozXMLTermStream.cpp b/mozilla/extensions/xmlterm/base/mozXMLTermStream.cpp index 649b2dad4e5..965b41991da 100644 --- a/mozilla/extensions/xmlterm/base/mozXMLTermStream.cpp +++ b/mozilla/extensions/xmlterm/base/mozXMLTermStream.cpp @@ -50,7 +50,7 @@ #include "nsIServiceManager.h" #include "nsIContentViewer.h" #include "nsIDocumentViewer.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIPresShell.h" #include "nsIViewManager.h" @@ -372,7 +372,7 @@ NS_IMETHODIMP mozXMLTermStream::SizeToContentHeight(PRInt32 maxHeight) return NS_ERROR_FAILURE; // Get pres context - nsCOMPtr presContext; + nsCOMPtr presContext; result = docShell->GetPresContext(getter_AddRefs(presContext)); if (NS_FAILED(result) || !presContext) return NS_ERROR_FAILURE; diff --git a/mozilla/extensions/xmlterm/base/mozXMLTermUtils.cpp b/mozilla/extensions/xmlterm/base/mozXMLTermUtils.cpp index ef924964f77..1604106d95b 100644 --- a/mozilla/extensions/xmlterm/base/mozXMLTermUtils.cpp +++ b/mozilla/extensions/xmlterm/base/mozXMLTermUtils.cpp @@ -47,7 +47,7 @@ #include "nsIContentViewer.h" #include "nsIDocumentViewer.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIPresShell.h" #include "nsIDeviceContext.h" @@ -156,7 +156,7 @@ mozXMLTermUtils::GetInnerDOMWindow(nsIDOMWindowInternal* outerDOMWindow, * @return NS_OK on success */ NS_EXPORT nsresult -mozXMLTermUtils::GetPresContextScrollableView(nsIPresContext* aPresContext, +mozXMLTermUtils::GetPresContextScrollableView(nsPresContext* aPresContext, nsIScrollableView** aScrollableView) { XMLT_LOG(mozXMLTermUtils::GetPresContextScrollableView,30,("\n")); @@ -184,7 +184,7 @@ mozXMLTermUtils::GetPresContextScrollableView(nsIPresContext* aPresContext, * @return NS_OK on success */ NS_EXPORT nsresult -mozXMLTermUtils::GetPresContextDeviceContext(nsIPresContext* aPresContext, +mozXMLTermUtils::GetPresContextDeviceContext(nsPresContext* aPresContext, nsIDeviceContext** aDeviceContext) { nsresult result; diff --git a/mozilla/extensions/xmlterm/base/mozXMLTermUtils.h b/mozilla/extensions/xmlterm/base/mozXMLTermUtils.h index 56e604668de..869dfd7d746 100644 --- a/mozilla/extensions/xmlterm/base/mozXMLTermUtils.h +++ b/mozilla/extensions/xmlterm/base/mozXMLTermUtils.h @@ -89,7 +89,7 @@ class mozXMLTermUtils * @return NS_OK on success */ static NS_EXPORT nsresult - GetPresContextScrollableView(nsIPresContext* aPresContext, + GetPresContextScrollableView(nsPresContext* aPresContext, nsIScrollableView** aScrollableView); /** Gets the device context for presentation context @@ -98,7 +98,7 @@ class mozXMLTermUtils * @return NS_OK on success */ static NS_EXPORT nsresult - GetPresContextDeviceContext(nsIPresContext* aPresContext, + GetPresContextDeviceContext(nsPresContext* aPresContext, nsIDeviceContext** aDeviceContext); /** Gets the script context for document diff --git a/mozilla/extensions/xmlterm/base/mozXMLTerminal.cpp b/mozilla/extensions/xmlterm/base/mozXMLTerminal.cpp index 3cad79d15f8..a0dd401f8af 100644 --- a/mozilla/extensions/xmlterm/base/mozXMLTerminal.cpp +++ b/mozilla/extensions/xmlterm/base/mozXMLTerminal.cpp @@ -54,7 +54,7 @@ #include "nsIObserver.h" #include "nsISelectionController.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsICaret.h" #include "nsRect.h" #include "nsIURI.h" @@ -417,7 +417,7 @@ NS_IMETHODIMP mozXMLTerminal::Activate(void) return NS_ERROR_FAILURE; // Get reference to presentation shell - nsCOMPtr presContext; + nsCOMPtr presContext; result = docShell->GetPresContext(getter_AddRefs(presContext)); if (NS_FAILED(result) || !presContext) return NS_ERROR_FAILURE; @@ -599,7 +599,7 @@ NS_IMETHODIMP mozXMLTerminal::ScreenSize(PRInt32* rows, PRInt32* cols, return NS_ERROR_FAILURE; // Get presentation context - nsCOMPtr presContext; + nsCOMPtr presContext; result = presShell->GetPresContext( getter_AddRefs(presContext) ); if (NS_FAILED(result)) return result; diff --git a/mozilla/gfx/public/nsFont.h b/mozilla/gfx/public/nsFont.h index 13b1c6af4fa..4a43eb499fe 100644 --- a/mozilla/gfx/public/nsFont.h +++ b/mozilla/gfx/public/nsFont.h @@ -50,7 +50,7 @@ typedef PRBool (*nsFontFamilyEnumFunc)(const nsString& aFamily, PRBool aGeneric, // IDs for generic fonts // NOTE: 0, 1 are reserved for the special IDs of the default variable -// and fixed fonts in the presentation context, see nsIPresContext.h +// and fixed fonts in the presentation context, see nsPresContext.h const PRUint8 kGenericFont_NONE = 0x00; // Special const PRUint8 kGenericFont_moz_variable = 0x00; // for the default variable width font diff --git a/mozilla/gfx/public/nsITheme.h b/mozilla/gfx/public/nsITheme.h index 4edc440a7b4..51bdb38ecec 100644 --- a/mozilla/gfx/public/nsITheme.h +++ b/mozilla/gfx/public/nsITheme.h @@ -47,7 +47,7 @@ struct nsRect; struct nsSize; struct nsFont; struct nsMargin; -class nsIPresContext; +class nsPresContext; class nsIRenderingContext; class nsIDeviceContext; class nsIFrame; @@ -88,7 +88,7 @@ public: NS_IMETHOD ThemeChanged()=0; - virtual PRBool ThemeSupportsWidget(nsIPresContext* aPresContext, + virtual PRBool ThemeSupportsWidget(nsPresContext* aPresContext, nsIFrame* aFrame, PRUint8 aWidgetType)=0; diff --git a/mozilla/gfx/src/gtk/nsNativeThemeGTK.cpp b/mozilla/gfx/src/gtk/nsNativeThemeGTK.cpp index 91c0bb16f41..e4e07d7782b 100644 --- a/mozilla/gfx/src/gtk/nsNativeThemeGTK.cpp +++ b/mozilla/gfx/src/gtk/nsNativeThemeGTK.cpp @@ -155,7 +155,7 @@ static PRInt32 GetContentState(nsIFrame* aFrame) if (!shell) return 0; - nsCOMPtr context; + nsCOMPtr context; shell->GetPresContext(getter_AddRefs(context)); PRInt32 flags = 0; context->EventStateManager()->GetContentState(aFrame->GetContent(), flags); @@ -690,7 +690,7 @@ nsNativeThemeGTK::ThemeChanged() } NS_IMETHODIMP_(PRBool) -nsNativeThemeGTK::ThemeSupportsWidget(nsIPresContext* aPresContext, +nsNativeThemeGTK::ThemeSupportsWidget(nsPresContext* aPresContext, nsIFrame* aFrame, PRUint8 aWidgetType) { diff --git a/mozilla/gfx/src/gtk/nsNativeThemeGTK.h b/mozilla/gfx/src/gtk/nsNativeThemeGTK.h index c4c8314645a..f32db3d3c7f 100644 --- a/mozilla/gfx/src/gtk/nsNativeThemeGTK.h +++ b/mozilla/gfx/src/gtk/nsNativeThemeGTK.h @@ -68,7 +68,7 @@ public: NS_IMETHOD ThemeChanged(); - NS_IMETHOD_(PRBool) ThemeSupportsWidget(nsIPresContext* aPresContext, + NS_IMETHOD_(PRBool) ThemeSupportsWidget(nsPresContext* aPresContext, nsIFrame* aFrame, PRUint8 aWidgetType); diff --git a/mozilla/gfx/src/mac/nsNativeThemeMac.cpp b/mozilla/gfx/src/mac/nsNativeThemeMac.cpp index e81c9cdb813..bc1c9e1981e 100644 --- a/mozilla/gfx/src/mac/nsNativeThemeMac.cpp +++ b/mozilla/gfx/src/mac/nsNativeThemeMac.cpp @@ -44,13 +44,13 @@ #include "nsTransform2D.h" #include "nsThemeConstants.h" #include "nsIPresShell.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIContent.h" #include "nsIDocument.h" #include "nsIFrame.h" #include "nsIEventStateManager.h" #include "nsINameSpaceManager.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsILookAndFeel.h" #include "nsRegionPool.h" #include "nsGfxUtils.h" @@ -746,7 +746,7 @@ nsNativeThemeMac::ThemeChanged() PRBool -nsNativeThemeMac::ThemeSupportsWidget(nsIPresContext* aPresContext, nsIFrame* aFrame, +nsNativeThemeMac::ThemeSupportsWidget(nsPresContext* aPresContext, nsIFrame* aFrame, PRUint8 aWidgetType) { #ifndef MOZ_WIDGET_COCOA diff --git a/mozilla/gfx/src/mac/nsNativeThemeMac.h b/mozilla/gfx/src/mac/nsNativeThemeMac.h index 553f774f2fe..eaaedac1c20 100644 --- a/mozilla/gfx/src/mac/nsNativeThemeMac.h +++ b/mozilla/gfx/src/mac/nsNativeThemeMac.h @@ -69,7 +69,7 @@ public: NS_IMETHOD WidgetStateChanged(nsIFrame* aFrame, PRUint8 aWidgetType, nsIAtom* aAttribute, PRBool* aShouldRepaint); NS_IMETHOD ThemeChanged(); - PRBool ThemeSupportsWidget(nsIPresContext* aPresContext, nsIFrame* aFrame, PRUint8 aWidgetType); + PRBool ThemeSupportsWidget(nsPresContext* aPresContext, nsIFrame* aFrame, PRUint8 aWidgetType); PRBool WidgetIsContainer(PRUint8 aWidgetType); protected: diff --git a/mozilla/gfx/src/shared/nsNativeTheme.cpp b/mozilla/gfx/src/shared/nsNativeTheme.cpp index 8be46ddaa7d..113e2ba6f2e 100644 --- a/mozilla/gfx/src/shared/nsNativeTheme.cpp +++ b/mozilla/gfx/src/shared/nsNativeTheme.cpp @@ -41,7 +41,7 @@ #include "nsIContent.h" #include "nsIFrame.h" #include "nsIPresShell.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIEventStateManager.h" #include "nsString.h" #include "nsINameSpaceManager.h" @@ -105,7 +105,7 @@ nsNativeTheme::GetContentState(nsIFrame* aFrame, PRUint8 aWidgetType) if (!shell) return 0; - nsCOMPtr context; + nsCOMPtr context; shell->GetPresContext(getter_AddRefs(context)); PRInt32 flags = 0; context->EventStateManager()->GetContentState(aFrame->GetContent(), flags); @@ -199,7 +199,7 @@ ConvertMarginToTwips(const nsMargin &aSource, nsMargin &aDest, float p2t) } PRBool -nsNativeTheme::IsWidgetStyled(nsIPresContext* aPresContext, nsIFrame* aFrame, +nsNativeTheme::IsWidgetStyled(nsPresContext* aPresContext, nsIFrame* aFrame, PRUint8 aWidgetType) { // Check for specific widgets to see if HTML has overridden the style. diff --git a/mozilla/gfx/src/shared/nsNativeTheme.h b/mozilla/gfx/src/shared/nsNativeTheme.h index 6a8cac4fea4..cca956a7135 100644 --- a/mozilla/gfx/src/shared/nsNativeTheme.h +++ b/mozilla/gfx/src/shared/nsNativeTheme.h @@ -47,7 +47,7 @@ class nsIFrame; class nsIPresShell; -class nsIPresContext; +class nsPresContext; class nsNativeTheme { @@ -60,7 +60,7 @@ class nsNativeTheme // Returns whether the widget is already styled by content // Normally called from ThemeSupportsWidget to turn off native theming // for elements that are already styled. - PRBool IsWidgetStyled(nsIPresContext* aPresContext, nsIFrame* aFrame, + PRBool IsWidgetStyled(nsPresContext* aPresContext, nsIFrame* aFrame, PRUint8 aWidgetType); // Accessors to widget-specific state information diff --git a/mozilla/gfx/src/windows/nsNativeThemeWin.cpp b/mozilla/gfx/src/windows/nsNativeThemeWin.cpp index 627e142315c..f2f8abb8201 100644 --- a/mozilla/gfx/src/windows/nsNativeThemeWin.cpp +++ b/mozilla/gfx/src/windows/nsNativeThemeWin.cpp @@ -45,7 +45,7 @@ #include "nsTransform2D.h" #include "nsThemeConstants.h" #include "nsIPresShell.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIContent.h" #include "nsIDocument.h" #include "nsIFrame.h" @@ -941,7 +941,7 @@ nsNativeThemeWin::ThemeChanged() } PRBool -nsNativeThemeWin::ThemeSupportsWidget(nsIPresContext* aPresContext, +nsNativeThemeWin::ThemeSupportsWidget(nsPresContext* aPresContext, nsIFrame* aFrame, PRUint8 aWidgetType) { @@ -981,7 +981,7 @@ nsNativeThemeWin::WidgetIsContainer(PRUint8 aWidgetType) /* Windows 9x/NT/2000/Classic XP Theme Support */ PRBool -nsNativeThemeWin::ClassicThemeSupportsWidget(nsIPresContext* aPresContext, +nsNativeThemeWin::ClassicThemeSupportsWidget(nsPresContext* aPresContext, nsIFrame* aFrame, PRUint8 aWidgetType) { diff --git a/mozilla/gfx/src/windows/nsNativeThemeWin.h b/mozilla/gfx/src/windows/nsNativeThemeWin.h index bc2e3db6c5c..17fe484f6cc 100644 --- a/mozilla/gfx/src/windows/nsNativeThemeWin.h +++ b/mozilla/gfx/src/windows/nsNativeThemeWin.h @@ -70,7 +70,7 @@ public: NS_IMETHOD ThemeChanged(); - PRBool ThemeSupportsWidget(nsIPresContext* aPresContext, + PRBool ThemeSupportsWidget(nsPresContext* aPresContext, nsIFrame* aFrame, PRUint8 aWidgetType); @@ -101,7 +101,7 @@ protected: nsSize* aResult, PRBool* aIsOverridable); - PRBool ClassicThemeSupportsWidget(nsIPresContext* aPresContext, + PRBool ClassicThemeSupportsWidget(nsPresContext* aPresContext, nsIFrame* aFrame, PRUint8 aWidgetType); diff --git a/mozilla/layout/base/nsBidiPresUtils.cpp b/mozilla/layout/base/nsBidiPresUtils.cpp index 8389177962f..2273d9e4144 100644 --- a/mozilla/layout/base/nsBidiPresUtils.cpp +++ b/mozilla/layout/base/nsBidiPresUtils.cpp @@ -41,7 +41,7 @@ #include "nsITextContent.h" #include "nsTextFragment.h" #include "nsLayoutAtoms.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIRenderingContext.h" #include "nsIServiceManager.h" #include "nsFrameManager.h" @@ -98,7 +98,7 @@ nsBidiPresUtils::IsSuccessful() const /* Some helper methods for Resolve() */ static nsresult -CreateBidiContinuation(nsIPresContext* aPresContext, +CreateBidiContinuation(nsPresContext* aPresContext, nsIContent* aContent, nsIFrame* aFrame, nsIFrame** aNewFrame) @@ -167,7 +167,7 @@ CreateBidiContinuation(nsIPresContext* aPresContext, * EnsureBidiContinuation() in previous reflows. */ nsresult -nsBidiPresUtils::Resolve(nsIPresContext* aPresContext, +nsBidiPresUtils::Resolve(nsPresContext* aPresContext, nsIFrame* aBlockFrame, nsIFrame* aFirstChild, PRBool& aForceReflow, @@ -356,7 +356,7 @@ nsBidiPresUtils::Resolve(nsIPresContext* aPresContext, } nsresult -nsBidiPresUtils::InitLogicalArray(nsIPresContext* aPresContext, +nsBidiPresUtils::InitLogicalArray(nsPresContext* aPresContext, nsIFrame* aCurrentFrame, nsIFrame* aNextInFlow, PRBool aAddMarkers) @@ -435,7 +435,7 @@ nsBidiPresUtils::InitLogicalArray(nsIPresContext* aPresContext, } void -nsBidiPresUtils::CreateBlockBuffer(nsIPresContext* aPresContext) +nsBidiPresUtils::CreateBlockBuffer(nsPresContext* aPresContext) { mBuffer.SetLength(0); @@ -486,7 +486,7 @@ nsBidiPresUtils::CreateBlockBuffer(nsIPresContext* aPresContext) } void -nsBidiPresUtils::ReorderFrames(nsIPresContext* aPresContext, +nsBidiPresUtils::ReorderFrames(nsPresContext* aPresContext, nsIRenderingContext* aRendContext, nsIFrame* aFirstChild, nsIFrame* aNextInFlow, @@ -506,7 +506,7 @@ nsBidiPresUtils::ReorderFrames(nsIPresContext* aPresContext, } nsresult -nsBidiPresUtils::Reorder(nsIPresContext* aPresContext, +nsBidiPresUtils::Reorder(nsPresContext* aPresContext, PRBool& aBidiEnabled) { aBidiEnabled = PR_FALSE; @@ -568,7 +568,7 @@ nsBidiPresUtils::Reorder(nsIPresContext* aPresContext, } void -nsBidiPresUtils::RepositionInlineFrames(nsIPresContext* aPresContext, +nsBidiPresUtils::RepositionInlineFrames(nsPresContext* aPresContext, nsIRenderingContext* aRendContext, nsIFrame* aFirstChild, PRInt32 aChildCount) const @@ -673,7 +673,7 @@ nsBidiPresUtils::RepositionInlineFrames(nsIPresContext* aPresContext, } void -nsBidiPresUtils::RepositionContainerFrame(nsIPresContext* aPresContext, +nsBidiPresUtils::RepositionContainerFrame(nsPresContext* aPresContext, nsIFrame* aContainer, PRInt32& aMinX, PRInt32& aMaxX) const @@ -716,7 +716,7 @@ nsBidiPresUtils::RepositionContainerFrame(nsIPresContext* aPresContext, } PRBool -nsBidiPresUtils::EnsureBidiContinuation(nsIPresContext* aPresContext, +nsBidiPresUtils::EnsureBidiContinuation(nsPresContext* aPresContext, nsIContent* aContent, nsIFrame* aFrame, nsIFrame** aNewFrame, @@ -751,7 +751,7 @@ nsBidiPresUtils::EnsureBidiContinuation(nsIPresContext* aPresContext, } void -nsBidiPresUtils::RemoveBidiContinuation(nsIPresContext* aPresContext, +nsBidiPresUtils::RemoveBidiContinuation(nsPresContext* aPresContext, nsIFrame* aFrame, PRInt32 aFirstIndex, PRInt32 aLastIndex, @@ -808,7 +808,7 @@ nsBidiPresUtils::RemoveBidiContinuation(nsIPresContext* aPresContext, } nsresult -nsBidiPresUtils::FormatUnicodeText(nsIPresContext* aPresContext, +nsBidiPresUtils::FormatUnicodeText(nsPresContext* aPresContext, PRUnichar* aText, PRInt32& aTextLength, nsCharType aCharType, @@ -1032,7 +1032,7 @@ nsresult nsBidiPresUtils::GetBidiEngine(nsBidi** aBidiEngine) nsresult nsBidiPresUtils::RenderText(PRUnichar* aText, PRInt32 aLength, nsBidiDirection aBaseDirection, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsIRenderingContext& aRenderingContext, nscoord aX, nscoord aY) diff --git a/mozilla/layout/base/nsBidiPresUtils.h b/mozilla/layout/base/nsBidiPresUtils.h index 294a2f3282d..5b68edb1c8d 100644 --- a/mozilla/layout/base/nsBidiPresUtils.h +++ b/mozilla/layout/base/nsBidiPresUtils.h @@ -70,7 +70,7 @@ public: * * @lina 06/18/2000 */ - nsresult Resolve(nsIPresContext* aPresContext, + nsresult Resolve(nsPresContext* aPresContext, nsIFrame* aBlockFrame, nsIFrame* aFirstChild, PRBool& aForceReflow, @@ -82,7 +82,7 @@ public: * * @lina 05/02/2000 */ - void ReorderFrames(nsIPresContext* aPresContext, + void ReorderFrames(nsPresContext* aPresContext, nsIRenderingContext* aRendContext, nsIFrame* aFirstChild, nsIFrame* aNextInFlow, @@ -95,7 +95,7 @@ public: * * @lina 06/18/2000 */ - nsresult FormatUnicodeText(nsIPresContext* aPresContext, + nsresult FormatUnicodeText(nsPresContext* aPresContext, PRUnichar* aText, PRInt32& aTextLength, nsCharType aCharType, @@ -134,7 +134,7 @@ public: nsresult RenderText(PRUnichar* aText, PRInt32 aLength, nsBidiDirection aBaseDirection, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsIRenderingContext& aRenderingContext, nscoord aX, nscoord aY); @@ -145,14 +145,14 @@ private: * * @lina 05/02/2000 */ - void CreateBlockBuffer(nsIPresContext* aPresContext); + void CreateBlockBuffer(nsPresContext* aPresContext); /** * Set up an array of the frames after splitting frames so that each frame has * consistent directionality. At this point the frames are still in logical * order */ - nsresult InitLogicalArray(nsIPresContext* aPresContext, + nsresult InitLogicalArray(nsPresContext* aPresContext, nsIFrame* aCurrentFrame, nsIFrame* aNextInFlow, PRBool aAddMarkers = PR_FALSE); @@ -163,22 +163,22 @@ private: * @param aBidiEnabled TRUE on return if the visual order is different from * the logical order */ - nsresult Reorder(nsIPresContext* aPresContext, + nsresult Reorder(nsPresContext* aPresContext, PRBool& aBidiEnabled); /** * Adjust frame positions following their visual order * - * @param nsIPresContext*, the first kid + * @param nsPresContext*, the first kid * * @lina 04/11/2000 */ - void RepositionInlineFrames(nsIPresContext* aPresContext, + void RepositionInlineFrames(nsPresContext* aPresContext, nsIRenderingContext* aRendContext, nsIFrame* aFirstChild, PRInt32 aChildCount) const; - void RepositionContainerFrame(nsIPresContext* aPresContext, + void RepositionContainerFrame(nsPresContext* aPresContext, nsIFrame* aContainer, PRInt32& aMinX, PRInt32& aMaxX) const; @@ -199,7 +199,7 @@ private: * @see Resolve() * @see RemoveBidiContinuation() */ - PRBool EnsureBidiContinuation(nsIPresContext* aPresContext, + PRBool EnsureBidiContinuation(nsPresContext* aPresContext, nsIContent* aContent, nsIFrame* aFrame, nsIFrame** aNewFrame, @@ -222,7 +222,7 @@ private: * @see Resolve() * @see EnsureBidiContinuation() */ - void RemoveBidiContinuation(nsIPresContext* aPresContext, + void RemoveBidiContinuation(nsPresContext* aPresContext, nsIFrame* aFrame, PRInt32 aFirstIndex, PRInt32 aLastIndex, diff --git a/mozilla/layout/base/nsCSSFrameConstructor.cpp b/mozilla/layout/base/nsCSSFrameConstructor.cpp index e1e69f7a776..a1cd1f4b22f 100644 --- a/mozilla/layout/base/nsCSSFrameConstructor.cpp +++ b/mozilla/layout/base/nsCSSFrameConstructor.cpp @@ -48,7 +48,7 @@ #include "nsIStyleRule.h" #include "nsIFrame.h" #include "nsHTMLAtoms.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsILinkHandler.h" #include "nsIDocument.h" #include "nsTableFrame.h" @@ -506,7 +506,7 @@ IsInlineFrame2(nsIFrame* aFrame) // XXX consolidate these things static PRBool -IsBlockFrame(nsIPresContext* aPresContext, nsIFrame* aFrame) +IsBlockFrame(nsPresContext* aPresContext, nsIFrame* aFrame) { // XXXwaterson this seems wrong; see IsInlineFrame() immediately // above, which will treat inline-block (e.g.) as an inline. Why @@ -516,7 +516,7 @@ IsBlockFrame(nsIPresContext* aPresContext, nsIFrame* aFrame) } static nsIFrame* -FindFirstBlock(nsIPresContext* aPresContext, nsIFrame* aKid, nsIFrame** aPrevKid) +FindFirstBlock(nsPresContext* aPresContext, nsIFrame* aKid, nsIFrame** aPrevKid) { nsIFrame* prevKid = nsnull; while (aKid) { @@ -532,7 +532,7 @@ FindFirstBlock(nsIPresContext* aPresContext, nsIFrame* aKid, nsIFrame** aPrevKid } static nsIFrame* -FindLastBlock(nsIPresContext* aPresContext, nsIFrame* aKid) +FindLastBlock(nsPresContext* aPresContext, nsIFrame* aKid) { nsIFrame* lastBlock = nsnull; while (aKid) { @@ -555,7 +555,7 @@ FindLastBlock(nsIPresContext* aPresContext, nsIFrame* aKid) * (if the real parent has NS_FRAME_IS_SPECIAL). */ inline void -MarkIBSpecialPrevSibling(nsIPresContext* aPresContext, +MarkIBSpecialPrevSibling(nsPresContext* aPresContext, nsFrameManager *aFrameManager, nsIFrame *aAnonymousFrame, nsIFrame *aSpecialParent) @@ -780,20 +780,20 @@ public: // Constructor // Use the passed-in history state. - nsFrameConstructorState(nsIPresContext* aPresContext, + nsFrameConstructorState(nsPresContext* aPresContext, nsIFrame* aFixedContainingBlock, nsIFrame* aAbsoluteContainingBlock, nsIFrame* aFloatContainingBlock, nsILayoutHistoryState* aHistoryState); // Get the history state from the pres context's pres shell. - nsFrameConstructorState(nsIPresContext* aPresContext, + nsFrameConstructorState(nsPresContext* aPresContext, nsIFrame* aFixedContainingBlock, nsIFrame* aAbsoluteContainingBlock, nsIFrame* aFloatContainingBlock); // Function to push the existing absolute containing block state and // create a new scope - void PushAbsoluteContainingBlock(nsIPresContext* aPresContext, + void PushAbsoluteContainingBlock(nsPresContext* aPresContext, nsIFrame* aNewAbsoluteContainingBlock, nsFrameConstructorSaveState& aSaveState); @@ -805,7 +805,7 @@ public: PRBool aFirstLineStyle); }; -nsFrameConstructorState::nsFrameConstructorState(nsIPresContext* aPresContext, +nsFrameConstructorState::nsFrameConstructorState(nsPresContext* aPresContext, nsIFrame* aFixedContainingBlock, nsIFrame* aAbsoluteContainingBlock, nsIFrame* aFloatContainingBlock, @@ -822,7 +822,7 @@ nsFrameConstructorState::nsFrameConstructorState(nsIPresContext* aPresCon mFrameManager = mPresShell->FrameManager(); } -nsFrameConstructorState::nsFrameConstructorState(nsIPresContext* aPresContext, +nsFrameConstructorState::nsFrameConstructorState(nsPresContext* aPresContext, nsIFrame* aFixedContainingBlock, nsIFrame* aAbsoluteContainingBlock, nsIFrame* aFloatContainingBlock) @@ -845,7 +845,7 @@ nsFrameConstructorState::nsFrameConstructorState(nsIPresContext* aPresCon // containing block. We don't need to do this for a block, since blocks aren't // continued in galley mode. static nsIFrame* -AdjustAbsoluteContainingBlock(nsIPresContext* aPresContext, +AdjustAbsoluteContainingBlock(nsPresContext* aPresContext, nsIFrame* aContainingBlockIn) { nsIFrame* containingBlock = aContainingBlockIn; @@ -858,7 +858,7 @@ AdjustAbsoluteContainingBlock(nsIPresContext* aPresContext, } void -nsFrameConstructorState::PushAbsoluteContainingBlock(nsIPresContext* aPresContext, +nsFrameConstructorState::PushAbsoluteContainingBlock(nsPresContext* aPresContext, nsIFrame* aNewAbsoluteContainingBlock, nsFrameConstructorSaveState& aSaveState) { @@ -945,7 +945,7 @@ GetRealFrame(nsIFrame* aFrame) * MoveChildrenTo(). */ static void -AdjustOutOfFlowFrameParentPtrs(nsIPresContext* aPresContext, +AdjustOutOfFlowFrameParentPtrs(nsPresContext* aPresContext, nsIFrame* aFrame, nsFrameConstructorState* aState) { @@ -1035,7 +1035,7 @@ AdjustOutOfFlowFrameParentPtrs(nsIPresContext* aPresContext, * pointers of out-of-flow frames will remain untouched. */ static void -MoveChildrenTo(nsIPresContext* aPresContext, +MoveChildrenTo(nsPresContext* aPresContext, nsStyleContext* aNewParentSC, nsIFrame* aNewParent, nsIFrame* aFrameList, @@ -1248,7 +1248,7 @@ GetCaptionAdjustedParent(nsIFrame* aParentFrame, // Helper function that determines the child list name that aChildFrame // is contained in static void -GetChildListNameFor(nsIPresContext* aPresContext, +GetChildListNameFor(nsPresContext* aPresContext, nsIFrame* aParentFrame, nsIFrame* aChildFrame, nsIAtom** aListName) @@ -1370,7 +1370,7 @@ nsCSSFrameConstructor::GeneratedContentFrameRemoved(nsIFrame* aFrame) } nsresult -nsCSSFrameConstructor::CreateGeneratedFrameFor(nsIPresContext* aPresContext, +nsCSSFrameConstructor::CreateGeneratedFrameFor(nsPresContext* aPresContext, nsIDocument* aDocument, nsIFrame* aParentFrame, nsIContent* aContent, @@ -1568,7 +1568,7 @@ nsCSSFrameConstructor::CreateGeneratedFrameFor(nsIPresContext* aPresContex */ PRBool nsCSSFrameConstructor::CreateGeneratedContentFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIFrame* aFrame, nsIContent* aContent, @@ -1649,7 +1649,7 @@ nsCSSFrameConstructor::CreateGeneratedContentFrame(nsIPresShell* aPresShe nsresult nsCSSFrameConstructor::CreateInputFrame(nsIPresShell *aPresShell, - nsIPresContext *aPresContext, + nsPresContext *aPresContext, nsIContent *aContent, nsIFrame *&aFrame, nsStyleContext *aStyleContext) @@ -1774,7 +1774,7 @@ GetOuterTableFrame(nsIFrame* aParentFrame) } static nsresult -ProcessPseudoFrame(nsIPresContext* aPresContext, +ProcessPseudoFrame(nsPresContext* aPresContext, nsPseudoFrameData& aPseudoData, nsIFrame*& aParent) { @@ -1792,7 +1792,7 @@ ProcessPseudoFrame(nsIPresContext* aPresContext, } static nsresult -ProcessPseudoTableFrame(nsIPresContext* aPresContext, +ProcessPseudoTableFrame(nsPresContext* aPresContext, nsPseudoFrames& aPseudoFrames, nsIFrame*& aParent) { @@ -1823,7 +1823,7 @@ ProcessPseudoTableFrame(nsIPresContext* aPresContext, } static nsresult -ProcessPseudoCellFrame(nsIPresContext* aPresContext, +ProcessPseudoCellFrame(nsPresContext* aPresContext, nsPseudoFrames& aPseudoFrames, nsIFrame*& aParent) { @@ -1839,7 +1839,7 @@ ProcessPseudoCellFrame(nsIPresContext* aPresContext, // limit the processing up to the frame type indicated by aHighestType. // make a complete processing when aHighestType is null static nsresult -ProcessPseudoFrames(nsIPresContext* aPresContext, +ProcessPseudoFrames(nsPresContext* aPresContext, nsPseudoFrames& aPseudoFrames, nsIAtom* aHighestType, nsIFrame*& aHighestFrame) @@ -1935,7 +1935,7 @@ ProcessPseudoFrames(nsIPresContext* aPresContext, } static nsresult -ProcessPseudoFrames(nsIPresContext* aPresContext, +ProcessPseudoFrames(nsPresContext* aPresContext, nsPseudoFrames& aPseudoFrames, nsFrameItems& aItems) { @@ -1949,7 +1949,7 @@ ProcessPseudoFrames(nsIPresContext* aPresContext, } static nsresult -ProcessPseudoFrames(nsIPresContext* aPresContext, +ProcessPseudoFrames(nsPresContext* aPresContext, nsPseudoFrames& aPseudoFrames, nsIAtom* aHighestType) { @@ -1960,7 +1960,7 @@ ProcessPseudoFrames(nsIPresContext* aPresContext, nsresult nsCSSFrameConstructor::CreatePseudoTableFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsTableCreator& aTableCreator, nsFrameConstructorState& aState, nsIFrame* aParentFrameIn) @@ -2009,7 +2009,7 @@ nsCSSFrameConstructor::CreatePseudoTableFrame(nsIPresShell* aPresShel nsresult nsCSSFrameConstructor::CreatePseudoRowGroupFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsTableCreator& aTableCreator, nsFrameConstructorState& aState, nsIFrame* aParentFrameIn) @@ -2053,7 +2053,7 @@ nsCSSFrameConstructor::CreatePseudoRowGroupFrame(nsIPresShell* aPresS nsresult nsCSSFrameConstructor::CreatePseudoColGroupFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsTableCreator& aTableCreator, nsFrameConstructorState& aState, nsIFrame* aParentFrameIn) @@ -2099,7 +2099,7 @@ nsCSSFrameConstructor::CreatePseudoColGroupFrame(nsIPresShell* aPresS nsresult nsCSSFrameConstructor::CreatePseudoRowFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsTableCreator& aTableCreator, nsFrameConstructorState& aState, nsIFrame* aParentFrameIn) @@ -2142,7 +2142,7 @@ nsCSSFrameConstructor::CreatePseudoRowFrame(nsIPresShell* aPresShell, nsresult nsCSSFrameConstructor::CreatePseudoCellFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsTableCreator& aTableCreator, nsFrameConstructorState& aState, nsIFrame* aParentFrameIn) @@ -2191,7 +2191,7 @@ nsCSSFrameConstructor::CreatePseudoCellFrame(nsIPresShell* aPresShell // called if the parent is not a table nsresult nsCSSFrameConstructor::GetPseudoTableFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsTableCreator& aTableCreator, nsFrameConstructorState& aState, nsIFrame& aParentFrameIn) @@ -2234,7 +2234,7 @@ nsCSSFrameConstructor::GetPseudoTableFrame(nsIPresShell* aPresShell, // called if the parent is not a col group nsresult nsCSSFrameConstructor::GetPseudoColGroupFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsTableCreator& aTableCreator, nsFrameConstructorState& aState, nsIFrame& aParentFrameIn) @@ -2281,7 +2281,7 @@ nsCSSFrameConstructor::GetPseudoColGroupFrame(nsIPresShell* aPresShel // called if the parent is not a row group nsresult nsCSSFrameConstructor::GetPseudoRowGroupFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsTableCreator& aTableCreator, nsFrameConstructorState& aState, nsIFrame& aParentFrameIn) @@ -2321,7 +2321,7 @@ nsCSSFrameConstructor::GetPseudoRowGroupFrame(nsIPresShell* aPresShel // called if the parent is not a row nsresult nsCSSFrameConstructor::GetPseudoRowFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsTableCreator& aTableCreator, nsFrameConstructorState& aState, nsIFrame& aParentFrameIn) @@ -2361,7 +2361,7 @@ nsCSSFrameConstructor::GetPseudoRowFrame(nsIPresShell* aPresShell, // called if the parent is not a cell or block nsresult nsCSSFrameConstructor::GetPseudoCellFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsTableCreator& aTableCreator, nsFrameConstructorState& aState, nsIFrame& aParentFrameIn) @@ -2398,7 +2398,7 @@ nsCSSFrameConstructor::GetPseudoCellFrame(nsIPresShell* aPresShell, nsresult nsCSSFrameConstructor::GetParentFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsTableCreator& aTableCreator, nsIFrame& aParentFrameIn, nsIAtom* aChildFrameType, @@ -2492,7 +2492,7 @@ nsCSSFrameConstructor::GetParentFrame(nsIPresShell* aPresShell, // of having frames handle page-break-before/after will solve the problem. nsresult nsCSSFrameConstructor::ConstructTableFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aContent, nsIFrame* aGeometricParent, @@ -2573,7 +2573,7 @@ nsCSSFrameConstructor::ConstructTableFrame(nsIPresShell* aPresShell, nsresult nsCSSFrameConstructor::ConstructTableCaptionFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aContent, nsIFrame* aParentFrameIn, @@ -2619,7 +2619,7 @@ nsCSSFrameConstructor::ConstructTableCaptionFrame(nsIPresShell* aPres nsresult nsCSSFrameConstructor::ConstructTableRowGroupFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aContent, nsIFrame* aParentFrameIn, @@ -2693,7 +2693,7 @@ nsCSSFrameConstructor::ConstructTableRowGroupFrame(nsIPresShell* aPre nsresult nsCSSFrameConstructor::ConstructTableColGroupFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aContent, nsIFrame* aParentFrameIn, @@ -2743,7 +2743,7 @@ nsCSSFrameConstructor::ConstructTableColGroupFrame(nsIPresShell* aPre nsresult nsCSSFrameConstructor::ConstructTableRowFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aContent, nsIFrame* aParentFrameIn, @@ -2798,7 +2798,7 @@ nsCSSFrameConstructor::ConstructTableRowFrame(nsIPresShell* aPresShel nsresult nsCSSFrameConstructor::ConstructTableColFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aContent, nsIFrame* aParentFrameIn, @@ -2861,7 +2861,7 @@ nsCSSFrameConstructor::ConstructTableColFrame(nsIPresShell* aPresShel nsresult nsCSSFrameConstructor::ConstructTableCellFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aContent, nsIFrame* aParentFrameIn, @@ -2958,7 +2958,7 @@ nsCSSFrameConstructor::ConstructTableCellFrame(nsIPresShell* aPresShe } PRBool -nsCSSFrameConstructor::MustGeneratePseudoParent(nsIPresContext* aPresContext, +nsCSSFrameConstructor::MustGeneratePseudoParent(nsPresContext* aPresContext, nsIFrame* aParentFrame, nsIAtom* aTag, nsIContent* aContent, @@ -2988,7 +2988,7 @@ nsCSSFrameConstructor::MustGeneratePseudoParent(nsIPresContext* aPresContext, // or row, but not a cell. nsresult nsCSSFrameConstructor::ConstructTableForeignFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aContent, nsIFrame* aParentFrameIn, @@ -3066,7 +3066,7 @@ NeedFrameFor(nsIFrame* aParentFrame, nsresult nsCSSFrameConstructor::TableProcessChildren(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aContent, nsIFrame* aParentFrame, @@ -3114,7 +3114,7 @@ nsCSSFrameConstructor::TableProcessChildren(nsIPresShell* aPresShell, nsresult nsCSSFrameConstructor::TableProcessChild(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aChildContent, nsIContent* aParentContent, @@ -3267,7 +3267,7 @@ nsCSSFrameConstructor::GetDisplay(nsIFrame* aFrame) nsresult nsCSSFrameConstructor::ConstructDocElementTableFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsIContent* aDocElement, nsIFrame* aParentFrame, nsIFrame*& aNewTableFrame, @@ -3295,7 +3295,7 @@ nsCSSFrameConstructor::ConstructDocElementTableFrame(nsIPresShell* aPresS * on the viewport at all */ nsIContent* -nsCSSFrameConstructor::PropagateScrollToViewport(nsIPresContext* aPresContext) +nsCSSFrameConstructor::PropagateScrollToViewport(nsPresContext* aPresContext) { // Set default aPresContext->SetViewportOverflowOverride(NS_STYLE_OVERFLOW_AUTO); @@ -3364,7 +3364,7 @@ nsCSSFrameConstructor::PropagateScrollToViewport(nsIPresContext* aPresContext) */ nsresult nsCSSFrameConstructor::ConstructDocElementFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aDocElement, nsIFrame* aParentFrame, @@ -3619,7 +3619,7 @@ nsCSSFrameConstructor::ConstructDocElementFrame(nsIPresShell* aPresShell, nsresult nsCSSFrameConstructor::ConstructRootFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsIContent* aDocElement, nsIFrame*& aNewFrame) { @@ -3709,7 +3709,7 @@ nsCSSFrameConstructor::ConstructRootFrame(nsIPresShell* aPresShell, PRBool isPaginated = aPresContext->IsPaginated(); PRBool isPrintPreview = - aPresContext->Type() == nsIPresContext::eContext_PrintPreview; + aPresContext->Type() == nsPresContext::eContext_PrintPreview; nsIFrame* rootFrame = nsnull; nsIAtom* rootPseudo; @@ -3953,7 +3953,7 @@ nsCSSFrameConstructor::ConstructRootFrame(nsIPresShell* aPresShell, nsresult nsCSSFrameConstructor::ConstructPageFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsIFrame* aParentFrame, nsIFrame* aPrevPageFrame, nsIFrame*& aPageFrame, @@ -4005,7 +4005,7 @@ nsCSSFrameConstructor::ConstructPageFrame(nsIPresShell* aPresShell, nsresult nsCSSFrameConstructor::CreatePlaceholderFrameFor(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameManager* aFrameManager, nsIContent* aContent, nsIFrame* aFrame, @@ -4041,7 +4041,7 @@ nsCSSFrameConstructor::CreatePlaceholderFrameFor(nsIPresShell* aPresShell, nsresult nsCSSFrameConstructor::ConstructRadioControlFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsIFrame*& aNewFrame, nsIContent* aContent, nsStyleContext* aStyleContext) @@ -4066,7 +4066,7 @@ nsCSSFrameConstructor::ConstructRadioControlFrame(nsIPresShell* aPresShel nsresult nsCSSFrameConstructor::ConstructCheckboxControlFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsIFrame*& aNewFrame, nsIContent* aContent, nsStyleContext* aStyleContext) @@ -4092,7 +4092,7 @@ nsCSSFrameConstructor::ConstructCheckboxControlFrame(nsIPresShell* aPresShell nsresult nsCSSFrameConstructor::ConstructSelectFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aContent, nsIFrame* aParentFrame, @@ -4255,7 +4255,7 @@ nsCSSFrameConstructor::ConstructSelectFrame(nsIPresShell* aPresShell, */ nsresult nsCSSFrameConstructor::InitializeSelectFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIFrame* scrollFrame, nsIFrame* scrolledFrame, @@ -4373,7 +4373,7 @@ nsCSSFrameConstructor::InitializeSelectFrame(nsIPresShell* aPresShell, nsresult nsCSSFrameConstructor::ConstructFieldSetFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aContent, nsIFrame* aParentFrame, @@ -4496,7 +4496,7 @@ nsCSSFrameConstructor::ConstructFieldSetFrame(nsIPresShell* aPresShel nsresult nsCSSFrameConstructor::ConstructTextFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aContent, nsIFrame* aParentFrame, @@ -4545,7 +4545,7 @@ nsCSSFrameConstructor::ConstructTextFrame(nsIPresShell* aPresShell, nsresult nsCSSFrameConstructor::ConstructHTMLFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aContent, nsIFrame* aParentFrame, @@ -4948,7 +4948,7 @@ nsCSSFrameConstructor::ConstructHTMLFrame(nsIPresShell* aPresShell, // after the node has been constructed and initialized create any // anonymous content a node needs. static void -LocateAnonymousFrame(nsIPresContext* aPresContext, +LocateAnonymousFrame(nsPresContext* aPresContext, nsIFrame* aParentFrame, nsIContent* aTargetContent, nsIFrame** aResult) @@ -4992,7 +4992,7 @@ LocateAnonymousFrame(nsIPresContext* aPresContext, nsresult nsCSSFrameConstructor::CreateAnonymousFrames(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsIAtom* aTag, nsFrameConstructorState& aState, nsIContent* aParent, @@ -5027,7 +5027,7 @@ nsCSSFrameConstructor::CreateAnonymousFrames(nsIPresShell* aPresShell // anonymous content a node needs. nsresult nsCSSFrameConstructor::CreateAnonymousFrames(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aParent, nsIDocument* aDocument, @@ -5141,7 +5141,7 @@ PRBool IsXULDisplayType(const nsStyleDisplay* aDisplay) nsresult nsCSSFrameConstructor::ConstructXULFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aContent, nsIFrame* aParentFrame, @@ -5790,7 +5790,7 @@ nsCSSFrameConstructor::ConstructXULFrame(nsIPresShell* aPresShell, already_AddRefed nsCSSFrameConstructor::BeginBuildingScrollFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aContent, nsStyleContext* aContentStyle, @@ -5810,7 +5810,7 @@ nsCSSFrameConstructor::BeginBuildingScrollFrame(nsIPresShell* aPresSh // if not then we are scrollbars inside the document. PRBool noScalingOfTwips = PR_FALSE; PRBool isPrintPreview = - aPresContext->Type() == nsIPresContext::eContext_PrintPreview; + aPresContext->Type() == nsPresContext::eContext_PrintPreview; if (isPrintPreview) { noScalingOfTwips = aParentFrame->GetType() == nsLayoutAtoms::viewportFrame; @@ -5887,7 +5887,7 @@ nsCSSFrameConstructor::BeginBuildingScrollFrame(nsIPresShell* aPresSh } nsresult -nsCSSFrameConstructor::FinishBuildingScrollFrame(nsIPresContext* aPresContext, +nsCSSFrameConstructor::FinishBuildingScrollFrame(nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aContent, nsIFrame* aScrollFrame, @@ -5961,7 +5961,7 @@ nsCSSFrameConstructor::FinishBuildingScrollFrame(nsIPresContext* aPresConte */ nsresult nsCSSFrameConstructor::BuildScrollFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aContent, nsStyleContext* aContentStyle, @@ -5978,7 +5978,7 @@ nsCSSFrameConstructor::BuildScrollFrame(nsIPresShell* aPresShell, // If the parent is a viewportFrame then we are the scrollbars for the UI // if not then we are scrollbars inside the document. PRBool noScalingOfTwips = PR_FALSE; - if (aPresContext->Type() == nsIPresContext::eContext_PrintPreview) { + if (aPresContext->Type() == nsPresContext::eContext_PrintPreview) { noScalingOfTwips = aParentFrame->GetType() == nsLayoutAtoms::viewportFrame; if (noScalingOfTwips) { aPresContext->SetScalingOfTwips(PR_FALSE); @@ -6033,7 +6033,7 @@ nsCSSFrameConstructor::BuildScrollFrame(nsIPresShell* aPresShell, */ nsresult nsCSSFrameConstructor::InitGfxScrollFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aContent, nsIDocument* aDocument, @@ -6059,7 +6059,7 @@ nsCSSFrameConstructor::InitGfxScrollFrame(nsIPresShell* aPresShell, nsresult nsCSSFrameConstructor::ConstructFrameByDisplayType(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, const nsStyleDisplay* aDisplay, nsIContent* aContent, @@ -6541,7 +6541,7 @@ nsCSSFrameConstructor::ConstructFrameByDisplayType(nsIPresShell* aPre PRBool -nsCSSFrameConstructor::IsScrollable(nsIPresContext* aPresContext, +nsCSSFrameConstructor::IsScrollable(nsPresContext* aPresContext, const nsStyleDisplay* aDisplay) { // For the time being it's scrollable if the overflow property is auto or @@ -6559,7 +6559,7 @@ nsCSSFrameConstructor::IsScrollable(nsIPresContext* aPresContext, nsresult -nsCSSFrameConstructor::InitAndRestoreFrame(nsIPresContext* aPresContext, +nsCSSFrameConstructor::InitAndRestoreFrame(nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aContent, nsIFrame* aParentFrame, @@ -6586,7 +6586,7 @@ nsCSSFrameConstructor::InitAndRestoreFrame(nsIPresContext* aPresContext } already_AddRefed -nsCSSFrameConstructor::ResolveStyleContext(nsIPresContext* aPresContext, +nsCSSFrameConstructor::ResolveStyleContext(nsPresContext* aPresContext, nsIFrame* aParentFrame, nsIContent* aContent) { @@ -6619,7 +6619,7 @@ nsCSSFrameConstructor::ResolveStyleContext(nsIPresContext* aPresContext, #ifdef MOZ_MATHML nsresult nsCSSFrameConstructor::ConstructMathMLFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aContent, nsIFrame* aParentFrame, @@ -6838,7 +6838,7 @@ nsCSSFrameConstructor::ConstructMathMLFrame(nsIPresShell* aPresShell, #ifdef MOZ_SVG nsresult nsCSSFrameConstructor::ConstructSVGFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aContent, nsIFrame* aParentFrame, @@ -6998,7 +6998,7 @@ nsCSSFrameConstructor::ConstructSVGFrame(nsIPresShell* aPresShell, PRBool nsCSSFrameConstructor::PageBreakBefore(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aContent, nsIFrame* aParentFrame, @@ -7022,7 +7022,7 @@ nsCSSFrameConstructor::PageBreakBefore(nsIPresShell* aPresShell, nsresult nsCSSFrameConstructor::ConstructPageBreakFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aContent, nsIFrame* aParentFrame, @@ -7045,7 +7045,7 @@ nsCSSFrameConstructor::ConstructPageBreakFrame(nsIPresShell* aPresShe nsresult nsCSSFrameConstructor::ConstructFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aContent, nsIFrame* aParentFrame, @@ -7097,7 +7097,7 @@ nsCSSFrameConstructor::ConstructFrame(nsIPresShell* aPresShell, nsresult nsCSSFrameConstructor::ConstructFrameInternal( nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aContent, nsIFrame* aParentFrame, @@ -7237,7 +7237,7 @@ IsRootBoxFrame(nsIFrame *aFrame) } nsresult -nsCSSFrameConstructor::ReconstructDocElementHierarchy(nsIPresContext* aPresContext) +nsCSSFrameConstructor::ReconstructDocElementHierarchy(nsPresContext* aPresContext) { NS_PRECONDITION(aPresContext, "null pres context argument"); @@ -7352,7 +7352,7 @@ nsCSSFrameConstructor::ReconstructDocElementHierarchy(nsIPresContext* aPresConte nsIFrame* nsCSSFrameConstructor::GetFrameFor(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsIContent* aContent) { // Get the primary frame associated with the content @@ -7366,7 +7366,7 @@ nsCSSFrameConstructor::GetFrameFor(nsIPresShell* aPresShell, } nsIFrame* -nsCSSFrameConstructor::GetAbsoluteContainingBlock(nsIPresContext* aPresContext, +nsCSSFrameConstructor::GetAbsoluteContainingBlock(nsPresContext* aPresContext, nsIFrame* aFrame) { NS_PRECONDITION(nsnull != mInitialContainingBlock, "no initial containing block"); @@ -7424,7 +7424,7 @@ nsCSSFrameConstructor::GetAbsoluteContainingBlock(nsIPresContext* aPresContext, } nsIFrame* -nsCSSFrameConstructor::GetFloatContainingBlock(nsIPresContext* aPresContext, +nsCSSFrameConstructor::GetFloatContainingBlock(nsPresContext* aPresContext, nsIFrame* aFrame) { NS_PRECONDITION(mInitialContainingBlock, "no initial containing block"); @@ -7471,7 +7471,7 @@ nsCSSFrameConstructor::GetFloatContainingBlock(nsIPresContext* aPresContext, * generated content. */ nsresult -nsCSSFrameConstructor::AppendFrames(nsIPresContext* aPresContext, +nsCSSFrameConstructor::AppendFrames(nsPresContext* aPresContext, nsIPresShell* aPresShell, nsFrameManager* aFrameManager, nsIContent* aContainer, @@ -7725,7 +7725,7 @@ nsCSSFrameConstructor::IsValidSibling(nsIPresShell& aPresShell, (NS_STYLE_DISPLAY_TABLE_FOOTER_GROUP == aSiblingDisplay)) { // if we haven't already, construct a style context to find the display type of aContent if (UNSET_DISPLAY == aDisplay) { - nsCOMPtr context; + nsCOMPtr context; aPresShell.GetPresContext(getter_AddRefs(context)); nsIFrame* parent = aSibling.GetParent(); @@ -7933,7 +7933,7 @@ ShouldIgnoreSelectChild(nsIContent* aContainer) // For tables, returns the inner table, if the child is not a caption. // For fieldsets, returns the area frame, if the child is not a legend. static nsIFrame* -GetAdjustedParentFrame(nsIPresContext* aPresContext, +GetAdjustedParentFrame(nsPresContext* aPresContext, nsIFrame* aParentFrame, nsIAtom* aParentFrameType, nsIContent* aParentContent, @@ -7959,7 +7959,7 @@ GetAdjustedParentFrame(nsIPresContext* aPresContext, return (newParent) ? newParent : aParentFrame; } -static nsresult InsertOutOfFlow(nsIPresContext* aPresContext, +static nsresult InsertOutOfFlow(nsPresContext* aPresContext, const nsAbsoluteItems& aFrameItems, nsIAtom* aChildListName) { if (!aFrameItems.childList) { @@ -8007,7 +8007,7 @@ static nsresult InsertOutOfFlow(nsIPresContext* aPresContext, static nsresult InsertOutOfFlowFrames(nsFrameConstructorState& aState, - nsIPresContext* aPresContext) { + nsPresContext* aPresContext) { // If there are new absolutely positioned child frames, then notify // the parent nsresult rv = InsertOutOfFlow(aPresContext, aState.mAbsoluteItems, @@ -8033,7 +8033,7 @@ InsertOutOfFlowFrames(nsFrameConstructorState& aState, } nsresult -nsCSSFrameConstructor::ContentAppended(nsIPresContext* aPresContext, +nsCSSFrameConstructor::ContentAppended(nsPresContext* aPresContext, nsIContent* aContainer, PRInt32 aNewIndexInContainer) { @@ -8398,7 +8398,7 @@ nsCSSFrameConstructor::ContentAppended(nsIPresContext* aPresContext, nsresult -nsCSSFrameConstructor::AddDummyFrameToSelect(nsIPresContext* aPresContext, +nsCSSFrameConstructor::AddDummyFrameToSelect(nsPresContext* aPresContext, nsIPresShell* aPresShell, nsFrameConstructorState& aState, nsIFrame* aListFrame, @@ -8444,13 +8444,13 @@ nsCSSFrameConstructor::AddDummyFrameToSelect(nsIPresContext* aPresContext, // defined below static nsresult -DeletingFrameSubtree(nsIPresContext* aPresContext, +DeletingFrameSubtree(nsPresContext* aPresContext, nsIPresShell* aPresShell, nsFrameManager* aFrameManager, nsIFrame* aFrame); nsresult -nsCSSFrameConstructor::RemoveDummyFrameFromSelect(nsIPresContext* aPresContext, +nsCSSFrameConstructor::RemoveDummyFrameFromSelect(nsPresContext* aPresContext, nsIPresShell * aPresShell, nsIContent* aContainer, nsIContent* aChild, @@ -8497,7 +8497,7 @@ nsCSSFrameConstructor::RemoveDummyFrameFromSelect(nsIPresContext* aPresContext, // aChild if a reframe is not necessary. PRBool nsCSSFrameConstructor::NeedSpecialFrameReframe(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsIContent* aParent1, nsIContent* aParent2, nsIFrame*& aParentFrame, @@ -8604,7 +8604,7 @@ enum content_operation // Helper function to lookup the listbox body frame and send a notification // for insertion or removal of content static -PRBool NotifyListBoxBody(nsIPresContext* aPresContext, +PRBool NotifyListBoxBody(nsPresContext* aPresContext, nsIContent* aContainer, nsIContent* aChild, PRInt32 aIndexInContainer, @@ -8657,7 +8657,7 @@ PRBool NotifyListBoxBody(nsIPresContext* aPresContext, #endif // MOZ_XUL nsresult -nsCSSFrameConstructor::ContentInserted(nsIPresContext* aPresContext, +nsCSSFrameConstructor::ContentInserted(nsPresContext* aPresContext, nsIContent* aContainer, nsIFrame* aContainerFrame, nsIContent* aChild, @@ -9022,7 +9022,7 @@ nsCSSFrameConstructor::ContentInserted(nsIPresContext* aPresContext, } nsresult -nsCSSFrameConstructor::ReinsertContent(nsIPresContext* aPresContext, +nsCSSFrameConstructor::ReinsertContent(nsPresContext* aPresContext, nsIContent* aContainer, nsIContent* aChild) { @@ -9063,7 +9063,7 @@ nsCSSFrameConstructor::ReinsertContent(nsIPresContext* aPresContext, * this changes */ static nsresult -DoDeletingFrameSubtree(nsIPresContext* aPresContext, +DoDeletingFrameSubtree(nsPresContext* aPresContext, nsIPresShell* aPresShell, nsFrameManager* aFrameManager, nsVoidArray& aDestroyQueue, @@ -9137,7 +9137,7 @@ DoDeletingFrameSubtree(nsIPresContext* aPresContext, * for aFrame and each of its continuing frames */ static nsresult -DeletingFrameSubtree(nsIPresContext* aPresContext, +DeletingFrameSubtree(nsPresContext* aPresContext, nsIPresShell* aPresShell, nsFrameManager* aFrameManager, nsIFrame* aFrame) @@ -9219,7 +9219,7 @@ DeletingFrameSubtree(nsIPresContext* aPresContext, } nsresult -nsCSSFrameConstructor::RemoveMappingsForFrameSubtree(nsIPresContext* aPresContext, +nsCSSFrameConstructor::RemoveMappingsForFrameSubtree(nsPresContext* aPresContext, nsIFrame* aRemovedFrame, nsILayoutHistoryState* aFrameState) { @@ -9233,7 +9233,7 @@ nsCSSFrameConstructor::RemoveMappingsForFrameSubtree(nsIPresContext* aPresContex } nsresult -nsCSSFrameConstructor::ContentRemoved(nsIPresContext* aPresContext, +nsCSSFrameConstructor::ContentRemoved(nsPresContext* aPresContext, nsIContent* aContainer, nsIContent* aChild, PRInt32 aIndexInContainer, @@ -9536,7 +9536,7 @@ static PRBool gInApplyRenderingChangeToTree = PR_FALSE; #endif static void -DoApplyRenderingChangeToTree(nsIPresContext* aPresContext, +DoApplyRenderingChangeToTree(nsPresContext* aPresContext, nsIFrame* aFrame, nsIViewManager* aViewManager, nsFrameManager* aFrameManager, @@ -9547,7 +9547,7 @@ DoApplyRenderingChangeToTree(nsIPresContext* aPresContext, * This rect is relative to aFrame's parent */ static void -UpdateViewsForTree(nsIPresContext* aPresContext, nsIFrame* aFrame, +UpdateViewsForTree(nsPresContext* aPresContext, nsIFrame* aFrame, nsIViewManager* aViewManager, nsFrameManager* aFrameManager, nsRect& aBoundsRect, nsChangeHint aChange) { @@ -9599,7 +9599,7 @@ UpdateViewsForTree(nsIPresContext* aPresContext, nsIFrame* aFrame, } static void -DoApplyRenderingChangeToTree(nsIPresContext* aPresContext, +DoApplyRenderingChangeToTree(nsPresContext* aPresContext, nsIFrame* aFrame, nsIViewManager* aViewManager, nsFrameManager* aFrameManager, @@ -9628,7 +9628,7 @@ DoApplyRenderingChangeToTree(nsIPresContext* aPresContext, } static void -ApplyRenderingChangeToTree(nsIPresContext* aPresContext, +ApplyRenderingChangeToTree(nsPresContext* aPresContext, nsIFrame* aFrame, nsIViewManager* aViewManager, nsChangeHint aChange) @@ -9679,7 +9679,7 @@ ApplyRenderingChangeToTree(nsIPresContext* aPresContext, } nsresult -nsCSSFrameConstructor::StyleChangeReflow(nsIPresContext* aPresContext, +nsCSSFrameConstructor::StyleChangeReflow(nsPresContext* aPresContext, nsIFrame* aFrame, nsIAtom* aAttribute) { @@ -9727,7 +9727,7 @@ nsCSSFrameConstructor::StyleChangeReflow(nsIPresContext* aPresContext, } nsresult -nsCSSFrameConstructor::CharacterDataChanged(nsIPresContext* aPresContext, +nsCSSFrameConstructor::CharacterDataChanged(nsPresContext* aPresContext, nsIContent* aContent, PRBool aAppend) { @@ -9794,7 +9794,7 @@ nsCSSFrameConstructor::CharacterDataChanged(nsIPresContext* aPresContext, nsresult nsCSSFrameConstructor::ProcessRestyledFrames(nsStyleChangeList& aChangeList, - nsIPresContext* aPresContext) + nsPresContext* aPresContext) { PRInt32 count = aChangeList.Count(); if (!count) @@ -9877,7 +9877,7 @@ nsCSSFrameConstructor::ProcessRestyledFrames(nsStyleChangeList& aChangeList, } void -nsCSSFrameConstructor::RestyleElement(nsIPresContext *aPresContext, +nsCSSFrameConstructor::RestyleElement(nsPresContext *aPresContext, nsIContent *aContent, nsIFrame *aPrimaryFrame) { @@ -9899,7 +9899,7 @@ nsCSSFrameConstructor::RestyleElement(nsIPresContext *aPresContext, } void -nsCSSFrameConstructor::RestyleLaterSiblings(nsIPresContext *aPresContext, +nsCSSFrameConstructor::RestyleLaterSiblings(nsPresContext *aPresContext, nsIContent *aContent) { nsIContent *parent = aContent->GetParent(); @@ -9922,7 +9922,7 @@ nsCSSFrameConstructor::RestyleLaterSiblings(nsIPresContext *aPresContext, } nsresult -nsCSSFrameConstructor::ContentStatesChanged(nsIPresContext* aPresContext, +nsCSSFrameConstructor::ContentStatesChanged(nsPresContext* aPresContext, nsIContent* aContent1, nsIContent* aContent2, PRInt32 aStateMask) @@ -9933,7 +9933,7 @@ nsCSSFrameConstructor::ContentStatesChanged(nsIPresContext* aPresContext, } void -nsCSSFrameConstructor::DoContentStateChanged(nsIPresContext* aPresContext, +nsCSSFrameConstructor::DoContentStateChanged(nsPresContext* aPresContext, nsIContent* aContent, PRInt32 aStateMask) { @@ -9975,7 +9975,7 @@ nsCSSFrameConstructor::DoContentStateChanged(nsIPresContext* aPresContext, } nsresult -nsCSSFrameConstructor::AttributeChanged(nsIPresContext* aPresContext, +nsCSSFrameConstructor::AttributeChanged(nsPresContext* aPresContext, nsIContent* aContent, PRInt32 aNameSpaceID, nsIAtom* aAttribute, @@ -10147,7 +10147,7 @@ void nsCSSFrameConstructor::GetAlternateTextFor(nsIContent* aContent, // Construct an alternate frame to use when the image can't be rendered nsresult nsCSSFrameConstructor::ConstructAlternateFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsIContent* aContent, nsStyleContext* aStyleContext, nsIFrame* aGeometricParent, @@ -10231,7 +10231,7 @@ IsPlaceholderFrame(nsIFrame* aFrame) static PRBool -HasDisplayableChildren(nsIPresContext* aPresContext, nsIFrame* aContainerFrame) +HasDisplayableChildren(nsPresContext* aPresContext, nsIFrame* aContainerFrame) { // Returns 'true' if there are frames within aContainerFrame that // could be displayed in the frame list. @@ -10264,7 +10264,7 @@ HasDisplayableChildren(nsIPresContext* aPresContext, nsIFrame* aContainerFrame) nsresult nsCSSFrameConstructor::CantRenderReplacedElement(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsIFrame* aFrame) { nsresult rv = NS_OK; @@ -10479,7 +10479,7 @@ nsCSSFrameConstructor::CantRenderReplacedElement(nsIPresShell* aPresShell, nsresult nsCSSFrameConstructor::CreateContinuingOuterTableFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsIFrame* aFrame, nsIFrame* aParentFrame, nsIContent* aContent, @@ -10553,7 +10553,7 @@ nsCSSFrameConstructor::CreateContinuingOuterTableFrame(nsIPresShell* aPresShe nsresult nsCSSFrameConstructor::CreateContinuingTableFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsIFrame* aFrame, nsIFrame* aParentFrame, nsIContent* aContent, @@ -10626,7 +10626,7 @@ nsCSSFrameConstructor::CreateContinuingTableFrame(nsIPresShell* aPresShell, } nsresult -nsCSSFrameConstructor::CreateContinuingFrame(nsIPresContext* aPresContext, +nsCSSFrameConstructor::CreateContinuingFrame(nsPresContext* aPresContext, nsIFrame* aFrame, nsIFrame* aParentFrame, nsIFrame** aContinuingFrame) @@ -10880,7 +10880,7 @@ nsCSSFrameConstructor::CreateContinuingFrame(nsIPresContext* aPresContext, // (and their children if the frames are "special") // for a frame that maps the specified content object nsIFrame* -nsCSSFrameConstructor::FindFrameWithContent(nsIPresContext* aPresContext, +nsCSSFrameConstructor::FindFrameWithContent(nsPresContext* aPresContext, nsFrameManager* aFrameManager, nsIFrame* aParentFrame, nsIContent* aParentContent, @@ -11029,7 +11029,7 @@ nsCSSFrameConstructor::FindFrameWithContent(nsIPresContext* aPresContext, // This is typically called by the pres shell when there is no mapping in // the pres shell hash table nsresult -nsCSSFrameConstructor::FindPrimaryFrameFor(nsIPresContext* aPresContext, +nsCSSFrameConstructor::FindPrimaryFrameFor(nsPresContext* aPresContext, nsFrameManager* aFrameManager, nsIContent* aContent, nsIFrame** aFrame, @@ -11197,7 +11197,7 @@ nsCSSFrameConstructor::GetInsertionPoint(nsIPresShell* aPresShell, // Capture state for the frame tree rooted at the frame associated with the // content object, aContent nsresult -nsCSSFrameConstructor::CaptureStateForFramesOf(nsIPresContext* aPresContext, +nsCSSFrameConstructor::CaptureStateForFramesOf(nsPresContext* aPresContext, nsIContent* aContent, nsILayoutHistoryState* aHistoryState) { @@ -11216,7 +11216,7 @@ nsCSSFrameConstructor::CaptureStateForFramesOf(nsIPresContext* aPresContext, // Capture state for the frame tree rooted at aFrame. nsresult -nsCSSFrameConstructor::CaptureStateFor(nsIPresContext* aPresContext, +nsCSSFrameConstructor::CaptureStateFor(nsPresContext* aPresContext, nsIFrame* aFrame, nsILayoutHistoryState* aHistoryState) { @@ -11230,7 +11230,7 @@ nsCSSFrameConstructor::CaptureStateFor(nsIPresContext* aPresContext, } nsresult -nsCSSFrameConstructor::MaybeRecreateFramesForContent(nsIPresContext* aPresContext, +nsCSSFrameConstructor::MaybeRecreateFramesForContent(nsPresContext* aPresContext, nsIContent* aContent) { nsresult result = NS_OK; @@ -11252,7 +11252,7 @@ nsCSSFrameConstructor::MaybeRecreateFramesForContent(nsIPresContext* aPresContex } nsresult -nsCSSFrameConstructor::RecreateFramesForContent(nsIPresContext* aPresContext, +nsCSSFrameConstructor::RecreateFramesForContent(nsPresContext* aPresContext, nsIContent* aContent) { // If there is no document, we don't want to recreate frames for it. (You @@ -11345,7 +11345,7 @@ nsCSSFrameConstructor::RecreateFramesForContent(nsIPresContext* aPresContext, // Block frame construction code already_AddRefed -nsCSSFrameConstructor::GetFirstLetterStyle(nsIPresContext* aPresContext, +nsCSSFrameConstructor::GetFirstLetterStyle(nsPresContext* aPresContext, nsIContent* aContent, nsStyleContext* aStyleContext) { @@ -11358,7 +11358,7 @@ nsCSSFrameConstructor::GetFirstLetterStyle(nsIPresContext* aPresContext, } already_AddRefed -nsCSSFrameConstructor::GetFirstLineStyle(nsIPresContext* aPresContext, +nsCSSFrameConstructor::GetFirstLineStyle(nsPresContext* aPresContext, nsIContent* aContent, nsStyleContext* aStyleContext) { @@ -11373,7 +11373,7 @@ nsCSSFrameConstructor::GetFirstLineStyle(nsIPresContext* aPresContext, // Predicate to see if a given content (block element) has // first-letter style applied to it. PRBool -nsCSSFrameConstructor::HaveFirstLetterStyle(nsIPresContext* aPresContext, +nsCSSFrameConstructor::HaveFirstLetterStyle(nsPresContext* aPresContext, nsIContent* aContent, nsStyleContext* aStyleContext) { @@ -11383,7 +11383,7 @@ nsCSSFrameConstructor::HaveFirstLetterStyle(nsIPresContext* aPresContext, } PRBool -nsCSSFrameConstructor::HaveFirstLineStyle(nsIPresContext* aPresContext, +nsCSSFrameConstructor::HaveFirstLineStyle(nsPresContext* aPresContext, nsIContent* aContent, nsStyleContext* aStyleContext) { @@ -11393,7 +11393,7 @@ nsCSSFrameConstructor::HaveFirstLineStyle(nsIPresContext* aPresContext, } void -nsCSSFrameConstructor::HaveSpecialBlockStyle(nsIPresContext* aPresContext, +nsCSSFrameConstructor::HaveSpecialBlockStyle(nsPresContext* aPresContext, nsIContent* aContent, nsStyleContext* aStyleContext, PRBool* aHaveFirstLetterStyle, @@ -11415,7 +11415,7 @@ nsCSSFrameConstructor::HaveSpecialBlockStyle(nsIPresContext* aPresContext, */ nsresult nsCSSFrameConstructor::ProcessChildren(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aContent, nsIFrame* aFrame, @@ -11497,7 +11497,7 @@ nsCSSFrameConstructor::ProcessChildren(nsIPresShell* aPresShell, // Support for :first-line style static void -ReparentFrame(nsIPresContext* aPresContext, +ReparentFrame(nsPresContext* aPresContext, nsIFrame* aNewParentFrame, nsStyleContext* aParentStyleContext, nsIFrame* aFrame) @@ -11513,7 +11513,7 @@ ReparentFrame(nsIPresContext* aPresContext, nsresult nsCSSFrameConstructor::WrapFramesInFirstLineFrame( nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aContent, nsIFrame* aFrame, @@ -11589,7 +11589,7 @@ nsCSSFrameConstructor::WrapFramesInFirstLineFrame( nsresult nsCSSFrameConstructor::AppendFirstLineFrames( nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aContent, nsIFrame* aBlockFrame, @@ -11666,7 +11666,7 @@ nsCSSFrameConstructor::AppendFirstLineFrames( // right place when first-line style is present. nsresult nsCSSFrameConstructor::InsertFirstLineFrames( - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aContent, nsIFrame* aBlockFrame, @@ -11886,7 +11886,7 @@ static PRBool IsFirstLetterContent(nsIContent* aContent) void nsCSSFrameConstructor::CreateFloatingLetterFrame( nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aTextContent, nsIFrame* aTextFrame, @@ -11956,7 +11956,7 @@ nsCSSFrameConstructor::CreateFloatingLetterFrame( * a child of aParentFrame. */ nsresult -nsCSSFrameConstructor::CreateLetterFrame(nsIPresShell* aPresShell, nsIPresContext* aPresContext, +nsCSSFrameConstructor::CreateLetterFrame(nsIPresShell* aPresShell, nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aTextContent, nsIFrame* aParentFrame, @@ -12016,7 +12016,7 @@ nsCSSFrameConstructor::CreateLetterFrame(nsIPresShell* aPresShell, nsIPresContex nsresult nsCSSFrameConstructor::WrapFramesInFirstLetterFrame( nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aBlockContent, nsIFrame* aBlockFrame, @@ -12078,7 +12078,7 @@ nsCSSFrameConstructor::WrapFramesInFirstLetterFrame( nsresult nsCSSFrameConstructor::WrapFramesInFirstLetterFrame( nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIFrame* aParentFrame, nsIFrame* aParentFrameList, @@ -12146,7 +12146,7 @@ nsCSSFrameConstructor::WrapFramesInFirstLetterFrame( nsresult nsCSSFrameConstructor::RemoveFloatingFirstLetterFrames( - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsIPresShell* aPresShell, nsFrameManager* aFrameManager, nsIFrame* aBlockFrame, @@ -12260,7 +12260,7 @@ nsCSSFrameConstructor::RemoveFloatingFirstLetterFrames( } nsresult -nsCSSFrameConstructor::RemoveFirstLetterFrames(nsIPresContext* aPresContext, +nsCSSFrameConstructor::RemoveFirstLetterFrames(nsPresContext* aPresContext, nsIPresShell* aPresShell, nsFrameManager* aFrameManager, nsIFrame* aFrame, @@ -12324,7 +12324,7 @@ nsCSSFrameConstructor::RemoveFirstLetterFrames(nsIPresContext* aPresContext, } nsresult -nsCSSFrameConstructor::RemoveLetterFrames(nsIPresContext* aPresContext, +nsCSSFrameConstructor::RemoveLetterFrames(nsPresContext* aPresContext, nsIPresShell* aPresShell, nsFrameManager* aFrameManager, nsIFrame* aBlockFrame) @@ -12342,7 +12342,7 @@ nsCSSFrameConstructor::RemoveLetterFrames(nsIPresContext* aPresContext, // Fixup the letter frame situation for the given block nsresult -nsCSSFrameConstructor::RecoverLetterFrames(nsIPresShell* aPresShell, nsIPresContext* aPresContext, +nsCSSFrameConstructor::RecoverLetterFrames(nsIPresShell* aPresShell, nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIFrame* aBlockFrame) { @@ -12387,7 +12387,7 @@ nsCSSFrameConstructor::RecoverLetterFrames(nsIPresShell* aPresShell, nsIPresCont // listbox Widget Routines nsresult -nsCSSFrameConstructor::CreateListBoxContent(nsIPresContext* aPresContext, +nsCSSFrameConstructor::CreateListBoxContent(nsPresContext* aPresContext, nsIFrame* aParentFrame, nsIFrame* aPrevFrame, nsIContent* aChild, @@ -12453,7 +12453,7 @@ nsCSSFrameConstructor::CreateListBoxContent(nsIPresContext* aPresContext, nsresult nsCSSFrameConstructor::ConstructBlock(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, const nsStyleDisplay* aDisplay, nsIContent* aContent, @@ -12534,7 +12534,7 @@ nsCSSFrameConstructor::AreAllKidsInline(nsIFrame* aFrameList) nsresult nsCSSFrameConstructor::ConstructInline(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, const nsStyleDisplay* aDisplay, nsIContent* aContent, @@ -12748,7 +12748,7 @@ nsCSSFrameConstructor::ConstructInline(nsIPresShell* aPresShell, nsresult nsCSSFrameConstructor::ProcessInlineChildren(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aContent, nsIFrame* aFrame, @@ -12839,7 +12839,7 @@ nsCSSFrameConstructor::ProcessInlineChildren(nsIPresShell* aPresShell, // This differs from DeletingFrameSubtree() because the frames have not yet been // added to the frame hierarchy static void -DoCleanupFrameReferences(nsIPresContext* aPresContext, +DoCleanupFrameReferences(nsPresContext* aPresContext, nsFrameManager* aFrameManager, nsIFrame* aFrameIn) { @@ -12870,7 +12870,7 @@ DoCleanupFrameReferences(nsIPresContext* aPresContext, // Helper function that walks a frame list and calls DoCleanupFrameReference() static void -CleanupFrameReferences(nsIPresContext* aPresContext, +CleanupFrameReferences(nsPresContext* aPresContext, nsFrameManager* aFrameManager, nsIFrame* aFrameList) { @@ -12883,7 +12883,7 @@ CleanupFrameReferences(nsIPresContext* aPresContext, } PRBool -nsCSSFrameConstructor::WipeContainingBlock(nsIPresContext* aPresContext, +nsCSSFrameConstructor::WipeContainingBlock(nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIFrame* aContainingBlock, nsIFrame* aFrame, @@ -13034,7 +13034,7 @@ nsCSSFrameConstructor::WipeContainingBlock(nsIPresContext* aPresContext, * sibling of |J|. */ nsresult -nsCSSFrameConstructor::SplitToContainingBlock(nsIPresContext* aPresContext, +nsCSSFrameConstructor::SplitToContainingBlock(nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIFrame* aFrame, nsIFrame* aLeftInlineChildFrame, @@ -13214,7 +13214,7 @@ nsCSSFrameConstructor::SplitToContainingBlock(nsIPresContext* aPresContext, } nsresult -nsCSSFrameConstructor::ReframeContainingBlock(nsIPresContext* aPresContext, nsIFrame* aFrame) +nsCSSFrameConstructor::ReframeContainingBlock(nsPresContext* aPresContext, nsIFrame* aFrame) { #ifdef DEBUG PRBool isAttinasi = PR_FALSE; @@ -13275,7 +13275,7 @@ nsCSSFrameConstructor::ReframeContainingBlock(nsIPresContext* aPresContext, nsIF return ReconstructDocElementHierarchy(aPresContext); } -nsresult nsCSSFrameConstructor::RemoveFixedItems(nsIPresContext* aPresContext, +nsresult nsCSSFrameConstructor::RemoveFixedItems(nsPresContext* aPresContext, nsIPresShell* aPresShell, nsFrameManager* aFrameManager) { diff --git a/mozilla/layout/base/nsCSSFrameConstructor.h b/mozilla/layout/base/nsCSSFrameConstructor.h index 31641f86bbc..81488c4674c 100644 --- a/mozilla/layout/base/nsCSSFrameConstructor.h +++ b/mozilla/layout/base/nsCSSFrameConstructor.h @@ -55,7 +55,7 @@ class nsVoidArray; class nsFrameManager; class nsFrameConstructorState; class nsIDOMHTMLSelectElement; -class nsIPresContext; +class nsPresContext; class nsStyleChangeList; class nsIFrame; @@ -86,17 +86,17 @@ private: public: nsresult ConstructRootFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsIContent* aDocElement, nsIFrame*& aNewFrame); - nsresult ReconstructDocElementHierarchy(nsIPresContext* aPresContext); + nsresult ReconstructDocElementHierarchy(nsPresContext* aPresContext); - nsresult ContentAppended(nsIPresContext* aPresContext, + nsresult ContentAppended(nsPresContext* aPresContext, nsIContent* aContainer, PRInt32 aNewIndexInContainer); - nsresult ContentInserted(nsIPresContext* aPresContext, + nsresult ContentInserted(nsPresContext* aPresContext, nsIContent* aContainer, nsIFrame* aContainerFrame, nsIContent* aChild, @@ -104,24 +104,24 @@ public: nsILayoutHistoryState* aFrameState, PRBool aInReinsertContent); - nsresult ContentRemoved(nsIPresContext* aPresContext, + nsresult ContentRemoved(nsPresContext* aPresContext, nsIContent* aContainer, nsIContent* aChild, PRInt32 aIndexInContainer, PRBool aInReinsertContent); - nsresult CharacterDataChanged(nsIPresContext* aPresContext, + nsresult CharacterDataChanged(nsPresContext* aPresContext, nsIContent* aContent, PRBool aAppend); - nsresult ContentStatesChanged(nsIPresContext* aPresContext, + nsresult ContentStatesChanged(nsPresContext* aPresContext, nsIContent* aContent1, nsIContent* aContent2, PRInt32 aStateMask); void GeneratedContentFrameRemoved(nsIFrame* aFrame); - nsresult AttributeChanged(nsIPresContext* aPresContext, + nsresult AttributeChanged(nsPresContext* aPresContext, nsIContent* aContent, PRInt32 aNameSpaceID, nsIAtom* aAttribute, @@ -133,15 +133,15 @@ public: void WillDestroyFrameTree(); nsresult ProcessRestyledFrames(nsStyleChangeList& aRestyleArray, - nsIPresContext* aPresContext); + nsPresContext* aPresContext); // Notification that we were unable to render a replaced element. nsresult CantRenderReplacedElement(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsIFrame* aFrame); // Request to create a continuing frame - nsresult CreateContinuingFrame(nsIPresContext* aPresContext, + nsresult CreateContinuingFrame(nsPresContext* aPresContext, nsIFrame* aFrame, nsIFrame* aParentFrame, nsIFrame** aContinuingFrame); @@ -149,7 +149,7 @@ public: // Request to find the primary frame associated with a given content object. // This is typically called by the pres shell when there is no mapping in // the pres shell hash table - nsresult FindPrimaryFrameFor(nsIPresContext* aPresContext, + nsresult FindPrimaryFrameFor(nsPresContext* aPresContext, nsFrameManager* aFrameManager, nsIContent* aContent, nsIFrame** aFrame, @@ -162,7 +162,7 @@ public: nsIFrame** aInsertionPoint, PRBool* aMultiple = nsnull); - nsresult CreateListBoxContent(nsIPresContext* aPresContext, + nsresult CreateListBoxContent(nsPresContext* aPresContext, nsIFrame* aParentFrame, nsIFrame* aPrevFrame, nsIContent* aChild, @@ -171,35 +171,35 @@ public: PRBool aIsScrollbar, nsILayoutHistoryState* aFrameState); - nsresult RemoveMappingsForFrameSubtree(nsIPresContext* aParentFrame, + nsresult RemoveMappingsForFrameSubtree(nsPresContext* aParentFrame, nsIFrame* aRemovedFrame, nsILayoutHistoryState* aFrameState); private: - nsresult ReinsertContent(nsIPresContext* aPresContext, + nsresult ReinsertContent(nsPresContext* aPresContext, nsIContent* aContainer, nsIContent* aChild); nsresult ConstructPageFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsIFrame* aParentFrame, nsIFrame* aPrevPageFrame, nsIFrame*& aPageFrame, nsIFrame*& aPageContentFrame); - void DoContentStateChanged(nsIPresContext* aPresContext, + void DoContentStateChanged(nsPresContext* aPresContext, nsIContent* aContent, PRInt32 aStateMask); - void RestyleElement(nsIPresContext* aPresContext, + void RestyleElement(nsPresContext* aPresContext, nsIContent* aContent, nsIFrame* aPrimaryFrame); - void RestyleLaterSiblings(nsIPresContext* aPresContext, + void RestyleLaterSiblings(nsPresContext* aPresContext, nsIContent* aContent); - nsresult InitAndRestoreFrame (nsIPresContext* aPresContext, + nsresult InitAndRestoreFrame (nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aContent, nsIFrame* aParentFrame, @@ -208,32 +208,32 @@ private: nsIFrame* aNewFrame); already_AddRefed - ResolveStyleContext(nsIPresContext* aPresContext, + ResolveStyleContext(nsPresContext* aPresContext, nsIFrame* aParentFrame, nsIContent* aContent); nsresult ConstructFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aContent, nsIFrame* aParentFrame, nsFrameItems& aFrameItems); nsresult ConstructDocElementFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aDocElement, nsIFrame* aParentFrame, nsIFrame*& aNewFrame); nsresult ConstructDocElementTableFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsIContent* aDocElement, nsIFrame* aParentFrame, nsIFrame*& aNewTableFrame, nsILayoutHistoryState* aFrameState); - nsresult CreateGeneratedFrameFor(nsIPresContext* aPresContext, + nsresult CreateGeneratedFrameFor(nsPresContext* aPresContext, nsIDocument* aDocument, nsIFrame* aParentFrame, nsIContent* aContent, @@ -243,7 +243,7 @@ private: nsIFrame** aFrame); PRBool CreateGeneratedContentFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIFrame* aFrame, nsIContent* aContent, @@ -251,7 +251,7 @@ private: nsIAtom* aPseudoElement, nsIFrame** aResult); - nsresult AppendFrames(nsIPresContext* aPresContext, + nsresult AppendFrames(nsPresContext* aPresContext, nsIPresShell* aPresShell, nsFrameManager* aFrameManager, nsIContent* aContainer, @@ -260,7 +260,7 @@ private: // BEGIN TABLE SECTION nsresult ConstructTableFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aContent, nsIFrame* aGeometricParent, @@ -274,7 +274,7 @@ private: PRBool& aIsPseudoParent); nsresult ConstructTableCaptionFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aContent, nsIFrame* aParent, @@ -285,7 +285,7 @@ private: PRBool& aIsPseudoParent); nsresult ConstructTableRowGroupFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aContent, nsIFrame* aParent, @@ -297,7 +297,7 @@ private: PRBool& aIsPseudoParent); nsresult ConstructTableColGroupFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aContent, nsIFrame* aParent, @@ -309,7 +309,7 @@ private: PRBool& aIsPseudoParent); nsresult ConstructTableRowFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aContent, nsIFrame* aParent, @@ -321,7 +321,7 @@ private: PRBool& aIsPseudoParent); nsresult ConstructTableColFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aContent, nsIFrame* aParent, @@ -333,7 +333,7 @@ private: PRBool& aIsPseudoParent); nsresult ConstructTableCellFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aContent, nsIFrame* aParentFrame, @@ -345,14 +345,14 @@ private: nsIFrame*& aNewCellInnerFrame, PRBool& aIsPseudoParent); - PRBool MustGeneratePseudoParent(nsIPresContext* aPresContext, + PRBool MustGeneratePseudoParent(nsPresContext* aPresContext, nsIFrame* aParentFrame, nsIAtom* aTag, nsIContent* aContent, nsStyleContext* aContext); nsresult ConstructTableForeignFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aContent, nsIFrame* aParentFrameIn, @@ -363,67 +363,67 @@ private: PRBool& aIsPseudoParent); nsresult CreatePseudoTableFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsTableCreator& aTableCreator, nsFrameConstructorState& aState, nsIFrame* aParentFrameIn = nsnull); nsresult CreatePseudoRowGroupFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsTableCreator& aTableCreator, nsFrameConstructorState& aState, nsIFrame* aParentFrameIn = nsnull); nsresult CreatePseudoColGroupFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsTableCreator& aTableCreator, nsFrameConstructorState& aState, nsIFrame* aParentFrameIn = nsnull); nsresult CreatePseudoRowFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsTableCreator& aTableCreator, nsFrameConstructorState& aState, nsIFrame* aParentFrameIn = nsnull); nsresult CreatePseudoCellFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsTableCreator& aTableCreator, nsFrameConstructorState& aState, nsIFrame* aParentFrameIn = nsnull); nsresult GetPseudoTableFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsTableCreator& aTableCreator, nsFrameConstructorState& aState, nsIFrame& aParentFrameIn); nsresult GetPseudoColGroupFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsTableCreator& aTableCreator, nsFrameConstructorState& aState, nsIFrame& aParentFrameIn); nsresult GetPseudoRowGroupFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsTableCreator& aTableCreator, nsFrameConstructorState& aState, nsIFrame& aParentFrameIn); nsresult GetPseudoRowFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsTableCreator& aTableCreator, nsFrameConstructorState& aState, nsIFrame& aParentFrameIn); nsresult GetPseudoCellFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsTableCreator& aTableCreator, nsFrameConstructorState& aState, nsIFrame& aParentFrameIn); nsresult GetParentFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsTableCreator& aTableCreator, nsIFrame& aParentFrameIn, nsIAtom* aChildFrameType, @@ -432,7 +432,7 @@ private: PRBool& aIsPseudoParent); nsresult TableProcessChildren(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aContent, nsIFrame* aParentFrame, @@ -441,7 +441,7 @@ private: nsIFrame*& aCaption); nsresult TableProcessChild(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aChildContent, nsIContent* aParentContent, @@ -457,7 +457,7 @@ private: // END TABLE SECTION nsresult CreatePlaceholderFrameFor(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameManager* aFrameManager, nsIContent* aContent, nsIFrame* aFrame, @@ -466,7 +466,7 @@ private: nsIFrame** aPlaceholderFrame); nsresult ConstructAlternateFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsIContent* aContent, nsStyleContext* aStyleContext, nsIFrame* aGeometricParent, @@ -474,19 +474,19 @@ private: nsIFrame*& aFrame); nsresult ConstructRadioControlFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsIFrame*& aNewFrame, nsIContent* aContent, nsStyleContext* aStyleContext); nsresult ConstructCheckboxControlFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsIFrame*& aNewFrame, nsIContent* aContent, nsStyleContext* aStyleContext); nsresult ConstructSelectFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aContent, nsIFrame* aParentFrame, @@ -500,7 +500,7 @@ private: nsFrameItems& aFrameItems); nsresult ConstructFieldSetFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aContent, nsIFrame* aParentFrame, @@ -513,7 +513,7 @@ private: PRBool aIsFixedPositioned); nsresult ConstructTextFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aContent, nsIFrame* aParentFrame, @@ -521,7 +521,7 @@ private: nsFrameItems& aFrameItems); nsresult ConstructPageBreakFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aContent, nsIFrame* aParentFrame, @@ -532,7 +532,7 @@ private: // and add it to aFrameItems. Return true if page-break-after:always is set on aStyleContext. // Don't do this for row groups, rows or cell, because tables handle those internally. PRBool PageBreakBefore(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aContent, nsIFrame* aParentFrame, @@ -540,7 +540,7 @@ private: nsFrameItems& aFrameItems); nsresult ConstructHTMLFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aContent, nsIFrame* aParentFrame, @@ -550,7 +550,7 @@ private: nsFrameItems& aFrameItems); nsresult ConstructFrameInternal( nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aContent, nsIFrame* aParentFrame, @@ -561,7 +561,7 @@ private: PRBool aXBLBaseTag); nsresult CreateAnonymousFrames(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsIAtom* aTag, nsFrameConstructorState& aState, nsIContent* aParent, @@ -571,7 +571,7 @@ private: PRBool aIsRoot = PR_FALSE); nsresult CreateAnonymousFrames(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aParent, nsIDocument* aDocument, @@ -582,7 +582,7 @@ private: //MathML Mod - RBS #ifdef MOZ_MATHML nsresult ConstructMathMLFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aContent, nsIFrame* aParentFrame, @@ -593,7 +593,7 @@ private: #endif nsresult ConstructXULFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aContent, nsIFrame* aParentFrame, @@ -608,7 +608,7 @@ private: // SVG - rods #ifdef MOZ_SVG nsresult ConstructSVGFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aContent, nsIFrame* aParentFrame, @@ -619,7 +619,7 @@ private: #endif nsresult ConstructFrameByDisplayType(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, const nsStyleDisplay* aDisplay, nsIContent* aContent, @@ -630,7 +630,7 @@ private: nsFrameItems& aFrameItems); nsresult ProcessChildren(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aContent, nsIFrame* aFrame, @@ -640,12 +640,12 @@ private: nsTableCreator* aTableCreator = nsnull); nsresult CreateInputFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsIContent* aContent, nsIFrame*& aFrame, nsStyleContext* aStyleContext); - nsresult AddDummyFrameToSelect(nsIPresContext* aPresContext, + nsresult AddDummyFrameToSelect(nsPresContext* aPresContext, nsIPresShell* aPresShell, nsFrameConstructorState& aState, nsIFrame* aListFrame, @@ -654,25 +654,25 @@ private: nsIContent* aContainer, nsIDOMHTMLSelectElement* aSelectElement); - nsresult RemoveDummyFrameFromSelect(nsIPresContext* aPresContext, + nsresult RemoveDummyFrameFromSelect(nsPresContext* aPresContext, nsIPresShell* aPresShell, nsIContent* aContainer, nsIContent* aChild, nsIDOMHTMLSelectElement* aSelectElement); - PRBool IsScrollable(nsIPresContext* aPresContext, const nsStyleDisplay* aDisplay); + PRBool IsScrollable(nsPresContext* aPresContext, const nsStyleDisplay* aDisplay); nsIFrame* GetFrameFor(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsIContent* aContent); - nsIFrame* GetAbsoluteContainingBlock(nsIPresContext* aPresContext, + nsIFrame* GetAbsoluteContainingBlock(nsPresContext* aPresContext, nsIFrame* aFrame); - nsIFrame* GetFloatContainingBlock(nsIPresContext* aPresContext, + nsIFrame* GetFloatContainingBlock(nsPresContext* aPresContext, nsIFrame* aFrame); - nsIContent* PropagateScrollToViewport(nsIPresContext* aPresContext); + nsIContent* PropagateScrollToViewport(nsPresContext* aPresContext); // Build a scroll frame: // Calls BeginBuildingScrollFrame, InitAndRestoreFrame, and then FinishBuildingScrollFrame @@ -681,7 +681,7 @@ private: // nsresult BuildScrollFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aContent, nsStyleContext* aContentStyle, @@ -695,7 +695,7 @@ private: // Builds the initial ScrollFrame already_AddRefed BeginBuildingScrollFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aContent, nsStyleContext* aContentStyle, @@ -712,7 +712,7 @@ private: // Creates and necessary views for the scrollframe and sets up the initial child list // nsresult - FinishBuildingScrollFrame(nsIPresContext* aPresContext, + FinishBuildingScrollFrame(nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aContent, nsIFrame* aScrollFrame, @@ -723,7 +723,7 @@ private: // nsresult InitGfxScrollFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aContent, nsIDocument* aDocument, @@ -738,7 +738,7 @@ private: nsresult InitializeSelectFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIFrame* scrollFrame, nsIFrame* scrolledFrame, @@ -749,18 +749,18 @@ private: PRBool aIsFixedPositioned, PRBool aCreateBlock); - nsresult MaybeRecreateFramesForContent(nsIPresContext* aPresContext, + nsresult MaybeRecreateFramesForContent(nsPresContext* aPresContext, nsIContent* aContent); - nsresult RecreateFramesForContent(nsIPresContext* aPresContext, + nsresult RecreateFramesForContent(nsPresContext* aPresContext, nsIContent* aContent); - nsresult RecreateFramesOnAttributeChange(nsIPresContext* aPresContext, + nsresult RecreateFramesOnAttributeChange(nsPresContext* aPresContext, nsIContent* aContent, nsIAtom* aAttribute); nsresult CreateContinuingOuterTableFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsIFrame* aFrame, nsIFrame* aParentFrame, nsIContent* aContent, @@ -768,7 +768,7 @@ private: nsIFrame** aContinuingFrame); nsresult CreateContinuingTableFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsIFrame* aFrame, nsIFrame* aParentFrame, nsIContent* aContent, @@ -780,37 +780,37 @@ private: // Methods support creating block frames and their children static already_AddRefed - GetFirstLetterStyle(nsIPresContext* aPresContext, + GetFirstLetterStyle(nsPresContext* aPresContext, nsIContent* aContent, nsStyleContext* aStyleContext); static already_AddRefed - GetFirstLineStyle(nsIPresContext* aPresContext, + GetFirstLineStyle(nsPresContext* aPresContext, nsIContent* aContent, nsStyleContext* aStyleContext); - static PRBool HaveFirstLetterStyle(nsIPresContext* aPresContext, + static PRBool HaveFirstLetterStyle(nsPresContext* aPresContext, nsIContent* aContent, nsStyleContext* aStyleContext); - static PRBool HaveFirstLineStyle(nsIPresContext* aPresContext, + static PRBool HaveFirstLineStyle(nsPresContext* aPresContext, nsIContent* aContent, nsStyleContext* aStyleContext); - static void HaveSpecialBlockStyle(nsIPresContext* aPresContext, + static void HaveSpecialBlockStyle(nsPresContext* aPresContext, nsIContent* aContent, nsStyleContext* aStyleContext, PRBool* aHaveFirstLetterStyle, PRBool* aHaveFirstLineStyle); - PRBool ShouldCreateFirstLetterFrame(nsIPresContext* aPresContext, + PRBool ShouldCreateFirstLetterFrame(nsPresContext* aPresContext, nsIContent* aContent, nsIFrame* aFrame); // |aContentParentFrame| should be null if it's really the same as // |aParentFrame|. nsresult ConstructBlock(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, const nsStyleDisplay* aDisplay, nsIContent* aContent, @@ -821,7 +821,7 @@ private: PRBool aRelPos); nsresult ConstructInline(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, const nsStyleDisplay* aDisplay, nsIContent* aContent, @@ -833,7 +833,7 @@ private: nsIFrame** aNextInlineFrame); nsresult ProcessInlineChildren(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aContent, nsIFrame* aFrame, @@ -843,14 +843,14 @@ private: PRBool AreAllKidsInline(nsIFrame* aFrameList); - PRBool WipeContainingBlock(nsIPresContext* aPresContext, + PRBool WipeContainingBlock(nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIFrame* blockContent, nsIFrame* aFrame, nsIFrame* aFrameList); PRBool NeedSpecialFrameReframe(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsIContent* aParent1, nsIContent* aParent2, nsIFrame*& aParentFrame, @@ -859,7 +859,7 @@ private: nsIFrame*& aPrevSibling, nsIFrame* aNextSibling); - nsresult SplitToContainingBlock(nsIPresContext* aPresContext, + nsresult SplitToContainingBlock(nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIFrame* aFrame, nsIFrame* aLeftInlineChildFrame, @@ -867,9 +867,9 @@ private: nsIFrame* aRightInlineChildFrame, PRBool aTransfer); - nsresult ReframeContainingBlock(nsIPresContext* aPresContext, nsIFrame* aFrame); + nsresult ReframeContainingBlock(nsPresContext* aPresContext, nsIFrame* aFrame); - nsresult StyleChangeReflow(nsIPresContext* aPresContext, nsIFrame* aFrame, nsIAtom* aAttribute); + nsresult StyleChangeReflow(nsPresContext* aPresContext, nsIFrame* aFrame, nsIAtom* aAttribute); /** Helper function that searches the immediate child frames * (and their children if the frames are "special") @@ -881,7 +881,7 @@ private: * @param aParentContent the parent for aContent * @param aHint an optional hint used to make the search for aFrame faster */ - nsIFrame* FindFrameWithContent(nsIPresContext* aPresContext, + nsIFrame* FindFrameWithContent(nsPresContext* aPresContext, nsFrameManager* aFrameManager, nsIFrame* aParentFrame, nsIContent* aParentContent, @@ -892,12 +892,12 @@ private: // Methods support :first-letter style - nsIContent* FindBlockFor(nsIPresContext* aPresContext, + nsIContent* FindBlockFor(nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aContainer); void CreateFloatingLetterFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aTextContent, nsIFrame* aTextFrame, @@ -907,21 +907,21 @@ private: nsFrameItems& aResult); nsresult CreateLetterFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aTextContent, nsIFrame* aParentFrame, nsFrameItems& aResult); nsresult WrapFramesInFirstLetterFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aBlockContent, nsIFrame* aBlockFrame, nsFrameItems& aBlockFrames); nsresult WrapFramesInFirstLetterFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIFrame* aParentFrame, nsIFrame* aParentFrameList, @@ -932,25 +932,25 @@ private: PRBool* aStopLooking); nsresult RecoverLetterFrames(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIFrame* aBlockFrame); // - nsresult RemoveLetterFrames(nsIPresContext* aPresContext, + nsresult RemoveLetterFrames(nsPresContext* aPresContext, nsIPresShell* aPresShell, nsFrameManager* aFrameManager, nsIFrame* aBlockFrame); // Recursive helper for RemoveLetterFrames - nsresult RemoveFirstLetterFrames(nsIPresContext* aPresContext, + nsresult RemoveFirstLetterFrames(nsPresContext* aPresContext, nsIPresShell* aPresShell, nsFrameManager* aFrameManager, nsIFrame* aFrame, PRBool* aStopLooking); // Special remove method for those pesky floating first-letter frames - nsresult RemoveFloatingFirstLetterFrames(nsIPresContext* aPresContext, + nsresult RemoveFloatingFirstLetterFrames(nsPresContext* aPresContext, nsIPresShell* aPresShell, nsFrameManager* aFrameManager, nsIFrame* aBlockFrame, @@ -958,12 +958,12 @@ private: // Capture state for the frame tree rooted at the frame associated with the // content object, aContent - nsresult CaptureStateForFramesOf(nsIPresContext* aPresContext, + nsresult CaptureStateForFramesOf(nsPresContext* aPresContext, nsIContent* aContent, nsILayoutHistoryState* aHistoryState); // Capture state for the frame tree rooted at aFrame. - nsresult CaptureStateFor(nsIPresContext* aPresContext, + nsresult CaptureStateFor(nsPresContext* aPresContext, nsIFrame* aFrame, nsILayoutHistoryState* aHistoryState); @@ -972,20 +972,20 @@ private: // Methods support :first-line style nsresult WrapFramesInFirstLineFrame(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aContent, nsIFrame* aFrame, nsFrameItems& aFrameItems); nsresult AppendFirstLineFrames(nsIPresShell* aPresShell, - nsIPresContext* aPresContext, + nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aContent, nsIFrame* aBlockFrame, nsFrameItems& aFrameItems); - nsresult InsertFirstLineFrames(nsIPresContext* aPresContext, + nsresult InsertFirstLineFrames(nsPresContext* aPresContext, nsFrameConstructorState& aState, nsIContent* aContent, nsIFrame* aBlockFrame, @@ -993,7 +993,7 @@ private: nsIFrame* aPrevSibling, nsFrameItems& aFrameItems); - nsresult RemoveFixedItems(nsIPresContext* aPresContext, + nsresult RemoveFixedItems(nsPresContext* aPresContext, nsIPresShell* aPresShell, nsFrameManager* aFrameManager); diff --git a/mozilla/layout/base/nsCSSRendering.cpp b/mozilla/layout/base/nsCSSRendering.cpp index 95add6658e1..a4141127d36 100644 --- a/mozilla/layout/base/nsCSSRendering.cpp +++ b/mozilla/layout/base/nsCSSRendering.cpp @@ -36,7 +36,7 @@ * * ***** END LICENSE BLOCK ***** */ #include "nsStyleConsts.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIImage.h" #include "nsIFrame.h" #include "nsPoint.h" @@ -1538,7 +1538,7 @@ nscolor newcolor; // then checked to ensure that it is the HTML or BODY element, and if it is, we get // it's primary frame and from that the style context and from that the color to use. // -PRBool GetBGColorForHTMLElement( nsIPresContext *aPresContext, +PRBool GetBGColorForHTMLElement( nsPresContext *aPresContext, const nsStyleBackground *&aBGColor ) { NS_ASSERTION(aPresContext, "null params not allowed"); @@ -1609,7 +1609,7 @@ PRBool GetBorderColor(const nsStyleColor* aColor, const nsStyleBorder& aBorder, } // XXX improve this to constrain rendering to the damaged area -void nsCSSRendering::PaintBorder(nsIPresContext* aPresContext, +void nsCSSRendering::PaintBorder(nsPresContext* aPresContext, nsIRenderingContext& aRenderingContext, nsIFrame* aForFrame, const nsRect& aDirtyRect, @@ -2040,7 +2040,7 @@ void nsCSSRendering::DrawCompositeSide(nsIRenderingContext& aRenderingContext, } // XXX improve this to constrain rendering to the damaged area -void nsCSSRendering::PaintOutline(nsIPresContext* aPresContext, +void nsCSSRendering::PaintOutline(nsPresContext* aPresContext, nsIRenderingContext& aRenderingContext, nsIFrame* aForFrame, const nsRect& aDirtyRect, @@ -2176,7 +2176,7 @@ nscoord width; // XXX: doesn't do corners or junctions well at all. Just uses logic stolen // from PaintBorder which is insufficient -void nsCSSRendering::PaintBorderEdges(nsIPresContext* aPresContext, +void nsCSSRendering::PaintBorderEdges(nsPresContext* aPresContext, nsIRenderingContext& aRenderingContext, nsIFrame* aForFrame, const nsRect& aDirtyRect, @@ -2426,7 +2426,7 @@ ComputeBackgroundAnchorPoint(const nsStyleBackground& aColor, // Returns the root scrollable frame, which is the first child of the root // frame. static nsIScrollableFrame* -GetRootScrollableFrame(nsIPresContext* aPresContext, nsIFrame* aRootFrame) +GetRootScrollableFrame(nsPresContext* aPresContext, nsIFrame* aRootFrame) { nsIScrollableFrame* scrollableFrame = nsnull; @@ -2518,7 +2518,7 @@ nsCSSRendering::FindNonTransparentBackground(nsStyleContext* aContext, // it does not actually paint a background, we need to get the right // background style so we correctly detect transparent documents. inline nsIFrame* -IsCanvasFrame(nsIPresContext* aPresContext, nsIFrame *aFrame) +IsCanvasFrame(nsPresContext* aPresContext, nsIFrame *aFrame) { nsIAtom* frameType = aFrame->GetType(); if (frameType == nsLayoutAtoms::canvasFrame || @@ -2536,7 +2536,7 @@ IsCanvasFrame(nsIPresContext* aPresContext, nsIFrame *aFrame) } inline PRBool -FindCanvasBackground(nsIPresContext* aPresContext, +FindCanvasBackground(nsPresContext* aPresContext, nsIFrame* aForFrame, const nsStyleBackground** aBackground) { @@ -2616,7 +2616,7 @@ FindCanvasBackground(nsIPresContext* aPresContext, } inline PRBool -FindElementBackground(nsIPresContext* aPresContext, +FindElementBackground(nsPresContext* aPresContext, nsIFrame* aForFrame, const nsStyleBackground** aBackground) { @@ -2658,7 +2658,7 @@ FindElementBackground(nsIPresContext* aPresContext, } PRBool -nsCSSRendering::FindBackground(nsIPresContext* aPresContext, +nsCSSRendering::FindBackground(nsPresContext* aPresContext, nsIFrame* aForFrame, const nsStyleBackground** aBackground, PRBool* aIsCanvas) @@ -2677,7 +2677,7 @@ nsCSSRendering::DidPaint() } void -nsCSSRendering::PaintBackground(nsIPresContext* aPresContext, +nsCSSRendering::PaintBackground(nsPresContext* aPresContext, nsIRenderingContext& aRenderingContext, nsIFrame* aForFrame, const nsRect& aDirtyRect, @@ -2760,7 +2760,7 @@ nsCSSRendering::PaintBackground(nsIPresContext* aPresContext, } void -nsCSSRendering::PaintBackgroundWithSC(nsIPresContext* aPresContext, +nsCSSRendering::PaintBackgroundWithSC(nsPresContext* aPresContext, nsIRenderingContext& aRenderingContext, nsIFrame* aForFrame, const nsRect& aDirtyRect, @@ -3212,7 +3212,7 @@ nsCSSRendering::PaintBackgroundWithSC(nsIPresContext* aPresContext, } void -nsCSSRendering::PaintBackgroundColor(nsIPresContext* aPresContext, +nsCSSRendering::PaintBackgroundColor(nsPresContext* aPresContext, nsIRenderingContext& aRenderingContext, nsIFrame* aForFrame, const nsRect& aBgClipArea, @@ -3287,7 +3287,7 @@ nsCSSRendering::PaintBackgroundColor(nsIPresContext* aPresContext, * @update 3/26/99 dwc */ void -nsCSSRendering::PaintRoundedBackground(nsIPresContext* aPresContext, +nsCSSRendering::PaintRoundedBackground(nsPresContext* aPresContext, nsIRenderingContext& aRenderingContext, nsIFrame* aForFrame, const nsRect& aBgClipArea, @@ -3397,7 +3397,7 @@ nsCSSRendering::PaintRoundedBackground(nsIPresContext* aPresContext, * @update 3/26/99 dwc */ void -nsCSSRendering::PaintRoundedBorder(nsIPresContext* aPresContext, +nsCSSRendering::PaintRoundedBorder(nsPresContext* aPresContext, nsIRenderingContext& aRenderingContext, nsIFrame* aForFrame, const nsRect& aDirtyRect, diff --git a/mozilla/layout/base/nsCSSRendering.h b/mozilla/layout/base/nsCSSRendering.h index f296c961c16..45f2de2cdf2 100644 --- a/mozilla/layout/base/nsCSSRendering.h +++ b/mozilla/layout/base/nsCSSRendering.h @@ -40,7 +40,7 @@ #include "nsIRenderingContext.h" struct nsPoint; class nsStyleContext; -class nsIPresContext; +class nsPresContext; class nsCSSRendering { public: @@ -52,7 +52,7 @@ public: * Both aDirtyRect and aBorderArea are in the local coordinate space * of aForFrame */ - static void PaintBorder(nsIPresContext* aPresContext, + static void PaintBorder(nsPresContext* aPresContext, nsIRenderingContext& aRenderingContext, nsIFrame* aForFrame, const nsRect& aDirtyRect, @@ -72,7 +72,7 @@ public: * Both aDirtyRect and aBorderArea are in the local coordinate space * of aForFrame */ - static void PaintOutline(nsIPresContext* aPresContext, + static void PaintOutline(nsPresContext* aPresContext, nsIRenderingContext& aRenderingContext, nsIFrame* aForFrame, const nsRect& aDirtyRect, @@ -94,7 +94,7 @@ public: * Both aDirtyRect and aBorderArea are in the local coordinate space * of aForFrame */ - static void PaintBorderEdges(nsIPresContext* aPresContext, + static void PaintBorderEdges(nsPresContext* aPresContext, nsIRenderingContext& aRenderingContext, nsIFrame* aForFrame, const nsRect& aDirtyRect, @@ -111,7 +111,7 @@ public: * using the pres context. This applies the rules for propagating * backgrounds between BODY, the root element, and the canvas. */ - static PRBool FindBackground(nsIPresContext* aPresContext, + static PRBool FindBackground(nsPresContext* aPresContext, nsIFrame* aForFrame, const nsStyleBackground** aBackground, PRBool* aIsCanvas); @@ -133,7 +133,7 @@ public: * Both aDirtyRect and aBorderArea are in the local coordinate space * of aForFrame */ - static void PaintBackground(nsIPresContext* aPresContext, + static void PaintBackground(nsPresContext* aPresContext, nsIRenderingContext& aRenderingContext, nsIFrame* aForFrame, const nsRect& aDirtyRect, @@ -148,7 +148,7 @@ public: * (which short-circuits the code that ensures that the root element's * background is drawn on the canvas. */ - static void PaintBackgroundWithSC(nsIPresContext* aPresContext, + static void PaintBackgroundWithSC(nsPresContext* aPresContext, nsIRenderingContext& aRenderingContext, nsIFrame* aForFrame, const nsRect& aDirtyRect, @@ -224,7 +224,7 @@ protected: * Both aDirtyRect and aBorderArea are in the local coordinate space * of aForFrame */ - static void PaintRoundedBorder(nsIPresContext* aPresContext, + static void PaintRoundedBorder(nsPresContext* aPresContext, nsIRenderingContext& aRenderingContext, nsIFrame* aForFrame, const nsRect& aDirtyRect, @@ -241,7 +241,7 @@ protected: PRUint8 aSide,nsMargin &aBorThick,nscoord aTwipsPerPixel, PRBool aIsOutline=PR_FALSE); - static void PaintBackgroundColor(nsIPresContext* aPresContext, + static void PaintBackgroundColor(nsPresContext* aPresContext, nsIRenderingContext& aRenderingContext, nsIFrame* aForFrame, const nsRect& aBgClipArea, @@ -250,7 +250,7 @@ protected: const nsStylePadding& aPadding, PRBool aCanPaintNonWhite); - static void PaintRoundedBackground(nsIPresContext* aPresContext, + static void PaintRoundedBackground(nsPresContext* aPresContext, nsIRenderingContext& aRenderingContext, nsIFrame* aForFrame, const nsRect& aBorderArea, diff --git a/mozilla/layout/base/nsCaret.cpp b/mozilla/layout/base/nsCaret.cpp index 87fafeab1c6..02900399ba0 100644 --- a/mozilla/layout/base/nsCaret.cpp +++ b/mozilla/layout/base/nsCaret.cpp @@ -58,7 +58,7 @@ #include "nsIView.h" #include "nsIScrollableView.h" #include "nsIViewManager.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsILookAndFeel.h" #include "nsBlockFrame.h" #include "nsISelectionController.h" @@ -118,7 +118,7 @@ NS_IMETHODIMP nsCaret::Init(nsIPresShell *inPresShell) // get nsILookAndFeel from the pres context, which has one cached. nsILookAndFeel *lookAndFeel = nsnull; - nsCOMPtr presContext; + nsCOMPtr presContext; inPresShell->GetPresContext(getter_AddRefs(presContext)); if (presContext) lookAndFeel = presContext->LookAndFeel(); @@ -340,7 +340,7 @@ NS_IMETHODIMP nsCaret::GetCaretCoordinates(EViewCoordinates aRelativeToType, nsI return NS_ERROR_UNEXPECTED; // ramp up to make a rendering context for measuring text. // First, we get the pres context ... - nsCOMPtr presContext; + nsCOMPtr presContext; err = presShell->GetPresContext(getter_AddRefs(presContext)); if (NS_FAILED(err)) return err; @@ -562,7 +562,7 @@ PRBool nsCaret::SetupDrawingFrameAndOffset(nsIDOMNode* aNode, PRInt32 aOffset, n // NS_STYLE_DIRECTION_LTR : LTR or Default // NS_STYLE_DIRECTION_RTL // NS_STYLE_DIRECTION_INHERIT - nsCOMPtr presContext; + nsCOMPtr presContext; rv = presShell->GetPresContext(getter_AddRefs(presContext)); if (presContext && presContext->BidiEnabled()) @@ -761,7 +761,7 @@ void nsCaret::GetViewForRendering(nsIFrame *caretFrame, EViewCoordinates coordTy if (!presShell) return; - nsCOMPtr presContext; + nsCOMPtr presContext; presShell->GetPresContext(getter_AddRefs(presContext)); viewOffset.x = 0; @@ -953,7 +953,7 @@ void nsCaret::GetCaretRectAndInvert() nsCOMPtr presShell = do_QueryReferent(mPresShell); if (!presShell) return; - nsCOMPtr presContext; + nsCOMPtr presContext; if (NS_FAILED(presShell->GetPresContext(getter_AddRefs(presContext)))) return; diff --git a/mozilla/layout/base/nsDocumentViewer.cpp b/mozilla/layout/base/nsDocumentViewer.cpp index 31dcfe734fe..88279ed822b 100644 --- a/mozilla/layout/base/nsDocumentViewer.cpp +++ b/mozilla/layout/base/nsDocumentViewer.cpp @@ -50,7 +50,7 @@ #include "nsIDocumentViewerPrint.h" #include "nsIDocument.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIPresShell.h" #include "nsStyleSet.h" #include "nsIStyleSheet.h" @@ -308,7 +308,7 @@ class DocumentViewerImpl : public nsIDocumentViewer, friend class nsPrintEngine; public: - DocumentViewerImpl(nsIPresContext* aPresContext); + DocumentViewerImpl(nsPresContext* aPresContext); NS_DECL_AND_IMPL_ZEROING_OPERATOR_NEW @@ -322,8 +322,8 @@ public: NS_IMETHOD SetUAStyleSheet(nsIStyleSheet* aUAStyleSheet); NS_IMETHOD GetDocument(nsIDocument** aResult); NS_IMETHOD GetPresShell(nsIPresShell** aResult); - NS_IMETHOD GetPresContext(nsIPresContext** aResult); - NS_IMETHOD CreateDocumentViewerUsing(nsIPresContext* aPresContext, + NS_IMETHOD GetPresContext(nsPresContext** aResult); + NS_IMETHOD CreateDocumentViewerUsing(nsPresContext* aPresContext, nsIDocumentViewer** aResult); // nsIContentViewerEdit @@ -390,7 +390,7 @@ protected: nsCOMPtr mDocument; nsCOMPtr mWindow; // ??? should we really own it? nsCOMPtr mViewManager; - nsCOMPtr mPresContext; + nsCOMPtr mPresContext; nsCOMPtr mPresShell; nsCOMPtr mUAStyleSheet; @@ -495,7 +495,7 @@ void DocumentViewerImpl::PrepareToStartLoad() } // Note: operator new zeros our memory, so no need to init things to null. -DocumentViewerImpl::DocumentViewerImpl(nsIPresContext* aPresContext) +DocumentViewerImpl::DocumentViewerImpl(nsPresContext* aPresContext) : mPresContext(aPresContext), mHintCharsetSource(kCharsetUninitialized), mAllowPlugins(PR_TRUE), @@ -790,9 +790,9 @@ DocumentViewerImpl::InitInternal(nsIWidget* aParentWidget, if (aDoCreation) { if (aParentWidget && !mPresContext) { // Create presentation context - mPresContext = new nsIPresContext(GetIsCreatingPrintPreview() ? - nsIPresContext::eContext_PrintPreview : - nsIPresContext::eContext_Galley); + mPresContext = new nsPresContext(GetIsCreatingPrintPreview() ? + nsPresContext::eContext_PrintPreview : + nsPresContext::eContext_Galley); NS_ENSURE_TRUE(mPresContext, NS_ERROR_OUT_OF_MEMORY); nsresult rv = mPresContext->Init(aDeviceContext); @@ -1361,7 +1361,7 @@ DocumentViewerImpl::GetPresShell(nsIPresShell** aResult) } NS_IMETHODIMP -DocumentViewerImpl::GetPresContext(nsIPresContext** aResult) +DocumentViewerImpl::GetPresContext(nsPresContext** aResult) { NS_IF_ADDREF(*aResult = mPresContext); @@ -1490,7 +1490,7 @@ DocumentViewerImpl::Show(void) } NS_ASSERTION(!mPresContext, "Shouldn't have a prescontext if we have no shell!"); - mPresContext = new nsIPresContext(nsIPresContext::eContext_Galley); + mPresContext = new nsPresContext(nsPresContext::eContext_Galley); NS_ENSURE_TRUE(mPresContext, NS_ERROR_OUT_OF_MEMORY); rv = mPresContext->Init(mDeviceContext); @@ -1935,7 +1935,7 @@ nsresult DocumentViewerImpl::GetDocumentSelection(nsISelection **aSelection, } NS_IMETHODIMP -DocumentViewerImpl::CreateDocumentViewerUsing(nsIPresContext* aPresContext, +DocumentViewerImpl::CreateDocumentViewerUsing(nsPresContext* aPresContext, nsIDocumentViewer** aResult) { if (!mDocument) { @@ -2668,7 +2668,7 @@ NS_IMETHODIMP DocumentViewerImpl::SizeToContent() NS_ENSURE_SUCCESS(presShell->ResizeReflow(NS_UNCONSTRAINEDSIZE, NS_UNCONSTRAINEDSIZE), NS_ERROR_FAILURE); - nsCOMPtr presContext; + nsCOMPtr presContext; GetPresContext(getter_AddRefs(presContext)); NS_ENSURE_TRUE(presContext, NS_ERROR_FAILURE); diff --git a/mozilla/layout/base/nsFrameContentIterator.cpp b/mozilla/layout/base/nsFrameContentIterator.cpp index 7cffd26ab05..31e0f8c46bd 100644 --- a/mozilla/layout/base/nsFrameContentIterator.cpp +++ b/mozilla/layout/base/nsFrameContentIterator.cpp @@ -38,7 +38,7 @@ #include "nsCOMPtr.h" #include "nsIContentIterator.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIFrame.h" #include "nsIContent.h" #include "nsIEnumerator.h" @@ -47,7 +47,7 @@ class nsFrameContentIterator : public nsIContentIterator { public: - nsFrameContentIterator(nsIPresContext* aPresContext, nsIFrame* aFrame); + nsFrameContentIterator(nsPresContext* aPresContext, nsIFrame* aFrame); virtual ~nsFrameContentIterator(); // nsISupports @@ -67,13 +67,13 @@ public: virtual nsresult PositionAt(nsIContent* aCurNode); private: - nsCOMPtr mPresContext; + nsCOMPtr mPresContext; nsIFrame* mParentFrame; nsIFrame* mCurrentChild; PRBool mIsDone; }; -nsFrameContentIterator::nsFrameContentIterator(nsIPresContext* aPresContext, +nsFrameContentIterator::nsFrameContentIterator(nsPresContext* aPresContext, nsIFrame* aFrame) : mPresContext(aPresContext), mParentFrame(aFrame), mIsDone(PR_FALSE) { @@ -109,7 +109,7 @@ nsFrameContentIterator::First() static nsIFrame* -GetNextChildFrame(nsIPresContext* aPresContext, nsIFrame* aFrame) +GetNextChildFrame(nsPresContext* aPresContext, nsIFrame* aFrame) { NS_PRECONDITION(aFrame, "null pointer"); @@ -167,7 +167,7 @@ nsFrameContentIterator::Next() } static nsIFrame* -GetPrevChildFrame(nsIPresContext* aPresContext, nsIFrame* aFrame) +GetPrevChildFrame(nsPresContext* aPresContext, nsIFrame* aFrame) { NS_PRECONDITION(aFrame, "null pointer"); @@ -265,7 +265,7 @@ nsFrameContentIterator::PositionAt(nsIContent* aCurNode) } nsresult -NS_NewFrameContentIterator(nsIPresContext* aPresContext, +NS_NewFrameContentIterator(nsPresContext* aPresContext, nsIFrame* aFrame, nsIContentIterator** aIterator) { diff --git a/mozilla/layout/base/nsFrameManager.cpp b/mozilla/layout/base/nsFrameManager.cpp index be6dceeea6e..9fb4b14900e 100644 --- a/mozilla/layout/base/nsFrameManager.cpp +++ b/mozilla/layout/base/nsFrameManager.cpp @@ -45,7 +45,7 @@ * 04/20/2000 IBM Corp. OS/2 VisualAge build. */ #include "nscore.h" -#include "nsIPresContext.h" +#include "nsPresContext.h" #include "nsIPresShell.h" #include "nsStyleSet.h" #include "nsCSSFrameConstructor.h" @@ -289,11 +289,11 @@ struct nsFrameManagerBase::PropertyList { // Removes the property associated with the given frame, and destroys // the property value - NS_HIDDEN_(PRBool) RemovePropertyForFrame(nsIPresContext* aPresContext, + NS_HIDDEN_(PRBool) RemovePropertyForFrame(nsPresContext* aPresContext, const nsIFrame* aFrame); // Destroy all remaining properties (without removing them) - NS_HIDDEN_(void) Destroy(nsIPresContext* aPresContext); + NS_HIDDEN_(void) Destroy(nsPresContext* aPresContext); }; @@ -332,7 +332,7 @@ nsFrameManager::Destroy() { NS_ASSERTION(mPresShell, "Frame manager already shut down."); - nsCOMPtr presContext; + nsCOMPtr presContext; mPresShell->GetPresContext(getter_AddRefs(presContext)); // Destroy the frame hierarchy. Don't destroy the property lists until after @@ -425,7 +425,7 @@ nsFrameManager::GetPrimaryFrameFor(nsIContent* aContent) // very fast in the embedded hash table. // This would almost completely remove the lookup penalty for things // like