diff common.cpp @ 84:8a4e26dc3182

* Make all of the "Open" options do something sensible
author Chris Cannam
date Mon, 22 Nov 2010 17:27:59 +0000
parents af7cf6f7282c
children 7ed57064f293
line wrap: on
line diff
--- a/common.cpp	Mon Nov 22 16:02:13 2010 +0000
+++ b/common.cpp	Mon Nov 22 17:27:59 2010 +0000
@@ -184,19 +184,24 @@
 
 FolderStatus getFolderStatus(QString path)
 {
+    DEBUG << "getFolderStatus: " << path << endl;
     QFileInfo fi(path);
     if (fi.exists()) {
+        DEBUG << "exists" << endl;
         QDir dir(path);
         if (!dir.exists()) { // returns false for files
+            DEBUG << "not directory" << endl;
             return FolderIsFile;
         }
         if (QDir(dir.filePath(".hg")).exists()) {
+            DEBUG << "has repo" << endl;
             return FolderHasRepo;
         }
         return FolderExists;
     } else {
         QDir parent = fi.dir();
         if (parent.exists()) {
+            DEBUG << "parent exists" << endl;
             return FolderParentExists;
         }
         return FolderUnknown;