mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-04-26 22:38:34 +00:00
WFSI: Implement patch install finalization.
This commit is contained in:
parent
76bbfbb511
commit
a641609857
3 changed files with 24 additions and 6 deletions
|
@ -521,7 +521,7 @@ bool DeleteDirRecursively(const std::string& directory)
|
|||
}
|
||||
|
||||
// Create directory and copy contents (does not overwrite existing files)
|
||||
void CopyDir(const std::string& source_path, const std::string& dest_path)
|
||||
void CopyDir(const std::string& source_path, const std::string& dest_path, bool destructive)
|
||||
{
|
||||
if (source_path == dest_path)
|
||||
return;
|
||||
|
@ -562,10 +562,16 @@ void CopyDir(const std::string& source_path, const std::string& dest_path)
|
|||
{
|
||||
if (!Exists(dest))
|
||||
File::CreateFullPath(dest + DIR_SEP);
|
||||
CopyDir(source, dest);
|
||||
CopyDir(source, dest, destructive);
|
||||
}
|
||||
else if (!Exists(dest) && !destructive)
|
||||
{
|
||||
Copy(source, dest);
|
||||
}
|
||||
else
|
||||
{
|
||||
Rename(source, dest);
|
||||
}
|
||||
else if (!Exists(dest))
|
||||
File::Copy(source, dest);
|
||||
#ifdef _WIN32
|
||||
} while (FindNextFile(hFind, &ffd) != 0);
|
||||
FindClose(hFind);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue