-
Notifications
You must be signed in to change notification settings - Fork 363
Expand file tree
/
Copy pathDisconnected.pm
More file actions
58 lines (48 loc) · 1.55 KB
/
Disconnected.pm
File metadata and controls
58 lines (48 loc) · 1.55 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
# Logitech Media Server Copyright 2001-2024 Logitech.
# Lyrion Music Server Copyright 2024 Lyrion Community.
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License,
# version 2.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# This class represents a disconnected player, that is, a player we
# probably know something about but is not currently connected. We
# can use this to still obtain prefs for the player, such as enabled apps.
#
package Slim::Player::Disconnected;
use strict;
use warnings;
use parent qw(Slim::Player::Client);
sub new {
my ( $class, $id ) = @_;
my $client = $class->SUPER::new($id);
$client->display( Slim::Display::NoDisplay->new($client) );
# Load strings for display
$client->display->displayStrings(Slim::Utils::Strings::clientStrings($client));
return $client;
}
# dummy methods
sub hidden { 1 }
sub bytesReceived { }
sub connected { 0 }
sub update { }
sub isPlayer { 0 }
sub stop { }
sub play { }
sub pause { }
sub rebuffer { 1 }
sub resume { 1 }
sub volume { 1 }
sub fade_volume { 1 }
sub bufferFullness { 0 }
sub formats { }
sub model { 'dummy' }
sub modelName { 'Dummy Client' }
sub decoder { }
sub vfd { undef }
sub canPowerOff { 0 }
1;