mirror of
https://github.com/greenshot/greenshot
synced 2025-08-14 10:47:02 -07:00
BUG-2114 & BUG-1992: Hopefully implemented this more stable as it used to be.
This commit is contained in:
parent
73bdd0f405
commit
0b2cbe1c0b
4 changed files with 43 additions and 16 deletions
|
@ -342,9 +342,8 @@ namespace GreenshotPlugin.Core {
|
|||
case "OutputFileAsFullpath":
|
||||
if (IniConfig.IsPortable) {
|
||||
return Path.Combine(Application.StartupPath, @"..\..\Documents\Pictures\Greenshots\dummy.png");
|
||||
} else {
|
||||
return Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.Desktop),"dummy.png");
|
||||
}
|
||||
return Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.Desktop),"dummy.png");
|
||||
case "OutputFilePath":
|
||||
if (IniConfig.IsPortable) {
|
||||
string pafOutputFilePath = Path.Combine(Application.StartupPath, @"..\..\Documents\Pictures\Greenshots");
|
||||
|
@ -515,16 +514,6 @@ namespace GreenshotPlugin.Core {
|
|||
if (WebRequestReadWriteTimeout < 1) {
|
||||
WebRequestReadWriteTimeout = 100;
|
||||
}
|
||||
|
||||
// Added for BUG-1992, reset the OutputFilePath / OutputFileAsFullpath if they don't exist (e.g. the configuration is used on a different PC)
|
||||
if (!Directory.Exists(OutputFilePath))
|
||||
{
|
||||
OutputFilePath = GetDefault(nameof(OutputFilePath)) as string;
|
||||
}
|
||||
if (!File.Exists(OutputFileAsFullpath))
|
||||
{
|
||||
OutputFileAsFullpath = GetDefault(nameof(OutputFileAsFullpath)) as string;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue