Commit graph

51 commits

Author SHA1 Message Date
Joshua Strobl
2bf5aa9388 Have visual track number start at 1 and not 0 in playlist page. 2021-06-29 13:08:50 +03:00
Joshua Strobl
269f422b63 Fix path fetching for Tracks. 2021-06-29 12:57:52 +03:00
Joshua Strobl
44e4564f1c Implement mutli-Library support.
Honestly, not going to bother summarizing this massive changeset. You are welcome to look it over in your own free time.

Fixes #10. Fixes #11
2021-06-22 16:48:13 +03:00
Joshua Strobl
8d823dbbec Add our Dev Diary 9 from end of May. 2021-06-22 13:44:39 +03:00
Joshua Strobl
a11ba1ec77 Separate out our functionality for reading from the database into db/loaders. 2021-06-01 13:10:18 +03:00
Joshua Strobl
7c7fe35b49 Implemented library hashtable, added / removed signals into Cartographer, add / remove / getters (ish).
Added KOTO_IS_CARTOGRAPHER macro and added that type check across all cartographer functions. Added more type checks and dropped use of g_object_get for UUIDs where possible.

Implemented koto_album_get_uuid function to be on parity with other structs like Artist, Playlist, Track.
2021-06-01 12:58:23 +03:00
Joshua Strobl
fc670e266f Fix title in README 2021-05-27 17:38:34 +03:00
Joshua Strobl
e4d6f9b9ef Fix image 2021-05-27 17:38:05 +03:00
Joshua Strobl
c2d34fdf86 Update README 2021-05-27 17:36:01 +03:00
Joshua Strobl
68c1a8eda0 Implement setter in Create Modify Dialog, mostly to remove the TODO. 2021-05-27 17:15:20 +03:00
Joshua Strobl
bfe4891620 Start cleanup of KotoLibrary logic and decoupling other components like Music Local from a specific library.
Fix the displaying of discs and tracks in an album on initial index due to missing cartographer add track call.

Cleanup lots of double empty newlines. Updated ptr spacing in uncrustify config to enforce consistency in pointer char (`*`) spacing.
2021-05-27 17:02:19 +03:00
Joshua Strobl
8334323af8 Implement support for dedicated theme CSS files from our gresource.
Properly implement light and gruvbox themes. Yay!
2021-05-27 15:47:45 +03:00
Joshua Strobl
4cc5c6efd4 Apply formatting 2021-05-27 13:03:24 +03:00
Joshua Strobl
fa19fd23b1 Implement TOML-based configuration support leveraging tomlc99 and custom file writer.
Fix code related to changing from temporary playlists to permanent ones.

Implement new centralized Koto Paths for defining our variables and revdns name for consistency.

Updated Album View to leverage KotoCoverArtButton component.

Started refactoring our theming to support multiple variants. It isn't where I want it yet but we'll get there.
2021-05-27 12:56:36 +03:00
Joshua Strobl
9f0e8dfbc8 Rename all KotoIndexed* to Koto*, KOTO_INDEXED_ to KOTO_, etc. Fixes #9. 2021-05-11 20:08:39 +03:00
Joshua Strobl
62de9c2032 Get to the point where we are fairly happy with our uncrustify config. Fixes #6. 2021-05-11 20:05:04 +03:00
Joshua Strobl
d07d3dfe50 Remove libnotify includes 2021-05-11 18:37:34 +03:00
Joshua Strobl
3e0e21e246 Implement Notification support. Fixes #8.
Implemented Notification support using notify-send as opposed to libnotify. This is because notify_notification_send does a synchronous dbus call to org.freedesktop.Notification and typically results in DBus timeouts. In the near future we will rewrite this to just use our own proxy and do an async send.

Refactored our GVariant metadata generation for a KotoIndexedTrack into a dedicated koto_indexed_track_get_metadata_vardict function. This can then be used across our playback engine and MPRIS.
2021-05-11 18:31:13 +03:00
Joshua Strobl
a3632b8757 Implement modified signal for playlist and hook it into nav and playlist page.
Fixes #4.
2021-05-11 14:43:20 +03:00
Joshua Strobl
b4ffba62c7 Implement koto_utils_is_valid_string to replace repetitive NULL and g_strcmp0 code.
Reduce usage of g_return_if_fail since it results in unnecessary warnings.
2021-05-07 21:57:21 +03:00
Joshua Strobl
0aafa68a35 Update README with latest blog post. 2021-05-07 19:26:12 +03:00
Joshua Strobl
0e2244ba90 Implement Playlist functionality. My god...
Too many changes to summarize.

- Fixes #2.
- Fixes #3.
- Fixes #5.
- Fixes #7.

Start work on uncrustify config.
2021-05-07 16:47:47 +03:00
Joshua Strobl
ddf1987b50 Support custom launch configurations
Added GDB and non-GDB Koto launching so I can stop using GNOME Builder.
2021-04-20 05:35:32 +03:00
Joshua Strobl
f2164b2ade Start work on playlist creation dialog
Started work on the playlist creation dialog. To facilitate my desired UX for dialogs, I changed the immediate child of KotoWindow to being a GtkOverlay, with the "child" being the primary layout GtkBox and the "overlay" being any active dialog.

There is no background on the dialogs yet, or really anything meaningful in it besides the GtkImage to show the playlist image as well as a GtkEntry for the label. Upon clicking the image, you will be presented with a GtkFileChooserNative, which will allow us to support various platforms aside from Linux (if we desire) but more importantly support desktop portals and the appropriate picker for each desktop environment.

This dialog is currently hooked into the + button in the Playlist nav section.

The intent is to also support drag-and-drop when possible, so you can drag an image file onto the GtkImage for it to set it to the playlist image.

Fixed various compiler warnings, such as:

- Unused variables (cast these as void so compiler knows to ignore them).
- Use g_hash_table_add instead of g_hash_table_insert since value does not matter and will complain about not casting TRUE as a pointer.
- Fixed some casting.

Fixed up Desktop file and fleshed out Appstream data. Use validate-relax in the appstream test or it gets cranky about screenshots missing. I know...the app is not ready yet. Get over it AppStream.

Added Visual Studio Code tasks and some C/C++ Extension setting files.
2021-04-07 13:17:33 +03:00
Joshua Strobl
e18b8ca100 Implement GNOME Settings Daemon MediaKeys handling.
Clean up some warnings.
2021-04-06 15:35:01 +03:00
Joshua Strobl
43ebe6d041 Implement explicit functions for setting track repeat and shuffling in KotoPlaybackEngine.
Use these new functions as well as new signals to simplify toggle state in playerbar, as well as ensure changes over MPRIS allow for the updating of our UX.

Implement method handlers and relevant setters for MPRIS support, as well as a koto_update_mpris_playback_state used to notify on state changes.

Clean up some debugging.
2021-04-06 13:56:29 +03:00
Joshua Strobl
07c3c00f1e Implement mimetype support reporting for MPRIS, start implementation of bulk of getters.
Implemented the following getters for MPRIS:

- CanQuit
- CanRaise
- HasTrackList
- Identity
- DesktopEntry
- SupportedUriSchemas
- SupportedMimeTypes
- Metadata
- CanPlay / CanPause / CanSeek
- CanControl
- PlaybackStatus

Implemented a koto_push_track_info_to_builder function that enables us to easily push KotoIndexedTrack as well as associated album and artist info to a GVariantBuilder for use in a GVariant for various getters.

Implemented a koto_update_mpris_info_for_track function that emits a signal for PropertiesChanged + "Metadata" when our track info changes.
2021-04-06 10:45:11 +03:00
Joshua Strobl
b1f4460a2e
Add Feb. (B-side) and March (A-side) links 2021-04-06 00:19:09 +03:00
Joshua Strobl
6849e6e4d4 Handle more handlers for the Playerbar progress scrolling / mouse related events.
Implemented playlist shuffling and repeat toggle button functionality.

Swapped out a considerable amount of NULL checks for proper KOTO_IS_BUTTON and GTK_IS_VOLUME_BUTTON macro checks.

Implemented GQueue played_tracks add / removal functions for KotoPlaylist, ensure randomizing works properly.

Start work on MPRIS.
2021-03-30 22:34:15 +03:00
Joshua Strobl
d957311d75 Implement seeking, volume control, artwork and track info updating 2021-03-25 17:29:45 +02:00
Joshua Strobl
05d90afc58 Implement start of Playback Engine, refactored most classes to leverage KotoCartographer, etc. 2021-03-23 19:50:09 +02:00
Joshua Strobl
a77efdb0aa Implement our global KotoCartographer class to enable easy reference, lookups, storage of various Koto classes. 2021-03-16 11:04:04 +02:00
Joshua Strobl
b6db2003b8 Rename KotoIndexedFile and "files" to KotoIndexedTrack and "tracks" 2021-03-16 08:51:35 +02:00
Joshua Strobl
cf81682f8c Start implementing Playlist functionality via KotoCurrentPlaylist and KotoPlaylist.
Implement functionality for gracefully showing the play button on top of KotoAlbumArt images. Implemented a new koto_indexed_album_set_as_current_playlist function for setting an album as the current playlist, useful when clicking to play an album via its artwork.
2021-03-10 13:44:08 +02:00
Joshua Strobl
35762ca233 Implemented clearer database functions and response codes so we know when to do library indexing.
Implement reading of artists, albums, and tracks. Fixed a bug related to unnecessary file name parsing. Fix SIGSEGV related to file name parsing and koto_utils_get_filename_without_extension.

Implemented an unquote string function for use when reading database entries. Try to fix some weird random rendering issues. Changed where we are doing some KotoPageMusicLocal widget construction.
2021-03-09 11:45:44 +02:00
Joshua Strobl
7566fb39f9 Consolidate indexer struct header definitions, implement artist, album, and file inserts.
Tweaked database schema. Ensure we enable FOREIGN KEYS.

Refactored how and when we are doing cover art and track fetching for an album.
2021-03-02 19:12:12 +02:00
Joshua Strobl
8f50d388bd Fix 4K res. 2021-02-27 18:00:45 +02:00
Joshua Strobl
aca24f3281 Refine window setting so we at the very least set 1300 on 1366x768. 2021-02-27 17:53:59 +02:00
Joshua Strobl
eac4940c77 Start implementation of database functionality, starting with table generation.
This database will be stored in the user's XDG_DATA_HOME directory under a folder called `com.github.joshstrobl.koto`.

Refactored Koto Track Listing into a dedicated Disc View component, break apart out CDs / Discs into relevant Disc View components, sorting them by the disc and showing a label if there are more than one discs / CDs.

Started using the row-activated event for our Artist GtkListBox instead of having press events on the artist buttons. Makes switching between artists far more reliable. Added a slide left / right stack animation and set its animation to 400ms so it's in the goldilocks zone (IMO) of not being too fast or too slow.

Fix a warning related to scale factor fetching in the PlayerBar.
2021-02-27 17:26:24 +02:00
Joshua Strobl
134b4d79a8 Add Dev Diary 2 to blog list 2021-02-25 18:21:47 +02:00
Joshua Strobl
56dd6b45b4 Convert from CSS to SCSS. Make a multitude of refinements to styling along the way.
Remove unused glade UI file. Added CSS classes to various components. Fix some alignment issues. Renamed our albums_strip to favorites_list.

Implement recursive file parsing in KotoIndexedAlbum with the intent of using it for "discs" / CD, useful for albums like Foo Fighters: In Your Honor that have 2 or more CDs. Still need to work on refining this further.

Add stub function in our album view for a planned separation of the track listing so we can do it based on discs and other depth-of-3 sub-folders.
2021-02-25 18:19:26 +02:00
Joshua Strobl
588a68b2cc Port to GTK4, start implementation of Local Music view, Artist and Album Views. 2021-02-24 20:17:18 +02:00
Joshua Strobl
8948a8ec9f Bump meson requirement to 0.57, drop most of postinstall for new gnome module functions 2021-02-16 23:18:23 +02:00
Joshua Strobl
304c7635da Implemented ID3 tag parsing in our KotoIndexedFile leveraging taglib, refactored our mimetype code.
Implemented KotoIndexedArtist as well as KotoIndexedAlbum, including moving the file indexing capabilities into the KotoIndexedAlbum (subject to change).

Added g_debug messages instead of using g_message for debug purposes. Re-introduced Koto Utils with new koto_utils_get_filename_without_extension, since that is used to get the extensionless file name across both album fetching and base file name fetching.
2021-02-16 17:15:10 +02:00
Joshua Strobl
9b6fa4593a Deprecate KotoFlipperButton, integrate flip functionality with an alt image into KotoButton.
We are now leveraging KotoButton in the KotoPlayerBar and KotoExpander. Dropped Glade UI templating from KotoWindow, set its default size using gtk_widget_set_size_request to force a minimum window size, set window title, WMClass, and icon name.

Start implementing KotoIndexedFile class to handle our provided audio files, setting its file name and attempting to parse the file name when we are not using ID3 data. The parsing is as follows:

- All `_` are replaced with whitespace
- We will attempt to remove nested references to the artist and album name (we need to implemented the relevant classes to leverage that).
- Remove any references to ` - ` followed by any stragglers `-` (without the whitespace around it).
- Split based on `.` and remove the trailing file extension, preserving the rest (so something like `Ch. 01.ogg` would be considered just `Ch. 01`).
2021-02-12 13:04:00 +02:00
Joshua Strobl
625c1be645 Update funding to include liberapay. Remove some commented out code. 2021-02-10 19:13:43 +02:00
Joshua Strobl
6fb3852f09 Work leading up to and including Day 4.
- Initial window bits
- Preliminary Nav sidebar
- Expanders
- Koto Button to reduce code duplication
- Started work on indexer
2021-02-09 17:37:26 +02:00
Joshua Strobl
9aa493c51a Fix license file. Fixes #1. 2021-02-01 07:02:28 +02:00
Joshua Strobl
c30eb09c12 Fix dev diary 1 link. 2021-01-25 17:28:58 +02:00
Joshua Strobl
c91b8a3709
Created our funding.yaml file 2021-01-25 17:01:17 +02:00