diff options
| author | Thomas Tanner <trtanner@btinternet.com> | 2015-12-05 10:21:44 +0000 |
|---|---|---|
| committer | Thomas Tanner <trtanner@btinternet.com> | 2015-12-05 10:21:44 +0000 |
| commit | ec9c78f8fa49ce960fb708d4a140c44ed3130989 (patch) | |
| tree | c6601b7045432caa5295b5cd1a4b51c6f19f5cb1 /src/shared/gameinfo.cpp | |
| parent | 7f9af7f93e1d06d021fd60bf4845d928f4a6bc38 (diff) | |
| parent | 688e149c96c29d8249c9db416f5773cfc7baad6d (diff) | |
Merge remote-tracking branch 'TanninOne/master'
# Conflicts:
# SConstruct
# src/modinfo.cpp
# src/modinfo.h
Diffstat (limited to 'src/shared/gameinfo.cpp')
| -rw-r--r-- | src/shared/gameinfo.cpp | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/src/shared/gameinfo.cpp b/src/shared/gameinfo.cpp index 1f25cec1..5338c069 100644 --- a/src/shared/gameinfo.cpp +++ b/src/shared/gameinfo.cpp @@ -86,6 +86,19 @@ void GameInfo::identifyMyGamesDirectory(const std::wstring &file) }
}
+bool GameInfo::isValidModURL(int modID, const std::wstring &url, const std::wstring &alt) const
+{
+ std::wostringstream os;
+ os << getNexusPage(false) << "/mods/" << modID;
+ if (url == os.str()) {
+ return true;
+ }
+ os.clear();
+ os.str(L"");
+ os << alt << "/mods/" << modID;
+ return url == os.str();
+}
+
bool GameInfo::identifyGame(const std::wstring &moDirectory, const std::wstring &moDataDirectory, const std::wstring &searchPath)
{
|
