Пример #1
0
void Client::removePlayer(const QString &player_name){
    ClientPlayer *player = findChild<ClientPlayer*>(player_name);
    if(player){
        player->setParent(NULL);

        alive_count--;

        emit player_removed(player_name);
    }
}
Пример #2
0
void Client::removePlayer(const QJsonValue &player_name){
	QString name = player_name.toString();
	ClientPlayer *player = findChild<ClientPlayer*>(name);
	if(player){
		player->setParent(NULL);

		alive_count--;

		emit player_removed(name);
	}
}
Пример #3
0
static void proxy_removed(GDBusProxy *proxy, void *user_data)
{
	const char *interface;

	interface = g_dbus_proxy_get_interface(proxy);

	if (!strcmp(interface, BLUEZ_MEDIA_PLAYER_INTERFACE))
		player_removed(proxy);
	if (!strcmp(interface, BLUEZ_MEDIA_FOLDER_INTERFACE))
		folder_removed(proxy);
	if (!strcmp(interface, BLUEZ_MEDIA_ITEM_INTERFACE))
		item_removed(proxy);
}