Commit Graph

35 Commits

Author SHA1 Message Date
Henrik Friedrichsen
dccb36d8e7 update to rust edition 2018 + bump version 2020-03-15 11:06:24 +01:00
Tobias Langendorf
363e71242a Shuffle: Start with random track if not selecting track directly
Starting a playlist, album or artist with shuffle enabled always
starts on the first track in it and then plays the rest of the
queue shuffled.
This changes it so unless a track is picked directly, playback
will start on a random track of the selection.
2020-02-21 18:42:31 +01:00
Henrik Friedrichsen
8924b85390 fix deprecation warnings that occured due to cursive 0.14.0 upgrade 2020-02-02 20:10:21 +01:00
Henrik Friedrichsen
2039878144 update to cursive 0.14.0 2020-02-02 19:55:26 +01:00
Rasmus Larsen
db7a09c87b Command parser 2019-05-21 18:11:54 +02:00
Rasmus Larsen
1671db14c1 Move to enum-based commands 2019-05-20 22:15:12 +02:00
Henrik Friedrichsen
82e1e3d1c2 update bindings, indicate that saving a queue can overwrite playlist
closes #60
2019-04-20 14:53:25 +02:00
KoffeinFlummi
4c974a83f7 Use command system for queue saving 2019-04-18 15:43:04 +02:00
KoffeinFlummi
adba809327 Display saved/followed checkmark 2019-04-18 14:04:40 +02:00
KoffeinFlummi
210c7d9f4e Implement saved tracks, albums, and artists 2019-04-16 19:52:22 +02:00
Oscar Linderholm
5981b08458 Refactor the simplified playlist function 2019-04-10 14:04:09 +02:00
Henrik Friedrichsen
534ccc904f respect currently playing track when shifting queue entries 2019-04-07 14:14:56 +02:00
Henrik Friedrichsen
b72f560e5a implement moving of tracks in queue 2019-04-05 00:27:20 +02:00
Henrik Friedrichsen
d7848ec333 code formatting + minor refactorings 2019-03-28 05:42:47 +01:00
KoffeinFlummi
486bc7617e Refactor command handling 2019-03-28 03:05:25 +01:00
Henrik Friedrichsen
0e3c9fc504 use constants for listview IDs and search edit 2019-03-26 21:28:25 +01:00
Henrik Friedrichsen
4f8342da83 refactorial spring cleaning (cargo fmt + clippy) 2019-03-26 20:51:39 +01:00
Henrik Friedrichsen
e0f7b5c156 implement functionality to save queues to playlists 2019-03-24 16:33:39 +01:00
KoffeinFlummi
b7e0e87e44 Add scroll bar to ListView, remove ScrollView 2019-03-20 22:32:45 +01:00
Henrik Friedrichsen
da4f39ffba Merge branch 'keybindings' of git://github.com/KoffeinFlummi/ncspot into KoffeinFlummi-keybindings 2019-03-17 15:45:13 +01:00
KoffeinFlummi
5a85619105 Add rebindable keys, refactor lists 2019-03-17 04:29:29 +01:00
Henrik Friedrichsen
392e3efb87 turn off autorefresh and redraw only on demand
this should significantly reduce CPU usage but is a little bit more complicated.
while we're at it, remove the different screen redraw events and use a combined
event for all screens.

TODO:
the spotify player still needs to update the statusbar at least every second.
2019-03-09 01:55:55 +01:00
Henrik Friedrichsen
502ac36de3 get rid of the panel wrapper for more space
the screen title is now displayed by the layout
2019-03-07 22:34:45 +01:00
Henrik Friedrichsen
b075c96134 update current_track when tracks before the current one are removed
also:
don't use events to update the queue UI
this makes the Add/Remove queue events useless, but we'll keep them for now

hopefully fixes #22
2019-03-07 17:33:45 +01:00
Henrik Friedrichsen
0b14fc5da7 transform simple queue to a preserving, more complex kind
this is a pretty big but necessary change and might not be stable yet.

some key points:
- the queue is now responsible for playback controls and track management, as
this was scattered between the queue and spotify objects.
- because the queue is now retained, it should be easier to save it as a
spotify playlist

closes #12
2019-03-06 23:59:33 +01:00
Henrik Friedrichsen
7b4c40026a extract SplitButton from TrackButton for future PlaylistButton 2019-03-06 00:46:47 +01:00
Henrik Friedrichsen
91e89c2970 introduce track data class 2019-03-06 00:15:28 +01:00
KoffeinFlummi
7a24eca809 Add main layout view and status bar
Fix #4
2019-03-05 19:18:36 +01:00
Henrik Friedrichsen
9507add6a4 more refined queue events + playlist delete binding
- move from listview to linearlayout + scrollview
- doesn't redraw the whole view on queue changes anymore
- uses new cursive functions for linearlayout (needs cursive git)

closes #3
2019-03-04 00:56:34 +01:00
Henrik Friedrichsen
909ce8c81d cargo fmt 2019-03-03 15:53:54 +01:00
Henrik Friedrichsen
a562f0b7a7 implement custom track button view (closes #2) 2019-03-03 00:16:17 +01:00
Henrik Friedrichsen
d73a3c144e always trigger a cursive event when a queue event is generated 2019-02-27 23:12:09 +01:00
Henrik Friedrichsen
d3c439342a introduce global event sink to trigger updates across threads 2019-02-27 22:50:31 +01:00
Henrik Friedrichsen
bebc6175cc cargo fmt 2019-02-26 23:32:38 +01:00
Henrik Friedrichsen
204cb18410 implement preliminary queue view
this approach needs some (re)work, as the UI is not fully sync'd with the data,
yet. it'd probably be better to have an event system triggered by the queue,
that will cause a UI refresh or similar.
2019-02-26 23:30:16 +01:00