MCPcopy Create free account
hub / github.com/RGAA-Software/GoDesk / FindInSteamManager

Method FindInSteamManager

src/render_panel/gr_run_game_manager.cpp:147–165  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

145 }
146
147 std::shared_ptr<SteamApp> GrRunGameManager::FindInSteamManager(const std::string& game_path) {
148 if (!SteamManager::IsSteamPath(game_path)) {
149 LOGI("path: {} is not a steam url", game_path);
150 return nullptr;
151 }
152
153 auto app_id = SteamManager::ParseSteamIdFromPath(game_path);
154 if (app_id.empty()) {
155 LOGE("Invalid steam url: {}", game_path);
156 return nullptr;
157 }
158 const auto& games = this->steam_mgr_->GetInstalledGames();
159 for (auto& game : games) {
160 if (game->app_id_ == std::atoi(app_id.c_str())) {
161 return game;
162 }
163 }
164 return nullptr;
165 }
166
167 std::shared_ptr<TcDBGame> GrRunGameManager::FindInDBGameManager(const std::string& game_path) {
168 if (SteamManager::IsSteamPath(game_path)) {

Callers

nothing calls this directly

Calls 1

GetInstalledGamesMethod · 0.80

Tested by

no test coverage detected