diff options
author | Dima Granetchi <system.grand@gmail.com> | 2016-07-31 01:10:13 +0300 |
---|---|---|
committer | Dima Granetchi <system.grand@gmail.com> | 2016-07-31 01:10:13 +0300 |
commit | 5e011dcd0e4958f6bc59f64e024402af1ad1dc0d (patch) | |
tree | 845b0d4fe320b869ecf1818cdb22a2affb36283d /tools | |
parent | 2b5198b23dde370563719f57d158f4f342263be2 (diff) |
dnd folder open scan window if engine.cfg not found
Diffstat (limited to 'tools')
-rw-r--r-- | tools/editor/project_manager.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/tools/editor/project_manager.cpp b/tools/editor/project_manager.cpp index 28d9738fee..20544d2f05 100644 --- a/tools/editor/project_manager.cpp +++ b/tools/editor/project_manager.cpp @@ -1104,11 +1104,17 @@ void ProjectManager::_install_project(const String& p_zip_path,const String& p_t } void ProjectManager::_files_dropped(StringArray p_files, int p_screen) { + bool import_project_file = false; for (int i = 0; i < p_files.size(); i++) { if (p_files[i].ends_with("engine.cfg")) { npdialog->import_from_file(p_files[i]); + import_project_file = true; } } + if (!import_project_file && p_files.size() > 0) { + scan_dir->set_current_dir(p_files[0]); + scan_dir->popup_centered_ratio(); + } } void ProjectManager::_bind_methods() { |