Clean up nsHTMLEditRules::GetHighestInlineParent, CheckInterlinePosition, InsertMozBRIfNeeded, etc.

RESOLVED FIXED in Firefox 49

Status

()

--
enhancement
RESOLVED FIXED
4 years ago
3 years ago

People

(Reporter: ayg, Assigned: ayg)

Tracking

unspecified
mozilla49
Points:
---
Bug Flags:
in-testsuite -

Firefox Tracking Flags

(firefox49 fixed)

Details

Attachments

(13 attachments, 14 obsolete attachments)

4.63 KB, patch
Details | Diff | Splinter Review
5.36 KB, patch
Details | Diff | Splinter Review
4.41 KB, patch
Details | Diff | Splinter Review
7.69 KB, patch
Details | Diff | Splinter Review
5.33 KB, patch
Details | Diff | Splinter Review
21.06 KB, patch
Details | Diff | Splinter Review
8.67 KB, patch
Details | Diff | Splinter Review
69.10 KB, patch
Details | Diff | Splinter Review
8.22 KB, patch
Details | Diff | Splinter Review
1.67 KB, patch
Details | Diff | Splinter Review
21.42 KB, patch
Details | Diff | Splinter Review
12.25 KB, patch
Details | Diff | Splinter Review
8.48 KB, patch
Details | Diff | Splinter Review
Comment hidden (empty)
Created attachment 8644357 [details] [diff] [review]
Part 1 -- Clean up nsHTMLEditRules::GetHighestInlineParent
Attachment #8644357 - Flags: review?(ehsan)
Created attachment 8644359 [details] [diff] [review]
Part 2 -- Clean up nsHTMLEditRules::CheckInterlinePosition
Attachment #8644359 - Flags: review?(ehsan)
Created attachment 8644360 [details] [diff] [review]
Part 3 -- Clean up nsHTMLEditRules::InsertMozBRIfNeeded
Attachment #8644360 - Flags: review?(ehsan)
Created attachment 8644362 [details] [diff] [review]
Part 4 -- Clean up nsHTMLEditRules::AlignBlock
Attachment #8644362 - Flags: review?(ehsan)
Created attachment 8644371 [details] [diff] [review]
Part 5 -- Clean up nsHTMLEditRules::IsEmptyInline
Attachment #8644371 - Flags: review?(ehsan)
Created attachment 8644372 [details] [diff] [review]
Part 6 -- Clean up IsBlockNode/IsInlineNode in nsHTMLEditRules.cpp
Attachment #8644372 - Flags: review?(ehsan)
Created attachment 8644374 [details] [diff] [review]
Part 7 -- Clean up nsHTMLEditRules::CheckForInvisibleBR
Attachment #8644374 - Flags: review?(ehsan)
Created attachment 8644375 [details] [diff] [review]
Part 8 -- Typedefs in headers for readability
Attachment #8644375 - Flags: review?(ehsan)
Created attachment 8644376 [details] [diff] [review]
Part 9 -- Remove old nsHTMLEditRules::ConvertListType variant
Attachment #8644376 - Flags: review?(ehsan)
Created attachment 8644377 [details] [diff] [review]
Part 10 -- More features for OwningNonNull
Attachment #8644377 - Flags: review?(nfroyd)
Created attachment 8644378 [details] [diff] [review]
Part 11 -- Clean up nsHTMLEditRules::WillOutdent
Attachment #8644378 - Flags: review?(ehsan)
Created attachment 8644379 [details] [diff] [review]
Part 12 -- Clean up nsHTMLEditRules::OutdentPartOfBlock
Attachment #8644379 - Flags: review?(ehsan)
Created attachment 8644380 [details] [diff] [review]
Part 13 -- Clean up nsHTMLEditRules::SplitBlock
Attachment #8644380 - Flags: review?(ehsan)
Attachment #8644377 - Flags: review?(nfroyd) → review+

Updated

3 years ago
Attachment #8644357 - Flags: review?(ehsan) → review+

Comment 15

3 years ago
Comment on attachment 8644359 [details] [diff] [review]
Part 2 -- Clean up nsHTMLEditRules::CheckInterlinePosition

Review of attachment 8644359 [details] [diff] [review]:
-----------------------------------------------------------------

::: editor/libeditor/nsHTMLEditRules.cpp
@@ +7177,3 @@
>    }
>  
> +  NS_ENSURE_TRUE(mHTMLEditor, );

NS_ENSURE_TRUE_VOID, as before.  Here and elsewhere in all other patches.
Attachment #8644359 - Flags: review?(ehsan) → review+

Updated

3 years ago
Attachment #8644360 - Flags: review?(ehsan) → review+

Comment 16

3 years ago
Comment on attachment 8644362 [details] [diff] [review]
Part 4 -- Clean up nsHTMLEditRules::AlignBlock

Review of attachment 8644362 [details] [diff] [review]:
-----------------------------------------------------------------

::: editor/libeditor/nsHTMLEditRules.cpp
@@ +8353,5 @@
> +  nsCOMPtr<nsIEditor> kungFuDeathGrip(mHTMLEditor);
> +
> +  nsresult res = RemoveAlignment(aElement.AsDOMNode(), aAlignType,
> +                                 aContentsOnly == ContentsOnly::yes ? true
> +                                                                    : false);

Just aContentsOnly == ContentsOnly::yes is enough.
Attachment #8644362 - Flags: review?(ehsan) → review+

Comment 17

3 years ago
Comment on attachment 8644371 [details] [diff] [review]
Part 5 -- Clean up nsHTMLEditRules::IsEmptyInline

Review of attachment 8644371 [details] [diff] [review]:
-----------------------------------------------------------------

::: editor/libeditor/nsHTMLEditRules.cpp
@@ +7658,5 @@
> +  NS_ENSURE_TRUE(mHTMLEditor, false);
> +  nsCOMPtr<nsIEditor> kungFuDeathGrip(mHTMLEditor);
> +
> +  if (IsInlineNode(aNode.AsDOMNode()) && mHTMLEditor->IsContainer(&aNode)) {
> +    bool isEmpty;

Please initialize to true.
Attachment #8644371 - Flags: review?(ehsan) → review+

Updated

3 years ago
Attachment #8644372 - Flags: review?(ehsan) → review+

Updated

3 years ago
Attachment #8644374 - Flags: review?(ehsan) → review+

Updated

3 years ago
Attachment #8644375 - Flags: review?(ehsan) → review+

Updated

3 years ago
Attachment #8644376 - Flags: review?(ehsan) → review+

Updated

3 years ago
Attachment #8644378 - Flags: review?(ehsan) → review+

Updated

3 years ago
Attachment #8644379 - Flags: review?(ehsan) → review+

Updated

3 years ago
Attachment #8644380 - Flags: review?(ehsan) → review+
Created attachment 8742780 [details] [diff] [review]
Part 1 updated -- Clean up nsHTMLEditRules::GetHighestInlineParent
Attachment #8644357 - Attachment is obsolete: true
Created attachment 8742785 [details] [diff] [review]
Part 2 updated
Attachment #8644359 - Attachment is obsolete: true
Created attachment 8742791 [details] [diff] [review]
0024-Bug-1191354-part-3-Clean-up-nsHTMLEditRules-InsertMo.patch
Attachment #8644360 - Attachment is obsolete: true
Created attachment 8742796 [details] [diff] [review]
0025-Bug-1191354-part-4-Clean-up-nsHTMLEditRules-AlignBlo.patch
Attachment #8644362 - Attachment is obsolete: true
Created attachment 8742802 [details] [diff] [review]
0026-Bug-1191354-part-5-Clean-up-nsHTMLEditRules-IsEmptyI.patch
Attachment #8644371 - Attachment is obsolete: true
Created attachment 8742826 [details] [diff] [review]
0026-Bug-1191354-part-5-Clean-up-nsHTMLEditRules-IsEmptyI.patch
Attachment #8742802 - Attachment is obsolete: true
Created attachment 8742827 [details] [diff] [review]
0027-Bug-1191354-part-6-Clean-up-IsBlockNode-IsInlineNode.patch
Created attachment 8742831 [details] [diff] [review]
0028-Bug-1191354-part-7-Clean-up-nsHTMLEditRules-CheckFor.patch
Attachment #8644372 - Attachment is obsolete: true
Attachment #8644374 - Attachment is obsolete: true
Created attachment 8742835 [details] [diff] [review]
0029-Bug-1191354-part-8-Typedefs-in-headers-for-readabili.patch
Attachment #8644375 - Attachment is obsolete: true
Created attachment 8742839 [details] [diff] [review]
0030-Bug-1191354-part-9-Remove-old-nsHTMLEditRules-Conver.patch
Attachment #8644376 - Attachment is obsolete: true
Created attachment 8742842 [details] [diff] [review]
0031-Bug-1191354-part-10-More-features-for-OwningNonNull-.patch
Created attachment 8742844 [details] [diff] [review]
0032-Bug-1191354-part-11-Clean-up-nsHTMLEditRules-WillOut.patch
Attachment #8644377 - Attachment is obsolete: true
Attachment #8644378 - Attachment is obsolete: true
Created attachment 8742846 [details] [diff] [review]
0033-Bug-1191354-part-12-Clean-up-nsHTMLEditRules-Outdent.patch
Attachment #8644379 - Attachment is obsolete: true
Created attachment 8742847 [details] [diff] [review]
0034-Bug-1191354-part-13-Clean-up-nsHTMLEditRules-SplitBl.patch
Attachment #8644380 - Attachment is obsolete: true
Checkin instructions at bug 1191356 comment 20.
Keywords: leave-open → checkin-needed
Keywords: checkin-needed
You need to log in before you can comment on or make changes to this bug.