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

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

Issue 2636083003: Remove unused function UndoStep::belongsTo() (Closed)
Patch Set: 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, 2006, 2007, 2008 Apple Inc. All rights reserved. 2 * Copyright (C) 2005, 2006, 2007, 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 82 matching lines...) Expand 10 before | Expand all | Expand 10 after
93 const VisibleSelection& startingSelection, 93 const VisibleSelection& startingSelection,
94 const VisibleSelection& endingSelection, 94 const VisibleSelection& endingSelection,
95 InputEvent::InputType inputType) 95 InputEvent::InputType inputType)
96 : m_document(document), 96 : m_document(document),
97 m_startingSelection(startingSelection), 97 m_startingSelection(startingSelection),
98 m_endingSelection(endingSelection), 98 m_endingSelection(endingSelection),
99 m_startingRootEditableElement(startingSelection.rootEditableElement()), 99 m_startingRootEditableElement(startingSelection.rootEditableElement()),
100 m_endingRootEditableElement(endingSelection.rootEditableElement()), 100 m_endingRootEditableElement(endingSelection.rootEditableElement()),
101 m_inputType(inputType) {} 101 m_inputType(inputType) {}
102 102
103 bool EditCommandComposition::belongsTo(const LocalFrame& frame) const {
104 DCHECK(m_document);
105 return m_document->frame() == &frame;
106 }
107
108 void EditCommandComposition::unapply() { 103 void EditCommandComposition::unapply() {
109 DCHECK(m_document); 104 DCHECK(m_document);
110 LocalFrame* frame = m_document->frame(); 105 LocalFrame* frame = m_document->frame();
111 DCHECK(frame); 106 DCHECK(frame);
112 107
113 // Changes to the document may have been made since the last editing operation 108 // Changes to the document may have been made since the last editing operation
114 // that require a layout, as in <rdar://problem/5658603>. Low level 109 // that require a layout, as in <rdar://problem/5658603>. Low level
115 // operations, like RemoveNodeCommand, don't require a layout because the high 110 // operations, like RemoveNodeCommand, don't require a layout because the high
116 // level operations that use them perform one if one is necessary (like for 111 // level operations that use them perform one if one is necessary (like for
117 // the creation of VisiblePositions). 112 // the creation of VisiblePositions).
(...skipping 1912 matching lines...) Expand 10 before | Expand all | Expand 10 after
2030 return node; 2025 return node;
2031 } 2026 }
2032 2027
2033 DEFINE_TRACE(CompositeEditCommand) { 2028 DEFINE_TRACE(CompositeEditCommand) {
2034 visitor->trace(m_commands); 2029 visitor->trace(m_commands);
2035 visitor->trace(m_composition); 2030 visitor->trace(m_composition);
2036 EditCommand::trace(visitor); 2031 EditCommand::trace(visitor);
2037 } 2032 }
2038 2033
2039 } // namespace blink 2034 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698