Commit graph

37 commits

Author SHA1 Message Date
Roderick van Domburg 87f6a78d3e
Fix examples 2021-12-07 23:52:34 +01:00
Roderick van Domburg d3074f597a
Remove keymaster and update example 2021-06-22 21:49:36 +02:00
johannesd3 041f084d7f Fix warnings 2021-05-13 22:42:55 +02:00
johannesd3 26c127c2ec Merge branch 'dev' into tokio_migration 2021-04-10 12:59:47 +02:00
johannesd3 11ce29077e Fix formatting 2021-04-09 10:45:48 +02:00
ThouCheese ec1ec59b8a update examples
Re-add default impl to SessionConfig and make Credentials::with_password generic over Into<String>

add docs for Credential

reintroduce old Default impl for SessionConfig

use the third argument for the track-to-play rather than a testing id
2021-03-24 01:14:44 +01:00
Roderick van Domburg 6379926eb4 Fix example 2021-03-12 23:47:15 +01:00
Ash 064359c26e
Add an example to fetch a Spotify API token (#512) 2020-08-25 23:13:46 +02:00
Konstantin Seiler 9eef690a22 Some clean up 2020-02-02 11:08:46 +11:00
Konstantin Seiler 5784b4652c Prepare for gapless play.
- change communication between player and spirc to use player events channel.
- enhance player events channel
- have spirc send loading messages to Spotify
- enable preloading of tracks in the player
2020-02-01 08:41:11 +11:00
marcelbuesing 38d82f2dc2
Rerun rustfmt on full codebase 2020-01-17 18:47:30 +01:00
ashthespy d26590afc5
Update to Rust 2018
- Fix deprecated Error::cause warnings and missing dyn
- Reset max_width
- Add rustfmt to Travis
- Run rustfmt on full codebase
 with `cargo fmt --all`
- Add rustfmt to Travis
- Complete migration to edition 2018
- Replace try! shorthand
- Use explicit `dyn Trait`
2020-01-17 18:11:52 +01:00
marcelbuesing be2ad9059a
Migrate to rust 2018 edition 2020-01-17 15:54:42 +01:00
HEnquist c530ee6e82 Some more cleaning 2019-12-16 09:57:59 +01:00
HEnquist e1322474fa Clean up playlist example 2019-12-16 09:57:59 +01:00
HEnquist 9468ab7eec Remove unused code from example 2019-12-16 09:57:59 +01:00
HEnquist e6295a6f9c Use new hm endpoint for playlists 2019-12-16 09:57:59 +01:00
HEnquist 9faaaae6d2 Add basic support for playlists 2019-12-16 09:57:59 +01:00
HEnquist abd6ad6b25 Some more cleaning 2019-12-16 09:57:59 +01:00
HEnquist abfcce282e Clean up playlist example 2019-12-16 09:57:59 +01:00
HEnquist ae0585eb5b Remove unused code from example 2019-12-16 09:51:43 +01:00
HEnquist d8fda8f79c Use new hm endpoint for playlists 2019-12-16 09:51:43 +01:00
HEnquist 5b26529811 Add basic support for playlists 2019-12-16 09:51:43 +01:00
Gilles Castel 93a00956ce Fix play.rs example 2019-10-09 18:18:38 +02:00
Nick Mavis c19375c5ca Fixed nightly conflict with 2019-09-16 15:00:09 -04:00
Harold 00e89343fb Formatting 2018-07-03 13:08:42 +02:00
Brice d40c0f50db Cache volume across restarts (#220)
* create Volume struct for use with Cache

* add "volume" file to Cache

* load cached volume on start, intial overrides cached overrides default

* amend volume_to_mixer function to cache the volume on every change

* pass cache to Spirc and SpircTask so volume_to_mixer has access

* rustfmt changes

* revert volume_to_mixer function and Spirc/SpircTask cache variable

* Volume implements Copy, pass by value instead of reference

* clamp volume to 100 if cached value exceeds limit

* convert Volume to u16 internally, use float and round to convert hex->dec

* convert initial_volume and ConnectConfig.volume to u16 as well

* add cache_volume function to SpircTask

* remove conversion to/from percentage on cached volume

* consolidate device.set_volume, mixer.set_volume, and caching

* streamline intial volume logic
2018-05-17 03:15:17 +02:00
Lasse Linkola 4caf2b88f2 formatting 2018-04-16 19:11:27 +03:00
Lasse Linkola d62b72f24d fixed example play.rs initalizing player 2018-04-16 19:04:31 +03:00
Johan Anderholm 612978908f Reformat according to new rustfmt rules 2018-03-24 08:45:43 +00:00
Sasha Hilton 237ef1e4f9 Format according to rustfmt 2018-02-26 02:50:41 +01:00
Sasha Hilton 4fb8c71b0a Set SpotifyId methods to return Result 2018-02-25 03:04:07 +01:00
akosel 3ce22113cf Fix example use declarations (#160) 2018-02-22 13:24:04 +01:00
awiouy 4c2b641cad core API: move spotify_id to lib.rs 2018-02-13 07:57:28 +01:00
awiouy 191caca518 core API: move Bitrate and PlayerConfig from core to playback 2018-02-11 23:55:41 +01:00
Paul Lietar 2846d3acfd Fix the play example 2017-08-03 20:11:30 +01:00
Paul Lietar 294a7821d6 Add simple playback example. 2017-04-28 23:24:55 +01:00