Music Hub
..
A session-wide music playback service
client_death_observer.cpp
Go to the documentation of this file.
1
/*
2
* Copyright © 2014 Canonical Ltd.
3
*
4
* This program is free software: you can redistribute it and/or modify it
5
* under the terms of the GNU Lesser General Public License version 3,
6
* as published by the Free Software Foundation.
7
*
8
* This program is distributed in the hope that it will be useful,
9
* but WITHOUT ANY WARRANTY; without even the implied warranty of
10
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11
* GNU Lesser General Public License for more details.
12
*
13
* You should have received a copy of the GNU Lesser General Public License
14
* along with this program. If not, see <http://www.gnu.org/licenses/>.
15
*
16
* Authored by: Thomas Voß <thomas.voss@canonical.com>
17
*/
18
19
#include <
core/media/client_death_observer.h
>
20
21
namespace
media
=
core::ubuntu::media
;
22
23
#if defined(MEDIA_HUB_HAVE_HYBRIS_MEDIA_COMPAT_LAYER)
24
#include <
core/media/hybris_client_death_observer.h
>
25
26
// Accesses the default client death observer implementation for the platform.
27
media::ClientDeathObserver::Ptr
media::platform_default_client_death_observer
()
28
{
29
return
media::HybrisClientDeathObserver::create
();
30
}
31
#else // MEDIA_HUB_HAVE_HYBRIS_MEDIA_COMPAT_LAYER
32
// Just throws a std::logic_error as we have not yet defined a default way to
33
// identify client death changes. One possible way of implementing the interface
34
// would be to listen to dbus name changes and react accordingly.
35
media::ClientDeathObserver::Ptr
media::platform_default_client_death_observer
()
36
{
37
throw
std::logic_error
38
{
39
"No platform-specific death observer implementation known."
40
};
41
}
42
#endif // MEDIA_HUB_HAVE_HYBRIS_MEDIA_COMPAT_LAYER
core::ubuntu::media::HybrisClientDeathObserver::create
static ClientDeathObserver::Ptr create()
Definition:
hybris_client_death_observer.cpp:75
core::ubuntu::media::ClientDeathObserver::Ptr
std::shared_ptr< ClientDeathObserver > Ptr
Definition:
client_death_observer.h:40
client_death_observer.h
core::ubuntu::media
Definition:
player.h:37
hybris_client_death_observer.h
core::ubuntu::media::platform_default_client_death_observer
ClientDeathObserver::Ptr platform_default_client_death_observer()
Definition:
client_death_observer.cpp:35
src
core
media
client_death_observer.cpp
Generated on Mon Apr 27 2015 23:48:55 for Music Hub by
1.8.9.1