示例#1
0
std::wstring Environment::GetDataPath()
{
    if (IsInstalled() || IsAppContainerProcess())
    {
        return IO::Path::Combine(
                   GetKnownFolderPath(FOLDERID_LocalAppData),
                   TEXT("PicoTorrent"));
    }

    return GetApplicationPath();
}
示例#2
0
文件: path.cpp 项目: erengy/taiga
std::wstring GetDataPath() {
  std::wstring path;

#ifdef TAIGA_PORTABLE
  // Return current path in portable mode
  path = GetPathOnly(Taiga.GetModulePath());
#else
  // Return %AppData% folder
  path = GetKnownFolderPath(FOLDERID_RoamingAppData);
  AddTrailingSlash(path);
  path += TAIGA_APP_NAME;
#endif

  AddTrailingSlash(path);
  return path + L"data\\";
}