From 39ac44c868108257212a6cd84f6bbcf00e991248 Mon Sep 17 00:00:00 2001 From: sum2012 Date: Sun, 26 Oct 2014 08:39:44 +0800 Subject: [PATCH] oop --- UI/GameSettingsScreen.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/UI/GameSettingsScreen.cpp b/UI/GameSettingsScreen.cpp index 9fea6e829f..7d022af96b 100644 --- a/UI/GameSettingsScreen.cpp +++ b/UI/GameSettingsScreen.cpp @@ -410,7 +410,7 @@ void GameSettingsScreen::CreateViews() { const std::string installedFile = PPSSPPpath + "installed.txt"; const std::string path = File::GetExeDirectory(); installed = File::Exists(installedFile); - if (!installed && result == S_OK){ + if (!installed && result == S_OK) { ofstream myfile; myfile.open(PPSSPPpath + "installedTEMP.txt"); if (myfile.is_open()){ @@ -423,7 +423,7 @@ void GameSettingsScreen::CreateViews() { SavePathInMyDocumentChoice->SetEnabled(false); } else { - if (installed && (result == S_OK)) { + if (installed && (result == S_OK)) { std::ifstream inputFile(ConvertUTF8ToWString(installedFile)); if (!inputFile.fail() && inputFile.is_open()) { SavePathInMyDocumentChoice->OnClick.Handle(this, &GameSettingsScreen::OnSavePathMydoc); @@ -432,6 +432,7 @@ void GameSettingsScreen::CreateViews() { // Skip UTF-8 encoding bytes if there are any. There are 3 of them. if (tempString.substr(0, 3) == "\xEF\xBB\xBF") + tempString = tempString.substr(3); if (!(tempString == "")){ installed = false; otherinstalled = true;