[gnome-color-manager] Allow the profile title to be changed in gcm-calibrate before calibration has started



commit 2b66c96319d556459c3824d551a04dd8fa5d6b41
Author: Richard Hughes <richard hughsie com>
Date:   Tue Jun 28 21:42:00 2011 +0100

    Allow the profile title to be changed in gcm-calibrate before calibration has started

 src/gcm-calibrate-argyll.c |   20 ++---
 src/gcm-calibrate-main.c   |  196 +++++++++++++++++++++++++++++++++++++------
 src/gcm-calibrate-native.c |   35 +-------
 src/gcm-calibrate.c        |  144 --------------------------------
 src/gcm-calibrate.h        |    8 --
 5 files changed, 180 insertions(+), 223 deletions(-)
---
diff --git a/src/gcm-calibrate-argyll.c b/src/gcm-calibrate-argyll.c
index b488a96..642dd0a 100644
--- a/src/gcm-calibrate-argyll.c
+++ b/src/gcm-calibrate-argyll.c
@@ -806,14 +806,12 @@ gcm_calibrate_argyll_display_generate_profile (GcmCalibrateArgyll *calibrate_arg
 	/* get shared data */
 	g_object_get (calibrate_argyll,
 		      "basename", &basename,
+		      "copyright", &copyright,
+		      "description", &description,
+		      "model", &model,
+		      "manufacturer", &manufacturer,
 		      NULL);
 
-	/* get profile text data */
-	copyright = gcm_calibrate_get_profile_copyright (GCM_CALIBRATE (calibrate_argyll));
-	description = gcm_calibrate_get_profile_description (GCM_CALIBRATE (calibrate_argyll));
-	model = gcm_calibrate_get_profile_model (GCM_CALIBRATE (calibrate_argyll));
-	manufacturer = gcm_calibrate_get_profile_manufacturer (GCM_CALIBRATE (calibrate_argyll));
-
 	/* get correct name of the command */
 	command = gcm_calibrate_argyll_get_tool_filename ("colprof", error);
 	if (command == NULL) {
@@ -1117,15 +1115,13 @@ gcm_calibrate_argyll_device_generate_profile (GcmCalibrateArgyll *calibrate_argy
 	/* get shared data */
 	g_object_get (calibrate_argyll,
 		      "basename", &basename,
+		      "copyright", &copyright,
+		      "description", &description,
+		      "model", &model,
+		      "manufacturer", &manufacturer,
 		      "reference-kind", &reference_kind,
 		      NULL);
 
-	/* get profile text data */
-	copyright = gcm_calibrate_get_profile_copyright (GCM_CALIBRATE (calibrate_argyll));
-	description = gcm_calibrate_get_profile_description (GCM_CALIBRATE (calibrate_argyll));
-	model = gcm_calibrate_get_profile_model (GCM_CALIBRATE (calibrate_argyll));
-	manufacturer = gcm_calibrate_get_profile_manufacturer (GCM_CALIBRATE (calibrate_argyll));
-
 	/* get correct name of the command */
 	command = gcm_calibrate_argyll_get_tool_filename ("colprof", error);
 	if (command == NULL) {
diff --git a/src/gcm-calibrate-main.c b/src/gcm-calibrate-main.c
index 0ea5708..78359c3 100644
--- a/src/gcm-calibrate-main.c
+++ b/src/gcm-calibrate-main.c
@@ -50,6 +50,7 @@ typedef enum {
 	GCM_CALIBRATE_PAGE_SENSOR,
 	GCM_CALIBRATE_PAGE_ACTION,
 	GCM_CALIBRATE_PAGE_FAILURE,
+	GCM_CALIBRATE_PAGE_TITLE,
 	GCM_CALIBRATE_PAGE_LAST
 } GcmCalibratePage;
 
@@ -74,11 +75,7 @@ typedef struct {
 	GtkWidget	*action_image;
 	gboolean	 has_pending_interaction;
 	gboolean	 started_calibration;
-	GcmCalibrateDisplayKind		 display_kind;
-	GcmCalibrateReferenceKind	 reference_kind;
-	GcmCalibratePrintKind		 print_kind;
-	GcmCalibratePrecision		 precision;
-	GcmCalibratePage		 current_page;
+	GcmCalibratePage current_page;
 } GcmCalibratePriv;
 
 /**
@@ -413,11 +410,6 @@ gcm_calib_start_idle_cb (gpointer user_data)
 	GcmCalibratePriv *calib = (GcmCalibratePriv *) user_data;
 	GtkAssistant *assistant = GTK_ASSISTANT (calib->main_window);
 
-	g_object_set (calib->calibrate,
-		      "display-kind", calib->display_kind,
-		      "precision", calib->precision,
-		      NULL);
-
 	/* actuall do the action */
 	calib->started_calibration = TRUE;
 	ret = gcm_calibrate_display (calib->calibrate,
@@ -541,16 +533,14 @@ gcm_calib_assistant_page_forward_cb (gint current_page, gpointer user_data)
  * gcm_calib_assistant_prepare_cb:
  **/
 static gboolean
-gcm_calib_assistant_prepare_cb (GtkAssistant *assistant, GtkWidget *page_widget, GcmCalibratePriv *calib)
+gcm_calib_assistant_prepare_cb (GtkAssistant *assistant,
+				GtkWidget *page_widget,
+				GcmCalibratePriv *calib)
 {
 	calib->current_page = GPOINTER_TO_UINT (g_object_get_data (G_OBJECT (page_widget),
 								   "GcmCalibrateMain::Index"));
 	switch (calib->current_page) {
-	case GCM_CALIBRATE_PAGE_INTRO:
-		g_debug ("now intro page");
-		break;
 	case GCM_CALIBRATE_PAGE_LAST:
-		g_debug ("now last page");
 		gcm_calib_device_uninihibit (calib);
 		gcm_calib_play_sound (calib);
 		break;
@@ -565,6 +555,15 @@ gcm_calib_assistant_prepare_cb (GtkAssistant *assistant, GtkWidget *page_widget,
 		break;
 	}
 
+	/* ensure we cancel argyllcms if the user clicks back */
+	if (calib->current_page != GCM_CALIBRATE_PAGE_ACTION &&
+	    calib->started_calibration) {
+		gcm_calibrate_interaction (calib->calibrate,
+					   GTK_RESPONSE_CANCEL);
+		gcm_calib_device_uninihibit (calib);
+		calib->started_calibration = FALSE;
+	}
+
 	/* forward on the action page just unsticks the calibration */
 	if (calib->current_page == GCM_CALIBRATE_PAGE_ACTION) {
 		gtk_assistant_set_forward_page_func (assistant,
@@ -1150,10 +1149,11 @@ gcm_calib_reference_kind_combobox_cb (GtkComboBox *combo_box,
 {
 	const gchar *filename;
 	gchar *path;
+	GcmCalibrateReferenceKind reference_kind;
 
 	/* not sorted so we can just use the index */
-	calib->reference_kind = gtk_combo_box_get_active (GTK_COMBO_BOX (combo_box));
-	filename = gcm_calib_reference_kind_to_image_filename (calib->reference_kind);
+	reference_kind = gtk_combo_box_get_active (GTK_COMBO_BOX (combo_box));
+	filename = gcm_calib_reference_kind_to_image_filename (reference_kind);
 
 	/* fallback */
 	if (filename == NULL)
@@ -1249,10 +1249,15 @@ static void
 gcm_calib_display_kind_toggled_cb (GtkToggleButton *togglebutton,
 				   GcmCalibratePriv *calib)
 {
+	GcmCalibrateDisplayKind	 display_kind;
+
 	if (!gtk_toggle_button_get_active (togglebutton))
 		return;
-	calib->display_kind = GPOINTER_TO_UINT (g_object_get_data (G_OBJECT (togglebutton),
-								   "GcmCalib::display-kind"));
+	display_kind = GPOINTER_TO_UINT (g_object_get_data (G_OBJECT (togglebutton),
+							    "GcmCalib::display-kind"));
+	g_object_set (calib->calibrate,
+		      "display-kind", display_kind,
+		      NULL);
 }
 
 /**
@@ -1427,10 +1432,14 @@ static void
 gcm_calib_print_kind_toggled_cb (GtkToggleButton *togglebutton,
 				   GcmCalibratePriv *calib)
 {
+	GcmCalibratePrintKind print_kind;
 	if (!gtk_toggle_button_get_active (togglebutton))
 		return;
-	calib->print_kind = GPOINTER_TO_UINT (g_object_get_data (G_OBJECT (togglebutton),
-								   "GcmCalib::print-kind"));
+	print_kind = GPOINTER_TO_UINT (g_object_get_data (G_OBJECT (togglebutton),
+							  "GcmCalib::print-kind"));
+	g_object_set (calib->calibrate,
+		      "print-kind", print_kind,
+		      NULL);
 }
 
 /**
@@ -1500,10 +1509,14 @@ static void
 gcm_calib_precision_toggled_cb (GtkToggleButton *togglebutton,
 				GcmCalibratePriv *calib)
 {
+	GcmCalibratePrecision precision;
 	if (!gtk_toggle_button_get_active (togglebutton))
 		return;
-	calib->precision = GPOINTER_TO_UINT (g_object_get_data (G_OBJECT (togglebutton),
-								"GcmCalib::precision"));
+	precision = GPOINTER_TO_UINT (g_object_get_data (G_OBJECT (togglebutton),
+							 "GcmCalib::precision"));
+	g_object_set (calib->calibrate,
+		      "precision", precision,
+		      NULL);
 }
 
 /**
@@ -1607,6 +1620,67 @@ gcm_calib_setup_page_precision (GcmCalibratePriv *calib)
 	gtk_widget_show_all (vbox);
 }
 
+static void
+gcm_calib_text_changed_cb (GtkEntry *entry,
+			   GcmCalibratePriv *calib)
+{
+	g_object_set (calib->calibrate,
+		      "description", gtk_entry_get_text (entry),
+		      NULL);
+}
+
+/**
+ * gcm_calib_setup_page_profile_title:
+ **/
+static void
+gcm_calib_setup_page_profile_title (GcmCalibratePriv *calib)
+{
+	GtkWidget *vbox;
+	GtkWidget *content;
+	GtkWidget *widget;
+	gchar *tmp = NULL;
+	GtkAssistant *assistant = GTK_ASSISTANT (calib->main_window);
+
+	/* TRANSLATORS: this is the page title */
+	vbox = gcm_calib_add_page_title (calib, _("Profile title"));
+
+	/* main contents */
+	content = gtk_box_new (GTK_ORIENTATION_VERTICAL, 6);
+	gtk_box_pack_start (GTK_BOX (vbox), content, FALSE, FALSE, 0);
+
+	/* TRANSLATORS: this is intro page text */
+	gcm_calib_add_page_para (content, _("Choose a title to identify the profile on your system."));
+
+	widget = gtk_entry_new ();
+	gtk_box_pack_start (GTK_BOX (content), widget, FALSE, FALSE, 0);
+	gtk_entry_set_max_length (GTK_ENTRY (widget), 128);
+
+	/* set the current title */
+	g_object_get (calib->calibrate,
+		      "description", &tmp,
+		      NULL);
+	gtk_entry_set_text (GTK_ENTRY (widget), tmp);
+	g_free (tmp);
+
+	/* watch for changes */
+	g_signal_connect (GTK_EDITABLE (widget), "changed",
+			  G_CALLBACK (gcm_calib_text_changed_cb), calib);
+
+	/* add to assistant */
+	gtk_assistant_append_page (assistant, vbox);
+	gtk_assistant_set_page_type (assistant, vbox, GTK_ASSISTANT_PAGE_CONTENT);
+	/* TRANSLATORS: this is the calibration wizard page title */
+	gtk_assistant_set_page_title (assistant, vbox, _("Profile Title"));
+	gtk_assistant_set_page_complete (assistant, vbox, TRUE);
+	g_ptr_array_add (calib->pages, vbox);
+	g_object_set_data (G_OBJECT (vbox),
+			   "GcmCalibrateMain::Index",
+			   GUINT_TO_POINTER (GCM_CALIBRATE_PAGE_TITLE));
+
+	/* show page */
+	gtk_widget_show_all (vbox);
+}
+
 /**
  * gcm_calib_setup_page_sensor:
  **/
@@ -1760,10 +1834,13 @@ gcm_calib_add_pages (GcmCalibratePriv *calib)
 	gcm_calib_setup_page_precision (calib);
 
 	if (calib->device_kind == CD_DEVICE_KIND_DISPLAY) {
-		if (!calib->internal_lcd)
+		if (!calib->internal_lcd) {
 			gcm_calib_setup_page_display_kind (calib);
-		else
-			calib->display_kind = GCM_CALIBRATE_DEVICE_KIND_LCD;
+		} else {
+			g_object_set (calib->calibrate,
+				      "display-kind", GCM_CALIBRATE_DEVICE_KIND_LCD,
+				      NULL);
+		}
 		gcm_calib_setup_page_display_temp (calib);
 	} else if (calib->device_kind == CD_DEVICE_KIND_PRINTER) {
 		gcm_calib_setup_page_print_kind (calib);
@@ -1774,6 +1851,7 @@ gcm_calib_add_pages (GcmCalibratePriv *calib)
 			gcm_calib_setup_page_install_targets (calib);
 	}
 
+	gcm_calib_setup_page_profile_title (calib);
 	gcm_calib_setup_page_action (calib);
 
 	gcm_calib_setup_page_summary (calib);
@@ -1806,7 +1884,14 @@ gcm_calib_sensor_added_cb (CdClient *client, CdSensor *sensor, GcmCalibratePriv
 static void
 gcm_calib_startup_cb (GApplication *application, GcmCalibratePriv *calib)
 {
+	const gchar *description;
+	const gchar *manufacturer;
+	const gchar *model;
+	const gchar *native_device;
+	const gchar *serial;
+	gchar *copyright = NULL;
 	gboolean ret;
+	GDateTime *dt = NULL;
 	GError *error = NULL;
 
 	/* add application specific icons to search path */
@@ -1873,12 +1958,68 @@ gcm_calib_startup_cb (GApplication *application, GcmCalibratePriv *calib)
 		goto out;
 	}
 
-	/* get the device kind */
+	/* get the device properties */
 	calib->device_kind = cd_device_get_kind (calib->device);
+
+	/* set, with fallbacks */
+	serial = cd_device_get_serial (calib->device);
+	if (serial == NULL) {
+		/* TRANSLATORS: this is saved in the profile */
+		serial = _("Unknown serial");
+	}
+	model = cd_device_get_model (calib->device);
+	if (model == NULL) {
+		/* TRANSLATORS: this is saved in the profile */
+		model = _("Unknown model");
+	}
+	description = cd_device_get_model (calib->device);
+	if (description == NULL) {
+		/* TRANSLATORS: this is saved in the profile */
+		description = _("Unknown description");
+	}
+	manufacturer = cd_device_get_vendor (calib->device);
+	if (manufacturer == NULL) {
+		/* TRANSLATORS: this is saved in the profile */
+		manufacturer = _("Unknown manufacturer");
+	}
+
+	dt = g_date_time_new_now_local ();
+	/* TRANSLATORS: this is the copyright string, where it might be
+	 * "Copyright (c) 2009 Edward Scissorhands"
+	 * BIG RED FLASHING NOTE: YOU NEED TO USE ASCII ONLY */
+	copyright = g_strdup_printf ("%s %04i %s", _("Copyright (c)"),
+				     g_date_time_get_year (dt),
+				     g_get_real_name ());
+
+	/* set the proper values */
+	g_object_set (calib->calibrate,
+		      "device-kind", calib->device_kind,
+		      "model", model,
+		      "description", description,
+		      "manufacturer", manufacturer,
+		      "serial", serial,
+		      "copyright", copyright,
+		      NULL);
+
+	/* display specific properties */
+	if (calib->device_kind == CD_DEVICE_KIND_DISPLAY) {
+		native_device = cd_device_get_metadata_item (calib->device,
+							     CD_DEVICE_METADATA_XRANDR_NAME);
+		if (native_device == NULL) {
+			g_warning ("failed to get output");
+			goto out;
+		}
+		g_object_set (calib->calibrate,
+			      "output-name", native_device,
+			      NULL);
+	}
 out:
 	/* add different pages depending on the device kind */
 	gcm_calib_add_pages (calib);
 	gtk_assistant_set_current_page (GTK_ASSISTANT (calib->main_window), 0);
+	if (dt != NULL)
+		g_date_time_unref (dt);
+	g_free (copyright);
 }
 
 static void
@@ -1985,7 +2126,6 @@ main (int argc, char **argv)
 	calib->brightness = gcm_brightness_new ();
 	calib->calibrate = gcm_calibrate_argyll_new ();
 	calib->device_kind = CD_DEVICE_KIND_UNKNOWN;
-	calib->display_kind = GCM_CALIBRATE_DEVICE_KIND_UNKNOWN;
 	g_signal_connect (calib->calibrate, "title-changed",
 			  G_CALLBACK (gcm_calib_title_changed_cb), calib);
 	g_signal_connect (calib->calibrate, "message-changed",
diff --git a/src/gcm-calibrate-native.c b/src/gcm-calibrate-native.c
index 10f6043..8446ccb 100644
--- a/src/gcm-calibrate-native.c
+++ b/src/gcm-calibrate-native.c
@@ -671,6 +671,10 @@ gcm_calibrate_native_display (GcmCalibrate *calibrate, CdDevice *device, CdSenso
 	/* get the number of steps to use */
 	g_object_get (calibrate,
 		      "precision", &precision,
+		      "copyright", &copyright,
+		      "description", &description,
+		      "model", &model,
+		      "manufacturer", &manufacturer,
 		      NULL);
 	if (precision == GCM_CALIBRATE_PRECISION_SHORT)
 		steps = 10;
@@ -682,12 +686,6 @@ gcm_calibrate_native_display (GcmCalibrate *calibrate, CdDevice *device, CdSenso
 	g_debug ("creating %s", filename_it8);
 	gcm_calibrate_native_create_it8_file (calibrate_native, sensor, filename_it8, steps);
 
-	/* get profile text data */
-	copyright = gcm_calibrate_get_profile_copyright (calibrate);
-	description = gcm_calibrate_get_profile_description (calibrate);
-	model = gcm_calibrate_get_profile_model (calibrate);
-	manufacturer = gcm_calibrate_get_profile_manufacturer (calibrate);
-
 	/* create basic profile */
 	profile = gcm_profile_new ();
 	gcm_profile_set_colorspace (profile, CD_COLORSPACE_RGB);
@@ -719,30 +717,6 @@ out:
 }
 
 /**
- * gcm_calibrate_native_spotread:
- **/
-static gboolean
-gcm_calibrate_native_spotread (GcmCalibrate *calibrate, CdDevice *device, CdSensor *sensor, GtkWindow *window, GError **error)
-{
-//	GcmCalibrateNative *calibrate_native = GCM_CALIBRATE_NATIVE(calibrate);
-//	GcmCalibrateNativePrivate *priv = calibrate_native->priv;
-	gboolean ret = TRUE;
-	const gchar *title;
-	const gchar *message;
-
-	/* TRANSLATORS: title, setting up the photospectromiter */
-	title = _("Setting up device");
-	/* TRANSLATORS: dialog message */
-	message = _("Setting up the device to read a spot colorâ");
-
-	/* push new messages into the UI */
-	g_debug ("title=%s, message=%s", title, message);
-
-//out:
-	return ret;
-}
-
-/**
  * gcm_calibrate_native_class_init:
  **/
 static void
@@ -754,7 +728,6 @@ gcm_calibrate_native_class_init (GcmCalibrateNativeClass *klass)
 
 	/* setup klass links */
 	parent_class->calibrate_display = gcm_calibrate_native_display;
-	parent_class->calibrate_spotread = gcm_calibrate_native_spotread;
 
 	g_type_class_add_private (klass, sizeof (GcmCalibrateNativePrivate));
 }
diff --git a/src/gcm-calibrate.c b/src/gcm-calibrate.c
index 99c71a6..e01cc40 100644
--- a/src/gcm-calibrate.c
+++ b/src/gcm-calibrate.c
@@ -137,81 +137,6 @@ out:
 }
 
 /**
- * gcm_calibrate_get_device_fallback:
- **/
-gchar *
-gcm_calibrate_get_profile_copyright (GcmCalibrate *calibrate)
-{
-	gchar *text;
-	GDate *date = NULL;
-
-	/* create date and set it to now */
-	date = g_date_new ();
-	g_date_set_time_t (date, time (NULL));
-
-	/* TRANSLATORS: this is the copyright string, where it might be "Copyright (c) 2009 Edward Scissorhands" - YOU NEED TO USE ASCII ONLY */
-	text = g_strdup_printf ("%s %04i %s", _("Copyright (c)"), date->year, g_get_real_name ());
-
-	g_date_free (date);
-	return text;
-}
-
-/**
- * gcm_calibrate_get_device_fallback:
- **/
-gchar *
-gcm_calibrate_get_profile_description (GcmCalibrate *calibrate)
-{
-	gchar *text;
-	const gchar *description;
-	GcmCalibratePrivate *priv = calibrate->priv;
-
-	/* we've got something set */
-	if (priv->description != NULL) {
-		description = priv->description;
-	} else {
-		/* TRANSLATORS: this is saved in the profile */
-		description = _("Unknown description");
-	}
-
-	/* get description */
-	text = g_strdup_printf ("%s, %s", priv->device, description);
-	return text;
-}
-
-/**
- * gcm_calibrate_get_device_fallback:
- **/
-gchar *
-gcm_calibrate_get_profile_model (GcmCalibrate *calibrate)
-{
-	GcmCalibratePrivate *priv = calibrate->priv;
-
-	/* we've got something set */
-	if (priv->model != NULL)
-		return g_strdup (priv->model);
-
-	/* TRANSLATORS: this is saved in the profile */
-	return g_strdup (_("Unknown model"));
-}
-
-/**
- * gcm_calibrate_get_device_fallback:
- **/
-gchar *
-gcm_calibrate_get_profile_manufacturer (GcmCalibrate *calibrate)
-{
-	GcmCalibratePrivate *priv = calibrate->priv;
-
-	/* we've got something set */
-	if (priv->manufacturer != NULL)
-		return g_strdup (priv->manufacturer);
-
-	/* TRANSLATORS: this is saved in the profile */
-	return g_strdup (_("Unknown manufacturer"));
-}
-
-/**
  * gcm_calibrate_get_time:
  **/
 static gchar *
@@ -306,65 +231,6 @@ gcm_calibrate_set_basename (GcmCalibrate *calibrate)
 }
 
 /**
- * gcm_calibrate_set_from_device:
- **/
-gboolean
-gcm_calibrate_set_from_device (GcmCalibrate *calibrate,
-			       CdDevice *device,
-			       CdSensor *sensor,
-			       GError **error)
-{
-	gboolean ret = TRUE;
-	const gchar *native_device = NULL;
-	const gchar *manufacturer = NULL;
-	const gchar *model = NULL;
-	const gchar *description = NULL;
-	const gchar *serial = NULL;
-	CdDeviceKind kind;
-
-	/* get the device */
-	kind = cd_device_get_kind (device);
-	serial = cd_device_get_serial (device);
-	model = cd_device_get_model (device);
-	description = cd_device_get_model (device);
-	manufacturer = cd_device_get_vendor (device);
-
-	/* do not refcount */
-	calibrate->priv->sensor = sensor;
-
-	/* set the proper values */
-	g_object_set (calibrate,
-		      "device-kind", kind,
-		      "model", model,
-		      "description", description,
-		      "manufacturer", manufacturer,
-		      "serial", serial,
-		      NULL);
-
-	/* get a filename based on calibration attributes we've just set */
-	gcm_calibrate_set_basename (calibrate);
-
-	/* display specific properties */
-	if (kind == CD_DEVICE_KIND_DISPLAY) {
-		native_device = cd_device_get_metadata_item (device, CD_DEVICE_METADATA_XRANDR_NAME);
-		if (native_device == NULL) {
-			g_set_error (error,
-				     GCM_CALIBRATE_ERROR,
-				     GCM_CALIBRATE_ERROR_INTERNAL,
-				     "failed to get output");
-			ret = FALSE;
-			goto out;
-		}
-		g_object_set (calibrate,
-			      "output-name", native_device,
-			      NULL);
-	}
-
-out:
-	return ret;
-}
-
-/**
  * gcm_calibrate_set_from_exif:
  **/
 gboolean
@@ -481,16 +347,6 @@ gcm_calibrate_display (GcmCalibrate *calibrate, CdDevice *device, GtkWindow *win
 
 	/* set basename */
 	gcm_calibrate_set_basename (calibrate);
-#if 0
-	const gchar *hardware_device;
-	/* get device, harder */
-	hardware_device = cd_sensor_get_model (priv->sensor);
-	if (hardware_device == NULL) {
-		/* TRANSLATORS: this is the formattted custom profile description.
-		 * "Custom" refers to the fact that it's user generated */
-		hardware_device = _("Custom");
-	}
-#endif
 
 	/* coldplug source */
 	if (klass->calibrate_display == NULL) {
diff --git a/src/gcm-calibrate.h b/src/gcm-calibrate.h
index caa6c68..9267b8a 100644
--- a/src/gcm-calibrate.h
+++ b/src/gcm-calibrate.h
@@ -145,10 +145,6 @@ void		 gcm_calibrate_interaction		(GcmCalibrate	*calibrate,
 							 GtkResponseType response);
 
 /* designed for super-classes to call */
-gchar		*gcm_calibrate_get_profile_copyright	(GcmCalibrate	*calibrate);
-gchar		*gcm_calibrate_get_profile_description	(GcmCalibrate	*calibrate);
-gchar		*gcm_calibrate_get_profile_model	(GcmCalibrate	*calibrate);
-gchar		*gcm_calibrate_get_profile_manufacturer	(GcmCalibrate	*calibrate);
 void		 gcm_calibrate_set_sensor		(GcmCalibrate	*calibrate,
 							 CdSensor	*sensor);
 void		 gcm_calibrate_set_title		(GcmCalibrate	*calibrate,
@@ -163,10 +159,6 @@ void		 gcm_calibrate_interaction_required	(GcmCalibrate	*calibrate,
 GtkWidget	*gcm_calibrate_get_content_widget	(GcmCalibrate	*calibrate);
 
 /* JUNK */
-gboolean	 gcm_calibrate_set_from_device		(GcmCalibrate	*calibrate,
-							 CdDevice	*device,
-							 CdSensor	*sensor,
-							 GError		**error);
 gboolean	 gcm_calibrate_set_from_exif		(GcmCalibrate	*calibrate,
 							 const gchar	*filename,
 							 GError		**error);



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]