From 0ba2d95e89f55b13f2247819b6672362a8b5a484 Mon Sep 17 00:00:00 2001 From: llornkcor Date: Tue, 21 May 2002 15:03:56 +0000 Subject: maybe fixed bug --- diff --git a/core/apps/textedit/fileBrowser.cpp b/core/apps/textedit/fileBrowser.cpp index fced326..9ad0d69 100644 --- a/core/apps/textedit/fileBrowser.cpp +++ b/core/apps/textedit/fileBrowser.cpp @@ -53,27 +53,27 @@ fileBrowser::fileBrowser( QWidget* parent, const char* name, bool modal, WFlags // getMimeTypes(); - mimeType = mimeFilter; - MimeType mt( mimeType); +// mimeType = mimeFilter; +// MimeType mt( mimeType); - if( mt.extension().isEmpty()) { +// if( mt.extension().isEmpty()) { - QStringList filterList; - filterList=QStringList::split(";",mimeFilter,FALSE); +// QStringList filterList; +// filterList=QStringList::split(";",mimeFilter,FALSE); - for ( QStringList::Iterator it = filterList.begin(); it != filterList.end(); ++it ) { - printf( "%s \n", (*it).latin1() ); - } +// for ( QStringList::Iterator it = filterList.begin(); it != filterList.end(); ++it ) { +// printf( "%s \n", (*it).latin1() ); +// } - filterStr = mimeFilter.right(mimeFilter.length() - mimeFilter.find("/",0,TRUE) - 1);// "*"; +// filterStr = mimeFilter.right(mimeFilter.length() - mimeFilter.find("/",0,TRUE) - 1);// "*"; - qDebug(filterStr); - } else { +// qDebug(filterStr); +// } else { filterStr = "*."+ mt.extension(); // qDebug("description "+mt.description()); // qDebug( "id "+mt.id()); // qDebug("extension "+mt.extension()); - } +// } // channel = new QCopChannel( "QPE/fileDialog", this ); // connect( channel, SIGNAL(received(const QCString&, const QByteArray&)), // this, SLOT(receive(const QCString&, const QByteArray&)) ); diff --git a/core/apps/textedit/textedit.cpp b/core/apps/textedit/textedit.cpp index 19449cb..b8d62db 100644 --- a/core/apps/textedit/textedit.cpp +++ b/core/apps/textedit/textedit.cpp @@ -510,12 +510,12 @@ void TextEdit::fileOpen() if(cfg.readEntry("useOldFileDialog") == "TRUE") b=TRUE; if(!b) { - QString str = OFileDialog::getOpenFileName( 1,"/","", "text/plain", this ); + QString str = OFileDialog::getOpenFileName( 1,"/","", "*", this ); if(!str.isEmpty() ) openFile( str ); } else { QString str; - browseForFiles = new fileBrowser(this,tr("Open File"),TRUE,0, "text/*"); // + browseForFiles = new fileBrowser(this,tr("Open File"),TRUE,0, "*"); // browseForFiles->setFileView( viewSelection ); browseForFiles->showMaximized(); // if( result != -1 ) -- cgit v0.9.0.2