|
|
|
@ -4,7 +4,7 @@ import 'package:simple_spell_checker/simple_spell_checker.dart'; |
|
|
|
|
|
|
|
|
|
import 'spellchecker_service.dart'; |
|
|
|
|
|
|
|
|
|
/// SimpleSpellCheckerImpl is a simple spell checker for get |
|
|
|
|
/// SimpleSpellCheckerImpl is a simple spell checker for get |
|
|
|
|
/// all words divide on different objects if them are wrong or not |
|
|
|
|
class SimpleSpellCheckerImpl extends SpellcheckerService { |
|
|
|
|
SimpleSpellCheckerImpl({required super.language}) |
|
|
|
@ -12,9 +12,10 @@ class SimpleSpellCheckerImpl extends SpellcheckerService { |
|
|
|
|
language: language, |
|
|
|
|
safeDictionaryLoad: true, |
|
|
|
|
); |
|
|
|
|
|
|
|
|
|
/// [SimpleSpellChecker] comes from the package [simple_spell_checker] |
|
|
|
|
/// that give us all necessary methods for get our spans with highlighting |
|
|
|
|
/// where needed |
|
|
|
|
/// where needed |
|
|
|
|
final SimpleSpellChecker checker; |
|
|
|
|
|
|
|
|
|
@override |
|
|
|
@ -32,7 +33,7 @@ class SimpleSpellCheckerImpl extends SpellcheckerService { |
|
|
|
|
|
|
|
|
|
@override |
|
|
|
|
void dispose({bool onlyPartial = false}) { |
|
|
|
|
if(onlyPartial) { |
|
|
|
|
if (onlyPartial) { |
|
|
|
|
checker.disposeControllers(); |
|
|
|
|
return; |
|
|
|
|
} |
|
|
|
|