#pragma once #include "Constants.h" #include "List.h" #include struct EpisodeList { char* name; List* episodes; float rewatchMarker; }; #define EPISODE_INVALID -3 #define EPISODE_SPECIAL -2 #define EPISODE_UNKNOWN -1 #define NOT_REWATCHING -1 struct Episode { float number; char* numberStr; char* path; char* releaseGroup; char* episodeName; bool watched; }; struct _json_value; void EpisodeList_init(struct EpisodeList* this); void EpisodeList_destroyMembers(struct EpisodeList* this); DEFAULT_CREATE_DESTROY_H(EpisodeList) struct EpisodeList* EpisodeList_fetch(const char* baseurl, const char* tvShow); struct EpisodeList* EpisodeList_restore(struct _json_value* json); List* EpisodeList_contstructPlaylist(struct EpisodeList* this); void EpisodeList_play(struct EpisodeList* this, const char* baseUrl, List* playlist); void Episode_init(struct Episode* this); void Episode_destroyMembers(struct Episode* this); DEFAULT_CREATE_DESTROY_H(Episode) /* void Episode_draw(struct Episode* this); */ struct Episode* Episode_restore(struct _json_value* episodeJson); int Episode_compare(void* av, void* bv);