]> git.saurik.com Git - wxWidgets.git/blobdiff - src/gtk/filedlg.cpp
Minor corrections to wxFlexGridSizer ctor documentation.
[wxWidgets.git] / src / gtk / filedlg.cpp
index fb0bfa7735710ea50372246fd529bd7d46000a04..ace2daddcdd72c41666ce1a0da4895a167f37b03 100644 (file)
@@ -369,8 +369,11 @@ void wxFileDialog::SetMessage(const wxString& message)
 
 void wxFileDialog::SetPath(const wxString& path)
 {
-    wxCHECK_RET(wxIsAbsolutePath(path), " wxFileDialog::SetPath requires an absolute filepath");
-    m_fc.SetPath( path );
+    // we need an absolute path for GTK native chooser so ensure that we have
+    // it
+    wxFileName fn(path);
+    fn.MakeAbsolute();
+    m_fc.SetPath(fn.GetFullPath());
 }
 
 void wxFileDialog::SetDirectory(const wxString& dir)