Chromium Code Reviews| Index: Source/core/editing/AppendNodeCommand.cpp |
| diff --git a/Source/core/editing/AppendNodeCommand.cpp b/Source/core/editing/AppendNodeCommand.cpp |
| index 264b586bae3c8f439b306f5f0cc254e25237660b..433c33ed7391b99a395f223b76a2d0402b25ac9f 100644 |
| --- a/Source/core/editing/AppendNodeCommand.cpp |
| +++ b/Source/core/editing/AppendNodeCommand.cpp |
| @@ -27,7 +27,6 @@ |
| #include "core/editing/AppendNodeCommand.h" |
| #include "bindings/v8/ExceptionState.h" |
| -#include "core/accessibility/AXObjectCache.h" |
| #include "core/dom/Document.h" |
| namespace WebCore { |
| @@ -44,26 +43,12 @@ AppendNodeCommand::AppendNodeCommand(PassRefPtr<ContainerNode> parent, PassRefPt |
| ASSERT(m_parent->rendererIsEditable() || !m_parent->attached()); |
| } |
| -static void sendAXTextChangedIgnoringLineBreaks(Node* node, AXObjectCache::AXTextChange textChange) |
|
aboxhall
2013/08/07 15:58:10
Why don't we need to special case text changes any
dmazzoni
2013/08/07 16:23:53
We never used them in Chromium. In WebKit, it look
|
| -{ |
| - String nodeValue = node->nodeValue(); |
| - // Don't consider linebreaks in this command |
| - if (nodeValue == "\n") |
| - return; |
| - |
| - if (AXObjectCache* cache = node->document()->existingAXObjectCache()) |
| - cache->nodeTextChangeNotification(node, textChange, 0, nodeValue); |
| -} |
| - |
| void AppendNodeCommand::doApply() |
| { |
| if (!m_parent->rendererIsEditable() && m_parent->attached()) |
| return; |
| m_parent->appendChild(m_node.get(), IGNORE_EXCEPTION_STATE, AttachLazily); |
| - |
| - if (AXObjectCache::accessibilityEnabled()) |
| - sendAXTextChangedIgnoringLineBreaks(m_node.get(), AXObjectCache::AXTextInserted); |
| } |
| void AppendNodeCommand::doUnapply() |
| @@ -71,10 +56,6 @@ void AppendNodeCommand::doUnapply() |
| if (!m_parent->rendererIsEditable()) |
| return; |
| - // Need to notify this before actually deleting the text |
| - if (AXObjectCache::accessibilityEnabled()) |
| - sendAXTextChangedIgnoringLineBreaks(m_node.get(), AXObjectCache::AXTextDeleted); |
| - |
| m_node->remove(IGNORE_EXCEPTION_STATE); |
| } |