Commit Graph

20 Commits

Author SHA1 Message Date
Anna Schumaker 9ba4dbc218 Updates for recent library changes
This fixes the gui, deck, and audio code due to the library changes I
just did.

NOTE: Library updating callbacks have been disabled in the gui.

Signed-off-by: Anna Schumaker <Anna@OcarinaProject.net>
2014-05-24 13:07:54 -04:00
Anna Schumaker 59220cc2ce tags: Add Track->played()
This function is called to increment play count and set "date last
played" variables.  Moving this into the Track class lets me remove an
internal callback and a few other unnecessary functions.

Signed-off-by: Anna Schumaker <Anna@OcarinaProject.net>
2014-05-23 21:53:36 -04:00
Anna Schumaker d939dcab20 queue: Begin code updates
So far I have renamed variables, changed a few functions, and updated
all the code that was affected.

Oh, I also started a new unit test.

Signed-off-by: Anna Schumaker <Anna@OcarinaProject.net>
2014-04-13 12:27:15 -04:00
Anna Schumaker 1c743239a0 Rename playqueue -> queue
Signed-off-by: Anna Schumaker <anna@ocarinaproject.net>
2014-04-09 21:10:08 -04:00
Anna Schumaker 0e4c05350a gui: Implement tab reordering
And prevent tabs from being moved into the perma-tab area.

Signed-off-by: Anna Schumaker <schumaker.anna@gmail.com>
2014-04-06 19:57:02 -04:00
Anna Schumaker 7dc57572aa deck: Pass a random-enabled flag when creating playqueues
Signed-off-by: Anna Schumaker <schumaker.anna@gmail.com>
2014-04-06 19:57:02 -04:00
Anna Schumaker a98443872c deck: Save the deck whenever a queue changes
I read in the saved file when init() is called.

Signed-off-by: Anna Schumaker <schumaker.anna@gmail.com>
2014-04-06 19:57:00 -04:00
Anna Schumaker 74da7beba1 deck: Add a library playqueue
When no songs are on the deck a track will be played from the library.

Signed-off-by: Anna Schumaker <schumaker.anna@gmail.com>
2014-04-06 19:56:58 -04:00
Anna Schumaker 1d559865c8 deck: Updates for the playlist -> playqueue renaming
Signed-off-by: Anna Schumaker <schumaker.anna@gmail.com>
2014-04-06 19:56:57 -04:00
Anna Schumaker b8b215be35 deck: Save and restore the playlist deck
The read and write functions will be called by a higher up layer, so I
need to open the file manually in the test.

Signed-off-by: Anna Schumaker <schumaker.anna@gmail.com>
2014-04-06 19:56:56 -04:00
Anna Schumaker 83a8b5ae1d deck: Implement next()
I make sure to remove empty playlists from the deck and throw an error
if there are no playable tracks on the deck.

Signed-off-by: Anna Schumaker <schumaker.anna@gmail.com>
2014-04-06 19:56:56 -04:00
Anna Schumaker fecc10ab5e deck: Implement basic deck features
- Add playlists
- Remove playlists
- Rearrange playlists
- Get a playlist based on id

Signed-off-by: Anna Schumaker <schumaker.anna@gmail.com>
2014-04-06 19:56:56 -04:00
Bryan Schumaker 101648dc0a Remove old include files
I'm going to replace them with new files for Ocarina 6.

Signed-off-by: Bryan Schumaker <bjschuma@gmail.com>
2014-04-06 19:56:51 -04:00
Bryan Schumaker acb0334122 libsaria: Move deck::next() to deck.cpp
And extra variables / functions needed by next().

Signed-off-by: Bryan Schumaker <bjschuma@gmail.com>
2012-11-18 12:03:26 -05:00
Bryan Schumaker 3a486082af libsaria: Move recent playlist to the new deck file
I also created a new playlist flag for unique playlists so I don't need
to handle this elsewhere.

Signed-off-by: Bryan Schumaker <bjschuma@gmail.com>
2012-11-18 11:45:10 -05:00
Bryan Schumaker b091df8ec4 libsaria: Load playlists to a new playlist_deck vector
The vector should be simpler than a linked list for tracking playlists.
I also changed reading playlists to use a function in the playlist class
rather than a function outside of the playlist.

Signed-off-by: Bryan Schumaker <bjschuma@gmail.com>
2012-11-18 11:15:18 -05:00
Bryan Schumaker 27b2e386f0 libsaria: Begin a new deck.cpp file
I'm going to gradually move this out of the playlist/ directory since it
doesn't really belong there.  I also plan on cleaning up / rewriting
much of the code as I go along.

Signed-off-by: Bryan Schumaker <bjschuma@gmail.com>
2012-11-18 10:20:31 -05:00
Bryan Schumaker fa09d53d70 libsaria: Remove my custom List class from the idle queue
I plan on removing this class in favor STL classes.  I probably
shouldn't have even tried to implement this myself...

Signed-off-by: Bryan Schumaker <bjschuma@gmail.com>
2012-11-18 09:53:43 -05:00
Bryan Schumaker bf5b8a3bdd libsaria: Remove PlaylistType in favor of flags
Flags let me manually set properties after the playlist has been
created, rather than needing to decide upfront with no way of converting
to something else.

Signed-off-by: Bryan Schumaker <bjschuma@gmail.com>
2012-09-14 20:25:09 -04:00
Bryan Schumaker 258875bdb8 libsaria: Move header files out of include/libsaria/
Ocarina no longer has a header file subdirectory so there is no reason
to have a libsaria subdirectory anymore.  Putting header files directly
in the include/ directory is a bit simpler.

Signed-off-by: Bryan Schumaker <bjschuma@gmail.com>
2012-09-12 08:15:31 -04:00