Skip to content

OpenToonz - An open-source full-featured 2D animation creation software

C

Revert "Fix Focus Lost when renaming new created folder"

Abel_Youf233746af059
diff --git a/toonz/sources/toonz/filebrowser.cpp b/toonz/sources/toonz/filebrowser.cpp
index e1e188257..0ac270753 100644
--- a/toonz/sources/toonz/filebrowser.cpp
+++ b/toonz/sources/toonz/filebrowser.cpp
@@ -2180,30 +2180,14 @@ void FileBrowser::newFolder() {
int i = 1;
while (TFileStatus(folderPath).doesExist())
folderPath = parentFolder + (folderName + L" " + std::to_wstring(++i));
-
- if (Preferences::instance()->isWatchFileSystemEnabled()) {
- MyFileSystemWatcher *watcher = MyFileSystemWatcher::instance();
- // Remove parent folder from watcher
- watcher->removePaths(QStringList() << parentFolder.getQString());
- try {
- TSystem::mkDir(folderPath);
- } catch (...) {
- DVGui::error(tr("It is not possible to create the %1 folder.")
- .arg(toQString(folderPath)));
- watcher->addPaths(QStringList() << parentFolder.getQString());
- return;
- }
- // Add the parent folder back
- watcher->addPaths(QStringList() << parentFolder.getQString());
- } else {
- try {
- TSystem::mkDir(folderPath);
- } catch (...) {
- DVGui::error(tr("It is not possible to create the %1 folder.")
- .arg(toQString(folderPath)));
- return;
- }
+ try {
+ TSystem::mkDir(folderPath);
+
+ } catch (...) {
+ DVGui::error(tr("It is not possible to create the %1 folder.")
+ .arg(toQString(folderPath)));
+ return;
}
DvDirModel *model = DvDirModel::instance();