Closed
Bug 1406726
Opened 8 years ago
Closed 8 years ago
After pressing ENTER appeard new line but cursor dont nove to new line, only to start of line.
Categories
(Core :: DOM: Editor, defect, P3)
Core
DOM: Editor
Tracking
()
RESOLVED
FIXED
mozilla60
| Tracking | Status | |
|---|---|---|
| firefox-esr52 | --- | unaffected |
| firefox58 | --- | wontfix |
| firefox59 | --- | wontfix |
| firefox60 | --- | fixed |
People
(Reporter: skala.vaclav96, Assigned: masayuki)
References
Details
(Keywords: regression)
Attachments
(1 file)
No description provided.
| Reporter | ||
Comment 1•8 years ago
|
||
https://hg.mozilla.org/integration/mozilla-inbound/pushloghtml?fromchange=7d39d921ab4241c3dc9dd9013ee5d3c950c084fa&tochange=21eac8bd06451064524aaafbfa6a4ec5c2bd8130
Happens on email.cz when answer on mail. I can give test account.
Comment 2•8 years ago
|
||
Hi Skala
Can you please tell me steps to reproduce this issue? Which versions of FF are affected? On which OS you reproduce this issue?
Flags: needinfo?(skala.vaclav96)
OS: Unspecified → Linux
Hardware: Unspecified → x86_64
| Reporter | ||
Comment 3•8 years ago
|
||
Hi
its appeard on both Windows and Linux on x86_64 architecture in nightly
with mozregression i detect that it affect all builds after
https://hg.mozilla.org/integration/mozilla-inbound/pushloghtml?fromchange=7d39d921ab4241c3dc9dd9013ee5d3c950c084fa&tochange=21eac8bd06451064524aaafbfa6a4ec5c2bd8130
I sent you a login to the test account on the your mail. To reproduce this bug log in on email.cz, open first message and press "odpovědět" (reply), then write some text and press ENTER, you will see that new line appeard but cursor dont move down. This bug is only in nightly, on firefox and other browsers it work fine.
Flags: needinfo?(skala.vaclav96)
Comment 4•8 years ago
|
||
Hi Skala,
Thanks for your help.
I verify this issue using Nightly 58.0a1 on Windows 10 x64, with Build ID 20171009220104
Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:58.0) Gecko/20100101 Firefox/58.0
To reproduce this issue you need to have an account and to be logged in.
Status: UNCONFIRMED → NEW
status-firefox58:
--- → affected
Component: Untriaged → Editor
Ever confirmed: true
Comment 5•8 years ago
|
||
(In reply to Valentina Claudia Ona from comment #4)
> Hi Skala,
> Thanks for your help.
> I verify this issue using Nightly 58.0a1 on Windows 10 x64, with Build ID
> 20171009220104
Does "verify" mean whether confirmed this bug or fixed by 58? If this is regression by 1297414, it can change behavior by editor.use_div_for_default_newlines. (beta and release channel is false, and nightly is true).
Blocks: 1297414
Flags: needinfo?(valentina.ona)
Comment 7•8 years ago
|
||
OK, although his is regression, but I think that this won't occur on beta and release... Even if this occur with editor.use_div_for_default_newlines=false on Nightly, I will raise priority. Do anyone this it?
Priority: -- → P3
| Assignee | ||
Comment 8•8 years ago
|
||
Hi, could you give a test account to fix this bug? I think that we should enable the new behavior in default setting for all users starting from Firefox 60 (next ESR). So, we need to fix this bug ASAP.
Flags: needinfo?(skala.vaclav96)
| Reporter | ||
Comment 9•8 years ago
|
||
Hi, I sent you a login to the test account on the your mail. To reproduce this bug log in on email.cz, open first message and press "odpovědět" (reply), then write some text and press ENTER.
But there is one complication. After this commit
(https://hg.mozilla.org/integration/autoland/json-pushes?changeset=bda35e3d8ce4e6fbdc416b427f2200110ce52ff4&full=1
MozReview-Commit-ID: LF2MwASuXzZ )
behavior changed, now pressing ENTER add 2 new lines instead of 1.
Flags: needinfo?(skala.vaclav96)
| Assignee | ||
Comment 10•8 years ago
|
||
Thank you.
Minimized testcase is here: https://jsfiddle.net/d_toybox/c9d308b7/
When you type Enter, HTMLEditRules::WillInsertBreak() calls HTMLEditRules::ApplyBlockStyle() via HTMLEditRules::MakeBasicBlock() to wrap existing nodes with <div> and create new <div> since the nearest ancestor block is editing host. When HTMLEditRules::ApplyBlockStyle() wraps existing nodes with <div>, HTMLEditRules::ApplyBlockStyle() sets its mNewBlock to the last <div> created by the method. Finally, HTMLEditRules::AfterEditInner() moves selection in the last new block which is mNewNode. However, from the point of view of users, it doesn't make sense to move caret into the last div if it just wraps existing node (in this case, it's the <button>).
Assignee: nobody → masayuki
Status: NEW → ASSIGNED
OS: Linux → All
Hardware: x86_64 → All
Version: unspecified → Trunk
| Assignee | ||
Comment 11•8 years ago
|
||
| Assignee | ||
Comment 12•8 years ago
|
||
| Assignee | ||
Comment 13•8 years ago
|
||
| Comment hidden (mozreview-request) |
Comment 15•8 years ago
|
||
| mozreview-review | ||
Comment on attachment 8950847 [details]
Bug 1406726 - HTMLEditRules::WillInsertBreak() should reset mNewNode with caret position
https://reviewboard.mozilla.org/r/220076/#review226350
Good, but it might be weird when using 4 bool paramers. After fixing this, we might consider good way except to using a lot of bool parameter.
Attachment #8950847 -
Flags: review?(m_kato) → review+
Comment 16•8 years ago
|
||
Pushed by masayuki@d-toybox.com:
https://hg.mozilla.org/integration/autoland/rev/ac9440a7256c
HTMLEditRules::WillInsertBreak() should reset mNewNode with caret position r=m_kato
Comment 17•8 years ago
|
||
| bugherder | ||
Status: ASSIGNED → RESOLVED
Closed: 8 years ago
status-firefox60:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla60
Updated•8 years ago
|
Updated•7 years ago
|
status-firefox-esr52:
--- → unaffected
You need to log in
before you can comment on or make changes to this bug.
Description
•