Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(42)

Side by Side Diff: third_party/WebKit/Source/core/editing/commands/InsertIntoTextNodeCommand.cpp

Issue 2615953003: Rename IGNORE_EXCEPTION to IGNORE_EXCEPTION_FOR_TESTING (Closed)
Patch Set: temp Created 3 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2005, 2008 Apple Inc. All rights reserved. 2 * Copyright (C) 2005, 2008 Apple 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 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 1. Redistributions of source code must retain the above copyright 7 * 1. Redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer. 8 * notice, this list of conditions and the following disclaimer.
9 * 2. Redistributions in binary form must reproduce the above copyright 9 * 2. Redistributions in binary form must reproduce the above copyright
10 * notice, this list of conditions and the following disclaimer in the 10 * notice, this list of conditions and the following disclaimer in the
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after
55 if (!hasEditableStyle(*m_node)) 55 if (!hasEditableStyle(*m_node))
56 return; 56 return;
57 57
58 if (passwordEchoEnabled) { 58 if (passwordEchoEnabled) {
59 LayoutText* layoutText = m_node->layoutObject(); 59 LayoutText* layoutText = m_node->layoutObject();
60 if (layoutText && layoutText->isSecure()) 60 if (layoutText && layoutText->isSecure())
61 layoutText->momentarilyRevealLastTypedCharacter(m_offset + 61 layoutText->momentarilyRevealLastTypedCharacter(m_offset +
62 m_text.length() - 1); 62 m_text.length() - 1);
63 } 63 }
64 64
65 m_node->insertData(m_offset, m_text, IGNORE_EXCEPTION); 65 m_node->insertData(m_offset, m_text, IGNORE_EXCEPTION_FOR_TESTING);
66 document().updateStyleAndLayout(); 66 document().updateStyleAndLayout();
67 } 67 }
68 68
69 void InsertIntoTextNodeCommand::doUnapply() { 69 void InsertIntoTextNodeCommand::doUnapply() {
70 if (!hasEditableStyle(*m_node)) 70 if (!hasEditableStyle(*m_node))
71 return; 71 return;
72 72
73 m_node->deleteData(m_offset, m_text.length(), IGNORE_EXCEPTION); 73 m_node->deleteData(m_offset, m_text.length(), IGNORE_EXCEPTION_FOR_TESTING);
74 document().updateStyleAndLayout(); 74 document().updateStyleAndLayout();
75 } 75 }
76 76
77 DEFINE_TRACE(InsertIntoTextNodeCommand) { 77 DEFINE_TRACE(InsertIntoTextNodeCommand) {
78 visitor->trace(m_node); 78 visitor->trace(m_node);
79 SimpleEditCommand::trace(visitor); 79 SimpleEditCommand::trace(visitor);
80 } 80 }
81 81
82 } // namespace blink 82 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698