mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-24 21:31:04 +00:00
Bug 1700051: part 2) Add GetNoCheckRange()
to mozInlineSpellStatus
. r=smaug
Depends on D109308 Differential Revision: https://phabricator.services.mozilla.com/D109309
This commit is contained in:
parent
3691a72cd6
commit
77b3add57e
@ -1389,8 +1389,9 @@ nsresult mozInlineSpellChecker::DoSpellCheck(
|
||||
// We do a simple check to see if the beginning of our word is in the
|
||||
// exclusion range. Because the exclusion range is a multiple of a word,
|
||||
// this is sufficient.
|
||||
if (aStatus->mNoCheckRange &&
|
||||
aStatus->mNoCheckRange->IsPointInRange(*beginNode, beginOffset, erv)) {
|
||||
if (aStatus->GetNoCheckRange() &&
|
||||
aStatus->GetNoCheckRange()->IsPointInRange(*beginNode, beginOffset,
|
||||
erv)) {
|
||||
continue;
|
||||
}
|
||||
|
||||
|
@ -73,10 +73,13 @@ class mozInlineSpellStatus {
|
||||
// hurt)
|
||||
RefPtr<nsRange> mCreatedRange;
|
||||
|
||||
// See `mNoCheckRange`.
|
||||
const nsRange* GetNoCheckRange() const { return mNoCheckRange; }
|
||||
|
||||
private:
|
||||
// Contains the range computed for the current word. Can be nullptr.
|
||||
RefPtr<nsRange> mNoCheckRange;
|
||||
|
||||
private:
|
||||
// Indicates the position of the cursor for the event (so we can compute
|
||||
// mNoCheckRange). It can be nullptr if we don't care about the cursor
|
||||
// position (such as for the intial check of everything).
|
||||
|
Loading…
Reference in New Issue
Block a user