mirror of
https://github.com/FeralInteractive/gamemode.git
synced 2025-06-26 17:31:45 +02:00
daemon: export game objects on the bus
For each registered game, export an object on the bus under the path "/com/feralinteractive/GameMode/Games/<pid>" with an dbus interface of ""com.feralinteractive.GameMode.Game". The interface currently provides to properties, ProcessId and Executable. Additionally add the ListGames method and the GameRegistered, GameUnregistered signals to the com.feralinteractive.GameMode interface.
This commit is contained in:
@ -486,6 +486,7 @@ int game_mode_context_register(GameModeContext *self, pid_t client, pid_t reques
|
||||
/* Unlock now we're done applying optimisations */
|
||||
pthread_rwlock_unlock(&self->rwlock);
|
||||
|
||||
game_mode_client_registered(client);
|
||||
game_mode_client_count_changed();
|
||||
|
||||
return 0;
|
||||
@ -586,6 +587,7 @@ int game_mode_context_unregister(GameModeContext *self, pid_t client, pid_t requ
|
||||
pthread_rwlock_unlock(&self->rwlock);
|
||||
|
||||
game_mode_client_count_changed();
|
||||
game_mode_client_unregistered(client);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
Reference in New Issue
Block a user