More nsIPresContext deCOMtamination (bug 229371). Removed GetBaseURL, rename GetMedium to Medium and inline it, remove virtual style resolution methods that forward to style set (callers will call style set methods directly). Removed PresContext parameter to StyleSet style resolution functions. r+sr=dbaron.

This commit is contained in:
bryner@brianryner.com
2004-01-28 00:18:22 +00:00
parent eedf54fc7a
commit 662d805035
55 changed files with 648 additions and 914 deletions

View File

@@ -71,6 +71,7 @@
#include "nsIServiceManager.h"
#include "nsIDOMHTMLButtonElement.h"
#include "nsIDOMHTMLInputElement.h"
#include "nsStyleSet.h"
#ifdef ACCESSIBILITY
#include "nsIAccessibilityService.h"
#endif
@@ -137,14 +138,15 @@ nsHTMLButtonControlFrame::Init(nsIPresContext* aPresContext,
}
nsIFrame* areaFrame;
NS_NewAreaFrame(aPresContext->PresShell(), &areaFrame, flags);
nsIPresShell *shell = aPresContext->PresShell();
NS_NewAreaFrame(shell, &areaFrame, flags);
mFrames.SetFrames(areaFrame);
// Resolve style and initialize the frame
nsRefPtr<nsStyleContext> styleContext;
styleContext = aPresContext->ResolvePseudoStyleContextFor(mContent,
nsCSSAnonBoxes::buttonContent,
mStyleContext);
styleContext = shell->StyleSet()->ResolvePseudoStyleFor(mContent,
nsCSSAnonBoxes::buttonContent,
mStyleContext);
mFrames.FirstChild()->Init(aPresContext, mContent, this, styleContext, nsnull);
return rv;