mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-12 04:45:45 +00:00
Make nsObjectFrame not be a container anymore. b=309532 r=biesi sr=bzbarsky
This commit is contained in:
parent
0e90005c2a
commit
86fc2334c3
@ -488,32 +488,7 @@ static NS_DEFINE_CID(kWidgetCID, NS_CHILD_CID);
|
||||
static NS_DEFINE_CID(kCAppShellCID, NS_APPSHELL_CID);
|
||||
static NS_DEFINE_CID(kCPluginManagerCID, NS_PLUGINMANAGER_CID);
|
||||
|
||||
PRIntn
|
||||
nsObjectFrame::GetSkipSides() const
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
// #define DO_DIRTY_INTERSECT 1 // enable dirty rect intersection during paint
|
||||
NS_IMETHODIMP
|
||||
nsObjectFrame::SetInitialChildList(nsPresContext* aPresContext,
|
||||
nsIAtom* aListName,
|
||||
nsIFrame* aChildList)
|
||||
{
|
||||
// we don't want to call this if it is already set (image)
|
||||
nsresult rv = NS_OK;
|
||||
if (mFrames.IsEmpty())
|
||||
rv = nsObjectFrameSuper::SetInitialChildList(aPresContext, aListName, aChildList);
|
||||
return rv;
|
||||
}
|
||||
|
||||
static void
|
||||
FirePluginNotFoundEvent(nsIContent *aTarget)
|
||||
{
|
||||
nsContentUtils::DispatchTrustedEvent(aTarget->GetDocument(), aTarget,
|
||||
NS_LITERAL_STRING("PluginNotFound"),
|
||||
PR_TRUE, PR_TRUE);
|
||||
}
|
||||
|
||||
NS_IMETHODIMP
|
||||
nsObjectFrame::Init(nsPresContext* aPresContext,
|
||||
@ -574,16 +549,6 @@ nsObjectFrame::CreateWidgetForView(nsIView* aView)
|
||||
return aView->CreateWidget(kWidgetCID, &initData);
|
||||
}
|
||||
|
||||
PRBool
|
||||
nsObjectFrame::IsLeaf() const
|
||||
{
|
||||
// We're actually a leaf. We inherit from nsContainerFrame for
|
||||
// convenience for now, but we construct our own kids and the frame
|
||||
// constructor shouldn't be messing with them.
|
||||
// XXXbz ideally, we wouldn't have this child frame thing at all.
|
||||
return PR_TRUE;
|
||||
}
|
||||
|
||||
nsresult
|
||||
nsObjectFrame::CreateWidget(nscoord aWidth,
|
||||
nscoord aHeight,
|
||||
|
@ -52,16 +52,13 @@ class nsIAccessible;
|
||||
|
||||
class nsPluginInstanceOwner;
|
||||
|
||||
#define nsObjectFrameSuper nsHTMLContainerFrame
|
||||
#define nsObjectFrameSuper nsFrame
|
||||
|
||||
class nsObjectFrame : public nsObjectFrameSuper, public nsIObjectFrame {
|
||||
public:
|
||||
// nsISupports
|
||||
NS_IMETHOD QueryInterface(const nsIID& aIID, void** aInstancePtr);
|
||||
|
||||
NS_IMETHOD SetInitialChildList(nsPresContext* aPresContext,
|
||||
nsIAtom* aListName,
|
||||
nsIFrame* aChildList);
|
||||
NS_IMETHOD Init(nsPresContext* aPresContext,
|
||||
nsIContent* aContent,
|
||||
nsIFrame* aParent,
|
||||
@ -89,8 +86,6 @@ public:
|
||||
virtual PRBool NeedsView() { return PR_TRUE; }
|
||||
virtual nsresult CreateWidgetForView(nsIView* aView);
|
||||
|
||||
virtual PRBool IsLeaf() const;
|
||||
|
||||
#ifdef DEBUG
|
||||
NS_IMETHOD GetFrameName(nsAString& aResult) const;
|
||||
#endif
|
||||
@ -130,11 +125,6 @@ public:
|
||||
|
||||
void FixUpURLS(const nsString &name, nsAString &value);
|
||||
|
||||
virtual PRBool IsContainingBlock() const
|
||||
{
|
||||
return PR_FALSE;
|
||||
}
|
||||
|
||||
protected:
|
||||
// nsISupports
|
||||
NS_IMETHOD_(nsrefcnt) AddRef(void);
|
||||
@ -142,8 +132,6 @@ protected:
|
||||
|
||||
virtual ~nsObjectFrame();
|
||||
|
||||
virtual PRIntn GetSkipSides() const;
|
||||
|
||||
// NOTE: This frame class does not inherit from |nsLeafFrame|, so
|
||||
// this is not a virtual method implementation.
|
||||
void GetDesiredSize(nsPresContext* aPresContext,
|
||||
|
Loading…
Reference in New Issue
Block a user