Closed
Bug 559261
Opened 14 years ago
Closed 14 years ago
Midas Demo not preserving line breaks and indentation in HTML Source view
Categories
(www.mozilla.org :: General, defect)
www.mozilla.org
General
Tracking
(Not tracked)
VERIFIED
FIXED
People
(Reporter: BijuMailList, Assigned: BijuMailList)
Details
Attachments
(2 files)
14.18 KB,
text/html
|
Details | |
1.57 KB,
patch
|
ehsan.akhgari
:
review+
|
Details | Diff | Splinter Review |
In "View HTML Source" mode if you enter new lines and spaces, it wont be preserved when next time you come to source view. new lines are gone an spaces for indentation will be replaced with Steps:- 1. go to http://www.mozilla.org/editor/midasdemo/index.html 2. click to check "View HTML Source" 3. Enter following HTML <ol> <li>level 1</li> <ol> <li>level 1.1</li> <ol> <li>level 1.1.1</li> <li>level 1.1.2</li> </ol> <li>level 1.2</li> </ol> <li>level 2</li> <li>level 3</li> </ol> 4. click to uncheck "View HTML Source" 5. click again to check "View HTML Source" result:- you lost all formatting, ie new lines and indentations This can be fixed by code change in function "viewsource(source)" See attached MidasDemo.html
Updated•14 years ago
|
Component: www.mozilla.com → www.mozilla.org
QA Contact: www-mozilla-com → www-mozilla-org
Comment 1•14 years ago
|
||
Is this a regression? If so, from when?
Updated•14 years ago
|
Summary: Midas Demo not preserving line brakes and indentation in HTML Source view → Midas Demo not preserving line breaks and indentation in HTML Source view
Comment 2•14 years ago
|
||
Probably a duplicate from bug 596455
Comment 3•14 years ago
|
||
Actually, loosing new lines might be related to bug 596455 but I do not see how indentation could be related...
(In reply to comment #2) > Probably a duplicate from bug 596455 From you test case at bug 596455, this is not dupe Here the problem is var divnode = document.createElement('div'); var htmlrange = document.body.ownerDocument.createRange(); divnode.innerHTML = "aaaa<br>bbbb<br>cccc"; htmlrange.selectNodeContents(divnode); alert(htmlrange.toString()); gives "aaaabbbbcccc" Per bz (bug 596455 Comment 13) it is right behaviour. And issue with indentation is because of non-preformatted text collapse space while displaying. (In reply to comment #1) > Is this a regression? If so, from when? I see same issue at google doc in Edit HTML View, since its introduction till the feature removed. test in Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.1b2pre) Gecko/20081106 SeaMonkey/2.0a2pre I see same problem So I dont think it is a regression just that nobody have tested that way I think.
Comment 5•14 years ago
|
||
I think this is INVALID then, right?
Status: NEW → RESOLVED
Closed: 14 years ago
Resolution: --- → INVALID
Comment 6•14 years ago
|
||
I would prefer to mark it fixed by bug 596455. Biju, it could be nice if you can confirm that is fixed with the latest nightly.
Resolution: INVALID → FIXED
retested on Mozilla/5.0 (Windows NT 6.0; rv:2.0b7pre) Gecko/20100921 Firefox/4.0b7pre bug 559261 FAIL bug 596455 PASS (In reply to comment #5) > I think this is INVALID then, right? NO.... This bug is against Product: Websites Component: www.mozilla.org I have already submitted FIX for this issue, ie attachment 438938 [details] I dont know how/(not have resource) to make patch Can you assign to somebody who have time to do so...
Comment 8•14 years ago
|
||
Oh, it wasn't clear. This bug has nothing to do with bug 596455 and that's not a regression. Pascal, do you know who should be pinged for this bug (it's a mozilla.org page)?
Comment 9•14 years ago
|
||
The pages in the Editor section are owned by Ehsan now, I believe.
Updated•14 years ago
|
Attachment #438938 -
Attachment mime type: text/html → text/plain
Updated•14 years ago
|
Attachment #438938 -
Attachment mime type: text/plain → text/html
Comment 10•14 years ago
|
||
Attachment #477550 -
Flags: review+
Comment 11•14 years ago
|
||
Fixed in r74817. David, do you know how can I update the code on mozilla.org with this revision?
Status: REOPENED → RESOLVED
Closed: 14 years ago → 14 years ago
Resolution: --- → FIXED
Comment 12•14 years ago
|
||
Changes to trunk go straight to the live site after 10 minutes or so, so you should be all set with that commit.
Comment 13•14 years ago
|
||
Indeed they're already live on mozilla.org. Thanks a lot, Biju, for the patch!
Assignee: nobody → BijuMailList
Status: RESOLVED → VERIFIED
Assignee | ||
Comment 14•14 years ago
|
||
Thanks... Its working...
Updated•12 years ago
|
Component: www.mozilla.org → General
Product: Websites → www.mozilla.org
You need to log in
before you can comment on or make changes to this bug.
Description
•