* @brief Open project-file. */
| 2357 | * @brief Open project-file. |
| 2358 | */ |
| 2359 | void CMainFrame::OnFileOpenProject() |
| 2360 | { |
| 2361 | String sFilepath; |
| 2362 | |
| 2363 | // get the default projects path |
| 2364 | String strProjectPath = GetOptionsMgr()->GetString(OPT_PROJECTS_PATH); |
| 2365 | if (!SelectFile(GetSafeHwnd(), sFilepath, true, strProjectPath.c_str(), _T(""), |
| 2366 | _("WinMerge Project Files (*.WinMerge)|*.WinMerge||"))) |
| 2367 | return; |
| 2368 | |
| 2369 | strProjectPath = paths::GetParentPath(sFilepath); |
| 2370 | // store this as the new project path |
| 2371 | GetOptionsMgr()->SaveOption(OPT_PROJECTS_PATH, strProjectPath); |
| 2372 | |
| 2373 | theApp.LoadAndOpenProjectFile(sFilepath); |
| 2374 | } |
| 2375 | |
| 2376 | /** |
| 2377 | * @brief Receive command line from another instance. |
nothing calls this directly
no test coverage detected