summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorrbuj <[email protected]>2020-03-15 13:14:52 +0100
committerraveit65 <[email protected]>2020-04-19 16:53:36 +0200
commitf8ce283d478e681dacfe21718fc5d618bd5a8cea (patch)
treefbe1cfb5b528982f4969a6f02437ad465bb803aa /src
parent2beb5d4fc7d18e63a633b7a3a5ccfda9c2746d3f (diff)
downloadmate-screensaver-f8ce283d478e681dacfe21718fc5d618bd5a8cea.tar.bz2
mate-screensaver-f8ce283d478e681dacfe21718fc5d618bd5a8cea.tar.xz
gs-lock-plug: remove function casting
Diffstat (limited to 'src')
-rw-r--r--src/gs-lock-plug.c20
1 files changed, 12 insertions, 8 deletions
diff --git a/src/gs-lock-plug.c b/src/gs-lock-plug.c
index cb27964..67b83f3 100644
--- a/src/gs-lock-plug.c
+++ b/src/gs-lock-plug.c
@@ -387,8 +387,10 @@ gs_lock_plug_response (GSLockPlug *plug,
}
static gboolean
-response_cancel_idle_cb (GSLockPlug *plug)
+response_cancel_idle_cb (gpointer user_data)
{
+ GSLockPlug *plug = user_data;
+
plug->priv->response_idle_id = 0;
gs_lock_plug_response (plug, GS_LOCK_PLUG_RESPONSE_CANCEL);
@@ -397,8 +399,10 @@ response_cancel_idle_cb (GSLockPlug *plug)
}
static gboolean
-dialog_timed_out (GSLockPlug *plug)
+dialog_timed_out (gpointer user_data)
{
+ GSLockPlug *plug = user_data;
+
gs_lock_plug_set_sensitive (plug, FALSE);
set_status_text (plug, _("Time has expired."));
@@ -410,8 +414,8 @@ dialog_timed_out (GSLockPlug *plug)
remove_response_idle (plug);
plug->priv->response_idle_id = g_timeout_add (2000,
- (GSourceFunc)response_cancel_idle_cb,
- plug);
+ response_cancel_idle_cb,
+ plug);
return FALSE;
}
@@ -462,8 +466,8 @@ restart_cancel_timeout (GSLockPlug *plug)
remove_cancel_timeout (plug);
plug->priv->cancel_timeout_id = g_timeout_add (plug->priv->timeout,
- (GSourceFunc)dialog_timed_out,
- plug);
+ dialog_timed_out,
+ plug);
}
void
@@ -1950,8 +1954,8 @@ switch_user_button_clicked (GtkButton *button,
gs_lock_plug_set_sensitive (plug, FALSE);
plug->priv->response_idle_id = g_timeout_add (2000,
- (GSourceFunc)response_cancel_idle_cb,
- plug);
+ response_cancel_idle_cb,
+ plug);
gs_lock_plug_set_busy (plug);
do_user_switch (plug);