Closed Bug 1159101 Opened 10 years ago Closed 10 years ago

Override GetWritingMode method in nsTable{Col,Row}{,Group}Frame

Categories

(Core :: Layout: Tables, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla40
Tracking Status
firefox40 --- fixed

People

(Reporter: xidorn, Assigned: xidorn)

References

Details

Attachments

(6 files, 1 obsolete file)

Since writing-mode is not applied to those frames, they should override GetWritingMode() to return the writing-mode of the table frame they belong to.
Attached patch patch (deleted) — Splinter Review
Attachment #8598425 - Flags: review?(roc)
Comment on attachment 8598425 [details] [diff] [review] patch Review of attachment 8598425 [details] [diff] [review]: ----------------------------------------------------------------- ::: layout/tables/nsTableColFrame.h @@ +73,5 @@ > virtual nsSplittableType GetSplittableType() const override; > > + virtual mozilla::WritingMode GetWritingMode() const override > + { > + nsIFrame* grandparent = GetParent()->GetParent(); nsTableFrame::GetTableFrame(this) ::: layout/tables/nsTableColGroupFrame.h @@ +115,5 @@ > virtual nsIAtom* GetType() const override; > > + virtual mozilla::WritingMode GetWritingMode() const override > + { > + nsIFrame* parent = GetParent(); nsTableFrame::GetTableFrame(this) ::: layout/tables/nsTableRowFrame.h @@ +102,5 @@ > + > + virtual mozilla::WritingMode GetWritingMode() const override > + { > + nsIFrame* grandparent = GetParent()->GetParent(); > + MOZ_ASSERT(grandparent->GetType() == nsGkAtoms::tableFrame); nsTableFrame::GetTableFrame(this) ::: layout/tables/nsTableRowGroupFrame.h @@ +120,5 @@ > > + virtual mozilla::WritingMode GetWritingMode() const override > + { > + nsIFrame* parent = GetParent(); > + MOZ_ASSERT(parent->GetType() == nsGkAtoms::tableFrame); nsTableFrame::GetTableFrame(this)
Attachment #8598425 - Flags: review?(roc) → review+
Attached file MozReview Request: bz://1159101/xidorn (obsolete) (deleted) —
/r/7815 - Bug 1159101 part 1 - Alter dependencies among headers of table struct frames. /r/7817 - Bug 1159101 part 2 - Add GetTableFrame() for table inner frames. /r/7819 - Bug 1159101 part 3 - Replace most of nsTableFrame::GetTableFrame() usage with new GetTableFrame() methods. /r/7821 - Bug 1159101 part 4 - Override GetWritingMode() in nsTable{{Col,Row}{,Group},Cell}Frame. Pull down these commits: hg pull -r cc604a67a3e0955886909d5f895392a502c9bbc1 https://reviewboard-hg.mozilla.org/gecko/
Attachment #8599022 - Flags: review?(roc)
https://reviewboard.mozilla.org/r/7815/#review6607 ::: layout/tables/nsTableFrame.h:102 (Diff revision 1) > + eColGroupContent = 0, // there is real col group content associated Remove trailing whitespace
Comment on attachment 8599022 [details] MozReview Request: bz://1159101/xidorn /r/7815 - Bug 1159101 part 1 - Alter dependencies among headers of table struct frames. r=roc /r/7817 - Bug 1159101 part 2 - Add GetTableFrame() for table inner frames. r=roc /r/7819 - Bug 1159101 part 3 - Replace most of nsTableFrame::GetTableFrame() usage with new GetTableFrame() methods. r=roc /r/7821 - Bug 1159101 part 4 - Override GetWritingMode() in nsTable{{Col,Row}{,Group},Cell}Frame. r=roc Pull down these commits: hg pull -r a94df6c7b2ab8de09813900e3911b762bec6b176 https://reviewboard-hg.mozilla.org/gecko/
Comment on attachment 8599022 [details] MozReview Request: bz://1159101/xidorn /r/7815 - Bug 1159101 part 1 - Alter dependencies among headers of table struct frames. r=roc /r/7817 - Bug 1159101 part 2 - Add GetTableFrame() for table inner frames. r=roc /r/7819 - Bug 1159101 part 3 - Replace most of nsTableFrame::GetTableFrame() usage with new GetTableFrame() methods. r=roc /r/7821 - Bug 1159101 part 4 - Override GetWritingMode() in nsTable{{Col,Row}{,Group},Cell}Frame. Pull down these commits: hg pull -r ed8cc08fb99c8baeae5277eed2b7b5727914861c https://reviewboard-hg.mozilla.org/gecko/
I changed one line in part 4, could you review that?
Flags: needinfo?(roc)
Attachment #8599699 - Flags: review?(roc)
Comment on attachment 8599699 [details] [diff] [review] patch 5 - fix table cell frame init Review of attachment 8599699 [details] [diff] [review]: ----------------------------------------------------------------- ::: layout/base/nsCSSFrameConstructor.cpp @@ +8694,2 @@ > nsTableCellFrame* cellFrame = > + NS_NewTableCellFrame(shell, styleContext, tableFrame); This isn't the right table frame. Get it from aParentFrame.
Attachment #8599699 - Flags: review?(roc) → review+
Attachment #8599022 - Flags: review?(roc)
Attachment #8599022 - Attachment is obsolete: true
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: