summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBastien Nocera <hadess@hadess.net>2021-02-11 11:49:53 +0100
committerBastien Nocera <hadess@hadess.net>2021-02-17 12:02:14 +0100
commitd93955b7c1a906181b3cdfc8afb6ea061e257e89 (patch)
treeb2fc1db6038748f5c471233d7f51eb4cf506853d
parente0349a553ecdb97e1275a51c12d0518e8c5215d2 (diff)
downloadgnome-bluetooth-d93955b7c1a906181b3cdfc8afb6ea061e257e89.tar.gz
settings: Remove use of deprecated GTimeVal
-rw-r--r--lib/bluetooth-settings-obexpush.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/lib/bluetooth-settings-obexpush.c b/lib/bluetooth-settings-obexpush.c
index 9ad399ce..9243062c 100644
--- a/lib/bluetooth-settings-obexpush.c
+++ b/lib/bluetooth-settings-obexpush.c
@@ -85,13 +85,11 @@ notification_launch_action_on_file_cb (NotifyNotification *notification,
if (g_str_equal (action, "display") != FALSE) {
GdkDisplay *display;
GAppLaunchContext *ctx;
- GTimeVal val;
-
- g_get_current_time (&val);
display = gdk_display_get_default ();
ctx = G_APP_LAUNCH_CONTEXT (gdk_display_get_app_launch_context (display));
- gdk_app_launch_context_set_timestamp (GDK_APP_LAUNCH_CONTEXT (ctx), val.tv_sec);
+ gdk_app_launch_context_set_timestamp (GDK_APP_LAUNCH_CONTEXT (ctx),
+ g_get_monotonic_time () / G_USEC_PER_SEC);
if (g_app_info_launch_default_for_uri (file_uri, ctx, NULL) == FALSE) {
g_warning ("Failed to launch the file viewer\n");