]> git.saurik.com Git - wxWidgets.git/blobdiff - src/msw/dir.cpp
disable workaround for lack of alpha support in native static bitmap control for...
[wxWidgets.git] / src / msw / dir.cpp
index 5525d72a611517124ccef1474efe02717e140c28..1bdeb321f7ba2942e53b855339bc96821acc2af1 100644 (file)
@@ -303,9 +303,20 @@ wxDir::wxDir(const wxString& dirname)
 bool wxDir::Open(const wxString& dirname)
 {
     delete M_DIR;
-    m_data = new wxDirData(dirname);
+    
+    // The Unix code does a similar test
+    if (wxDirExists(dirname))
+    {
+        m_data = new wxDirData(dirname);
 
-    return true;
+        return true;
+    }
+    else
+    {
+        m_data = NULL;
+    
+        return false;
+    }
 }
 
 bool wxDir::IsOpened() const