// Name: filedlg.cpp
// Purpose:
// Author: Robert Roebling
-// Created: 01/02/97
-// Id:
-// Copyright: (c) 1998 Robert Roebling, Julian Smart and Markus Holzem
+// Id: $Id$
+// Copyright: (c) 1998 Robert Roebling
// Licence: wxWindows licence
/////////////////////////////////////////////////////////////////////////////
}
dialog->OnOK( event );
-};
+}
void gtk_filedialog_cancel_callback( GtkWidget *WXUNUSED(widget), gpointer data )
{
wxFileDialog *dialog = (wxFileDialog*)data;
wxCommandEvent event(wxEVT_NULL);
dialog->OnCancel( event );
-};
+}
IMPLEMENT_DYNAMIC_CLASS(wxFileDialog,wxDialog)
m_dialogStyle = style;
m_filterIndex = 1;
- m_widget = gtk_file_selection_new(_("File selection"));
+ m_widget = gtk_file_selection_new( m_message );
int x = (gdk_screen_width () - 400) / 2;
int y = (gdk_screen_height () - 400) / 2;
gtk_signal_connect( GTK_OBJECT(sel->cancel_button), "clicked",
GTK_SIGNAL_FUNC(gtk_filedialog_cancel_callback), (gpointer*)this );
-};
+}
int wxFileDialog::ShowModal(void)
{
{
m_fileName = gtk_file_selection_get_filename( GTK_FILE_SELECTION(m_widget) );
m_path = gtk_file_selection_get_filename( GTK_FILE_SELECTION(m_widget) );
- };
+ }
return ret;
-};
+}
char *wxFileSelector(const char *title,
return wxBuffer;
}
else
- return NULL;
-};
+ return (char *) NULL;
+}
char* wxLoadFileSelector(const char *what, const char *extension, const char *default_name,
wxWindow *parent )
char wild[60];
sprintf(wild, "*.%s", ext);
- return wxFileSelector (prompt, NULL, default_name, ext, wild, 0, parent);
-};
+ return wxFileSelector (prompt, (const char *) NULL, default_name, ext, wild, 0, parent);
+}
char* wxSaveFileSelector(const char *what, const char *extension, const char *default_name,
wxWindow *parent )
char wild[60];
sprintf(wild, "*.%s", ext);
- return wxFileSelector (prompt, NULL, default_name, ext, wild, 0, parent);
-};
+ return wxFileSelector (prompt, (const char *) NULL, default_name, ext, wild, 0, parent);
+}