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

Unified Diff: Source/core/editing/Editor.h

Issue 21694005: Spell check whole content of an editable element when it gets focused. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: async test added. Sync suffixed with -sync Created 7 years, 4 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 side-by-side diff with in-line comments
Download patch
Index: Source/core/editing/Editor.h
diff --git a/Source/core/editing/Editor.h b/Source/core/editing/Editor.h
index 053c3879df0890f10a76c38c05fac7a88a32081e..83fe6c8b29d7c93d7a992ab09f824ef982cbc4f7 100644
--- a/Source/core/editing/Editor.h
+++ b/Source/core/editing/Editor.h
@@ -214,8 +214,8 @@ public:
bool canRedo();
void redo();
- void didBeginEditing();
- void didEndEditing();
+ void didBeginEditing(Element*);
+ void didEndEditing(Element*);
tony 2013/08/20 22:10:39 It doesn't look like we use Element in didEndEditi
void setBaseWritingDirection(WritingDirection);
@@ -281,7 +281,7 @@ public:
bool markedTextMatchesAreHighlighted() const;
void setMarkedTextMatchesAreHighlighted(bool);
- void textFieldDidBeginEditing(Element*);
+ void textAreaOrTextFieldDidBeginEditing(Element*);
void textFieldDidEndEditing(Element*);
void textDidChangeInTextField(Element*);
bool doTextFieldCommandFromEvent(Element*, KeyboardEvent*);
@@ -309,6 +309,10 @@ public:
};
friend class RevealSelectionScope;
+ // Spell checks whole contents of a editable element (<input="text"/>, <textarea> or contenteditable)
+ // This gets called when any editable element gets focused.
tony 2013/08/20 22:10:39 I would remove this comment. It's a 'what' commen
+ void elementDidBeginEditing(Element*);
+
private:
RefPtr<CompositeEditCommand> m_lastEditCommand;
RefPtr<Node> m_removedAnchor;
@@ -321,6 +325,7 @@ private:
bool m_areMarkedTextMatchesHighlighted;
EditorParagraphSeparator m_defaultParagraphSeparator;
bool m_overwriteModeEnabled;
+ Vector<RefPtr<Node> > m_editablesSpellCheckedOnFocus;
tony 2013/08/20 22:10:39 This should be a HashSet, not a Vector. Also, why
pstanek 2013/08/21 06:05:18 I was thinking the same i.e. it's only a key so No
bool canDeleteRange(Range*) const;
bool canSmartReplaceWithPasteboard(Pasteboard*);

Powered by Google App Engine
This is Rietveld 408576698