File tree Expand file tree Collapse file tree 1 file changed +16
-0
lines changed Expand file tree Collapse file tree 1 file changed +16
-0
lines changed Original file line number Diff line number Diff line change 1
1
#include " config.hpp"
2
+ #include " fs.hpp"
2
3
#include " imgui.h"
3
4
#include " language.hpp"
4
5
#include " popups.hpp"
5
6
#include " usb.hpp"
7
+ #include " windows.hpp"
6
8
7
9
namespace Popups {
8
10
static bool done = false ;
@@ -21,6 +23,20 @@ namespace Popups {
21
23
if (ImGui::Button (strings[cfg.lang ][Lang::ButtonOK], ImVec2 (120 , 0 ))) {
22
24
if (!done) {
23
25
USB::Unmount ();
26
+
27
+ // Reset device back to sdmc
28
+ device = " sdmc:" ;
29
+ fs = std::addressof (devices[FileSystemSDMC]);
30
+
31
+ cwd = " /" ;
32
+ data.entries .clear ();
33
+ FS::GetDirList (device, cwd, data.entries );
34
+
35
+ data.checkbox_data .checked .resize (data.entries .size ());
36
+ FS::GetUsedStorageSpace (data.used_storage );
37
+ FS::GetTotalStorageSpace (data.total_storage );
38
+ sort = -1 ;
39
+
24
40
ImGui::CloseCurrentPopup ();
25
41
done = true ;
26
42
}
You can’t perform that action at this time.
0 commit comments