mirror of https://github.com/GNOME/gimp.git
Bug 785427 - GIMP crashes after applying any GEGL filter
Need to access GimpSettings' "time" property using gint64 variables now.
This commit is contained in:
parent
17c9f7cbd7
commit
bb93e3401f
|
@ -894,7 +894,9 @@ gimp_filter_tool_real_set_config (GimpFilterTool *filter_tool,
|
|||
* will be considered to be among the automatically stored recently
|
||||
* used settings
|
||||
*/
|
||||
g_object_set (filter_tool->config, "time", 0, NULL);
|
||||
g_object_set (filter_tool->config,
|
||||
"time", (gint64) 0,
|
||||
NULL);
|
||||
}
|
||||
|
||||
static void
|
||||
|
|
|
@ -866,7 +866,7 @@ gimp_settings_box_truncate_list (GimpSettingsBox *box,
|
|||
while (list)
|
||||
{
|
||||
GimpConfig *config = list->data;
|
||||
guint t;
|
||||
gint64 t;
|
||||
|
||||
list = g_list_next (list);
|
||||
|
||||
|
@ -944,7 +944,7 @@ gimp_settings_box_add_current (GimpSettingsBox *box,
|
|||
list;
|
||||
list = g_list_next (list))
|
||||
{
|
||||
guint t;
|
||||
gint64 t;
|
||||
|
||||
config = list->data;
|
||||
|
||||
|
@ -955,19 +955,27 @@ gimp_settings_box_add_current (GimpSettingsBox *box,
|
|||
if (t > 0 && gimp_config_is_equal_to (config,
|
||||
GIMP_CONFIG (private->config)))
|
||||
{
|
||||
GDateTime *now = g_date_time_new_now_utc ();
|
||||
|
||||
g_object_set (config,
|
||||
"time", (guint) time (NULL),
|
||||
"time", g_date_time_to_unix (now),
|
||||
NULL);
|
||||
g_date_time_unref (now);
|
||||
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
if (! list)
|
||||
{
|
||||
GDateTime *now = g_date_time_new_now_utc ();
|
||||
|
||||
config = gimp_config_duplicate (GIMP_CONFIG (private->config));
|
||||
|
||||
g_object_set (config,
|
||||
"time", (guint) time (NULL),
|
||||
"time", g_date_time_to_unix (now),
|
||||
NULL);
|
||||
g_date_time_unref (now);
|
||||
|
||||
gimp_container_insert (private->container, GIMP_OBJECT (config), 0);
|
||||
g_object_unref (config);
|
||||
|
|
|
@ -395,12 +395,16 @@ gimp_settings_editor_name_edited (GtkCellRendererText *cell,
|
|||
|
||||
if (strlen (name) && strcmp (old_name, name))
|
||||
{
|
||||
guint t;
|
||||
gint64 t;
|
||||
|
||||
g_object_get (object, "time", &t, NULL);
|
||||
g_object_get (object,
|
||||
"time", &t,
|
||||
NULL);
|
||||
|
||||
if (t > 0)
|
||||
g_object_set (object, "time", 0, NULL);
|
||||
g_object_set (object,
|
||||
"time", (gint64) 0,
|
||||
NULL);
|
||||
|
||||
/* set name after time so the object is reordered correctly */
|
||||
gimp_object_take_name (object, name);
|
||||
|
|
Loading…
Reference in New Issue