1
0
Fork 0
mirror of https://github.com/DarkMatterCore/nxdumptool.git synced 2024-11-23 02:36:41 +00:00
nxdumptool/source/ui.h
2018-06-30 02:37:42 -04:00

66 lines
1.4 KiB
C

#pragma once
#ifndef __UI_H__
#define __UI_H__
#define FILENAME_BUFFER_SIZE (1024 * 32) // 32 KiB
#define FILENAME_MAX_CNT 2048
typedef enum {
resultNone,
resultShowMainMenu,
resultShowXciDumpMenu,
resultDumpXci,
resultShowRawPartitionDumpMenu,
resultDumpRawPartition,
resultShowPartitionDataDumpMenu,
resultDumpPartitionData,
resultShowViewGameCardFsMenu,
resultShowViewGameCardFsGetList,
resultShowViewGameCardFsBrowser,
resultViewGameCardFsBrowserCopyFile,
resultDumpGameCardCertificate,
resultUpdateNSWDBXml,
resultUpdateApplication,
resultExit
} UIResult;
typedef enum {
stateMainMenu,
stateXciDumpMenu,
stateDumpXci,
stateRawPartitionDumpMenu,
stateDumpRawPartition,
statePartitionDataDumpMenu,
stateDumpPartitionData,
stateViewGameCardFsMenu,
stateViewGameCardFsGetList,
stateViewGameCardFsBrowser,
stateViewGameCardFsBrowserCopyFile,
stateDumpGameCardCertificate,
stateUpdateNSWDBXml,
stateUpdateApplication
} UIState;
void uiFill(int x, int y, int width, int height, u8 r, u8 g, u8 b);
void uiDrawString(const char* string, int x, int y, u8 r, u8 g, u8 b);
void uiStatusMsg(const char* fmt, ...);
void uiUpdateStatusMsg();
void uiPleaseWait();
void uiUpdateFreeSpace();
void uiInit();
void uiDeinit();
void uiSetState(UIState state);
UIState uiGetState();
void uiClearScreen();
void uiPrintHeadline();
UIResult uiLoop(u32 keysDown);
#endif