Bug 1264837 Part 13 - Remove nsRubyTextFrameSuper.
MozReview-Commit-ID: ILOZIBDmeIA
--- a/layout/generic/nsRubyTextFrame.cpp
+++ b/layout/generic/nsRubyTextFrame.cpp
@@ -17,17 +17,17 @@ using namespace mozilla;
//----------------------------------------------------------------------
// Frame class boilerplate
// =======================
NS_QUERYFRAME_HEAD(nsRubyTextFrame)
NS_QUERYFRAME_ENTRY(nsRubyTextFrame)
-NS_QUERYFRAME_TAIL_INHERITING(nsRubyTextFrameSuper)
+NS_QUERYFRAME_TAIL_INHERITING(nsRubyContentFrame)
NS_IMPL_FRAMEARENA_HELPERS(nsRubyTextFrame)
nsContainerFrame*
NS_NewRubyTextFrame(nsIPresShell* aPresShell,
nsStyleContext* aContext)
{
return new (aPresShell) nsRubyTextFrame(aContext);
@@ -65,33 +65,32 @@ nsRubyTextFrame::GetFrameName(nsAString&
nsRubyTextFrame::BuildDisplayList(nsDisplayListBuilder* aBuilder,
const nsRect& aDirtyRect,
const nsDisplayListSet& aLists)
{
if (IsAutoHidden()) {
return;
}
- nsRubyTextFrameSuper::BuildDisplayList(aBuilder, aDirtyRect, aLists);
+ nsRubyContentFrame::BuildDisplayList(aBuilder, aDirtyRect, aLists);
}
/* virtual */ void
nsRubyTextFrame::Reflow(nsPresContext* aPresContext,
nsHTMLReflowMetrics& aDesiredSize,
const nsHTMLReflowState& aReflowState,
nsReflowStatus& aStatus)
{
// Even if we want to hide this frame, we have to reflow it first.
// If we leave it dirty, changes to its content will never be
// propagated to the ancestors, then it won't be displayed even if
// the content is no longer the same, until next reflow triggered by
// some other change. In general, we always reflow all the frames we
// created. There might be other problems if we don't do that.
- nsRubyTextFrameSuper::Reflow(aPresContext, aDesiredSize,
- aReflowState, aStatus);
+ nsRubyContentFrame::Reflow(aPresContext, aDesiredSize, aReflowState, aStatus);
if (IsAutoHidden()) {
// Reset the ISize. The BSize is not changed so that it won't
// affect vertical positioning in unexpected way.
WritingMode lineWM = aReflowState.mLineLayout->GetWritingMode();
aDesiredSize.ISize(lineWM) = 0;
aDesiredSize.SetOverflowAreasToDesiredBounds();
}
--- a/layout/generic/nsRubyTextFrame.h
+++ b/layout/generic/nsRubyTextFrame.h
@@ -6,26 +6,24 @@
/* rendering object for CSS "display: ruby-text" */
#ifndef nsRubyTextFrame_h___
#define nsRubyTextFrame_h___
#include "nsRubyContentFrame.h"
-typedef nsRubyContentFrame nsRubyTextFrameSuper;
-
/**
* Factory function.
* @return a newly allocated nsRubyTextFrame (infallible)
*/
nsContainerFrame* NS_NewRubyTextFrame(nsIPresShell* aPresShell,
nsStyleContext* aContext);
-class nsRubyTextFrame final : public nsRubyTextFrameSuper
+class nsRubyTextFrame final : public nsRubyContentFrame
{
public:
NS_DECL_FRAMEARENA_HELPERS
NS_DECL_QUERYFRAME_TARGET(nsRubyTextFrame)
NS_DECL_QUERYFRAME
// nsIFrame overrides
virtual nsIAtom* GetType() const override;
@@ -48,12 +46,12 @@ public:
{
return GetStateBits() & NS_RUBY_TEXT_FRAME_AUTOHIDE;
}
protected:
friend nsContainerFrame* NS_NewRubyTextFrame(nsIPresShell* aPresShell,
nsStyleContext* aContext);
explicit nsRubyTextFrame(nsStyleContext* aContext)
- : nsRubyTextFrameSuper(aContext) {}
+ : nsRubyContentFrame(aContext) {}
};
#endif /* nsRubyTextFrame_h___ */