Path code cleanup, move some UI code (#21037)

* Move a bunch of path logic into Core/Util/PathUtil.cpp/h

.

* Move GameImageView out from SaveDataScreen

* More cleanup, add a translation string
This commit is contained in:
Henrik Rydgård
2025-11-25 00:44:24 +01:00
committed by GitHub
parent 3116eba395
commit b8fced5b41
72 changed files with 416 additions and 330 deletions
+2
View File
@@ -2468,6 +2468,8 @@ add_library(${CoreLibName} ${CoreLinkType}
Core/Util/MemStick.h
Core/Util/GameDB.cpp
Core/Util/GameDB.h
Core/Util/PathUtil.cpp
Core/Util/PathUtil.h
Core/Util/PortManager.cpp
Core/Util/PortManager.h
Core/Util/BlockAllocator.cpp
+1
View File
@@ -329,6 +329,7 @@ static bool ResolvePathVista(const std::wstring &path, wchar_t *buf, DWORD bufSi
}
#endif
// Canonicalize the given path, resolving symlinks, relative paths, etc.
std::string ResolvePath(std::string_view path) {
if (LOG_IO) {
INFO_LOG(Log::IO, "ResolvePath %.*s", (int)path.size(), path.data());
-25
View File
@@ -204,31 +204,6 @@ void PathBrowser::ResetPending() {
pendingPath_.clear();
}
std::string PathBrowser::GetFriendlyPath() const {
// Show relative to memstick root if there.
if (path_.StartsWith(aliasMatch_)) {
std::string p;
if (aliasMatch_.ComputePathTo(path_, p)) {
return aliasDisplay_ + p;
}
std::string str = path_.ToString();
if (aliasMatch_.size() < str.length()) {
return aliasDisplay_ + str.substr(aliasMatch_.size());
} else {
return aliasDisplay_;
}
}
std::string str = path_.ToString();
#if !PPSSPP_PLATFORM(ANDROID) && (PPSSPP_PLATFORM(LINUX) || PPSSPP_PLATFORM(MAC))
char *home = getenv("HOME");
if (home != nullptr && !strncmp(str.c_str(), home, strlen(home))) {
return std::string("~") + str.substr(strlen(home));
}
#endif
return path_.ToVisualString();
}
bool PathBrowser::GetListing(std::vector<File::FileInfo> &fileInfo, const char *extensionFilter, bool *cancel) {
std::unique_lock<std::mutex> guard(pendingLock_);
while (!IsListingReady() && (!cancel || !*cancel)) {
-7
View File
@@ -36,15 +36,10 @@ public:
const Path &GetPath() const {
return path_;
}
std::string GetFriendlyPath() const;
void SetUserAgent(std::string_view s) {
userAgent_ = s;
}
void SetRootAlias(std::string_view alias, const Path &rootPath) {
aliasDisplay_ = alias;
aliasMatch_ = rootPath;
}
void RestrictToRoot(const Path &root);
bool empty() const {
return path_.empty();
@@ -62,8 +57,6 @@ private:
Path pendingPath_;
Path restrictedRoot_;
std::string userAgent_;
std::string aliasDisplay_;
Path aliasMatch_;
std::vector<File::FileInfo> pendingFiles_;
std::condition_variable pendingCond_;
std::mutex pendingLock_;
+8 -76
View File
@@ -57,6 +57,7 @@
#include "Core/HLE/sceUtility.h"
#include "Core/Instance.h"
#include "Core/Util/RecentFiles.h"
#include "Core/Util/PathUtil.h"
#include "GPU/Common/FramebufferManagerCommon.h"
@@ -73,8 +74,6 @@ static const std::string_view logSectionName = "LogDebug";
static const std::string_view logSectionName = "Log";
#endif
bool TryUpdateSavedPath(Path *path);
static const std::vector<std::string_view> defaultProAdhocServerList = {
"socom.cc", "psp.gameplayer.club", // TODO: Add some saved recent history too?
};
@@ -1177,10 +1176,10 @@ void Config::UpdateIniLocation(const char *iniFileName, const char *controllerIn
const bool useIniFilename = iniFileName != nullptr && strlen(iniFileName) > 0;
const char *ppssppIniFilename = IsVREnabled() ? "ppssppvr.ini" : "ppsspp.ini";
bool exists;
iniFilename_ = FindConfigFile(useIniFilename ? iniFileName : ppssppIniFilename, &exists);
iniFilename_ = FindConfigFile(searchPath_, useIniFilename ? iniFileName : ppssppIniFilename, &exists);
const bool useControllerIniFilename = controllerIniFilename != nullptr && strlen(controllerIniFilename) > 0;
const char *controlsIniFilename = IsVREnabled() ? "controlsvr.ini" : "controls.ini";
controllerIniFilename_ = FindConfigFile(useControllerIniFilename ? controllerIniFilename : controlsIniFilename, &exists);
controllerIniFilename_ = FindConfigFile(searchPath_, useControllerIniFilename ? controllerIniFilename : controlsIniFilename, &exists);
}
bool Config::LoadAppendedConfig() {
@@ -1538,70 +1537,10 @@ void Config::NotifyUpdatedCpuCore() {
}
}
// On iOS, the path to the app documents directory changes on each launch.
// Example path:
// /var/mobile/Containers/Data/Application/0E0E89DE-8D8E-485A-860C-700D8BC87B86/Documents/PSP/GAME/SuicideBarbie
// The GUID part changes on each launch.
bool TryUpdateSavedPath(Path *path) {
#if PPSSPP_PLATFORM(IOS)
// DEBUG_LOG(Log::Loader, "Original path: %s", path->c_str());
std::string pathStr = path->ToString();
const std::string_view applicationRoot = "/var/mobile/Containers/Data/Application/";
if (startsWith(pathStr, applicationRoot)) {
size_t documentsPos = pathStr.find("/Documents/");
if (documentsPos == std::string::npos) {
return false;
}
std::string memstick = g_Config.memStickDirectory.ToString();
size_t memstickDocumentsPos = memstick.find("/Documents"); // Note: No trailing slash, or we won't find it.
*path = Path(memstick.substr(0, memstickDocumentsPos) + pathStr.substr(documentsPos));
return true;
} else {
// Path can't be auto-updated.
return false;
}
#else
return false;
#endif
}
void Config::SetSearchPath(const Path &searchPath) {
searchPath_ = searchPath;
}
Path Config::FindConfigFile(std::string_view baseFilename, bool *exists) const {
// Don't search for an absolute path.
if (baseFilename.size() > 1 && baseFilename[0] == '/') {
Path path(baseFilename);
*exists = File::Exists(path);
return path;
}
#ifdef _WIN32
// Handle paths starting with a drive letter.
if (baseFilename.size() > 3 && baseFilename[1] == ':' && (baseFilename[2] == '/' || baseFilename[2] == '\\')) {
Path path(baseFilename);
*exists = File::Exists(path);
return path;
}
#endif
Path filename = searchPath_ / baseFilename;
if (File::Exists(filename)) {
*exists = true;
return filename;
}
*exists = false;
// Make sure at least the directory it's supposed to be in exists.
Path parent = filename.NavigateUp();
// We try to create the path and ignore if it fails (already exists).
if (parent != GetSysDirectory(DIRECTORY_SYSTEM)) {
File::CreateFullPath(parent);
}
return filename;
}
void Config::RestoreDefaults(RestoreSettingsBits whatToRestore, bool log) {
if (IsGameSpecific()) {
// TODO: This could be done in a cleaner way.
@@ -1636,13 +1575,13 @@ void Config::RestoreDefaults(RestoreSettingsBits whatToRestore, bool log) {
bool Config::HasGameConfig(std::string_view gameId) {
bool exists = false;
Path fullIniFilePath = GetGameConfigFilePath(gameId, &exists);
Path fullIniFilePath = GetGameConfigFilePath(searchPath_, gameId, &exists);
return exists;
}
bool Config::CreateGameConfig(std::string_view gameId) {
bool exists;
Path fullIniFilePath = GetGameConfigFilePath(gameId, &exists);
Path fullIniFilePath = GetGameConfigFilePath(searchPath_, gameId, &exists);
if (exists) {
INFO_LOG(Log::System, "Game config already exists");
@@ -1655,7 +1594,7 @@ bool Config::CreateGameConfig(std::string_view gameId) {
bool Config::DeleteGameConfig(std::string_view gameId) {
bool exists = false;
Path fullIniFilePath = Path(GetGameConfigFilePath(gameId, &exists));
Path fullIniFilePath = GetGameConfigFilePath(searchPath_, gameId, &exists);
if (exists) {
if (System_GetPropertyBool(SYSPROP_HAS_TRASH_BIN)) {
@@ -1667,13 +1606,6 @@ bool Config::DeleteGameConfig(std::string_view gameId) {
return true;
}
Path Config::GetGameConfigFilePath(std::string_view gameId, bool *exists) {
std::string_view ppssppIniFilename = IsVREnabled() ? "_ppssppvr.ini" : "_ppsspp.ini";
std::string iniFileName = join(gameId, ppssppIniFilename);
Path iniFileNameFull = FindConfigFile(iniFileName, exists);
return iniFileNameFull;
}
bool Config::SaveGameConfig(const std::string &gameId, std::string_view titleForComment) {
if (gameId.empty()) {
return false;
@@ -1685,7 +1617,7 @@ bool Config::SaveGameConfig(const std::string &gameId, std::string_view titleFor
}
bool exists;
Path fullIniFilePath = GetGameConfigFilePath(gameId, &exists);
Path fullIniFilePath = GetGameConfigFilePath(searchPath_, gameId, &exists);
IniFile iniFile;
@@ -1735,7 +1667,7 @@ bool Config::SaveGameConfig(const std::string &gameId, std::string_view titleFor
bool Config::LoadGameConfig(const std::string &gameId) {
bool exists;
Path iniFileNameFull = GetGameConfigFilePath(gameId, &exists);
Path iniFileNameFull = GetGameConfigFilePath(searchPath_, gameId, &exists);
if (!exists) {
// Bail if there's no game-specific config.
DEBUG_LOG(Log::Loader, "No game-specific settings found in %s. Using global defaults.", iniFileNameFull.c_str());
-3
View File
@@ -672,12 +672,10 @@ public:
bool SaveGameConfig(const std::string &pGameId, std::string_view titleForComment);
void UnloadGameConfig();
Path GetGameConfigFilePath(std::string_view gameId, bool *exists);
bool HasGameConfig(std::string_view gameId);
bool IsGameSpecific() const { return !gameId_.empty(); }
void SetSearchPath(const Path &path);
Path FindConfigFile(std::string_view baseFilename, bool *exists) const;
void UpdateIniLocation(const char *iniFileName = nullptr, const char *controllerIniFilename = nullptr);
@@ -744,7 +742,6 @@ private:
};
std::string CreateRandMAC();
bool TryUpdateSavedPath(Path *path);
// TODO: Find a better place for this.
extern http::RequestManager g_DownloadManager;
+3 -1
View File
@@ -936,6 +936,7 @@
<ClCompile Include="Util\GameDB.cpp" />
<ClCompile Include="Util\GameManager.cpp" />
<ClCompile Include="Util\MemStick.cpp" />
<ClCompile Include="Util\PathUtil.cpp" />
<ClCompile Include="Util\PortManager.cpp" />
<ClCompile Include="Util\PPGeDraw.cpp" />
<ClCompile Include="..\ext\xxhash.c">
@@ -1304,6 +1305,7 @@
<ClInclude Include="Util\GameDB.h" />
<ClInclude Include="Util\GameManager.h" />
<ClInclude Include="Util\MemStick.h" />
<ClInclude Include="Util\PathUtil.h" />
<ClInclude Include="Util\PortManager.h" />
<ClInclude Include="Util\PPGeDraw.h" />
<ClInclude Include="..\ext\xxhash.h" />
@@ -1348,4 +1350,4 @@
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
<ImportGroup Label="ExtensionTargets">
</ImportGroup>
</Project>
</Project>
+7 -1
View File
@@ -1393,6 +1393,9 @@
<ClCompile Include="HW\GranularMixer.cpp">
<Filter>HW</Filter>
</ClCompile>
<ClCompile Include="Util\PathUtil.cpp">
<Filter>Util</Filter>
</ClCompile>
</ItemGroup>
<ItemGroup>
<ClInclude Include="ELF\ElfReader.h">
@@ -2250,6 +2253,9 @@
<ClInclude Include="HW\GranularMixer.h">
<Filter>HW</Filter>
</ClInclude>
<ClInclude Include="Util\PathUtil.h">
<Filter>Util</Filter>
</ClInclude>
</ItemGroup>
<ItemGroup>
<None Include="..\LICENSE.TXT" />
@@ -2278,4 +2284,4 @@
<Filter>Ext</Filter>
</Text>
</ItemGroup>
</Project>
</Project>
-99
View File
@@ -774,105 +774,6 @@ void PSP_RunLoopFor(int cycles) {
Core_RunLoopUntil(CoreTiming::GetTicks() + cycles);
}
Path GetSysDirectory(PSPDirectories directoryType) {
const Path &memStickDirectory = g_Config.memStickDirectory;
Path pspDirectory;
if (!strcasecmp(memStickDirectory.GetFilename().c_str(), "PSP")) {
// Let's strip this off, to easily allow choosing a root directory named "PSP" on Android.
pspDirectory = memStickDirectory;
} else {
pspDirectory = memStickDirectory / "PSP";
}
switch (directoryType) {
case DIRECTORY_PSP:
return pspDirectory;
case DIRECTORY_CHEATS:
return pspDirectory / "Cheats";
case DIRECTORY_GAME:
return pspDirectory / "GAME";
case DIRECTORY_SAVEDATA:
return pspDirectory / "SAVEDATA";
case DIRECTORY_SCREENSHOT:
return pspDirectory / "SCREENSHOT";
case DIRECTORY_SYSTEM:
return pspDirectory / "SYSTEM";
case DIRECTORY_PAUTH:
return memStickDirectory / "PAUTH"; // This one's at the root...
case DIRECTORY_EXDATA:
return memStickDirectory / "EXDATA"; // This one's traditionally at the root...
case DIRECTORY_DUMP:
return pspDirectory / "SYSTEM/DUMP";
case DIRECTORY_SAVESTATE:
return pspDirectory / "PPSSPP_STATE";
case DIRECTORY_CACHE:
return pspDirectory / "SYSTEM/CACHE";
case DIRECTORY_TEXTURES:
return pspDirectory / "TEXTURES";
case DIRECTORY_PLUGINS:
return pspDirectory / "PLUGINS";
case DIRECTORY_APP_CACHE:
if (!g_Config.appCacheDirectory.empty()) {
return g_Config.appCacheDirectory;
}
return pspDirectory / "SYSTEM/CACHE";
case DIRECTORY_VIDEO:
return pspDirectory / "VIDEO";
case DIRECTORY_AUDIO:
return pspDirectory / "AUDIO";
case DIRECTORY_CUSTOM_SHADERS:
return pspDirectory / "shaders";
case DIRECTORY_CUSTOM_THEMES:
return pspDirectory / "themes";
case DIRECTORY_MEMSTICK_ROOT:
return g_Config.memStickDirectory;
// Just return the memory stick root if we run into some sort of problem.
default:
ERROR_LOG(Log::FileSystem, "Unknown directory type.");
return g_Config.memStickDirectory;
}
}
bool CreateSysDirectories() {
#if PPSSPP_PLATFORM(ANDROID)
const bool createNoMedia = true;
#else
const bool createNoMedia = false;
#endif
Path pspDir = GetSysDirectory(DIRECTORY_PSP);
INFO_LOG(Log::IO, "Creating '%s' and subdirs:", pspDir.c_str());
File::CreateFullPath(pspDir);
if (!File::Exists(pspDir)) {
INFO_LOG(Log::IO, "Not a workable memstick directory. Giving up");
return false;
}
// Create the default directories that a real PSP creates. Good for homebrew so they can
// expect a standard environment. Skipping THEME though, that's pointless.
static const PSPDirectories sysDirs[] = {
DIRECTORY_CHEATS,
DIRECTORY_SAVEDATA,
DIRECTORY_SAVESTATE,
DIRECTORY_GAME,
DIRECTORY_SYSTEM,
DIRECTORY_TEXTURES,
DIRECTORY_PLUGINS,
DIRECTORY_CACHE,
};
for (auto dir : sysDirs) {
Path path = GetSysDirectory(dir);
File::CreateFullPath(path);
if (createNoMedia) {
// Create a nomedia file in each specified subdirectory.
File::CreateEmptyFile(path / ".nomedia");
}
}
return true;
}
const char *DumpFileTypeToString(DumpFileType type) {
switch (type) {
case DumpFileType::EBOOT: return "EBOOT";
+1 -24
View File
@@ -22,6 +22,7 @@
#include "Common/File/Path.h"
#include "Core/CoreParameter.h"
#include "Core/ConfigValues.h"
#include "Core/Util/PathUtil.h"
class MetaFileSystem;
class ParamSFOData;
@@ -39,30 +40,6 @@ enum GlobalUIState {
UISTATE_EXCEPTION,
};
// Use these in conjunction with GetSysDirectory.
enum PSPDirectories {
DIRECTORY_PSP,
DIRECTORY_CHEATS,
DIRECTORY_SCREENSHOT,
DIRECTORY_SYSTEM,
DIRECTORY_GAME,
DIRECTORY_SAVEDATA,
DIRECTORY_PAUTH,
DIRECTORY_DUMP,
DIRECTORY_SAVESTATE,
DIRECTORY_CACHE,
DIRECTORY_TEXTURES,
DIRECTORY_PLUGINS,
DIRECTORY_APP_CACHE, // Use the OS app cache if available
DIRECTORY_VIDEO,
DIRECTORY_AUDIO,
DIRECTORY_MEMSTICK_ROOT,
DIRECTORY_EXDATA,
DIRECTORY_CUSTOM_SHADERS,
DIRECTORY_CUSTOM_THEMES,
COUNT,
};
class GraphicsContext;
enum class GPUBackend;
+211
View File
@@ -0,0 +1,211 @@
#include <string_view>
#include "Common/File/Path.h"
#include "Common/File/FileUtil.h"
#include "Common/StringUtils.h"
#include "Common/System/System.h"
#include "Common/Log.h"
#include "Core/Util/PathUtil.h"
#include "Core/Config.h"
#include "Common/VR/PPSSPPVR.h"
Path FindConfigFile(const Path &searchPath, std::string_view baseFilename, bool *exists) {
// Don't search for an absolute path.
if (baseFilename.size() > 1 && baseFilename[0] == '/') {
Path path(baseFilename);
*exists = File::Exists(path);
return path;
}
#ifdef _WIN32
// Handle paths starting with a drive letter.
if (baseFilename.size() > 3 && baseFilename[1] == ':' && (baseFilename[2] == '/' || baseFilename[2] == '\\')) {
Path path(baseFilename);
*exists = File::Exists(path);
return path;
}
#endif
Path filename = searchPath / baseFilename;
if (File::Exists(filename)) {
*exists = true;
return filename;
}
*exists = false;
// Make sure at least the directory it's supposed to be in exists.
Path parent = filename.NavigateUp();
// We try to create the path and ignore if it fails (already exists).
if (parent != GetSysDirectory(DIRECTORY_SYSTEM)) {
File::CreateFullPath(parent);
}
return filename;
}
Path GetSysDirectory(PSPDirectories directoryType) {
const Path &memStickDirectory = g_Config.memStickDirectory;
Path pspDirectory;
if (!strcasecmp(memStickDirectory.GetFilename().c_str(), "PSP")) {
// Let's strip this off, to easily allow choosing a root directory named "PSP" on Android.
pspDirectory = memStickDirectory;
} else {
pspDirectory = memStickDirectory / "PSP";
}
switch (directoryType) {
case DIRECTORY_PSP:
return pspDirectory;
case DIRECTORY_CHEATS:
return pspDirectory / "Cheats";
case DIRECTORY_GAME:
return pspDirectory / "GAME";
case DIRECTORY_SAVEDATA:
return pspDirectory / "SAVEDATA";
case DIRECTORY_SCREENSHOT:
return pspDirectory / "SCREENSHOT";
case DIRECTORY_SYSTEM:
return pspDirectory / "SYSTEM";
case DIRECTORY_PAUTH:
return memStickDirectory / "PAUTH"; // This one's at the root...
case DIRECTORY_EXDATA:
return memStickDirectory / "EXDATA"; // This one's traditionally at the root...
case DIRECTORY_DUMP:
return pspDirectory / "SYSTEM/DUMP";
case DIRECTORY_SAVESTATE:
return pspDirectory / "PPSSPP_STATE";
case DIRECTORY_CACHE:
return pspDirectory / "SYSTEM/CACHE";
case DIRECTORY_TEXTURES:
return pspDirectory / "TEXTURES";
case DIRECTORY_PLUGINS:
return pspDirectory / "PLUGINS";
case DIRECTORY_APP_CACHE:
if (!g_Config.appCacheDirectory.empty()) {
return g_Config.appCacheDirectory;
}
return pspDirectory / "SYSTEM/CACHE";
case DIRECTORY_VIDEO:
return pspDirectory / "VIDEO";
case DIRECTORY_AUDIO:
return pspDirectory / "AUDIO";
case DIRECTORY_CUSTOM_SHADERS:
return pspDirectory / "shaders";
case DIRECTORY_CUSTOM_THEMES:
return pspDirectory / "themes";
case DIRECTORY_MEMSTICK_ROOT:
return g_Config.memStickDirectory;
// Just return the memory stick root if we run into some sort of problem.
default:
ERROR_LOG(Log::FileSystem, "Unknown directory type.");
return g_Config.memStickDirectory;
}
}
bool CreateSysDirectories() {
#if PPSSPP_PLATFORM(ANDROID)
const bool createNoMedia = true;
#else
const bool createNoMedia = false;
#endif
Path pspDir = GetSysDirectory(DIRECTORY_PSP);
INFO_LOG(Log::IO, "Creating '%s' and subdirs:", pspDir.c_str());
File::CreateFullPath(pspDir);
if (!File::Exists(pspDir)) {
INFO_LOG(Log::IO, "Not a workable memstick directory. Giving up");
return false;
}
// Create the default directories that a real PSP creates. Good for homebrew so they can
// expect a standard environment. Skipping THEME though, that's pointless.
static const PSPDirectories sysDirs[] = {
DIRECTORY_CHEATS,
DIRECTORY_SAVEDATA,
DIRECTORY_SAVESTATE,
DIRECTORY_GAME,
DIRECTORY_SYSTEM,
DIRECTORY_TEXTURES,
DIRECTORY_PLUGINS,
DIRECTORY_CACHE,
};
for (auto dir : sysDirs) {
Path path = GetSysDirectory(dir);
File::CreateFullPath(path);
if (createNoMedia) {
// Create a nomedia file in each specified subdirectory.
File::CreateEmptyFile(path / ".nomedia");
}
}
return true;
}
Path GetGameConfigFilePath(const Path &searchPath, std::string_view gameId, bool *exists) {
std::string_view ppssppIniFilename = IsVREnabled() ? "_ppssppvr.ini" : "_ppsspp.ini";
std::string iniFileName = join(gameId, ppssppIniFilename);
Path iniFileNameFull = FindConfigFile(searchPath, iniFileName, exists);
return iniFileNameFull;
}
// On iOS, the path to the app documents directory changes on each launch.
// Example path:
// /var/mobile/Containers/Data/Application/0E0E89DE-8D8E-485A-860C-700D8BC87B86/Documents/PSP/GAME/SuicideBarbie
// The GUID part changes on each launch.
bool TryUpdateSavedPath(Path *path) {
#if PPSSPP_PLATFORM(IOS)
// DEBUG_LOG(Log::Loader, "Original path: %s", path->c_str());
std::string pathStr = path->ToString();
const std::string_view applicationRoot = "/var/mobile/Containers/Data/Application/";
if (startsWith(pathStr, applicationRoot)) {
size_t documentsPos = pathStr.find("/Documents/");
if (documentsPos == std::string::npos) {
return false;
}
std::string memstick = g_Config.memStickDirectory.ToString();
size_t memstickDocumentsPos = memstick.find("/Documents"); // Note: No trailing slash, or we won't find it.
*path = Path(memstick.substr(0, memstickDocumentsPos) + pathStr.substr(documentsPos));
return true;
} else {
// Path can't be auto-updated.
return false;
}
#else
return false;
#endif
}
Path GetFailedBackendsDir() {
Path failedBackendsDir;
if (System_GetPropertyBool(SYSPROP_SUPPORTS_PERMISSIONS)) {
failedBackendsDir = GetSysDirectory(DIRECTORY_APP_CACHE);
} else {
failedBackendsDir = GetSysDirectory(DIRECTORY_SYSTEM);
}
return failedBackendsDir;
}
std::string GetFriendlyPath(Path path, Path aliasMatch, std::string_view aliasDisplay) {
// Show relative to memstick root if there.
if (path.StartsWith(aliasMatch)) {
std::string p;
if (aliasMatch.ComputePathTo(path, p)) {
return join(aliasDisplay, p);
}
std::string str = path.ToString();
if (aliasMatch.size() < str.length()) {
return join(aliasDisplay, str.substr(aliasMatch.size()));
} else {
return std::string(aliasDisplay);
}
}
std::string str = path.ToString();
#if !PPSSPP_PLATFORM(ANDROID) && (PPSSPP_PLATFORM(LINUX) || PPSSPP_PLATFORM(MAC))
char *home = getenv("HOME");
if (home != nullptr && !strncmp(str.c_str(), home, strlen(home))) {
return std::string("~") + str.substr(strlen(home));
}
#endif
return path.ToVisualString();
}
+38
View File
@@ -0,0 +1,38 @@
#pragma once
#include <string>
#include <string_view>
#include "Common/File/Path.h"
// Use these in conjunction with GetSysDirectory.
enum PSPDirectories {
DIRECTORY_PSP,
DIRECTORY_CHEATS,
DIRECTORY_SCREENSHOT,
DIRECTORY_SYSTEM,
DIRECTORY_GAME,
DIRECTORY_SAVEDATA,
DIRECTORY_PAUTH,
DIRECTORY_DUMP,
DIRECTORY_SAVESTATE,
DIRECTORY_CACHE,
DIRECTORY_TEXTURES,
DIRECTORY_PLUGINS,
DIRECTORY_APP_CACHE, // Use the OS app cache if available
DIRECTORY_VIDEO,
DIRECTORY_AUDIO,
DIRECTORY_MEMSTICK_ROOT,
DIRECTORY_EXDATA,
DIRECTORY_CUSTOM_SHADERS,
DIRECTORY_CUSTOM_THEMES,
COUNT,
};
Path FindConfigFile(const Path &searchPath, std::string_view baseFilename, bool *exists);
Path GetSysDirectory(PSPDirectories directoryType);
bool CreateSysDirectories();
Path GetGameConfigFilePath(const Path &searchPath, std::string_view gameId, bool *exists);
bool TryUpdateSavedPath(Path *path);
Path GetFailedBackendsDir();
std::string GetFriendlyPath(Path path, Path aliasMatch, std::string_view aliasDisplay);
+1
View File
@@ -9,6 +9,7 @@
#include "Common/TimeUtil.h"
#include "Core/Loaders.h"
#include "Core/Util/RecentFiles.h"
#include "Core/Util/PathUtil.h"
#include "Core/Config.h"
RecentFilesManager g_recentFiles;
+6 -3
View File
@@ -402,13 +402,16 @@ void GameInfo::SetTitle(const std::string &newTitle) {
}
void GameInfo::FinishPendingTextureLoads(Draw::DrawContext *draw) {
if (draw && icon.dataLoaded && !icon.texture) {
if (!draw) {
return;
}
if (icon.dataLoaded && !icon.texture) {
SetupTexture(draw, icon);
}
if (draw && pic0.dataLoaded && !pic0.texture) {
if (pic0.dataLoaded && !pic0.texture) {
SetupTexture(draw, pic0);
}
if (draw && pic1.dataLoaded && !pic1.texture) {
if (pic1.dataLoaded && !pic1.texture) {
SetupTexture(draw, pic1);
}
}
+1
View File
@@ -197,6 +197,7 @@ public:
// redrawing the UI often. Only set flags to GAMEINFO_WANTBG or WANTSND if you really want them
// because they're big. bgTextures and sound may be discarded over time as well.
// NOTE: This never returns null, so you don't need to check for that. Do check Ready() flags though.
// It's OK to pass in nullptr for draw if you don't need the actual texture right now.
std::shared_ptr<GameInfo> GetInfo(Draw::DrawContext *draw, const Path &gamePath, GameInfoFlags wantFlags, GameInfoFlags *outHasFlags = nullptr);
void FlushBGs(); // Gets rid of all BG textures. Also gets rid of bg sounds.
+7 -4
View File
@@ -519,10 +519,11 @@ GameBrowser::GameBrowser(int token, const Path &path, BrowseFlags browseFlags, b
using namespace UI;
path_.SetUserAgent(StringFromFormat("PPSSPP/%s", PPSSPP_GIT_VERSION));
Path memstickRoot = GetSysDirectory(DIRECTORY_MEMSTICK_ROOT);
aliasMatch_ = memstickRoot;
if (memstickRoot == GetSysDirectory(DIRECTORY_PSP)) {
path_.SetRootAlias("ms:/PSP/", memstickRoot);
aliasDisplay_ = "ms:/PSP/";
} else {
path_.SetRootAlias("ms:/", memstickRoot);
aliasDisplay_ = "ms:/";
}
if (System_GetPropertyBool(SYSPROP_LIMITED_FILE_BROWSING) &&
(path.Type() == PathType::NATIVE || path.Type() == PathType::CONTENT_URI)) {
@@ -782,13 +783,15 @@ void GameBrowser::Refresh() {
const bool pathOnSeparateLine = g_display.dp_xres < 1050 || portrait_;
std::string pathStr = GetFriendlyPath(path_.GetPath(), aliasMatch_, aliasDisplay_);
if (pathOnSeparateLine) {
Add(new TextView(path_.GetFriendlyPath(), ALIGN_VCENTER | FLAG_WRAP_TEXT, true, new LinearLayoutParams(FILL_PARENT, WRAP_CONTENT, Margins(8, 0, 8, 0))));
Add(new TextView(pathStr, ALIGN_VCENTER | FLAG_WRAP_TEXT, true, new LinearLayoutParams(FILL_PARENT, WRAP_CONTENT, Margins(8, 0, 8, 0))));
}
if (browseFlags_ & BrowseFlags::NAVIGATE) {
if (!pathOnSeparateLine) {
topBar->Add(new Spacer(2.0f));
topBar->Add(new TextView(path_.GetFriendlyPath(), ALIGN_VCENTER | FLAG_WRAP_TEXT, true, new LinearLayoutParams(FILL_PARENT, 64.0f, 1.0f)));
topBar->Add(new TextView(pathStr, ALIGN_VCENTER | FLAG_WRAP_TEXT, true, new LinearLayoutParams(FILL_PARENT, 64.0f, 1.0f)));
}
topBar->Add(new Choice(ImageID("I_HOME"), new LayoutParams(WRAP_CONTENT, 64.0f)))->OnClick.Handle(this, &GameBrowser::OnHomeClick);
if (System_GetPropertyBool(SYSPROP_HAS_ADDITIONAL_STORAGE)) {
+2
View File
@@ -116,6 +116,8 @@ private:
ScreenManager *screenManager_;
int token_ = -1;
bool portrait_ = false;
Path aliasMatch_;
std::string aliasDisplay_;
};
class RemoteISOBrowseScreen;
+52
View File
@@ -158,3 +158,55 @@ PaneTitleBar::PaneTitleBar(const Path &gamePath, std::string_view title, const s
});
}
}
void GameImageView::GetContentDimensions(const UIContext &dc, float &w, float &h) const {
w = textureWidth_;
h = textureHeight_;
}
void GameImageView::Draw(UIContext &dc) {
using namespace UI;
std::shared_ptr<GameInfo> info = g_gameInfoCache->GetInfo(dc.GetDrawContext(), gamePath_, image_);
if (!info->Ready(image_) || !info->icon.texture) {
return;
}
Draw::Texture *texture = nullptr;
switch (image_) {
case GameInfoFlags::ICON:
texture = info->icon.texture;
break;
case GameInfoFlags::PIC0:
texture = info->pic0.texture;
break;
case GameInfoFlags::PIC1:
texture = info->pic1.texture;
break;
}
if (!texture) {
return;
}
textureWidth_ = texture->Width() * scale_;
textureHeight_ = texture->Height() * scale_;
// Fade icon with the backgrounds.
double loadTime = info->icon.timeLoaded;
auto pic = info->GetPIC1();
if (pic) {
loadTime = std::max(loadTime, pic->timeLoaded);
}
uint32_t color = whiteAlpha(ease((time_now_d() - loadTime) * 3));
// Adjust size so we don't stretch the image vertically or horizontally.
// Make sure it's not wider than 144 (like Doom Legacy homebrew), ugly in the grid mode.
float nw = std::min(bounds_.h * textureWidth_ / textureHeight_, (float)bounds_.w);
int x = bounds_.x + (bounds_.w - nw) / 2.0f;
dc.Flush();
dc.GetDrawContext()->BindTexture(0, texture);
dc.Draw()->Rect(x, bounds_.y, nw, bounds_.h, color);
dc.Flush();
dc.RebindTexture();
}
+19
View File
@@ -3,6 +3,7 @@
#include "Common/Common.h"
#include "Common/UI/View.h"
#include "UI/ViewGroup.h"
#include "UI/GameInfoCache.h"
// Compound view, showing a text with an icon.
class TextWithImage : public UI::LinearLayout {
@@ -57,3 +58,21 @@ public:
private:
Path gamePath_;
};
class GameImageView : public UI::InertView {
public:
GameImageView(const Path &gamePath, GameInfoFlags image, float scale, UI::LayoutParams *layoutParams = 0)
: InertView(layoutParams), image_(image), gamePath_(gamePath), scale_(scale) {
}
void GetContentDimensions(const UIContext &dc, float &w, float &h) const override;
void Draw(UIContext &dc) override;
std::string DescribeText() const override { return ""; }
private:
Path gamePath_;
GameInfoFlags image_;
float scale_ = 1.0f;
int textureWidth_ = 0;
int textureHeight_ = 0;
};
+1 -10
View File
@@ -111,6 +111,7 @@
#include "Core/Util/PortManager.h"
#include "Core/Util/AudioFormat.h"
#include "Core/Util/RecentFiles.h"
#include "Core/Util/PathUtil.h"
#include "Core/WebServer.h"
#include "Core/TiltEventProcessor.h"
@@ -257,16 +258,6 @@ void PostLoadConfig() {
#endif
}
static Path GetFailedBackendsDir() {
Path failedBackendsDir;
if (System_GetPropertyBool(SYSPROP_SUPPORTS_PERMISSIONS)) {
failedBackendsDir = GetSysDirectory(DIRECTORY_APP_CACHE);
} else {
failedBackendsDir = GetSysDirectory(DIRECTORY_SYSTEM);
}
return failedBackendsDir;
}
static void CheckFailedGPUBackends() {
#ifdef _DEBUG
// If you're in debug mode, you probably don't want a fallback. If you're in release mode, use IGNORE below.
-1
View File
@@ -257,7 +257,6 @@ static bool LoadGameList(const Path &url, std::vector<Path> &games) {
browser.SetPath(url);
std::vector<File::FileInfo> files;
browser.SetUserAgent(StringFromFormat("PPSSPP/%s", PPSSPP_GIT_VERSION));
browser.SetRootAlias("ms:", GetSysDirectory(DIRECTORY_MEMSTICK_ROOT));
browser.GetListing(files, "iso:cso:chd:pbp:elf:prx:ppdmp:", &scanCancelled);
if (scanCancelled) {
return false;
+1 -52
View File
@@ -45,6 +45,7 @@
#include "Core/SaveState.h"
#include "Core/System.h"
#include "Core/HLE/sceUtility.h"
#include "UI/MiscViews.h"
class SavedataButton;
@@ -722,55 +723,3 @@ void SavedataScreen::sendMessage(UIMessage message, const char *value) {
stateBrowser_->SetSearchFilter(searchFilter_);
}
}
void GameImageView::GetContentDimensions(const UIContext &dc, float &w, float &h) const {
w = textureWidth_;
h = textureHeight_;
}
void GameImageView::Draw(UIContext &dc) {
using namespace UI;
std::shared_ptr<GameInfo> info = g_gameInfoCache->GetInfo(dc.GetDrawContext(), gamePath_, image_);
if (!info->Ready(image_) || !info->icon.texture) {
return;
}
Draw::Texture *texture = nullptr;
switch (image_) {
case GameInfoFlags::ICON:
texture = info->icon.texture;
break;
case GameInfoFlags::PIC0:
texture = info->pic0.texture;
break;
case GameInfoFlags::PIC1:
texture = info->pic1.texture;
break;
}
if (!texture) {
return;
}
textureWidth_ = texture->Width() * scale_;
textureHeight_ = texture->Height() * scale_;
// Fade icon with the backgrounds.
double loadTime = info->icon.timeLoaded;
auto pic = info->GetPIC1();
if (pic) {
loadTime = std::max(loadTime, pic->timeLoaded);
}
uint32_t color = whiteAlpha(ease((time_now_d() - loadTime) * 3));
// Adjust size so we don't stretch the image vertically or horizontally.
// Make sure it's not wider than 144 (like Doom Legacy homebrew), ugly in the grid mode.
float nw = std::min(bounds_.h * textureWidth_ / textureHeight_, (float)bounds_.w);
int x = bounds_.x + (bounds_.w - nw) / 2.0f;
dc.Flush();
dc.GetDrawContext()->BindTexture(0, texture);
dc.Draw()->Rect(x, bounds_.y, nw, bounds_.h, color);
dc.Flush();
dc.RebindTexture();
}
-17
View File
@@ -97,23 +97,6 @@ private:
std::string searchFilter_;
};
class GameImageView : public UI::InertView {
public:
GameImageView(const Path &gamePath, GameInfoFlags image, float scale, UI::LayoutParams *layoutParams = 0)
: InertView(layoutParams), image_(image), gamePath_(gamePath), scale_(scale) {}
void GetContentDimensions(const UIContext &dc, float &w, float &h) const override;
void Draw(UIContext &dc) override;
std::string DescribeText() const override { return ""; }
private:
Path gamePath_;
GameInfoFlags image_;
float scale_ = 1.0f;
int textureWidth_ = 0;
int textureHeight_ = 0;
};
class SavedataButton : public UI::Clickable {
public:
SavedataButton(const Path &gamePath, UI::LayoutParams *layoutParams = 0)
+3 -1
View File
@@ -315,6 +315,7 @@
<ClInclude Include="..\..\Core\Util\AtracTrack.h" />
<ClInclude Include="..\..\Core\Util\GameDB.h" />
<ClInclude Include="..\..\Core\Util\MemStick.h" />
<ClInclude Include="..\..\Core\Util\PathUtil.h" />
<ClInclude Include="..\..\Core\Util\PortManager.h" />
<ClInclude Include="..\..\Core\Util\RecentFiles.h" />
<ClInclude Include="..\..\Core\WebServer.h" />
@@ -621,6 +622,7 @@
<ClCompile Include="..\..\Core\Util\AtracTrack.cpp" />
<ClCompile Include="..\..\Core\Util\GameDB.cpp" />
<ClCompile Include="..\..\Core\Util\MemStick.cpp" />
<ClCompile Include="..\..\Core\Util\PathUtil.cpp" />
<ClCompile Include="..\..\Core\Util\PortManager.cpp" />
<ClCompile Include="..\..\Core\Util\RecentFiles.cpp" />
<ClCompile Include="..\..\Core\WebServer.cpp" />
@@ -1032,4 +1034,4 @@
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
<ImportGroup Label="ExtensionTargets">
</ImportGroup>
</Project>
</Project>
+5 -6
View File
@@ -75,6 +75,7 @@
<ClCompile Include="..\..\Core\HLE\sceNp2.cpp" />
<ClCompile Include="..\..\Core\HLE\sceReg.cpp" />
<ClCompile Include="..\..\Core\HLE\SocketManager.cpp" />
<ClCompile Include="..\..\Core\HW\GranularMixer.cpp" />
<ClCompile Include="..\..\Core\Instance.cpp" />
<ClCompile Include="..\..\Core\HLE\HLE.cpp" />
<ClCompile Include="..\..\Core\HLE\HLEHelperThread.cpp" />
@@ -165,7 +166,6 @@
<ClCompile Include="..\..\Core\HW\Atrac3Standalone.cpp" />
<ClCompile Include="..\..\Core\HW\SimpleAudioDec.cpp" />
<ClCompile Include="..\..\Core\HW\StereoResampler.cpp" />
<ClCompile Include="..\..\Core\HW\GranularMixer.cpp" />
<ClCompile Include="..\..\Core\KeyMap.cpp" />
<ClCompile Include="..\..\Core\KeyMapDefaults.cpp" />
<ClCompile Include="..\..\Core\Loaders.cpp" />
@@ -410,6 +410,7 @@
<ClCompile Include="..\..\ext\xbrz\xbrz.cpp" />
<ClCompile Include="..\..\ext\xxhash.c" />
<ClCompile Include="pch.cpp" />
<ClCompile Include="..\..\Core\Util\PathUtil.cpp" />
</ItemGroup>
<ItemGroup>
<ClInclude Include="..\..\Core\AVIDump.h" />
@@ -488,6 +489,7 @@
<ClInclude Include="..\..\Core\HLE\sceNp2.h" />
<ClInclude Include="..\..\Core\HLE\sceReg.h" />
<ClInclude Include="..\..\Core\HLE\SocketManager.h" />
<ClInclude Include="..\..\Core\HW\GranularMixer.h" />
<ClInclude Include="..\..\Core\Instance.h" />
<ClInclude Include="..\..\Core\HLE\FunctionWrappers.h" />
<ClInclude Include="..\..\Core\HLE\HLE.h" />
@@ -680,12 +682,9 @@
<ClInclude Include="..\..\ext\xxhash.h" />
<ClInclude Include="pch.h" />
<ClInclude Include="targetver.h" />
<<<<<<< HEAD
=======
<ClInclude Include="..\..\Core\HW\GranularMixer.h" />
>>>>>>> cfb162d436 (Integrate Dolphin's granule based audio resampler.)
<ClInclude Include="..\..\Core\Util\PathUtil.h" />
</ItemGroup>
<ItemGroup>
<None Include="..\..\ext\gason\LICENSE" />
</ItemGroup>
</Project>
</Project>
+1
View File
@@ -758,6 +758,7 @@ EXEC_AND_LIB_FILES := \
$(SRC)/Core/Util/AtracTrack.cpp \
$(SRC)/Core/Util/AudioFormat.cpp \
$(SRC)/Core/Util/MemStick.cpp \
$(SRC)/Core/Util/PathUtil.cpp \
$(SRC)/Core/Util/PortManager.cpp \
$(SRC)/Core/Util/GameDB.cpp \
$(SRC)/Core/Util/GameManager.cpp \
+1
View File
@@ -1010,6 +1010,7 @@ Some network functionality in this game is not working = Some network functional
To play in Infrastructure Mode, you must enter a username = To play in Infrastructure Mode, you must enter a username
Transfer files = نقل الملفات
Unable to find UPnP device = Unable to find UPnP device
Upload files = رفع الملفات
UPnP (port-forwarding) = UPnP (port forwarding)
UPnP need to be reinitialized = UPnP need to be reinitialized
UPnP use original port = UPnP use original port (enabled = PSP compatibility)
+1
View File
@@ -1005,6 +1005,7 @@ Some network functionality in this game is not working = Bu oyundakı bəzi bağ
To play in Infrastructure Mode, you must enter a username = İnfrastruktur Modunda oynamaq üçün işlədici adı yazmalısınız
Transfer files = Faylları köçürmək
Unable to find UPnP device = UPnP qurğusu tapılmır
Upload files = Faylları yükləyin
UPnP (port-forwarding) = UPnP (port yönləndirməsi)
UPnP need to be reinitialized = UPnP, yenidən başladılmalıdır
UPnP use original port = UPnP doğma portu işlədir (açıqdır = PSP uyumluğu)
+1
View File
@@ -969,6 +969,7 @@ Some network functionality in this game is not working = Some network functional
To play in Infrastructure Mode, you must enter a username = To play in Infrastructure Mode, you must enter a username
Transfer files = Перадаць файлы
Unable to find UPnP device = Unable to find UPnP device
Upload files = Загрузіць файлы
UPnP (port-forwarding) = UPnP (port forwarding)
UPnP need to be reinitialized = UPnP need to be reinitialized
UPnP use original port = UPnP use original port (enabled = PSP compatibility)
+1
View File
@@ -1002,6 +1002,7 @@ Some network functionality in this game is not working = Some network functional
To play in Infrastructure Mode, you must enter a username = To play in Infrastructure Mode, you must enter a username
Transfer files = Прехвърляне на файлове
Unable to find UPnP device = Unable to find UPnP device
Upload files = Качване на файлове
UPnP (port-forwarding) = UPnP (port forwarding)
UPnP need to be reinitialized = UPnP need to be reinitialized
UPnP use original port = UPnP use original port (enabled = PSP compatibility)
+1
View File
@@ -1002,6 +1002,7 @@ Some network functionality in this game is not working = Some network functional
To play in Infrastructure Mode, you must enter a username = To play in Infrastructure Mode, you must enter a username
Transfer files = Transferir fitxers
Unable to find UPnP device = Unable to find UPnP device
Upload files = Pujar fitxers
UPnP (port-forwarding) = UPnP (port forwarding)
UPnP need to be reinitialized = UPnP need to be reinitialized
UPnP use original port = UPnP use original port (enabled = PSP compatibility)
+1
View File
@@ -1002,6 +1002,7 @@ Some network functionality in this game is not working = Some network functional
To play in Infrastructure Mode, you must enter a username = To play in Infrastructure Mode, you must enter a username
Transfer files = Přenos souborů
Unable to find UPnP device = Unable to find UPnP device
Upload files = Nahrát soubory
UPnP (port-forwarding) = UPnP (port forwarding)
UPnP need to be reinitialized = UPnP need to be reinitialized
UPnP use original port = UPnP use original port (enabled = PSP compatibility)
+1
View File
@@ -1002,6 +1002,7 @@ Some network functionality in this game is not working = Some network functional
To play in Infrastructure Mode, you must enter a username = To play in Infrastructure Mode, you must enter a username
Transfer files = Overfør filer
Unable to find UPnP device = Unable to find UPnP device
Upload files = Upload filer
UPnP (port-forwarding) = UPnP (port forwarding)
UPnP need to be reinitialized = UPnP need to be reinitialized
UPnP use original port = UPnP use original port (enabled = PSP compatibility)
+1
View File
@@ -991,6 +991,7 @@ Some network functionality in this game is not working = Einige Netzwerkfunktion
To play in Infrastructure Mode, you must enter a username = Um im Infrastrukturmodus zu spielen, musst du einen Benutzernamen eingeben
Transfer files = Dateien übertragen
Unable to find UPnP device = UPnP-Gerät konnte nicht gefunden werden
Upload files = Dateien hochladen
UPnP (port-forwarding) = UPnP (Port-Weiterleitung)
UPnP need to be reinitialized = UPnP muss neu initialisiert werden
UPnP use original port = UPnP-Original-Port verwenden (aktiviert = PSP-Kompatibilität)
+1
View File
@@ -1002,6 +1002,7 @@ Some network functionality in this game is not working = Some network functional
To play in Infrastructure Mode, you must enter a username = To play in Infrastructure Mode, you must enter a username
Transfer files = Transfer file
Unable to find UPnP device = Unable to find UPnP device
Upload files = Unggah file
UPnP (port-forwarding) = UPnP (port forwarding)
UPnP need to be reinitialized = UPnP need to be reinitialized
UPnP use original port = UPnP use original port (enabled = PSP compatibility)
+1
View File
@@ -993,6 +993,7 @@ Some network functionality in this game is not working = Some network functional
To play in Infrastructure Mode, you must enter a username = To play in Infrastructure Mode, you must enter a username
Transfer files = Transfer files
Unable to find UPnP device = Unable to find UPnP device
Upload files = Upload files
UPnP (port-forwarding) = UPnP (port forwarding)
UPnP need to be reinitialized = UPnP need to be reinitialized
UPnP use original port = UPnP use original port (enabled = PSP compatibility)
+1
View File
@@ -1003,6 +1003,7 @@ Some network functionality in this game is not working = Algunas funciones de re
To play in Infrastructure Mode, you must enter a username = Para jugar en el modo Infraestructura, debes introducir un nombre de usuario
Transfer files = Transferir archivos
Unable to find UPnP device = Dispositivo UPnP no encontrado
Upload files = Subir archivos
UPnP (port-forwarding) = UPnP (redirección de puertos)
UPnP need to be reinitialized = Es necesario reiniciar UPnP
UPnP use original port = UPnP usa puerto original (activado = compatibilidad PSP)
+1
View File
@@ -1002,6 +1002,7 @@ Some network functionality in this game is not working = Some network functional
To play in Infrastructure Mode, you must enter a username = To play in Infrastructure Mode, you must enter a username
Transfer files = Transferir archivos
Unable to find UPnP device = No se encuentra el dispositivo UPnP
Upload files = Subir archivos
UPnP (port-forwarding) = UPnP (redirección de puertos)
UPnP need to be reinitialized = La función de UPnP debe reinicializarse.
UPnP use original port = Usar puerto UPnP de PSP (activado = más compatible con PSP )
+1
View File
@@ -1002,6 +1002,7 @@ Some network functionality in this game is not working = Some network functional
To play in Infrastructure Mode, you must enter a username = To play in Infrastructure Mode, you must enter a username
Transfer files = انتقال فایل‌ها
Unable to find UPnP device = پیدا کردن دستگاه UPnP ممکن نیست
Upload files = بارگذاری فایل‌ها
UPnP (port-forwarding) = UPnP (هدایت درگاه)
UPnP need to be reinitialized = UPnP باید بازراه‌اندازی شود
UPnP use original port = استفاده از درگاه اصلی UPnP (فعال = سازگاری با PSP)
+1
View File
@@ -1002,6 +1002,7 @@ Some network functionality in this game is not working = Some network functional
To play in Infrastructure Mode, you must enter a username = To play in Infrastructure Mode, you must enter a username
Transfer files = Siirrä tiedostoja
Unable to find UPnP device = Unable to find UPnP device
Upload files = Lataa tiedostoja
UPnP (port-forwarding) = UPnP (port forwarding)
UPnP need to be reinitialized = UPnP need to be reinitialized
UPnP use original port = UPnP use original port (enabled = PSP compatibility)
+1
View File
@@ -1002,6 +1002,7 @@ Some network functionality in this game is not working = Some network functional
To play in Infrastructure Mode, you must enter a username = To play in Infrastructure Mode, you must enter a username
Transfer files = Transférer des fichiers
Unable to find UPnP device = Appareil UPnP introuvable
Upload files = Télécharger des fichiers
UPnP (port-forwarding) = UPnP (redirection de port)
UPnP need to be reinitialized = UPnP doit être réinitialisé
UPnP use original port = Utiliser les ports originaux avec UPnP (activé = compatibilité PSP)
+1
View File
@@ -1002,6 +1002,7 @@ Some network functionality in this game is not working = Some network functional
To play in Infrastructure Mode, you must enter a username = To play in Infrastructure Mode, you must enter a username
Transfer files = Transferir arquivos
Unable to find UPnP device = Unable to find UPnP device
Upload files = Subir ficheiros
UPnP (port-forwarding) = UPnP (port forwarding)
UPnP need to be reinitialized = UPnP need to be reinitialized
UPnP use original port = UPnP use original port (enabled = PSP compatibility)
+1
View File
@@ -1002,6 +1002,7 @@ Some network functionality in this game is not working = Some network functional
To play in Infrastructure Mode, you must enter a username = To play in Infrastructure Mode, you must enter a username
Transfer files = Μεταφορά αρχείων
Unable to find UPnP device = Unable to find UPnP device
Upload files = Ανεβάστε αρχεία
UPnP (port-forwarding) = UPnP (port forwarding)
UPnP need to be reinitialized = UPnP need to be reinitialized
UPnP use original port = UPnP use original port (enabled = PSP compatibility)
+1
View File
@@ -1002,6 +1002,7 @@ Some network functionality in this game is not working = Some network functional
To play in Infrastructure Mode, you must enter a username = To play in Infrastructure Mode, you must enter a username
Transfer files = העבר קבצים
Unable to find UPnP device = Unable to find UPnP device
Upload files = העלה קבצים
UPnP (port-forwarding) = UPnP (port forwarding)
UPnP need to be reinitialized = UPnP need to be reinitialized
UPnP use original port = UPnP use original port (enabled = PSP compatibility)
+1
View File
@@ -999,6 +999,7 @@ Some network functionality in this game is not working = Some network functional
To play in Infrastructure Mode, you must enter a username = To play in Infrastructure Mode, you must enter a username
Transfer files = קבצים העבר
Unable to find UPnP device = Unable to find UPnP device
Upload files = םִשָּׁא חֶבַּק
UPnP (port-forwarding) = UPnP (port forwarding)
UPnP need to be reinitialized = UPnP need to be reinitialized
UPnP use original port = UPnP use original port (enabled = PSP compatibility)
+1
View File
@@ -1002,6 +1002,7 @@ Some network functionality in this game is not working = Some network functional
To play in Infrastructure Mode, you must enter a username = To play in Infrastructure Mode, you must enter a username
Transfer files = Prenesi datoteke
Unable to find UPnP device = Unable to find UPnP device
Upload files = Otprema datoteka
UPnP (port-forwarding) = UPnP (port forwarding)
UPnP need to be reinitialized = UPnP need to be reinitialized
UPnP use original port = UPnP use original port (enabled = PSP compatibility)
+1
View File
@@ -1002,6 +1002,7 @@ Some network functionality in this game is not working = Some network functional
To play in Infrastructure Mode, you must enter a username = To play in Infrastructure Mode, you must enter a username
Transfer files = Fájlok átvitele
Unable to find UPnP device = UPnP eszköz nem található
Upload files = Fájlok feltöltése
UPnP (port-forwarding) = UPnP (port átirányítás)
UPnP need to be reinitialized = UPnP újra-inicializálás szükséges
UPnP use original port = UPnP eredeti portot használja (be = PSP kompatibilitás)
+1
View File
@@ -1002,6 +1002,7 @@ Some network functionality in this game is not working = Beberapa fungsi jaringa
To play in Infrastructure Mode, you must enter a username = Untuk bermain dalam Mode Infrastruktur, Anda harus memasukkan nama pengguna
Transfer files = Transfer file
Unable to find UPnP device = Tidak dapat menemukan perangkat UPnP
Upload files = Unggah berkas
UPnP (port-forwarding) = UPnP (penerusan port)
UPnP need to be reinitialized = UPnP perlu diinisialisasi ulang
UPnP use original port = UPnP menggunakan port asli (diaktifkan = kompatibilitas PSP)
+1
View File
@@ -970,6 +970,7 @@ Some network functionality in this game is not working = Alcune funzionalità di
To play in Infrastructure Mode, you must enter a username = Per giocare in modalità Infrastruttura, è necessario inserire un nome utente
Transfer files = Trasferisci file
Unable to find UPnP device = Impossibile trovare il dispositivo UPnP
Upload files = Carica file
UPnP (port-forwarding) = UPnP (reindirizzamento della porta)
UPnP need to be reinitialized = UPnP dev'essere reinizializzato
UPnP use original port = Usa la porta originale di UPnP (attiva = compatibilità PSP)
+1
View File
@@ -969,6 +969,7 @@ Some network functionality in this game is not working = このゲームの一
To play in Infrastructure Mode, you must enter a username = インフラストラクチャモードでプレイするには、ユーザー名を入力する必要があります
Transfer files = ファイルを転送
Unable to find UPnP device = UPnPデバイスがみつかりません
Upload files = ファイルをアップロード
UPnP (port-forwarding) = UPnP(ポートフォワーディング)
UPnP need to be reinitialized = UPnPの再初期化が必要です
UPnP use original port = UPnPでオリジナルのポートを使用する (有効 = PSP互換)
+1
View File
@@ -1002,6 +1002,7 @@ Some network functionality in this game is not working = Some network functional
To play in Infrastructure Mode, you must enter a username = To play in Infrastructure Mode, you must enter a username
Transfer files = Transfer file
Unable to find UPnP device = Unable to find UPnP device
Upload files = Upload file
UPnP (port-forwarding) = UPnP (port forwarding)
UPnP need to be reinitialized = UPnP need to be reinitialized
UPnP use original port = UPnP use original port (enabled = PSP compatibility)
+1
View File
@@ -969,6 +969,7 @@ Some network functionality in this game is not working = 이 게임의 일부
To play in Infrastructure Mode, you must enter a username = 인프라 모드에서 플레이하려면 사용자 이름을 입력해야 함
Transfer files = 파일 전송
Unable to find UPnP device = UPnP 장치를 찾을 수 없습니다.
Upload files = 파일 업로드
UPnP (port-forwarding) = UPnP (포트 포워딩)
UPnP need to be reinitialized = UPnP를 다시 초기화해야 합니다.
UPnP use original port = UPnP는 원래 포트를 사용합니다 (활성화됨 = PSP 호환성)
+1
View File
@@ -983,6 +983,7 @@ Some network functionality in this game is not working = Some network functional
To play in Infrastructure Mode, you must enter a username = To play in Infrastructure Mode, you must enter a username
Transfer files = Pelanên transfer bike
Unable to find UPnP device = Unable to find UPnP device
Upload files = Pelên barkirin
UPnP (port-forwarding) = UPnP (port forwarding)
UPnP need to be reinitialized = UPnP need to be reinitialized
UPnP use original port = UPnP use original port (enabled = PSP compatibility)
+1
View File
@@ -1002,6 +1002,7 @@ Some network functionality in this game is not working = Some network functional
To play in Infrastructure Mode, you must enter a username = To play in Infrastructure Mode, you must enter a username
Transfer files = ເກັບໃສ່ໄຟລ໌
Unable to find UPnP device = Unable to find UPnP device
Upload files = ເອົາໄຟລ໌
UPnP (port-forwarding) = UPnP (port forwarding)
UPnP need to be reinitialized = UPnP need to be reinitialized
UPnP use original port = UPnP use original port (enabled = PSP compatibility)
+1
View File
@@ -1002,6 +1002,7 @@ Some network functionality in this game is not working = Some network functional
To play in Infrastructure Mode, you must enter a username = To play in Infrastructure Mode, you must enter a username
Transfer files = Perkelti failus
Unable to find UPnP device = Unable to find UPnP device
Upload files = Įkelti failus
UPnP (port-forwarding) = UPnP (port forwarding)
UPnP need to be reinitialized = UPnP need to be reinitialized
UPnP use original port = UPnP use original port (enabled = PSP compatibility)
+1
View File
@@ -1002,6 +1002,7 @@ Some network functionality in this game is not working = Some network functional
To play in Infrastructure Mode, you must enter a username = To play in Infrastructure Mode, you must enter a username
Transfer files = Pindahkan fail
Unable to find UPnP device = Unable to find UPnP device
Upload files = Muat naik fail
UPnP (port-forwarding) = UPnP (port forwarding)
UPnP need to be reinitialized = UPnP need to be reinitialized
UPnP use original port = UPnP use original port (enabled = PSP compatibility)
+1
View File
@@ -1002,6 +1002,7 @@ Some network functionality in this game is not working = Some network functional
To play in Infrastructure Mode, you must enter a username = To play in Infrastructure Mode, you must enter a username
Transfer files = Bestanden overdragen
Unable to find UPnP device = Unable to find UPnP device
Upload files = Bestanden uploaden
UPnP (port-forwarding) = UPnP (port forwarding)
UPnP need to be reinitialized = UPnP need to be reinitialized
UPnP use original port = UPnP use original port (enabled = PSP compatibility)
+1
View File
@@ -1002,6 +1002,7 @@ Some network functionality in this game is not working = Some network functional
To play in Infrastructure Mode, you must enter a username = To play in Infrastructure Mode, you must enter a username
Transfer files = Overfør filer
Unable to find UPnP device = Unable to find UPnP device
Upload files = Last opp filer
UPnP (port-forwarding) = UPnP (port forwarding)
UPnP need to be reinitialized = UPnP need to be reinitialized
UPnP use original port = UPnP use original port (enabled = PSP compatibility)
+1
View File
@@ -998,6 +998,7 @@ Some network functionality in this game is not working = Niektóre funkcje sieci
To play in Infrastructure Mode, you must enter a username = Aby grać w trybie infrastruktury, musisz wprowadzić nazwę użytkownika.
Transfer files = Przenieś pliki
Unable to find UPnP device = Nie udało się zlokalizować urządzenia UPnP
Upload files = Prześlij pliki
UPnP (port-forwarding) = UPnP (przekierowanie portów)
UPnP need to be reinitialized = Należy ponownie zainicjować UPnP
UPnP use original port = UPnP używa oryginalnego portu (włączone = kompatybilność z PSP)
+1
View File
@@ -992,6 +992,7 @@ Some network functionality in this game is not working = Algumas funcionalidades
To play in Infrastructure Mode, you must enter a username = Pra jogar no Modo de Infra-estrutura você deve inserir um nome de usuário
Transfer files = Transferir arquivos
Unable to find UPnP device = Incapaz de achar o dispositivo UPnP
Upload files = Enviar arquivos
UPnP (port-forwarding) = UPnP (abertura das portas)
UPnP need to be reinitialized = O UPnP precisa ser reinicializado
UPnP use original port = O UPnP usa a porta original (ativado = compatibilidade com o PSP)
+1
View File
@@ -994,6 +994,7 @@ Some network functionality in this game is not working = Some network functional
To play in Infrastructure Mode, you must enter a username = To play in Infrastructure Mode, you must enter a username
Transfer files = Transferir ficheiros
Unable to find UPnP device = Não é possível encontrar o dispositivo UPnP
Upload files = Carregar ficheiros
UPnP (port-forwarding) = UPnP (abertura das portas)
UPnP need to be reinitialized = O UPnP precisa ser reiniciado
UPnP use original port = O UPnP usa a porta original (ativado = compatibilidade com a PSP)
+1
View File
@@ -1003,6 +1003,7 @@ Some network functionality in this game is not working = Some network functional
To play in Infrastructure Mode, you must enter a username = To play in Infrastructure Mode, you must enter a username
Transfer files = Transferați fișiere
Unable to find UPnP device = Unable to find UPnP device
Upload files = Încărcați fișiere
UPnP (port-forwarding) = UPnP (port forwarding)
UPnP need to be reinitialized = UPnP need to be reinitialized
UPnP use original port = UPnP use original port (enabled = PSP compatibility)
+1
View File
@@ -969,6 +969,7 @@ Some network functionality in this game is not working = Некоторые се
To play in Infrastructure Mode, you must enter a username = Для игры в режиме инфраструктуры необходимо ввести имя пользователя
Transfer files = Перенос файлов
Unable to find UPnP device = Невозможно найти устройство UPnP
Upload files = Загрузить файлы
UPnP (port-forwarding) = UPnP (проброс портов)
UPnP need to be reinitialized = Необходимо перезапустить UPnP
UPnP use original port = Использовать оригинальный порт UPnP (включено = совместимость с PSP)
+1
View File
@@ -970,6 +970,7 @@ Some network functionality in this game is not working = Viss nätverksfunktiona
To play in Infrastructure Mode, you must enter a username = För att spela i infrastrukturläge måste du ange ett användarnamn
Transfer files = Överför filer
Unable to find UPnP device = Kunde inte hitta UPnP-enhet
Upload files = Ladda upp filer
UPnP (port-forwarding) = UPnP (port forwarding)
UPnP need to be reinitialized = UPnP behöver ominitialiseras
UPnP use original port = UPnP use original port (enabled = PSP compatibility)
+1
View File
@@ -1003,6 +1003,7 @@ Some network functionality in this game is not working = Some network functional
To play in Infrastructure Mode, you must enter a username = To play in Infrastructure Mode, you must enter a username
Transfer files = Файли интиқол кунед
Unable to find UPnP device = Hindi mahanap ang UPnP device
Upload files = Гирифтан файли
UPnP (port-forwarding) = UPnP (pagpapasa ng port)
UPnP need to be reinitialized = Kailangang muling simulan ang UPnP
UPnP use original port = Gamitin ang orihinal na port ng UPnP (enabled = PSP compatibility)
+1
View File
@@ -1021,6 +1021,7 @@ Some network functionality in this game is not working = ฟังก์ชั
To play in Infrastructure Mode, you must enter a username = การเล่นในโหมด Infrastructure คุณจะต้องป้อนชื่อผู้ใช้งาน
Transfer files = โอนไฟล์
Unable to find UPnP device = ไม่พบอุปกรณ์ UPnP
Upload files = อัพโหลดไฟล์
UPnP (port-forwarding) = โพรโตคอล UPnP (ฟอร์เวิร์ด พอร์ต อัตโนมัติ)
UPnP need to be reinitialized = UPnP จำเป็นต้องเริ่มการทำงานใหม่
UPnP use original port = UPnP ใช้พอร์ตค่าเริ่มต้น (เปิดใช้งาน = เล่นกับเครื่อง PSP)
+1
View File
@@ -1004,6 +1004,7 @@ Some network functionality in this game is not working = Bu oyundaki bazı ağ i
To play in Infrastructure Mode, you must enter a username = Altyapı modunda oynamak için bir kullanıcı adı girmelisiniz
Transfer files = Dosyaları aktar
Unable to find UPnP device = UPnP cihazı bulunamıyor
Upload files = Dosya yükle
UPnP (port-forwarding) = UPnP (Port Yönlendirme)
UPnP need to be reinitialized = UPnP yeniden başlatılmalı
UPnP use original port = UPnP Orijinal Port Kullan
+1
View File
@@ -1002,6 +1002,7 @@ Some network functionality in this game is not working = Some network functional
To play in Infrastructure Mode, you must enter a username = To play in Infrastructure Mode, you must enter a username
Transfer files = Передати файли
Unable to find UPnP device = Неможливо знайти пристрій UPnP
Upload files = Завантажити файли
UPnP (port-forwarding) = UPnP (переадресація портів)
UPnP need to be reinitialized = UPnP необхідно повторно ініціалізувати
UPnP use original port = UPnP використовує оригінальний порт (увімкнуто = PSP сумісність)
+1
View File
@@ -1002,6 +1002,7 @@ Some network functionality in this game is not working = Some network functional
To play in Infrastructure Mode, you must enter a username = To play in Infrastructure Mode, you must enter a username
Transfer files = Chuyển tệp
Unable to find UPnP device = Unable to find UPnP device
Upload files = Tải lên tệp
UPnP (port-forwarding) = UPnP (port forwarding)
UPnP need to be reinitialized = UPnP need to be reinitialized
UPnP use original port = UPnP use original port (enabled = PSP compatibility)
+1
View File
@@ -1003,6 +1003,7 @@ Some network functionality in this game is not working = 此游戏中的某些
To play in Infrastructure Mode, you must enter a username = 您必须输入用户名,才能在基础模式下游玩
Transfer files = 传输文件
Unable to find UPnP device = 未找到UPnP设备
Upload files = 上传文件
UPnP (port-forwarding) = UPnP (端口转发)
UPnP need to be reinitialized = UPnP 需要重新初始化
UPnP use original port = UPnP 使用原始端口 (启用=兼容PSP)
+1
View File
@@ -969,6 +969,7 @@ Some network functionality in this game is not working = 此遊戲中的某些
To play in Infrastructure Mode, you must enter a username = 您必須輸入使用者名稱,才能在基礎模式下游玩
Transfer files = 傳輸檔案
Unable to find UPnP device = 找不到 UPnP 裝置
Upload files = 上傳檔案
UPnP (port-forwarding) = UPnP (連接埠轉送)
UPnP need to be reinitialized = UPnP 需要重新初始化
UPnP use original port = UPnP 使用原始連接埠 (已啟用 = PSP 相容性)
+1
View File
@@ -887,6 +887,7 @@ SOURCES_CXX += \
$(COREDIR)/Util/PPGeDraw.cpp \
$(COREDIR)/Util/RecentFiles.cpp \
$(COREDIR)/Util/AudioFormat.cpp \
$(COREDIR)/Util/PathUtil.cpp \
$(COREDIR)/Util/PortManager.cpp \
$(CORE_DIR)/UI/GameInfoCache.cpp