From kde-commits Thu Jul 31 21:53:27 2003 From: Nadeem Hasan Date: Thu, 31 Jul 2003 21:53:27 +0000 To: kde-commits Subject: kdebase/konsole/konsole X-MARC-Message: https://marc.info/?l=kde-commits&m=105968899024810 CVS commit by nhasan: s/KLineEditDlg/KInputDialog/g One can no longer use strings with all blanks. M +18 -11 konsole.cpp 1.395 M +8 -5 konsole_part.cpp 1.86 --- kdebase/konsole/konsole/konsole.cpp #1.394:1.395 @@ -98,5 +98,5 @@ Time to start a requirement list. #include #include -#include +#include #include #include @@ -1024,9 +1024,13 @@ void Konsole::configureRequest(TEWidget* void Konsole::slotSaveSessionsProfile() { - KLineEditDlg dlg(i18n("Enter name under which the profile should be saved:"), QString::null, this); - dlg.setCaption(i18n("Save Sessions Profile")); - if (dlg.exec()) { - QString path = locateLocal( "data", QString::fromLatin1( "konsole/profiles/" ) + - dlg.text(), KGlobal::instance() ); + bool ok; + + QString prof = KInputDialog::getText( i18n( "Save Sessions Profile" ), + i18n( "Enter name under which the profile should be saved:" ), + QString::null, &ok, this ); + if ( ok ) { + QString path = locateLocal( "data", + QString::fromLatin1( "konsole/profiles/" ) + prof, + KGlobal::instance() ); if ( QFile::exists( path ) ) @@ -2760,9 +2764,12 @@ void Konsole::slotRenameSession() { KRadioAction *ra = session2action.find(se); QString name = se->Title(); - KLineEditDlg dlg(i18n("Session name:"),name, this); - dlg.setCaption(i18n("Rename Session")); - if (dlg.exec()) { - se->setTitle(dlg.text()); - ra->setText(dlg.text().replace('&',"&&")); + bool ok; + + name = KInputDialog::getText( i18n( "Rename Session" ), + i18n( "Session name:" ), name, &ok, this ); + + if (ok) { + se->setTitle(name); + ra->setText(name.replace('&',"&&")); ra->setIcon( se->IconName() ); // I don't know why it is needed here if(se->isMasterMode()) --- kdebase/konsole/konsole/konsole_part.cpp #1.85:1.86 @@ -36,5 +36,5 @@ #include #include -#include +#include #include #include @@ -850,8 +850,11 @@ void konsolePart::slotBlinkingCursor() void konsolePart::slotWordSeps() { - KLineEditDlg dlg(i18n("Characters other than alphanumerics considered part of a word when double clicking:"),s_word_seps, (KMainWindow*)parentWidget); - dlg.setCaption(i18n("Word Connectors")); - if (dlg.exec()) { - s_word_seps = dlg.text(); + bool ok; + + QString seps = KInputDialog::getText( i18n( "Word Connectors" ), + i18n( "Characters other than alphanumerics considered part of a word when double clicking:" ), s_word_seps, &ok, parentWidget ); + if ( ok ) + { + s_word_seps = seps; te->setWordCharacters(s_word_seps); }