File 0021-fix-preferences-dialog-assertion-failures-wx3_2_8_x.patch of Package CodeLite
diff --git a/LiteEditor/options_dlg2.cpp b/LiteEditor/options_dlg2.cpp
index 8185e5bc3..4755cf8a9 100644
--- a/LiteEditor/options_dlg2.cpp
+++ b/LiteEditor/options_dlg2.cpp
@@ -73,7 +73,8 @@ void PreferencesDialog::DoSave()
EditorConfigST::Get()->Save();
// Notify plugins about settings changed
- PostCmdEvent(wxEVT_EDITOR_SETTINGS_CHANGED);
+ wxCommandEvent event(wxEVT_EDITOR_CONFIG_CHANGED);
+ EventNotifier::Get()->ProcessEvent(event);
}
void PreferencesDialog::Initialize()
diff --git a/Plugin/editor_config.cpp b/Plugin/editor_config.cpp
index f6381b393..902871478 100644
--- a/Plugin/editor_config.cpp
+++ b/Plugin/editor_config.cpp
@@ -177,7 +177,7 @@ void EditorConfig::SetOptions(OptionsConfigPtr opts)
DoSave();
wxCommandEvent evt(wxEVT_EDITOR_CONFIG_CHANGED);
evt.SetString(nodeName);
- EventNotifier::Get()->AddPendingEvent(evt);
+ EventNotifier::Get()->ProcessEvent(evt);
}
int clSortStringsFunc(const wxString& first, const wxString& second)
@@ -248,7 +248,7 @@ void EditorConfig::SetRecentItems(const wxArrayString& files, const wxString& no
DoSave();
wxCommandEvent evt(wxEVT_EDITOR_CONFIG_CHANGED);
evt.SetString(nodeName);
- EventNotifier::Get()->AddPendingEvent(evt);
+ EventNotifier::Get()->ProcessEvent(evt);
}
bool EditorConfig::WriteObject(const wxString& name, SerializedObject* obj)
@@ -260,7 +260,7 @@ bool EditorConfig::WriteObject(const wxString& name, SerializedObject* obj)
bool res = DoSave();
wxCommandEvent evt(wxEVT_EDITOR_CONFIG_CHANGED);
evt.SetString(name);
- EventNotifier::Get()->AddPendingEvent(evt);
+ EventNotifier::Get()->ProcessEvent(evt);
return res;
}
@@ -336,7 +336,7 @@ bool EditorConfig::DoSave() const
// Notify that the editor configuration was modified
wxCommandEvent event(wxEVT_EDITOR_CONFIG_CHANGED);
- EventNotifier::Get()->AddPendingEvent(event);
+ EventNotifier::Get()->ProcessEvent(event);
return XmlUtils::SaveXmlToFile(m_doc, m_fileName.GetFullPath());
}