-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathFileHandler.h
More file actions
68 lines (53 loc) · 1.24 KB
/
FileHandler.h
File metadata and controls
68 lines (53 loc) · 1.24 KB
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
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
// filehandler.h
#ifndef FILEHANDLER_H
#define FILEHANDLER_H
#include <SDL/SDL.h>
#include "SDL/SDL_image.h"
#include "SDL/SDL_rotozoom.h"
#include "string.h"
#include <vector>
#include "Configuration.h"
#include "Helper.h"
using namespace std;
class FileHandler {
public:
vector<string> fileNames;
vector<string> boxArtNames;
vector<string> screenshotNames;
vector<string> _favList;
/* Config */
Configuration::CFConfig _cfg;
Helper _helper;
struct FileContainer
{
string character = "";
string fileName = "";
string boxartName = "";
string screenshotName = "";
bool useDefault = false;
bool useDefaultScreen = false;
};
/* Console */
struct ConsoleContainer
{
SDL_Rect position;
SDL_Surface* consoleImage;
string consoleName;
};
int CONSOLE_WIDTH = 105;
int CONSOLE_HEIGHT = 105;
vector<ConsoleContainer> _consoleContainer;
vector<FileContainer> _fileCollection;
vector<string> _characterList;
FileHandler();
void listFilesRecursively(string basePath);
void LoadEmulators();
void LoadFavList();
void LoadFiles();
void SetCharacterList();
void SetCharacterEmulatorList();
const string getext(string filename);
const vector<string> split(string str, string token);
const vector<string> GetThemes();
};
#endif