Music Hub  ..
A session-wide music playback service
service_implementation.h
Go to the documentation of this file.
1 /*
2  * Copyright © 2013 Canonical Ltd.
3  * Copyright © 2022 UBports Foundation.
4  *
5  * Contact: Alberto Mardegan <mardy@users.sourceforge.net>
6  *
7  * This program is free software: you can redistribute it and/or modify it
8  * under the terms of the GNU Lesser General Public License version 3,
9  * as published by the Free Software Foundation.
10  *
11  * This program is distributed in the hope that it will be useful,
12  * but WITHOUT ANY WARRANTY; without even the implied warranty of
13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14  * GNU Lesser General Public License for more details.
15  *
16  * You should have received a copy of the GNU Lesser General Public License
17  * along with this program. If not, see <http://www.gnu.org/licenses/>.
18  *
19  * Authored by: Thomas Voß <thomas.voss@canonical.com>
20  */
21 
22 #ifndef LOMIRI_MEDIAHUBSERVICE_SERVICE_IMPLEMENTATION_H
23 #define LOMIRI_MEDIAHUBSERVICE_SERVICE_IMPLEMENTATION_H
24 
25 #include "player.h"
26 
27 #include <QObject>
28 #include <QScopedPointer>
29 
30 namespace lomiri
31 {
32 namespace MediaHubService
33 {
34 class PlayerImplementation;
35 
36 class ServiceImplementationPrivate;
38 {
39  Q_OBJECT
40 
41 public:
42  ServiceImplementation(QObject *parent = nullptr);
44 
46 
50 
51 Q_SIGNALS:
52  void currentPlayerChanged();
53 
54 private:
55  Q_DECLARE_PRIVATE(ServiceImplementation)
56  QScopedPointer<ServiceImplementationPrivate> d_ptr;
57 };
58 }
59 }
60 
61 #endif // LOMIRI_MEDIAHUBSERVICE_SERVICE_IMPLEMENTATION_H
QObject
lomiri::MediaHubService::PlayerImplementation
Definition: player_implementation.h:44
lomiri::MediaHubService::ServiceImplementation::~ServiceImplementation
~ServiceImplementation()
Definition: service_implementation.cpp:314
lomiri::MediaHubService::Player::Client
Definition: player.h:61
lomiri::MediaHubService::Player::PlayerKey
uint32_t PlayerKey
Definition: player.h:55
lomiri::MediaHubService::ServiceImplementation::ServiceImplementation
ServiceImplementation(QObject *parent=nullptr)
Definition: service_implementation.cpp:308
lomiri::MediaHubService::ServiceImplementation::playerByKey
PlayerImplementation * playerByKey(Player::PlayerKey key) const
Definition: service_implementation.cpp:358
lomiri::MediaHubService::ServiceImplementation::currentPlayerChanged
void currentPlayerChanged()
lomiri::MediaHubService::ServiceImplementation::create_session
PlayerImplementation * create_session(const Player::Client &client)
Definition: service_implementation.cpp:318
player.h
lomiri::MediaHubService::ServiceImplementation
Definition: service_implementation.h:37
lomiri
Definition: dbus_utils.h:24
lomiri::MediaHubService::ServiceImplementation::pause_other_sessions
void pause_other_sessions(Player::PlayerKey key)
Definition: service_implementation.cpp:364
lomiri::MediaHubService::ServiceImplementation::currentPlayer
Player::PlayerKey currentPlayer() const
Definition: service_implementation.cpp:371