Commit 7ebe6420 authored by Igor Poboiko's avatar Igor Poboiko
Browse files

Don't crash if activateRichText was called before createActions

activateRichText emits textModeChanged signal, which leads to
richTextComposerActions::textModeChanged call. Which segfaults if table
actions are not yet created by explicit createActions call.
parent eca065cd
Pipeline #21709 passed with stage
in 7 minutes and 49 seconds
...@@ -601,5 +601,7 @@ void RichTextComposerActions::uncheckActionFormatPainter() ...@@ -601,5 +601,7 @@ void RichTextComposerActions::uncheckActionFormatPainter()
void RichTextComposerActions::textModeChanged(KPIMTextEdit::RichTextComposer::Mode mode) void RichTextComposerActions::textModeChanged(KPIMTextEdit::RichTextComposer::Mode mode)
{ {
d->action_add_table->setRichTextMode(mode == KPIMTextEdit::RichTextComposer::Rich); if (d->action_add_table) {
d->action_add_table->setRichTextMode(mode == KPIMTextEdit::RichTextComposer::Rich);
}
} }
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment