[Kst] kdeextragear-2/kst/kst (silent)

Andrew Walker arwalker at sumusltd.com
Thu Mar 3 19:52:33 CET 2005


CVS commit by arwalker: 

KLineEditDlg has been deprecated.

CVS_SILENT


  M +9 -0      kst.cpp   1.283
  M +4 -0      kstviewobject.cpp   1.117
  M +13 -0     kstviewwindow.h   1.30


--- kdeextragear-2/kst/kst/kst.cpp  #1.282:1.283
@@ -1728,8 +1728,17 @@ QString KstApp::windowName(bool prompt, 
       QRegExp exp("\\S+.*");
       QRegExpValidator val(exp, 0L);
+      
       if (rename) {
+#if KDE_VERSION >= KDE_MAKE_VERSION(3,3,0)
+        name = KInputDialog::getText(i18n("Kst"), i18n("Enter a new name for the window:"), name, &ok, 0L, 0L, &val).stripWhiteSpace();
+#else
         name = KLineEditDlg::getText(i18n("Enter a new name for the window:"), name, &ok, 0L, &val).stripWhiteSpace();
+#endif
       } else {
+#if KDE_VERSION >= KDE_MAKE_VERSION(3,3,0)
+        name = KInputDialog::getText(i18n("Kst"), i18n("Enter a name for the new window:"), name, &ok, 0L, 0L, &val).stripWhiteSpace();
+#else
         name = KLineEditDlg::getText(i18n("Enter a name for the new window:"), name, &ok, 0L, &val).stripWhiteSpace();
+#endif
       }
       if (ok && name==defaultTag) {

--- kdeextragear-2/kst/kst/kstviewobject.cpp  #1.116:1.117
@@ -1045,5 +1045,9 @@ void KstViewObject::detach() {
 void KstViewObject::rename() {
   bool ok = false;
+#if KDE_VERSION >= KDE_MAKE_VERSION(3,3,0)
+  QString newName = KInputDialog::getText(i18n("Kst"), i18n("Enter a new name for %1:").arg(tagName()), tagName(), &ok);
+#else
   QString newName = KLineEditDlg::getText(i18n("Enter a new name for %1:").arg(tagName()), tagName(), &ok, 0L);
+#endif
   if (ok) {
     setTagName(newName);

--- kdeextragear-2/kst/kst/kstviewwindow.h  #1.29:1.30
@@ -22,7 +22,12 @@
 
 // include files for KDE
+#if KDE_VERSION >= KDE_MAKE_VERSION(3,3,0)
+#include <kinputdialog.h>
+#else
 #include <klineeditdlg.h>
+#endif
 #include <klocale.h>
 
+// application specific includes
 #include "kst.h"
 #include "kstdatacollection.h"
@@ -126,5 +131,9 @@ QString KstViewWindow::createPlot(const 
   if (prompt) {
     bool ok = false;
+#if KDE_VERSION >= KDE_MAKE_VERSION(3,3,0)
+    name = KInputDialog::getText(i18n("Kst"), i18n("Enter a name for the new plot:"), name, &ok);
+#else
     name = KLineEditDlg::getText(i18n("Enter a name for the new plot:"), name, &ok, 0L);
+#endif
     if (!ok) {
       return QString::null;
@@ -144,5 +153,9 @@ QString KstViewWindow::createPlot(const 
           if (rc) {
             duplicate = true;
+#if KDE_VERSION >= KDE_MAKE_VERSION(3,3,0)
+            name = KInputDialog::getText(i18n("Kst"), i18n("Enter a name for the new plot:"), name, &ok);
+#else
             name = KLineEditDlg::getText(i18n("Enter a name for the new plot:"), name, &ok, 0L);
+#endif
             if (!ok) {
               app->deleteIterator(iter);




More information about the Kst mailing list