forked from isage/VitaShell
-
Notifications
You must be signed in to change notification settings - Fork 5
Expand file tree
/
Copy pathio_process.h
More file actions
81 lines (65 loc) · 1.94 KB
/
io_process.h
File metadata and controls
81 lines (65 loc) · 1.94 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
69
70
71
72
73
74
75
76
77
78
79
80
81
/*
VitaShell
Copyright (C) 2015-2018, TheFloW
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#ifndef __IO_PROCESS_H__
#define __IO_PROCESS_H__
#include "file.h"
#define COUNTUP_WAIT 50 * 1000
#define DIALOG_WAIT 900 * 1000
enum CopyModes {
COPY_MODE_NORMAL,
COPY_MODE_MOVE,
COPY_MODE_EXTRACT
};
enum HashTypes {
HASH_TYPE_SHA1,
HASH_TYPE_MD5,
HASH_TYPE_SHA256
};
typedef struct {
uint64_t max;
int show_kbs;
char *current_file;
int show_eta;
} UpdateArguments;
typedef struct {
FileList *file_list;
FileList *mark_list;
int index;
} DeleteArguments;
typedef struct {
FileList *file_list;
FileList *copy_list;
const char *archive_path;
int copy_mode;
} CopyArguments;
typedef struct {
FileList *file_list;
FileList *mark_list;
int index;
} ExportArguments;
typedef struct {
char *file_path;
int hash_type;
} HashArguments;
int cancelHandler();
void SetProgress(uint64_t value, uint64_t max);
void SetCurrentFile(const char *filename);
SceUID createStartUpdateThread(uint64_t max, int show_kbs);
SceUID createStartUpdateThreadEx(uint64_t max, int show_kbs, char *current_file, int show_eta);
int delete_thread(SceSize args_size, DeleteArguments *args);
int copy_thread(SceSize args_size, CopyArguments *args);
int export_thread(SceSize args_size, ExportArguments *args);
int hash_thread(SceSize args_size, HashArguments *args);
#endif