summaryrefslogtreecommitdiffabout
path: root/microkde/kfiledialog.cpp
Side-by-side diff
Diffstat (limited to 'microkde/kfiledialog.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r--microkde/kfiledialog.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/microkde/kfiledialog.cpp b/microkde/kfiledialog.cpp
index 977499e..309f8dc 100644
--- a/microkde/kfiledialog.cpp
+++ b/microkde/kfiledialog.cpp
@@ -17,16 +17,17 @@ QString KFileDialog::getSaveFileName( const QString & fn,
lay.setMargin(7);
lay.setSpacing(7);
dia.setCaption( cap );
QString file = fn;
if ( file.isEmpty() )
file = QDir::homeDirPath()+"/*";
QFileInfo fi ( file );
OFileSelector o ( &dia,OFileSelector::FileSelector, OFileSelector::Save, fi.dirPath(true), fi.fileName() );
+ QObject::connect ( &o, SIGNAL( ok() ), &dia, SLOT ( accept () ) );
lay.addWidget( &o);
// o.setNewVisible( true );
// o.setNameVisible( true );
dia.showMaximized();
int res = dia.exec();
if ( res )
retfile = o.selectedName();
return retfile;
@@ -42,16 +43,17 @@ QString KFileDialog::getOpenFileName( const QString & fn,
lay.setMargin(7);
lay.setSpacing(7);
dia.setCaption( cap );
QString file = fn;
if ( file.isEmpty() )
file = QDir::homeDirPath()+"/*";;
QFileInfo fi ( file );
OFileSelector o ( &dia,OFileSelector::FileSelector, OFileSelector::Open, fi.dirPath(true), fi.fileName() );
+ QObject::connect ( &o, SIGNAL( ok() ), &dia, SLOT ( accept () ) );
lay.addWidget( &o);
dia.showMaximized();
int res = dia.exec();
if ( res )
retfile = o.selectedName();
return retfile;
}