Commit d279c793 authored by Theo Linkspfeifer's avatar Theo Linkspfeifer Committed by Sean Davis

keyboard: Fix crash when editing shortcut (Bug #15958)

Signed-off-by: Sean Davis's avatarSean Davis <smd.seandavis@gmail.com>
parent ff24dad9
......@@ -1159,14 +1159,16 @@ xfce_keyboard_settings_edit_button_clicked (XfceKeyboardSettings *settings)
test_new_shortcut = (g_strcmp0 (shortcut, new_shortcut) != 0);
if (g_strcmp0 (command, new_command) != 0 || (test_new_shortcut) || snotify != new_snotify)
{
/* Remove the row because we add new one from the
* shortcut-added signal */
gtk_list_store_remove (GTK_LIST_STORE (model), &iter);
if (test_new_shortcut)
/* Remove old keyboard shortcut via xfconf */
xfce_shortcuts_provider_reset_shortcut (settings->priv->provider,
shortcut);
{
/* Remove the row because we add new one from the
* shortcut-added signal */
gtk_list_store_remove (GTK_LIST_STORE (model), &iter);
/* Remove old keyboard shortcut via xfconf */
xfce_shortcuts_provider_reset_shortcut (settings->priv->provider,
shortcut);
}
/* Save settings */
xfce_shortcuts_provider_set_shortcut (settings->priv->provider,
......
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