static void
gtk_form_field_datetime_init (GtkFormFieldDateTime *gtk_form_field)
{
+ GtkFormFieldDateTimePrivate *priv = GTK_FORM_FIELD_DATETIME_GET_PRIVATE (gtk_form_field);
+
+ priv->default_value = NULL;
+ priv->original_value = NULL;
}
/**
|| value->tm_min != priv->original_value->tm_min
|| value->tm_sec != priv->original_value->tm_sec);
}
+ else if (value == NULL && priv->original_value != NULL)
+ {
+ ret = TRUE;
+ }
return ret;
}
gchar *field_name;
struct tm *datetime;
gchar *value;
- gchar *format;
g_return_val_if_fail (IS_GTK_FORM_FIELD_DATETIME (field), FALSE);
g_return_val_if_fail (GDA_IS_DATA_MODEL (dm), FALSE);
ret = gtk_form_field_datetime_set_value_stringify (field, value);
- format = gtk_form_field_datetime_get_str_format (GTK_FORM_FIELD_DATETIME (field));
-
priv->original_value = g_memdup (datetime, sizeof (struct tm));
}
else
static void
gtk_form_field_text_init (GtkFormFieldText *gtk_form_field)
{
+ GtkFormFieldTextPrivate *priv = GTK_FORM_FIELD_TEXT_GET_PRIVATE (gtk_form_field);
+
+ priv->original_value = g_strdup ("");
}
/**