]> git.saurik.com Git - wxWidgets.git/blobdiff - src/gtk1/filedlg.cpp
avoid setting initial position if it was not specified, broken in r70734
[wxWidgets.git] / src / gtk1 / filedlg.cpp
index f64b08470315d9f3ef02cd1e934cd522ab895ff9..168b1e8b02fe387bd149a9b614490cad6825d554 100644 (file)
@@ -2,7 +2,6 @@
 // Name:        src/gtk1/filedlg.cpp
 // Purpose:     native implementation of wxFileDialog
 // Author:      Robert Roebling, Zbigniew Zagorski, Mart Raudsepp
-// Id:          $Id$
 // Copyright:   (c) 1998 Robert Roebling, 2004 Zbigniew Zagorski, 2005 Mart Raudsepp
 // Licence:     wxWindows licence
 /////////////////////////////////////////////////////////////////////////////
@@ -13,6 +12,7 @@
 #if wxUSE_FILEDLG
 
 #include "wx/filedlg.h"
+#include "wx/modalhook.h"
 
 
 //-----------------------------------------------------------------------------
@@ -29,11 +29,13 @@ wxFileDialog::wxFileDialog(wxWindow *parent, const wxString& message,
                            const wxString& defaultDir,
                            const wxString& defaultFileName,
                            const wxString& wildCard,
-                           long style, const wxPoint& pos)
+                           long style, const wxPoint& pos,
+                           const wxSize& sz,
+                           const wxString& name)
     : wxGenericFileDialog(parent, message, defaultDir, defaultFileName,
-                       wildCard, style, pos, true )
+                       wildCard, style, pos, sz, name, true )
 {
-        wxGenericFileDialog::Create( parent, message, defaultDir, defaultFileName, wildCard, style, pos );
+        wxGenericFileDialog::Create( parent, message, defaultDir, defaultFileName, wildCard, style, pos, sz, name );
 }
 
 wxFileDialog::~wxFileDialog()
@@ -42,11 +44,13 @@ wxFileDialog::~wxFileDialog()
 
 void wxFileDialog::OnFakeOk( wxCommandEvent &event )
 {
-    wxGenericFileDialog::OnListOk( event );
+    wxGenericFileDialog::OnOk( event );
 }
 
 int wxFileDialog::ShowModal()
 {
+    WX_HOOK_MODAL_DIALOG();
+
     return wxGenericFileDialog::ShowModal();
 }