summaryrefslogtreecommitdiff
path: root/gtk/gtkcolorsel.c
diff options
context:
space:
mode:
authorMatthias Clasen <maclas@gmx.de>2003-08-02 09:22:38 +0000
committerMatthias Clasen <matthiasc@src.gnome.org>2003-08-02 09:22:38 +0000
commit3d4c726c489f36954649c3ecbd4a1782a5423ad0 (patch)
tree34dd8494b64e6c3520cc3dce74e541e74004c9a1 /gtk/gtkcolorsel.c
parent3dc24f5893e40b85633370742e393fe57b3be36a (diff)
downloadgtk+-3d4c726c489f36954649c3ecbd4a1782a5423ad0.tar.gz
Accept drops with the wrong format, since the KDE color chooser
2003-08-02 Matthias Clasen <maclas@gmx.de> * gtk/gtkcolorsel.c (color_sample_drop_handle) (palette_drop_handle): * gtk/gtkcolorbutton.c (gtk_color_button_drag_data_received): Accept drops with the wrong format, since the KDE color chooser incorrectly drops application/x-color with format 8.
Diffstat (limited to 'gtk/gtkcolorsel.c')
-rw-r--r--gtk/gtkcolorsel.c12
1 files changed, 8 insertions, 4 deletions
diff --git a/gtk/gtkcolorsel.c b/gtk/gtkcolorsel.c
index d493484810..e7a191a042 100644
--- a/gtk/gtkcolorsel.c
+++ b/gtk/gtkcolorsel.c
@@ -313,8 +313,10 @@ color_sample_drop_handle (GtkWidget *widget,
if (selection_data->length < 0)
return;
- if ((selection_data->format != 16) ||
- (selection_data->length != 8))
+ /* We accept drops with the wrong format, since the KDE color
+ * chooser incorrectly drops application/x-color with format 8.
+ */
+ if (selection_data->length != 8)
{
g_warning ("Received invalid color data\n");
return;
@@ -1022,8 +1024,10 @@ palette_drop_handle (GtkWidget *widget,
if (selection_data->length < 0)
return;
- if ((selection_data->format != 16) ||
- (selection_data->length != 8))
+ /* We accept drops with the wrong format, since the KDE color
+ * chooser incorrectly drops application/x-color with format 8.
+ */
+ if (selection_data->length != 8)
{
g_warning ("Received invalid color data\n");
return;