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

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

Issue 593583002: Assert that frame() derefs a non-null pointer. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 6 years, 3 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 | « Source/core/editing/SpellCheckRequester.h ('k') | Source/core/frame/FrameConsole.h » ('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 74 matching lines...) Expand 10 before | Expand all | Expand 10 after
85 void cancelCheck(); 85 void cancelCheck();
86 void chunkAndMarkAllMisspellingsAndBadGrammar(Node*); 86 void chunkAndMarkAllMisspellingsAndBadGrammar(Node*);
87 void requestTextChecking(const Element&); 87 void requestTextChecking(const Element&);
88 88
89 // Exposed for testing only 89 // Exposed for testing only
90 SpellCheckRequester& spellCheckRequester() const { return *m_spellCheckReque ster; } 90 SpellCheckRequester& spellCheckRequester() const { return *m_spellCheckReque ster; }
91 91
92 private: 92 private:
93 explicit SpellChecker(LocalFrame&); 93 explicit SpellChecker(LocalFrame&);
94 94
95 LocalFrame& frame() const { return *m_frame; } 95 LocalFrame& frame() const
96 {
97 ASSERT(m_frame);
98 return *m_frame;
99 }
96 100
97 void markMisspellingsOrBadGrammar(const VisibleSelection&, bool checkSpellin g, RefPtrWillBeRawPtr<Range>& firstMisspellingRange); 101 void markMisspellingsOrBadGrammar(const VisibleSelection&, bool checkSpellin g, RefPtrWillBeRawPtr<Range>& firstMisspellingRange);
98 TextCheckingTypeMask resolveTextCheckingTypeMask(TextCheckingTypeMask); 102 TextCheckingTypeMask resolveTextCheckingTypeMask(TextCheckingTypeMask);
99 103
100 bool unifiedTextCheckerEnabled() const; 104 bool unifiedTextCheckerEnabled() const;
101 105
102 void chunkAndMarkAllMisspellingsAndBadGrammar(TextCheckingTypeMask textCheck ingOptions, const TextCheckingParagraph& fullParagraphToCheck, bool asynchronous ); 106 void chunkAndMarkAllMisspellingsAndBadGrammar(TextCheckingTypeMask textCheck ingOptions, const TextCheckingParagraph& fullParagraphToCheck, bool asynchronous );
103 void markAllMisspellingsAndBadGrammarInRanges(TextCheckingTypeMask textCheck ingOptions, Range* checkingRange, Range* paragraphRange, bool asynchronous, int requestNumber, int* checkingLength = 0); 107 void markAllMisspellingsAndBadGrammarInRanges(TextCheckingTypeMask textCheck ingOptions, Range* checkingRange, Range* paragraphRange, bool asynchronous, int requestNumber, int* checkingLength = 0);
104 108
105 RawPtrWillBeMember<LocalFrame> m_frame; 109 RawPtrWillBeMember<LocalFrame> m_frame;
106 const OwnPtrWillBeMember<SpellCheckRequester> m_spellCheckRequester; 110 const OwnPtrWillBeMember<SpellCheckRequester> m_spellCheckRequester;
107 }; 111 };
108 112
109 } // namespace blink 113 } // namespace blink
110 114
111 #endif // SpellChecker_h 115 #endif // SpellChecker_h
OLDNEW
« no previous file with comments | « Source/core/editing/SpellCheckRequester.h ('k') | Source/core/frame/FrameConsole.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698