[gnome-color-manager] trivial: only show the CIE widget for RGB profiles when importing profiles
- From: Richard Hughes <rhughes src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-color-manager] trivial: only show the CIE widget for RGB profiles when importing profiles
- Date: Sat, 6 Mar 2010 19:04:28 +0000 (UTC)
commit 048a7fd0b8ea35fb1dab155db5f050f6f1816081
Author: Richard Hughes <richard hughsie com>
Date: Sat Mar 6 16:05:29 2010 +0000
trivial: only show the CIE widget for RGB profiles when importing profiles
src/gcm-import.c | 6 ++++++
1 files changed, 6 insertions(+), 0 deletions(-)
---
diff --git a/src/gcm-import.c b/src/gcm-import.c
index ef2a218..bf60932 100644
--- a/src/gcm-import.c
+++ b/src/gcm-import.c
@@ -65,6 +65,7 @@ main (int argc, char **argv)
gchar **files = NULL;
guint retval = 1;
GcmProfile *profile = NULL;
+ GcmColorspaceEnum colorspace;
GError *error = NULL;
GOptionContext *context;
GString *string = NULL;
@@ -128,6 +129,7 @@ main (int argc, char **argv)
g_object_get (profile,
"description", &description,
"copyright", ©right,
+ "colorspace", &colorspace,
"white", &white,
"red", &red,
"green", &green,
@@ -188,6 +190,10 @@ main (int argc, char **argv)
/* add cie widget */
gcm_import_add_cie_widget (GTK_DIALOG(dialog), cie_widget);
+ /* only show the cie widget if we have RGB data */
+ if (colorspace != GCM_COLORSPACE_ENUM_RGB)
+ gtk_widget_hide (cie_widget);
+
gtk_window_set_resizable (GTK_WINDOW (dialog), TRUE);
response = gtk_dialog_run (GTK_DIALOG (dialog));
gtk_widget_destroy (dialog);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]