Commit graph

65 commits

Author SHA1 Message Date
Federico Fossemò
20fc764916
default volume to 50% 2017-12-03 18:06:24 +01:00
Paul Lietar
bf60f6e7ab Create new librespot-core crate 2017-08-03 19:58:44 +01:00
Paul Lietar
72070b6ce0 Allow device type to be chosen.
Fix #187
2017-08-03 19:31:15 +01:00
Paul Lietar
7c237c77df Change Connect mercury URL 2017-05-15 21:55:49 +01:00
Paul Lietar
294a7821d6 Add simple playback example. 2017-04-28 23:24:55 +01:00
Jörg Krause
14da5c8f17 spirc: add more commands
Add play, playpause, pause, prev, next, volumeup, and volumedown.

volume up/down is realized in 16 steps.
2017-03-27 08:22:38 +02:00
Paul Lietar
d940ed161a Allow switching user accounts at runtime
Fixes #130
2017-02-22 04:18:27 +00:00
Paul Lietar
2708aa4fef Merge remote-tracking branch 'origin/master' 2017-02-21 22:46:19 +00:00
Paul Lietar
5974cf7f24 Fixes for PR #148 2017-02-21 21:49:45 +00:00
Paul Lietar
6f1871d822 Merge remote-tracking branch 'origin/master' 2017-02-09 01:33:52 +00:00
Daniel Romero
10f9da410e Remove code to notify spirc manager from the mixer 2017-02-03 17:11:36 +01:00
Daniel Romero
44467a44d6 Call start and stop on mixer 2017-02-03 13:30:30 +01:00
Daniel Romero
5ef28bf2a5 SpircManager: Update state from player and mixer before sending info 2017-02-03 13:22:49 +01:00
Daniel Romero
48a43f4948 Move structs which are send across threads to own module 2017-02-03 13:22:49 +01:00
Daniel Romero
134239d298 Send update messages from mixer to SpircManager 2017-02-03 13:22:49 +01:00
Daniel Romero
c8ee08663d Create channel in spirc instead of in mercury and use MercuryResponseSender implemented by macro 2017-02-03 13:22:49 +01:00
Daniel Romero
59398b3cee Remove mixer from Player and add it to SpircManager 2017-02-03 13:22:49 +01:00
Paul Lietar
9873eaf2a0 Better handling of shutdown 2017-01-31 08:21:30 +00:00
Paul Lietar
7be9626836 spirc: Increase the number of volume steps to 64 2017-01-30 04:13:18 +00:00
Paul Lietar
bbc438d9b2 Clippy run 2017-01-29 17:20:12 +00:00
Paul Lietar
8aeb266a2d Refactor player and spirc 2017-01-29 15:02:12 +00:00
Paul Lietar
0da9020ad3 Store DeviceState directly into SpircTask 2017-01-20 14:44:13 +00:00
Paul Lietar
bcedfefaa9 Move spirc to tokio 2017-01-20 13:28:13 +00:00
Paul Lietar
bcbd7afb1a Change mercury to use tokio 2017-01-20 01:59:47 +00:00
Paul Lietar
d27063d5da Create event loop in main 2017-01-20 01:59:46 +00:00
Jörg Krause
c1e570f48d Say goodbye when terminating
When librespot is terminated while a session is active it will now send
a goodbye message, so that the Spotify client unregisters the device
from its list.

Closes: #114
2016-09-20 21:00:01 +02:00
Jörg Krause
0716643ae3 Fix out of bounds panic
Selecting a librespot device with the Spotify desktop client causes a
crash if the playlist is empty.

Take into account the case where an empty list of tracks is received. In
this case notify the desktop client, so it will accept the device and
turn the status bar green.

Closes: #71
2016-08-23 23:49:19 +02:00
Paul Lietar
edb8a6a766 Cleanup authentication logic 2016-04-24 12:15:53 +01:00
Marcus Thiesen
b0ea636179 Replace some more println with log 2016-04-23 13:35:00 +02:00
Paul Lietar
230c891df0 Print librespot version on startup. 2016-03-17 03:31:57 +00:00
Paul Lietar
0770f6ce61 Move authentication to a different directory, and make discover use hyper. 2016-03-17 03:28:28 +00:00
Paul Lietar
c3c258dfaf Bump protobuf-macros version and use the simpler string literal syntax 2016-02-22 05:48:58 +00:00
Paul Lietar
c700315b30 Fix a deadlock between SpircManager and Player.
The player was invoking its observers with the state locked, and the
SpircManager’s registered observer would try to lock it again.

Instead, the observers are invoked with a cloned state, and the SpircManager
avoids locking the state again.
2016-02-22 05:41:37 +00:00
Paul Lietar
95d1dfd774 Make recipient of SpircManager methods non-mut.
SpircManager has interior mutability using a Mutex. There’s no need to
make it’s methods take a mut reference.
2016-02-19 00:03:08 +00:00
Simon Persson
3ccb2e2a10 Clean up before merging. 2016-02-19 00:02:41 +01:00
Simon Persson
c98ff9bd54 Make SpricManager cloneable to simplify for clients. 2016-02-17 20:53:25 +01:00
Simon Persson
906241b92e Export the current queue. 2016-02-17 20:53:25 +01:00
Simon Persson
8e0325c297 Add function for sending load comand. 2016-02-17 20:53:25 +01:00
Simon Persson
5e3404137f Add support for replacing tracks. Make a builder out of send_cmd. 2016-02-17 20:53:21 +01:00
Simon Persson
08cb429a0c Add functions for sending commands to other clients. 2016-02-17 20:45:01 +01:00
Simon Persson
677173d01b Export devices. 2016-02-17 20:45:01 +01:00
Simon Persson
5a19d38270 Refactor notify/notify_with_player_state. 2016-02-17 20:45:01 +01:00
Simon Persson
958d0c74d4 Maintain list of connected devices. 2016-02-17 20:44:54 +01:00
Paul Lietar
93640465dc Import librespot_protocol as protocol. 2016-01-27 10:40:00 +00:00
Paul Lietar
7a1db5f5a9 Encapsulate the session data and configuration. 2016-01-26 22:34:57 +00:00
Paul Lietar
8fed885595 Reorganize the spirc/player interaction.
Updates are now sent through a callback mechanism rather than a channel.
2016-01-20 15:52:50 +00:00
Paul Lietar
463ce97661 Remove the SpircDelegate abstraction 2016-01-20 14:11:49 +00:00
Paul Lietar
303121032d Store the volume as a u16 2016-01-20 13:55:36 +00:00
Paul Lietar
c5ed04f70d Merge remote-tracking branch 'realtwister/queue' 2016-01-20 13:51:35 +00:00
Paul Lietar
ac0d597e75 Ignore files which don’t have an id.
Fixes #42
2016-01-20 10:37:57 +00:00