Commit 0e69ad32 authored by Max Kellermann's avatar Max Kellermann

client_idle: export client_idle_add()

parent 9b4e14df
......@@ -51,12 +51,9 @@ client_idle_notify(struct client *client)
g_timer_start(client->last_activity);
}
static void
client_idle_callback(gpointer data, gpointer user_data)
void
client_idle_add(struct client *client, unsigned flags)
{
struct client *client = data;
unsigned flags = GPOINTER_TO_UINT(user_data);
if (client_is_expired(client))
return;
......@@ -68,6 +65,15 @@ client_idle_callback(gpointer data, gpointer user_data)
}
}
static void
client_idle_callback(gpointer data, gpointer user_data)
{
struct client *client = data;
unsigned flags = GPOINTER_TO_UINT(user_data);
client_idle_add(client, flags);
}
void client_manager_idle_add(unsigned flags)
{
assert(flags != 0);
......
......@@ -24,6 +24,9 @@
struct client;
void
client_idle_add(struct client *client, unsigned flags);
/**
* Adds the specified idle flags to all clients and immediately sends
* notifications to all waiting clients.
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment