Commit cd84b283 authored by Tomas Popela's avatar Tomas Popela

EHTMLEditorSelection - Recalculate just plain text properties when selection...

EHTMLEditorSelection - Recalculate just plain text properties when selection changes in plain text mode

We don't need to recalculate the HTML properties as they are not used
in plain text mode.
parent 5e719cf2
......@@ -234,27 +234,37 @@ get_font_property (EHTMLEditorSelection *selection,
}
static void
html_editor_selection_selection_changed_cb (WebKitWebView *webview,
html_editor_selection_selection_changed_cb (WebKitWebView *web_view,
EHTMLEditorSelection *selection)
{
EHTMLEditorView *view;
view = e_html_editor_selection_ref_html_editor_view (selection);
g_object_freeze_notify (G_OBJECT (selection));
g_object_notify (G_OBJECT (selection), "alignment");
g_object_notify (G_OBJECT (selection), "block-format");
g_object_notify (G_OBJECT (selection), "indented");
g_object_notify (G_OBJECT (selection), "text");
if (!e_html_editor_view_get_html_mode (view))
goto out;
g_object_notify (G_OBJECT (selection), "background-color");
g_object_notify (G_OBJECT (selection), "bold");
g_object_notify (G_OBJECT (selection), "font-name");
g_object_notify (G_OBJECT (selection), "font-size");
g_object_notify (G_OBJECT (selection), "font-color");
g_object_notify (G_OBJECT (selection), "block-format");
g_object_notify (G_OBJECT (selection), "indented");
g_object_notify (G_OBJECT (selection), "italic");
g_object_notify (G_OBJECT (selection), "monospaced");
g_object_notify (G_OBJECT (selection), "strikethrough");
g_object_notify (G_OBJECT (selection), "subscript");
g_object_notify (G_OBJECT (selection), "superscript");
g_object_notify (G_OBJECT (selection), "text");
g_object_notify (G_OBJECT (selection), "underline");
out:
g_object_unref (view);
g_object_thaw_notify (G_OBJECT (selection));
}
......
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