1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
#pragma once
#include <ncurses.h>
#include "Constants.h"
#include "EpisodeList.h"
struct TvShows;
struct Page;
struct EpisodePage {
char* name;
const char* baseUrl;
struct TvShows* startPage;
struct EpisodeList* episodes;
ListNode* selectedLi;
WINDOW* window;
void** activePage;
};
void EpisodePage_init(struct EpisodePage* this);
void EpisodePage_destroyMembers(struct EpisodePage* this);
bool EpisodePage_handleInput(struct EpisodePage* this, int c);
void EpisodePage_draw(struct EpisodePage*);
void EpisodePage_drawEpisode(struct EpisodePage* this, struct Episode* ep, int y);
void EpisodePage_selectFirstOrLast(struct EpisodePage* this, bool direction);
void EpisodePage_selectDelta(struct EpisodePage* this, int delta);
void EpisodePage_playSelected(struct EpisodePage* this);
void EpisodePage_fetch(struct EpisodePage* this, const char* name);
void EpisodePage_activate(struct EpisodePage* this);
void EpisodePage_toggleWatchedLi(struct EpisodePage* this);
void EpisodePage_onServerEvent(const char* event, const char* data, void* userdata);
DEFAULT_CREATE_DESTROY_H(EpisodePage)