diff options
| author | 2009-06-24 16:17:57 +0000 | |
|---|---|---|
| committer | 2009-06-24 16:17:57 +0000 | |
| commit | 77ebbf9d4c80c99a372e91f675a602496a5796be (patch) | |
| tree | 07ad128562148ca54e4b511cb5b47ea3c0ddd20c | |
| parent | updated german translations (diff) | |
| download | KVIrc-77ebbf9d4c80c99a372e91f675a602496a5796be.tar.gz KVIrc-77ebbf9d4c80c99a372e91f675a602496a5796be.tar.bz2 KVIrc-77ebbf9d4c80c99a372e91f675a602496a5796be.zip | |
fix for #466
git-svn-id: https://svn.kvirc.de/svn/trunk/kvirc@3283 17fca916-40b9-46aa-a4ea-0a15b648b75c
| -rw-r--r-- | src/kvilib/config/kvi_fileextensions.h | 4 | ||||
| -rw-r--r-- | src/modules/options/optw_identity.cpp | 12 |
2 files changed, 10 insertions, 6 deletions
diff --git a/src/kvilib/config/kvi_fileextensions.h b/src/kvilib/config/kvi_fileextensions.h index f91812f02..be75de7a2 100644 --- a/src/kvilib/config/kvi_fileextensions.h +++ b/src/kvilib/config/kvi_fileextensions.h @@ -61,9 +61,9 @@ #define KVI_FILTER_THEME "KVIrc Theme (*.kvt)" #define KVI_FILTER_ADDON "KVIrc Addon (*.kva)" // Provided for convenience -#define KVI_FILTER_SCRIPTS "KVIrc Script and Addon (*.kvs; *.kva)" +#define KVI_FILTER_SCRIPTS "KVIrc Script and Addon (*.kvs *.kva)" #define KVI_FILTER_INI "INI File (*.ini)" -#define KVI_FILTER_IMAGE "Image File (*.png; *.jpg; *.jpeg; *.bmp; *.gif; *.xpm)" +#define KVI_FILTER_IMAGE "Image File (*.png *.jpg *.jpeg *.bmp *.gif *.xpm)" #define KVI_FILTER_UI "User Interface File (*.ui)" #endif //_KVI_FILEEXTENSIONS_H_ diff --git a/src/modules/options/optw_identity.cpp b/src/modules/options/optw_identity.cpp index 7174fe470..f0e1a9b97 100644 --- a/src/modules/options/optw_identity.cpp +++ b/src/modules/options/optw_identity.cpp @@ -204,7 +204,6 @@ KviAvatarSelectionDialog::KviAvatarSelectionDialog(QWidget * par,const QString & QGridLayout * g = new QGridLayout(this); - QString msg = "<center>"; msg += __tr2qs_ctx("Please select an avatar image. " \ "The full path to a local file or an image on the Web can be used.<br>" \ @@ -227,7 +226,9 @@ KviAvatarSelectionDialog::KviAvatarSelectionDialog(QWidget * par,const QString & QPushButton * b = new QPushButton(__tr2qs_ctx("&Browse...","options"),this); connect(b,SIGNAL(clicked()),this,SLOT(chooseFileClicked())); g->addWidget(b,1,2); - KviTalHBox * h = new KviTalHBox(this);h->setSpacing(8); + + KviTalHBox * h = new KviTalHBox(this); + h->setSpacing(8); g->addWidget(h,2,1,1,2); b = new QPushButton(__tr2qs_ctx("&OK","options"),h); b->setMinimumWidth(80); @@ -260,13 +261,16 @@ void KviAvatarSelectionDialog::cancelClicked() void KviAvatarSelectionDialog::chooseFileClicked() { QString tmp; - if(KviFileDialog::askForOpenFileName(tmp,__tr2qs_ctx("Choose an Image File - KVIrc","options"), - QString(),KVI_FILTER_IMAGE,false,true,this)) + //QString szFilter = "*.jpg; *.png"; + if(KviFileDialog::askForOpenFileName(tmp,__tr2qs_ctx("Choose an Image File - KVIrc","options"),QString(),KVI_FILTER_IMAGE,false,true,this)) + //if(KviFileDialog::askForOpenFileName(tmp,__tr2qs_ctx("Choose an Image File - KVIrc","options"),QString(),szFilter,false,true,this)) { m_pLineEdit->setText(tmp); } } +//static bool askForOpenFileName(QString & szBuffer, const QString & szCaption, const QString & szInitial = QString(), const QString & szFilter = QString(), bool bShowHidden = false, bool bShowNative = true, QWidget * pParent = 0); + void KviAvatarSelectionDialog::closeEvent(QCloseEvent * e) { e->ignore(); |
