summaryrefslogtreecommitdiff
path: root/src/profile-editor.c
diff options
context:
space:
mode:
authormonsta <[email protected]>2017-12-27 14:03:29 +0300
committermonsta <[email protected]>2018-01-09 22:48:16 +0300
commit30ce4834e8305510cff82ddd043bac660c68d3d0 (patch)
tree5b8828e21e8b4fd4737b0a51f935e5056f0a1155 /src/profile-editor.c
parent7ab5af88f15fc8ad4b421c6a117c12e8ab02e021 (diff)
downloadmate-terminal-30ce4834e8305510cff82ddd043bac660c68d3d0.tar.bz2
mate-terminal-30ce4834e8305510cff82ddd043bac660c68d3d0.tar.xz
profile-editor: properly initialize the first palette color
taken from: https://git.gnome.org/browse/gnome-terminal/commit/?id=6447aded26416e49bf5fdce8a8fd13c16c0ebb44
Diffstat (limited to 'src/profile-editor.c')
-rw-r--r--src/profile-editor.c11
1 files changed, 3 insertions, 8 deletions
diff --git a/src/profile-editor.c b/src/profile-editor.c
index 1aa9f90..e3667eb 100644
--- a/src/profile-editor.c
+++ b/src/profile-editor.c
@@ -461,18 +461,13 @@ profile_palette_notify_colorpickers_cb (TerminalProfile *profile,
for (i = 0; i < n_colors; i++)
{
char name[32];
- GdkRGBA old_color;
g_snprintf (name, sizeof (name), "palette-colorpicker-%d", i + 1);
w = profile_editor_get_widget (editor, name);
- gtk_color_chooser_get_rgba (GTK_COLOR_CHOOSER (w), &old_color);
- if (!gdk_rgba_equal (&old_color, &colors[i]))
- {
- g_signal_handlers_block_by_func (w, G_CALLBACK (palette_color_notify_cb), profile);
- gtk_color_chooser_set_rgba (GTK_COLOR_CHOOSER (w), &colors[i]);
- g_signal_handlers_unblock_by_func (w, G_CALLBACK (palette_color_notify_cb), profile);
- }
+ g_signal_handlers_block_by_func (w, G_CALLBACK (palette_color_notify_cb), profile);
+ gtk_color_chooser_set_rgba (GTK_COLOR_CHOOSER (w), &colors[i]);
+ g_signal_handlers_unblock_by_func (w, G_CALLBACK (palette_color_notify_cb), profile);
}
}