[gnome-terminal/gnome-3-20] profile: editor: Properly initialize the first palette color
- From: Egmont Koblinger <egmontkob src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-terminal/gnome-3-20] profile: editor: Properly initialize the first palette color
- Date: Fri, 22 Jul 2016 14:43:45 +0000 (UTC)
commit 2a10e0ed7d6210b0522ffc2faf8483c64f1d183d
Author: Egmont Koblinger <egmont gmail com>
Date: Fri Jul 22 16:42:14 2016 +0200
profile: editor: Properly initialize the first palette color
https://bugzilla.gnome.org/show_bug.cgi?id=768850
(cherry picked from commit 6447aded26416e49bf5fdce8a8fd13c16c0ebb44)
src/profile-editor.c | 11 +++--------
1 files changed, 3 insertions(+), 8 deletions(-)
---
diff --git a/src/profile-editor.c b/src/profile-editor.c
index ff26df6..82cc7a9 100644
--- a/src/profile-editor.c
+++ b/src/profile-editor.c
@@ -405,18 +405,13 @@ profile_palette_notify_colorpickers_cb (GSettings *profile,
for (i = 0; i < n_colors; i++)
{
char name[32];
- GdkRGBA old_color;
g_snprintf (name, sizeof (name), "palette-colorpicker-%" G_GSIZE_FORMAT, i + 1);
w = (GtkWidget *) gtk_builder_get_object (builder, name);
- gtk_color_chooser_get_rgba (GTK_COLOR_CHOOSER (w), &old_color);
- if (!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);
}
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]