Reuse the IOS code for WAD installation

* Less code and logic duplication.

* Fixes a bug with the data dir not being created, steps being done in
  the wrong order.
This commit is contained in:
Léo Lam
2017-05-14 00:15:12 +02:00
parent afcda22da9
commit c8bffb0153
8 changed files with 87 additions and 75 deletions

View File

@ -83,6 +83,8 @@
#include "InputCommon/ControllerInterface/ControllerInterface.h"
#include "UICommon/WiiUtils.h"
#include "VideoCommon/RenderBase.h"
#include "VideoCommon/VideoBackendBase.h"
#include "VideoCommon/VideoConfig.h"
@ -1209,11 +1211,8 @@ void CFrame::OnInstallWAD(wxCommandEvent& event)
wxPD_APP_MODAL | wxPD_ELAPSED_TIME | wxPD_ESTIMATED_TIME |
wxPD_REMAINING_TIME | wxPD_SMOOTH);
u64 titleID = DiscIO::CNANDContentManager::Access().Install_WiiWAD(fileName);
if (titleID == TITLEID_SYSMENU)
{
if (WiiUtils::InstallWAD(fileName))
UpdateLoadWiiMenuItem();
}
}
void CFrame::OnUninstallWAD(wxCommandEvent&)