File tree Expand file tree Collapse file tree 2 files changed +12
-0
lines changed Expand file tree Collapse file tree 2 files changed +12
-0
lines changed Original file line number Diff line number Diff line change 22
33#define DSPELLCHECK_SETLANG_MSG 1 // See DSpellCheckSetLangMsgInfo
44#define DSPELLCHECK_GETLANGUAGELIST_MSG 2 // See DSpellCheckGetLanguageListMsgInfo
5+ #define DSPELLCHECK_ENABLESPELLCHECK_MSG 3 // See DSpellCheckEnableSpellCheckMsgInfo
56
67// Set language to lang_name, if was_success non-zero, it will be set to true in case of success and fales in case of failure
78struct DSpellCheckSetLangMsgInfo {
@@ -14,3 +15,7 @@ struct DSpellCheckGetLanguageListMsgInfo {
1415 void (* language_callback )(void * payload , const wchar_t * lang_name );
1516 void * payload ;
1617};
18+
19+ struct DSpellCheckEnableSpellCheckMsgInfo {
20+ bool enabled ;
21+ };
Original file line number Diff line number Diff line change @@ -907,6 +907,13 @@ bool process_internal_msg(const CommunicationInfo& communication_info) {
907907 }
908908 }
909909 return true ;
910+ case DSPELLCHECK_ENABLESPELLCHECK_MSG: {
911+ if (const auto info = reinterpret_cast <DSpellCheckEnableSpellCheckMsgInfo *>(communication_info.info )) {
912+ auto mut = settings->modify (SettingsModificationStyle::ignore_file_errors);
913+ mut->data .auto_check_text = info->enabled ;
914+ }
915+ }
916+ return true ;
910917 }
911918 return false ;
912919}
You can’t perform that action at this time.
0 commit comments