Commit Graph

1075 Commits

Author SHA1 Message Date
casey langen
9d662a73bf Disable thumbnail_id from AlbumListQuery for now -- need to figure out how
to address this issue efficiently.
2017-02-09 00:05:05 -08:00
Casey Langen
4c0f48fb9f Fixed macOS/clang compile. 2017-02-08 22:26:20 -08:00
casey langen
24c9ee8232 Added some private namespace to the SdkWrapper classes in MetadataMap and
MetadataMapList so they don't collide and confuse the runtime. Also fixed
AlbumListQuery to return distinct entries and updated CMakeLists.txt with
the new files.
2017-02-08 22:21:17 -08:00
casey langen
205f719c44 - Renamed IMetadataWriter -> ITrackWriter for clarity
- Added IMetadataMap, IMetadataMapList as a generic way to represent more
  complex types of metadata that aren't just simple { id, value } tuples
  -- for example, complex album information including an id, value,
  artist, and artwork info
- Added a new AlbumListQuery that can be used by the SDK to get a rich
  list of album information for display in a UI. (CategoryListQuery still
  supports albums)
2017-02-08 20:57:43 -08:00
casey langen
62c25d50a6 Make sure we notify remotes when shuffle status changes. 2017-02-07 23:22:04 -08:00
casey langen
ec3a1909b2 * Constified ITrackList methods and added ITrackList::GetTrack
* Modified a couple IPlaybackService method args to accept const
  TrackLists, instead of non-const
* Added IPlaybackService::GetTrackList to get a const reference to the
  internal tracklist.
* Modified NowPlayingLayout to use the PlaybackService's TrackList by
  const reference, instead of making a copy for every mutating operation.
* Fixed a nasty bug where PlaybackService::Shuffled could be broadcast on
  a background thread.
2017-02-07 22:31:39 -08:00
casey langen
978ad2ec9d Removed 'IMMNotificationClient' implementation of audio endpoint routing,
go with a polling method instead. There are bugs with
IMMNotificationClient with no apparent solution.
2017-02-07 19:20:00 -08:00
casey langen
2495fd97d4 A couple small playqueue editing related bug fixes. 2017-02-07 19:19:41 -08:00
casey langen
f88896d0ac Seed the random number generator on startup. 2017-02-05 23:10:25 -08:00
Casey Langen
3a9f69e097 Fixed clang (and hopefully gcc) compile. 2017-02-05 22:34:11 -08:00
casey langen
d8815a1a88 Added playlist editing to IPlaybackService -- it was already in the
implementation -- so just expose it to the SDK now.

Also implemented the missing ::Shuffle() and ::Clear() methods in the
playback service's editor.
2017-02-05 22:13:11 -08:00
casey langen
969934fb16 Fixed a deadlock in LocalLibrary 2017-02-05 22:12:43 -08:00
casey langen
aa64784128 Updated IPlaybackService (and impl) to allow the ability to set the play
queue from plugins.
2017-02-05 21:19:41 -08:00
casey langen
d91f05627a * Added ITrack::GetId() and renamed other Track*::Id() methods.
* Added the ability to query tracks by category in ISimpleDataProvider
2017-02-05 15:16:10 -08:00
casey langen
19c620fcbd * Started fleshing out ISimpleDataProvider interface, which is just a facade
plugins can use to access existing queries. Started implementing it
against the LocalLibrary in LocalSimpleDataProvider.

* Added musik::core::plugins that can be used as a centralized place for
initializing plugins with components they require, e.g. preferences and
data providers.

* Added some more constants to the SDK interface.
2017-02-05 13:32:09 -08:00
Casey Langen
2590d37e4b * Fixed clang compile.
* Removed the query template stuff from last night. Overly-complicated and not
  necessary.
* Renamed QueryBase to LocalQueryBase
2017-02-05 11:06:00 -08:00
casey langen
fb74bb3d1f Incremental work to support more generic query types.
* Parameterized the QueryBase on a ConnectionType.
* Re-namespaced IQuery and QueryBase to musik::core::db
* Removed IQueryPtr
* Added runtime type checking for query type in LocalLibrary. yeah, i
  know. don't tell anyone. but it ensures things are safe.
* Moved queries out of glue and back into core so they can be used by
  plugins to query metadata.
2017-02-05 01:45:16 -08:00
casey langen
eaa60205cc Ramped SdkVersion and fixed musikwin example. 2017-02-04 01:50:34 -08:00
casey langen
e4c1acca84 Added a couple new SDK interfaces -- IMetadataValue and
IMetadataValueList. Implement these interface in CategoryListQuery.

Also added TrackListQueryBase::WrappedTrackList so we can return track
query results to plugins efficiently.
2017-02-03 23:19:51 -08:00
Casey Langen
27bfa8fd3c Tweaked CMakeLists.txt to hush the deprecation warnings because they're getting
in the way. Will remove this once we get a new version of boost on macOS.
2017-02-03 18:13:25 -08:00
casey langen
e21fffac3d Added the ability for plugins to save preferences. 2017-02-03 18:04:29 -08:00
casey langen
bc87e4d28c Fixed a deadlock in PlaybackService when changing tracks from an IPlaybackRemote. 2017-02-03 08:13:28 +00:00
Casey Langen
482433e5da Fixed compiler warnings on macOS (and Linux) 2017-02-02 20:54:29 -08:00
Casey Langen
85913132e3 Return genre, artist, album, and album_artist ids in track queries. 2017-02-02 20:52:34 -08:00
casey langen
5b9338c61e * Fixed a bug where queries may be enqueued into the library during
shutdown, and run after calling components have been destroyed.

* Fixed a bug in PlaybackService where the "ModeChanged" event wasn't
getting called after shuffling, and sometimes not on the MessageQueue
thread.
2017-02-01 23:22:31 -08:00
casey langen
7721f7d412 Added configurable hotkeys for play queue playlist operations. 2017-01-28 23:14:14 -08:00
casey langen
2ff3f3cc78 Ensure that focus status is taken into account properly when re-creating
windows and setting their colors.
2017-01-28 14:02:00 -08:00
Casey Langen
06b10b36f3 Updated changelog. 2017-01-28 11:47:17 -08:00
casey langen
3c75ab2a3d An attempt to work around an impossible-to-reproduce bug in PulseOut. It seems that sometimes setting the stream volume doesn't work immediately, maybe because the stream isn't ready. Or maybe due a floating point rounding error. 2017-01-28 08:38:39 +00:00
Casey Langen
bf18797b26 Updated changelog and bumped version. Will release after more testing (and any
required bug fixes).
2017-01-27 09:20:40 -08:00
Casey Langen
18faa2056d Added an error dialog when trying to edit an empty list of playlists. Also
added the ability for the save playlist dialog to pre-select a playlist by id.
2017-01-27 09:10:29 -08:00
casey langen
fe4869e673 - Ensure that playlist tracks are properly cleaned up when tracks are
removed from the library
- Fixed a super old bug in PlaybackService where playing a deleted file
  could crash or cause other strange problems.
- Updated win32 build files for the DeletePlaylistQuery
2017-01-26 23:05:41 -08:00
Casey Langen
3d4bf9e4a4 Added playlist deletion queries and basic UI. 2017-01-26 22:50:27 -08:00
casey langen
715a58f2d1 Removed "esc focuses shortcut bar" setting. No use turning it off anymore. 2017-01-26 22:26:13 -08:00
casey langen
1dfd14911c - Fixed Windows compile
- Fixed new playlist creation
- Added a confirmation dialog when replacing a playlist
2017-01-26 19:29:20 -08:00
Casey Langen
879df9321d - Implemented playlist renaming
- Standardized PlayQueueOverlay widths for all overlays
- Fixed TextInput::SetText() to set the cursor at the proper position
2017-01-26 18:45:26 -08:00
Casey Langen
de859a7f7a Added proper playlist creation and replacing. 2017-01-26 18:24:15 -08:00
Casey Langen
1f0139c5cd - Updated SDK version, added IPlaybackService::GetPlayingTrack()
- Added PlaybackService::GetPlayingTrack and PlaybackService::GetPlaying to get
  an IRetainedTrack or TrackPtr to the currently playing track, respectively.
- Fixed PlaybackService::CopyFrom() to correctly discover the playing track and
  queue up the next one, if applicable. Else queue up the first track
- Fixed NowPlayingLayout to use PlaybackService::GetPlaying() to resolve the
  currently playing track.
2017-01-26 08:46:06 -08:00
Casey Langen
e778c6034d Added basic code for saving a playlist. Need to support updating and renaming
next.
2017-01-26 00:10:18 -08:00
casey langen
85eb56b74e - Updated code to use a couple constants (ListWindow::NO_SELECTION and
CURSESPP_DEFAULT_COLOR) instead of a bunch of inline (size_t)-1 and -1LL
  values throughout the code.
- Updated win32 project files.
2017-01-25 21:19:29 -08:00
Casey Langen
9b7a078348 - Fixed some global focus (and focus styling issues) by introducing special
color pairs for the focused state for both the frame and content views
- Tweaked App.cpp to ensure newly focused windows have Focus() called, and
  previously focus windows have Blur() called.
- More fixes to InputOverlay -- it's pretty much functional now.
- Fixed bug in LayoutBase where child windows weren't properly getting their
  windows reset to null when the parent is destroyed.
- Various other small fixes that were fallout from the focus cleanup.
2017-01-25 18:28:50 -08:00
casey langen
545d179873 Fixed win32 compile, and a couple small bugs. 2017-01-25 07:42:15 -08:00
Casey Langen
5c4ef10f5f * Added InputOverlay.h/cpp. Still doesn't draw completely correctly.
* Added support for item deletion in ListOverlay. generally untested
* Fixed lastPlaylistId initialization in NowPlayingLayout
2017-01-24 23:05:05 -08:00
Casey Langen
3331e91d12 More incremental work to support loading playlists into the play queue.
A playlist can be selected from a list, and it will replace the current queue.
2017-01-24 21:42:35 -08:00
Casey Langen
5f78e4eb97 Modified CategoryListQuery also support playlist. Added a (probably temporary)
PlayQueueOverlay for loading playlists. this functionality will likely be
rolled into a category list view next to now playing.
2017-01-24 11:39:47 -08:00
casey langen
cd6b3a8f72 Renamed StreamPtr -> IStreamPtr, LibraryPtr -> ILibraryPtr 2017-01-23 20:47:08 -08:00
Casey Langen
7c800ff817 Add new RowDecorator to TrackListView, with a default implementation. Added
a custom implementation to NowPlayingLayout to make sure the actively playing
instance is highlighted, instead of all tracks that have the same ID.
2017-01-23 07:52:49 -08:00
Casey Langen
a44c7c76a3 Fixed a crazy old bug in SettingsLayout when trying to add/remove an empty
directory in the settings screen.
2017-01-22 21:46:06 -08:00
casey langen
07bc12d283 Cleaned up a couple more play queue editor issues related to prefetching
the next track, if the next track is already prefetched and an edit
operation changed the next track's position.
2017-01-22 21:35:40 -08:00
Casey Langen
8d9fd8fd09 Fixed play_queue_move_down constant. 2017-01-22 21:15:34 -08:00