RESOLVED FIXED 76183
Web Inspector: make HTML editing preserve node identity when node nesting level changes.
https://bugs.webkit.org/show_bug.cgi?id=76183
Summary Web Inspector: make HTML editing preserve node identity when node nesting lev...
Pavel Feldman
Reported 2012-01-12 08:51:28 PST
As of today, editing <p>Foo</p> to become <div><p>Foo</p></div> re-creates <p>Foo</p>, hence all JavaScript wrappers pointing to <p> become invalid. It should move it into the new <div> instead, while preserving the node identity and wrapper references.
Attachments
Patch (34.56 KB, patch)
2012-01-12 08:54 PST, Pavel Feldman
yurys: review+
Pavel Feldman
Comment 1 2012-01-12 08:54:41 PST
Yury Semikhatsky
Comment 2 2012-01-12 09:42:14 PST
Comment on attachment 122253 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=122253&action=review > Source/WebCore/inspector/DOMEditor.cpp:402 > + Deque<Digest*> queue; Why do you prefer BFS over DFS here?
Pavel Feldman
Comment 3 2012-01-13 05:25:11 PST
Csaba Osztrogonác
Comment 4 2012-01-13 05:39:31 PST
(In reply to comment #3) > Committed r104920: <http://trac.webkit.org/changeset/104920> Reopen, because it broke the 32 bit builds: cc1plus: warnings being treated as errors /ramdisk/qt-linux-32-release-webkit2/build/Source/WebCore/inspector/DOMEditor.cpp: In member function ‘void WebCore::DOMEditor::dumpMap(const WTF::String&, const WTF::Vector<std::pair<WebCore::DOMEditor::Digest*, unsigned int>, 0u>&, const WTF::Vector<WTF::OwnPtr<WebCore::DOMEditor::Digest>, 0u>&)’: /ramdisk/qt-linux-32-release-webkit2/build/Source/WebCore/inspector/DOMEditor.cpp:430: error: format ‘%ld’ expects type ‘long int’, but argument 4 has type ‘size_t’ /ramdisk/qt-linux-32-release-webkit2/build/Source/WebCore/inspector/DOMEditor.cpp:430: error: format ‘%ld’ expects type ‘long int’, but argument 6 has type ‘unsigned int’ Could you fix it?
Csaba Osztrogonác
Comment 5 2012-01-13 06:02:58 PST
Antonio Gomes
Comment 6 2012-02-25 13:07:18 PST
(In reply to comment #5) > Buildfix landed in http://trac.webkit.org/changeset/104923 can be re-closed?
Note You need to log in before you can comment on or make changes to this bug.