Merge branch 'master' of github.com:ShareX/ShareX

This commit is contained in:
Jaex 2015-01-07 01:56:10 +02:00
commit 86ac891748
3 changed files with 22 additions and 2 deletions

View file

@ -661,7 +661,15 @@ public static void CreateDirectoryIfNotExist(string path, bool isFilePath = true
if (!string.IsNullOrEmpty(path) && !Directory.Exists(path))
{
Directory.CreateDirectory(path);
try
{
Directory.CreateDirectory(path);
}
catch (Exception e)
{
DebugHelper.WriteException(e);
MessageBox.Show(Resources.Helpers_CreateDirectoryIfNotExist_Create_failed_ + "\r\n" + e, "ShareX", MessageBoxButtons.OK, MessageBoxIcon.Error);
}
}
}
}

View file

@ -1,7 +1,7 @@
//------------------------------------------------------------------------------
// <auto-generated>
// This code was generated by a tool.
// Runtime Version:4.0.30319.34209
// Runtime Version:4.0.30319.18444
//
// Changes to this file may cause incorrect behavior and will be lost if
// the code is regenerated.
@ -672,6 +672,15 @@ internal static string HashCheckForm_fileCheck_FileCheckCompleted_Start {
}
}
/// <summary>
/// Looks up a localized string similar to Could not create directory, check your path settings:.
/// </summary>
internal static string Helpers_CreateDirectoryIfNotExist_Create_failed_ {
get {
return ResourceManager.GetString("Helpers_CreateDirectoryIfNotExist_Create_failed_", resourceCulture);
}
}
/// <summary>
/// Looks up a localized string similar to Download failed:.
/// </summary>

View file

@ -616,4 +616,7 @@ Would you like to download and install it?</value>
<data name="UpdateMessageBox_UpdateMessageBox_update_is_available" xml:space="preserve">
<value>Update is available</value>
</data>
<data name="Helpers_CreateDirectoryIfNotExist_Create_failed_" xml:space="preserve">
<value>Could not create directory, check your path settings:</value>
</data>
</root>