-
Notifications
You must be signed in to change notification settings - Fork 10
/
RomLister.h
36 lines (31 loc) · 662 Bytes
/
RomLister.h
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
#ifndef ROMLISTER
#define ROMLISTER
#include <string>
#include <vector>
#include "rom_selector.h"
#define ROMLISTER_MAXPATH 100
namespace Frens {
class RomLister
{
public:
struct RomEntry {
char Path[ROMLISTER_MAXPATH]; // Without dirname
bool IsDirectory = false;
int Index = 0;
};
RomLister(uintptr_t NES_FILE_ADDR, void *buffer, size_t buffersize);
~RomLister();
RomEntry* GetEntries();
char *FolderName();
size_t Count();
void list( );
private:
char directoryname[ROMLISTER_MAXPATH];
int length{};
size_t max_entries{};
RomEntry *entries{};
size_t numberOfEntries{};
const uint8_t *address{};
};
}
#endif