Commit Graph

3693 Commits (1ef7853488545c1e90a2f1c793a2fd2565f03433)

Author SHA1 Message Date
Christopher Snowhill 9d559481d3 [Sandbox] Disable distributed iTunes notification
This notification can't escape the sandbox anyway, and I forgot to
remove it after adding the app sandbox code again.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-06-20 16:43:21 -07:00
Christopher Snowhill 9dbe0a0d3e Updated VGMStream to r1745-33-gbb2a6624
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-06-20 16:22:07 -07:00
Christopher Snowhill 3153159658 [Sandbox] Make Sandbox prefer the longest path
The Sandbox Broker should prefer the token with the longest matching
path, not the shortest.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-06-20 16:16:04 -07:00
Christopher Snowhill f85c86c5ba Fix update_feed.rb for new Sparkle
New Sparkle appcast generator stores the version string in the item
rather than as an attribute of the entities.
2022-06-20 05:18:38 -07:00
Christopher Snowhill 08107f4a41 [Sparkle] Updated to version 2.1.0 for Sandbox
Sandbox requires Sparkle version 2 or newer anyway, so upgrade it.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-06-20 03:46:36 -07:00
Christopher Snowhill c23bece62c Reintroducing App Sandbox, and more
- Implemented App Sandboxing in a more friendly manner.
- All sandboxed paths will need to be set in Preferences. Set as loose
  a path as you want. The shortest path will be preferred.
- Removed Last.fm client support, as it was non-functional by now,
  unfortunately. Maybe something better can come in the future.
- Added support for insecure SSL to the HTTP/S reader, in case anyone
  needs streams which are "protected" by self-signed or expired
  certificates, without having to futz around by adding certificates to
  the system settings, especially for expired certificates that can't
  otherwise be dodged this way.

If you want to import your old playlists to the new version, copy the
contents of `~/Library/Application Support/Cog` to the alternate sandbox
path: `~/Library/Containers/org.cogx.cog/Data/Library/Application `...
...continued...`Support/Cog`. The preferences file will migrate to the
new version automatically.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-06-20 03:35:29 -07:00
Christopher Snowhill 8009d911c2 [Crashlytics] Remove unnecessary extra log sending
The log sending should be automatic, this is unnecessary.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-06-19 21:48:33 -07:00
Christopher Snowhill e071b4d913 [Crashlytics] Remove AppCheck from debug builds
Remove the AppCheck code from the debug builds, as it's not even enabled
on the project in Firebase anyway.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-06-19 21:46:30 -07:00
Christopher Snowhill 071d23b1c6
[SceneKit Visualization] Refine blocklist again
* Remove exception variable setter

Remove SceneKit crash variable setting exception
handler from NSApplication delegate.

* Restrict SceneKit to 10.13, 10.14, and 11.0+

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-06-19 21:42:39 -07:00
Christopher Snowhill 385335b37c [Core Data Storage] Refine deleted/empty items
Remove empty items also with empty URL fields.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-06-19 20:04:30 -07:00
Christopher Snowhill 2563125ec5 [SceneKit Visualizer] Refine blocklist
The blocklist wasn't actually blocking the requisite GPUs properly.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-06-19 20:03:47 -07:00
Christopher Snowhill a2a75d6565 [MAD Decoder] Add support for FhG VBRI headers
This header type was missing, causing some Fraunhofer VBR MP3 files to
decode the wrong length information.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-06-19 19:40:40 -07:00
Christopher Snowhill 453e29b2f5 [MAD Decoder] Patch a slight bug in libmad
There was a slight bug with handling Xing/LAME headers with main data
pointers indicating data preceding the header frame. This should allow
decoding their information properly.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-06-19 18:26:18 -07:00
Christopher Snowhill 163ae5c864 [Core Data] Optimize queue and shuffle loading
Optimize queue loading code, and add shuffle list reading code.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-06-19 02:05:26 -07:00
Christopher Snowhill 8962403e2a [Playback Controller] Remove blank line
Remove a blank line in the code, for no real reason, other than
tidiness.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-06-19 01:43:35 -07:00
Christopher Snowhill 8306bd31f4 [Playback Controller] Reformat metadata handler
Metadata notifier should have been reformatted to use the properties as
dotted members, and also check for empty strings.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-06-19 01:43:08 -07:00
Christopher Snowhill 7fcfdb373b [Playback Status] Remember last play position
Remember last play position in the playlist, rather than using an index
variable to store its position and play time. Still store whether the
player was last playing in a configuration variable, though.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-06-19 01:42:27 -07:00
Christopher Snowhill cd14377dcd [Now Playing Spam] Don't crash if nothing playing
Don't crash on now playing spam hotkey if no track is currently playing.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-06-19 00:20:40 -07:00
Christopher Snowhill c2388d2659 [Localizations] Remove or rename obsolete files
Remove or rename obsolete English.lproj files, renaming where
en.lproj does not already exist, or removing if en.lproj has
already replaced it.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-06-19 00:03:09 -07:00
Christopher Snowhill 636fefaf6f [ReplayGain Info] Info strings are now localized
The strings are now part of the localized strings storage, which is
still awaiting a volunteer to add more translations to the app.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-06-18 23:45:18 -07:00
Christopher Snowhill a0a5106e51 [Play Counts] Now correctly reports last seen time
Correctly reports last seen time, instead of reporting the first seen
time twice.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-06-18 23:44:29 -07:00
Christopher Snowhill 1c36869e57 [Audio Threads] Remove unused code
This code turned out to be somewhat of a mistake to employ, so it's now
being removed, and shall not be re-added, as it doesn't really work.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-06-18 23:02:24 -07:00
Christopher Snowhill 84d0cbee3c [Playlist Controller] Remove unused function
Remove a leftover function from previous code.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-06-18 23:01:11 -07:00
Christopher Snowhill 901ba8d218 [AppleScript Automation] Rename Playlist member
Rename this class member to match the current interface design.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-06-18 23:00:49 -07:00
Christopher Snowhill a2d8e0ec42 [Track Info] Add play count tabulation and display
Add play count data collection, including first seen times for every
file first added to the playlist. Data is indexed by album, artist, and
title, or by filename, whichever matches first. Add interfaces to
AppleScript automation definition as well.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-06-18 23:00:08 -07:00
Christopher Snowhill 404d354918 [Playback Notifications] Fix empty hyphen on tags
This change needed to be applied in two places, oops, forgot the modern
macOS case.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-06-18 19:03:25 -07:00
Christopher Snowhill 3a1599d22e [Playback Notifications] Oops, fix breakage
That change broke notifications. Reverting.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-06-18 19:02:10 -07:00
Christopher Snowhill 8cb46b4f15 [Legacy SQLite Store] Handle errors with database
Handle missing track items in the databse more gracefully, by deleting
the track entries before passing them on to the caller, so problems do
not occur later.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-06-18 18:41:14 -07:00
Christopher Snowhill 7cad442b73 [Localization] Fix another unlocalized string
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-06-18 18:26:42 -07:00
Christopher Snowhill 20904cf2c4 [Playback Notification] Prevent sending blank tags
Prevent the notification balloons from displaying empty hyphens or tags
if either album or artist is empty but not nil.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-06-18 18:20:12 -07:00
Christopher Snowhill b01924e10e [SceneKit Spectrum] Added device name to logging
Device name logging is essential in determining if crashes are on
specific device models that haven't been blocklisted.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-06-18 18:14:25 -07:00
Christopher Snowhill 41d4c7458e [Translations] Load PlaylistEntry error messages
These error messages should be loaded from the main bundle, where the
class is located.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-06-18 16:16:43 -07:00
Christopher Snowhill ecb30dd734 [Translation Support] Update strings a bit.
Update the strings, and remove the comments where they won't be used.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-06-18 16:10:18 -07:00
Christopher Snowhill 1c2ecc1c7c [Playlist] Handle invalid files in a better way
Invalid files may include nil URLs, which should be skipped or stop
playback altogether. Invalid files will be marked as an error, and
stop playback.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-06-18 16:09:41 -07:00
Christopher Snowhill 54b102f09e [Playlist] Fix refresh handling range
Apparently, somehow, indexes in obscene ranges hit this code, and cause
exceptions. Strange.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-06-18 15:50:25 -07:00
Christopher Snowhill 4a269f05a1 [Audio Threads] Remove workgroup code
As it doesn't seem to work properly on Intel machines, anyway. It just
leads to pointless crashes, and doesn't seem to serve any purpose.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-06-18 15:43:40 -07:00
Christopher Snowhill 3156aad9e1 [Audio Threads] Restrict workgroup use to macOS 12
Restrict the use of workgroup joining and workgroup intervals to macOS
Monterey or newer, as it seems the way I use it, it's completely broken
on macOS Big Sur, which was the original minimum target for the API.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-06-17 22:39:00 -07:00
Christopher Snowhill 88b7cd6352 [Crashlytics] Added logging of track events
Added logging of track metadata load and track playback events, to aid
with crash logging.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-06-17 22:34:51 -07:00
Christopher Snowhill fe0c388ec7 Touched by Xcode
This resource file was touched by the resource editor and altered.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-06-17 22:16:45 -07:00
Christopher Snowhill 711c18a3bd [SceneKit Spectrum] Add device block list
Currently blocking all Radeon cards up to and including Polaris cards.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-06-17 22:16:20 -07:00
Christopher Snowhill cbcbdf893d [Spectrum Visualizer] Add crash check for SceneKit
The SceneKit visualizer now has a crash check, which will trigger if an
exception is thrown by the app.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-06-17 22:15:14 -07:00
Christopher Snowhill fda16cc401 [Mini Window] Remove NSToolbar subclass definition
The Mini Window had its toolbar set to a non-existent class. Removed.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-06-17 22:00:26 -07:00
Christopher Snowhill 8acd7fb8f6 [Crashlytics] Add AppCheck for debugging builds
Enable Firebase AppCheck in debugging builds, so that more info may be
logged.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-06-17 19:18:41 -07:00
Christopher Snowhill 82e3f7bd9a [Crashlytics] Enable data collection by default
Enable data collection by default, so crashes are hopefully logged.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-06-17 19:18:05 -07:00
Christopher Snowhill fa177fe96c [Audio Threads] Make work interval name unique
Work interval names should be unique. Apparently they are deduplicated
based on their names?

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-06-17 18:04:42 -07:00
Christopher Snowhill e334d8a017 [Audio Threads] Apply changes to workgroup handler
Apply changes to exit the thread if workgroup initialization or joining
fails, instead of attempting to continue executing the thread.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-06-17 18:02:32 -07:00
Christopher Snowhill 4b4776fbc0 [Shuffle Function] Make album predicate exact
Make the album match predicate an exact match, rather than using the
"like" operator, in case there's a speed up from doing so.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-06-17 17:25:42 -07:00
Christopher Snowhill e9b02d54f4 [Core Storage] Apply index sort to fetch request
Apply the index sort to the fetch request itself, rather than applying
it to the resulting array afterward.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-06-17 17:20:45 -07:00
Christopher Snowhill cad6ddac02 [Shuffle Function] Greatly optimize list generator
The list generator now selects only a list of unique album names, which
may include empty string as well as NSNull, so filter those as well.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-06-17 17:03:50 -07:00
Christopher Snowhill 9820571a94 [Shuffle Function] Rewrite query for Core Data
Rewrite the album filter function to apply the filter predicate against
Core Data directly, which also requires filtering out deLeted entries so
they don't end up in the results, and also requires sorting the results.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-06-17 17:02:24 -07:00