[Webkit-unassigned] [Bug 23389] Clean up ApplyStyleCommand and deploy a bit more PassRefPtr

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Fri Jan 16 14:43:22 PST 2009


https://bugs.webkit.org/show_bug.cgi?id=23389


justin.garcia at apple.com changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
  Attachment #26807|review?                     |review+
               Flag|                            |




------- Comment #2 from justin.garcia at apple.com  2009-01-16 14:43 PDT -------
(From update of attachment 26807)
-    if (styleChange.applyBold()) {
-        RefPtr<Element> boldElement =
document()->createElementNS(xhtmlNamespaceURI, "b", ec);
-        ASSERT(ec == 0);
-        insertNodeBefore(boldElement.get(), startNode);
-        surroundNodeRangeWithElement(startNode, endNode, boldElement.get());
-    }
+    if (styleChange.applyBold())
+        surroundNodeRangeWithElement(startNode, endNode,
document()->createElementNS(xhtmlNamespaceURI, "b", ec));

You no longer ASSERT that createElementNS completed without error, I suppose if
it encounters an error it will return 0 and that will be caught by
surroundNodeRangeWithElement, ya?

r=me


-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.



More information about the webkit-unassigned mailing list