From 0d8a81b722e18092062f83b7fd8c0b3a5f4d613a Mon Sep 17 00:00:00 2001 From: Cosimo Cecchi Date: Mon, 20 Aug 2012 19:46:33 +0200 Subject: [PATCH] mount-op: use gint64 instead of guint64 for time_left and bytes_left Since those can be -1, they need to be signed. https://bugzilla.gnome.org/show_bug.cgi?id=682284 --- gio/gmountoperation.c | 9 +++++---- gio/gmountoperation.h | 4 ++-- 2 files changed, 7 insertions(+), 6 deletions(-) diff --git a/gio/gmountoperation.c b/gio/gmountoperation.c index 31b2a3420..ec7f5ff9d 100644 --- a/gio/gmountoperation.c +++ b/gio/gmountoperation.c @@ -243,8 +243,8 @@ show_processes (GMountOperation *op, static void show_unmount_progress (GMountOperation *op, const gchar *message, - guint64 time_left, - guint64 bytes_left) + gint64 time_left, + gint64 bytes_left) { /* nothing to do */ } @@ -387,7 +387,8 @@ g_mount_operation_class_init (GMountOperationClass *klass) * GMountOperation::show-unmount-progress: * @op: a #GMountOperation: * @message: string containing a mesage to display to the user - * @time_left: the estimated time left before the operation completes, or -1 + * @time_left: the estimated time left before the operation completes, + * in microseconds, or -1 * @bytes_left: the amount of bytes to be written before the operation * completes (or -1 if such amount is not known), or zero if the operation * is completed @@ -418,7 +419,7 @@ g_mount_operation_class_init (GMountOperationClass *klass) G_STRUCT_OFFSET (GMountOperationClass, show_unmount_progress), NULL, NULL, NULL, G_TYPE_NONE, 3, - G_TYPE_STRING, G_TYPE_UINT64, G_TYPE_UINT64); + G_TYPE_STRING, G_TYPE_INT64, G_TYPE_INT64); /** * GMountOperation:username: diff --git a/gio/gmountoperation.h b/gio/gmountoperation.h index ae363988b..0c112658e 100644 --- a/gio/gmountoperation.h +++ b/gio/gmountoperation.h @@ -82,8 +82,8 @@ struct _GMountOperationClass void (* show_unmount_progress) (GMountOperation *op, const gchar *message, - guint64 time_left, - guint64 bytes_left); + gint64 time_left, + gint64 bytes_left); /*< private >*/ /* Padding for future expansion */