Commit Graph

374 Commits (8372ed4eea13a499cf3a82d45e78d07d9be5e276)

Author SHA1 Message Date
Christopher Snowhill b8a98e301e Metadata loading: Correctly merge over empty tags
Metadata versus properties merging, correctly merge over empty fields if
they are assigned with empty strings or zeroed numbers, instead of only
merging over completely missing fields.

Fixes emailed bug, CUE Sheet metadata reading, primarily.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-02-14 20:02:18 -08:00
Christopher Snowhill d7becdf01a Add a nil pointer check for metadata read
No idea if this is needed or not.
2022-02-11 06:00:36 -08:00
Christopher Snowhill bf88c57454 Minor artwork caching changes
Art ID should be set on new files when they are stored into the
database, and the album art property should be affected by assigning to
the artId property, since it affects the caching identifier.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-02-10 22:45:26 -08:00
Christopher Snowhill 740fdfa883 Attempt to wrangle memory usage from artwork
Now cache around NSData objects of individual pieces of album art,
unique by their byte contents. And the artwork image cacher will also
use the art ID keys from the database as the cache keys for NSImages,
so they'll not only be only read once per unique image, but also tracks
can have unique artwork per track, if the files so feature it.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-02-10 22:37:37 -08:00
Christopher Snowhill 2e52066293 Skip to next on trash, else stop playback
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-02-10 21:48:30 -08:00
Christopher Snowhill 2e1460f72d Only trash regular files
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-02-10 21:48:08 -08:00
Christopher Snowhill 5411a60ea1 Added option to remove tracks to the trash
Fixes #23

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-02-10 21:35:13 -08:00
Christopher Snowhill 39dcb88728 FFmpeg input: Support reading metadata
Where TagLib is not being employed, use FFmpeg to read tags where
possible. This allows reading tags from files like IFF. It reads it
through properties, otherwise allowing tag readers to function like
usual.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-02-10 15:29:13 -08:00
Christopher Snowhill 8f1143818b Replace playlist status icons with SF Symbols
On Big Sur and up only, of course.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-02-10 01:51:40 -08:00
Christopher Snowhill a4387dc6d1 Playlist now supports dragging tracks out of app
Playlist now supports dragging copies of URL references to other apps,
including Finder, and possibly other audio players. The chosen drag
operation is to copy files.

Fixes #75

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-02-10 01:32:09 -08:00
Christopher Snowhill 5330295a97 Fix array bounds issues with album shuffle builder
The shuffle list builder was encountering errors when some album tags or
empty album tags led to empty lists.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-02-10 01:14:42 -08:00
Christopher Snowhill df63726128 Track properties take priority over metadata read from tag readers
This allows inputs to override things with self-read tags and such, such
as ReplayGain tags.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-02-09 21:26:17 -08:00
Christopher Snowhill 64c4aa2e25 Handle deleting the current track gracefully
Now it should flow playback correctly to the next remaining track after
the block of deleted tracks. And if the user deletes the next queued
track, it will still be queued to flow past the deleted block. If the
user undoes their deletes and restores the tracks, playback will resume
after the originally deleted track.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-02-09 21:04:17 -08:00
Christopher Snowhill 7cea254f4c Implement framework for dynamic metadata updates
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-02-08 21:21:53 -08:00
Christopher Snowhill b927f4c02b Replace more NSDictionary use with literals
Use literals to initialize fixed NSDictionary objects in various places.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-02-08 19:56:04 -08:00
Christopher Snowhill 6120fce40a Metadata: Fix length field on track reloading
This fixes the dynamic length field not updating correctly after a track
info reload, which breaks the seekbar when reloading the current track.

Fixes #227

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-02-07 03:03:39 -08:00
Christopher Snowhill 95fb65527f Playlist Entry / SQLite: Add channel config field
Add channel config field to PlaylistEntry and the SQLite backing store.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-02-07 01:11:30 -08:00
Christopher Snowhill 85c7073649 Reformat my own source code with clang-format
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-02-06 21:49:27 -08:00
Christopher Snowhill 6d9f1be7ea Playlist Controller: Stop when deleting current
When deleting the currently playing track, stop playback, because the
player engine doesn't like dealing with the current playing track not
actually having a playlist reference to go with it. Better stop playback
instead, as a safety check.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-02-04 19:54:43 -08:00
Christopher Snowhill 85fd3836c0 Debug logging: Added logging of playback and tags
Added a logging method that indicates starting playback of a given URL,
and added a debug build only logging of every metadata load event.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-01-29 16:34:43 -08:00
Christopher Snowhill 2541633c17 Playlist Entry: Display full URL for remotes
For Playlist Entries that are not File URLs, return the full absolute
URL for path queries, so the playlist path column will show the full
URL instead of a useless reduced path string.

Fixes #214.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-01-27 00:11:14 -08:00
Christopher Snowhill d8b16e44c7 SQLite Store / Drag and Drop: Now correctly store changes made by dragging playlist entries around to the database 2022-01-24 06:07:13 -08:00
Christopher Snowhill 8e5c62f185 Info Inspector: Now displays ReplayGain info as tooltip for status text 2022-01-22 20:44:06 -08:00
Christopher Snowhill b54b10861b Playlist View: Enable column text tightening before truncation 2022-01-22 15:03:30 -08:00
Christopher Snowhill 5bf5830b17 Info Inspector: Now displays ReplayGain tag presence 2022-01-21 23:49:07 -08:00
Christopher Snowhill 9bfc51cbf4 Info Inspector: Add field to display whether a track has an embedded CUE Sheet 2022-01-21 23:19:32 -08:00
Christopher Snowhill 0c4d5002f6 Metadata: Now supports storing cuesheet tags and encoding quality status properties 2022-01-21 22:38:54 -08:00
Christopher Snowhill 2165d37144 Metadata: Now supports disc number field where possible 2022-01-21 21:49:17 -08:00
Christopher Snowhill bde3f552d9 Drag and Drop: Fixed jank with dragging, especially undo and redo 2022-01-21 16:11:24 -08:00
Christopher Snowhill 391fc474f3 Drag and Drop: Made DND undo possibly less janky 2022-01-21 15:00:27 -08:00
Christopher Snowhill 297b7b2909 Playlist View: Fix default sorting and playlist refreshing, which fixes playlist search bugging out 2022-01-21 00:16:29 -08:00
Christopher Snowhill 0f90dd3b3e Playlist View: Support undoing and redoing Drag and Drop operations within the playlist 2022-01-20 21:48:23 -08:00
Christopher Snowhill c07b268288 Playlist View: Adjust threshold for expansion tooltip assignment 2022-01-20 18:18:05 -08:00
Christopher Snowhill 4e918fc868 Playlist View: Refresh playlist entries when queue is emptied 2022-01-20 17:58:24 -08:00
Christopher Snowhill 973664f3b3 Playlist View: Correctly refresh playlist tooltips when queue is manipulated 2022-01-20 17:54:02 -08:00
Christopher Snowhill 7cc4ee22f7 Playlist View: Fix centering and sizing of status icons 2022-01-20 17:37:56 -08:00
Christopher Snowhill 8c63e8fde3 Playlist View: Now using monospaced numbers on all fields 2022-01-20 17:26:30 -08:00
Christopher Snowhill b317bfcdc2 Playlist View: Remove some bugs in the sizing 2022-01-20 17:02:34 -08:00
Christopher Snowhill db867c841c Playlist View: Add status tooltip to status icon 2022-01-20 15:54:40 -08:00
Christopher Snowhill a4c3509e75 Playlist View: Refresh entire rows on status changes to refresh tooltips 2022-01-20 15:51:24 -08:00
Christopher Snowhill b78e55a50c Playlist View: Fix status message tooltip 2022-01-20 15:39:29 -08:00
Christopher Snowhill 2b4de1033d Playlist View: Replace Cell-based table with View-based table. It needs some work still, though. 2022-01-20 14:59:26 -08:00
Christopher Snowhill 6f0f9d7617 Playlist Entry: Made copy contsructor proper 2022-01-20 14:54:42 -08:00
Christopher Snowhill ba5f5b8694 Playlist Entry: Made object copyable 2022-01-19 23:23:17 -08:00
Christopher Snowhill 684951bdc0 Change a bunch of NSArray declarations to const collection literals 2022-01-18 18:12:57 -08:00
Christopher Snowhill 74cd0f7da9 SQLite playlist store: Greatly improved performance of playlist sync operations 2022-01-14 22:42:57 -08:00
Christopher Snowhill d24a01a637 Implemented basic embedded CueSheet support 2022-01-14 16:46:35 -08:00
Christopher Snowhill 8a91bc1d09 Playlist loader: Allocate larger properties dictionary 2022-01-11 19:35:59 -08:00
Christopher Snowhill 7fe67b1630 Implement dock icon progress bar indicator for many processing operations, including adding tracks, removing tracks, and loading or reloading track metadata 2022-01-09 02:10:08 -08:00
Christopher Snowhill b40b506cc3 Remove unneeded header import 2022-01-07 02:16:55 -08:00