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

Side by Side Diff: Source/core/editing/Editor.h

Issue 337473010: Move implementation of WebFrameImpl::executeCommand to Editor (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: 2014-06-30T10:05:35 Created 6 years, 5 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
« no previous file with comments | « no previous file | Source/core/editing/EditorCommand.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2006, 2007, 2008 Apple Inc. All rights reserved. 2 * Copyright (C) 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 137 matching lines...) Expand 10 before | Expand all | Expand 10 after
148 // Returns 0 if this Command is not supported. 148 // Returns 0 if this Command is not supported.
149 int idForHistogram() const; 149 int idForHistogram() const;
150 private: 150 private:
151 const EditorInternalCommand* m_command; 151 const EditorInternalCommand* m_command;
152 EditorCommandSource m_source; 152 EditorCommandSource m_source;
153 RefPtr<LocalFrame> m_frame; 153 RefPtr<LocalFrame> m_frame;
154 }; 154 };
155 Command command(const String& commandName); // Command source is CommandFrom MenuOrKeyBinding. 155 Command command(const String& commandName); // Command source is CommandFrom MenuOrKeyBinding.
156 Command command(const String& commandName, EditorCommandSource); 156 Command command(const String& commandName, EditorCommandSource);
157 157
158 // |Editor::executeCommand| is implementation of |WebFrame::executeCommand|
159 // rather than |Document::execCommand|.
160 bool executeCommand(const String&);
161 bool executeCommand(const String& commandName, const String& value);
162
158 bool insertText(const String&, Event* triggeringEvent); 163 bool insertText(const String&, Event* triggeringEvent);
159 bool insertTextWithoutSendingTextEvent(const String&, bool selectInsertedTex t, TextEvent* triggeringEvent); 164 bool insertTextWithoutSendingTextEvent(const String&, bool selectInsertedTex t, TextEvent* triggeringEvent);
160 bool insertLineBreak(); 165 bool insertLineBreak();
161 bool insertParagraphSeparator(); 166 bool insertParagraphSeparator();
162 167
163 bool isOverwriteModeEnabled() const { return m_overwriteModeEnabled; } 168 bool isOverwriteModeEnabled() const { return m_overwriteModeEnabled; }
164 void toggleOverwriteModeEnabled(); 169 void toggleOverwriteModeEnabled();
165 170
166 bool canUndo(); 171 bool canUndo();
167 void undo(); 172 void undo();
(...skipping 122 matching lines...) Expand 10 before | Expand all | Expand 10 after
290 295
291 inline bool Editor::markedTextMatchesAreHighlighted() const 296 inline bool Editor::markedTextMatchesAreHighlighted() const
292 { 297 {
293 return m_areMarkedTextMatchesHighlighted; 298 return m_areMarkedTextMatchesHighlighted;
294 } 299 }
295 300
296 301
297 } // namespace WebCore 302 } // namespace WebCore
298 303
299 #endif // Editor_h 304 #endif // Editor_h
OLDNEW
« no previous file with comments | « no previous file | Source/core/editing/EditorCommand.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698