summaryrefslogtreecommitdiff
path: root/shared/dragAndDrop.cpp
diff options
context:
space:
mode:
authorDaniel Wilhelm <daniel@wili.li>2014-04-18 17:07:43 +0200
committerDaniel Wilhelm <daniel@wili.li>2014-04-18 17:07:43 +0200
commit4226e548662339ea1ca37b45385a7cf9b237ff1e (patch)
tree9a3fa54b85d97f05164e41bdb96b82f748a37342 /shared/dragAndDrop.cpp
parent3.7 (diff)
downloadFreeFileSync-4226e548662339ea1ca37b45385a7cf9b237ff1e.tar.gz
FreeFileSync-4226e548662339ea1ca37b45385a7cf9b237ff1e.tar.bz2
FreeFileSync-4226e548662339ea1ca37b45385a7cf9b237ff1e.zip
3.8
Diffstat (limited to 'shared/dragAndDrop.cpp')
-rw-r--r--shared/dragAndDrop.cpp8
1 files changed, 5 insertions, 3 deletions
diff --git a/shared/dragAndDrop.cpp b/shared/dragAndDrop.cpp
index 581aac96..c5919e76 100644
--- a/shared/dragAndDrop.cpp
+++ b/shared/dragAndDrop.cpp
@@ -13,6 +13,8 @@
#include <wx/filename.h>
#include "fileHandling.h"
#include "stringConv.h"
+#include "checkExist.h"
+
//define new event type
const wxEventType FFS_DROP_FILE_EVENT = wxNewEventType();
@@ -128,7 +130,8 @@ void DragDropOnMainDlg::OnFilesDropped(FFSFileDropEvent& event)
void DragDropOnMainDlg::OnWriteDirManually(wxCommandEvent& event)
{
const Zstring newDir = getFormattedDirectoryName(wxToZ(event.GetString()));
- if (dirExists(newDir))
+
+ if (Utility::dirExists(newDir, 100) == Utility::EXISTING_TRUE) //potentially slow network access: wait 100 ms at most
dirPicker_->SetPath(zToWx(newDir));
event.Skip();
@@ -196,7 +199,7 @@ void DragDropOnDlg::OnFilesDropped(FFSFileDropEvent& event)
void DragDropOnDlg::OnWriteDirManually(wxCommandEvent& event)
{
const Zstring newDir = FreeFileSync::getFormattedDirectoryName(wxToZ(event.GetString()));
- if (dirExists(newDir))
+ if (Utility::dirExists(newDir, 100) == Utility::EXISTING_TRUE) //potentially slow network access: wait 100 ms at most
dirPicker_->SetPath(zToWx(newDir));
event.Skip();
@@ -210,4 +213,3 @@ void DragDropOnDlg::OnDirSelected(wxFileDirPickerEvent& event)
event.Skip();
}
-
bgstack15