| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2012 Google Inc. All rights reserved. | 2 * Copyright (C) 2012 Google Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions are | 5 * modification, are permitted provided that the following conditions are |
| 6 * met: | 6 * met: |
| 7 * | 7 * |
| 8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
| 9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
| 10 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
| (...skipping 352 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 363 return m_history->perform(adoptPtr(new InsertBeforeAction(parentNode, node,
anchorNode)), exceptionState); | 363 return m_history->perform(adoptPtr(new InsertBeforeAction(parentNode, node,
anchorNode)), exceptionState); |
| 364 } | 364 } |
| 365 | 365 |
| 366 bool DOMEditor::removeChild(Node* parentNode, Node* node, ExceptionState& except
ionState) | 366 bool DOMEditor::removeChild(Node* parentNode, Node* node, ExceptionState& except
ionState) |
| 367 { | 367 { |
| 368 return m_history->perform(adoptPtr(new RemoveChildAction(parentNode, node)),
exceptionState); | 368 return m_history->perform(adoptPtr(new RemoveChildAction(parentNode, node)),
exceptionState); |
| 369 } | 369 } |
| 370 | 370 |
| 371 bool DOMEditor::setAttribute(Element* element, const String& name, const String&
value, ExceptionState& exceptionState) | 371 bool DOMEditor::setAttribute(Element* element, const String& name, const String&
value, ExceptionState& exceptionState) |
| 372 { | 372 { |
| 373 return m_history->perform(adoptPtr(new SetAttributeAction(element, name, val
ue)), exceptionState); | 373 return m_history->perform(adoptPtr(new SetAttributeAction(element, AtomicStr
ing(name), AtomicString(value))), exceptionState); |
| 374 } | 374 } |
| 375 | 375 |
| 376 bool DOMEditor::removeAttribute(Element* element, const String& name, ExceptionS
tate& exceptionState) | 376 bool DOMEditor::removeAttribute(Element* element, const String& name, ExceptionS
tate& exceptionState) |
| 377 { | 377 { |
| 378 return m_history->perform(adoptPtr(new RemoveAttributeAction(element, name))
, exceptionState); | 378 return m_history->perform(adoptPtr(new RemoveAttributeAction(element, Atomic
String(name))), exceptionState); |
| 379 } | 379 } |
| 380 | 380 |
| 381 bool DOMEditor::setOuterHTML(Node* node, const String& html, Node** newNode, Exc
eptionState& exceptionState) | 381 bool DOMEditor::setOuterHTML(Node* node, const String& html, Node** newNode, Exc
eptionState& exceptionState) |
| 382 { | 382 { |
| 383 OwnPtr<SetOuterHTMLAction> action = adoptPtr(new SetOuterHTMLAction(node, ht
ml)); | 383 OwnPtr<SetOuterHTMLAction> action = adoptPtr(new SetOuterHTMLAction(node, ht
ml)); |
| 384 SetOuterHTMLAction* rawAction = action.get(); | 384 SetOuterHTMLAction* rawAction = action.get(); |
| 385 bool result = m_history->perform(action.release(), exceptionState); | 385 bool result = m_history->perform(action.release(), exceptionState); |
| 386 if (result) | 386 if (result) |
| 387 *newNode = rawAction->newNode(); | 387 *newNode = rawAction->newNode(); |
| 388 return result; | 388 return result; |
| (...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 452 bool DOMEditor::replaceWholeText(Text* textNode, const String& text, ErrorString
* errorString) | 452 bool DOMEditor::replaceWholeText(Text* textNode, const String& text, ErrorString
* errorString) |
| 453 { | 453 { |
| 454 TrackExceptionState exceptionState; | 454 TrackExceptionState exceptionState; |
| 455 bool result = replaceWholeText(textNode, text, exceptionState); | 455 bool result = replaceWholeText(textNode, text, exceptionState); |
| 456 populateErrorString(exceptionState, errorString); | 456 populateErrorString(exceptionState, errorString); |
| 457 return result; | 457 return result; |
| 458 } | 458 } |
| 459 | 459 |
| 460 } // namespace WebCore | 460 } // namespace WebCore |
| 461 | 461 |
| OLD | NEW |