[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-commits
Subject: KDE/kdeedu
From: Peter Hedlund <peter () peterandlinda ! com>
Date: 2005-06-04 17:38:28
Message-ID: 1117906708.365257.5296.nullmailer () svn ! kde ! org
[Download RAW message or body]
SVN commit 422170 by hedlund:
KNewStuff: Inform user about where downloaded files are saved.
M +5 -0 kvoctrain/kvoctrain/kvtnewstuff.cpp
M +9 -17 kwordquiz/src/kwqnewstuff.cpp
M +4 -0 kwordquiz/src/kwqnewstuff.h
--- trunk/KDE/kdeedu/kvoctrain/kvoctrain/kvtnewstuff.cpp #422169:422170
@@ -109,6 +109,11 @@
if (result == KMessageBox::No)
return QString::null;
}
+ KMessageBox::information(parentWidget(),
+ i18n("<qt>The selected file will now be downloaded and saved \
as\n<b>'%1'</b>.</qt>") + .arg(file),
+ QString::null,
+ "NewStuffDownloadLocation");
return file;
}
--- trunk/KDE/kdeedu/kwordquiz/src/kwqnewstuff.cpp #422169:422170
@@ -23,32 +23,19 @@
#include <kmessagebox.h>
#include <knewstuff/entry.h>
+#include "kwordquiz.h"
#include "kwqnewstuff.h"
#include "prefs.h"
KWQNewStuff::KWQNewStuff(QWidget *parent, const char *name) : QObject(), \
KNewStuff("kdeedu/vocabulary", parent) {
-
+ m_app = (KWordQuizApp *) parent;
}
bool KWQNewStuff::install(const QString & fileName)
{
- QStringList list, list2;
-
- QString cmd = Prefs::installationCommand();
- if (!cmd.isEmpty())
- {
- list = QStringList::split(" ", cmd);
- for (QStringList::iterator it = list.begin(); it != list.end(); it++ )
- {
- list2 << (*it).replace("%f", fileName);
- }
- KProcess proc;
- proc << list2;
- proc.start(KProcess::DontCare);
- }
-
+ m_app->slotFileOpenRecent(KURL(fileName));
return true;
}
@@ -93,11 +80,16 @@
int result = KMessageBox::questionYesNo(parentWidget(),
i18n("The file '%1' already exists. Do you want to overwrite it?")
.arg(file),
- QString::null,
+ QString::null,
i18n("Overwrite"));
if (result == KMessageBox::No)
return QString::null;
}
+ KMessageBox::information(parentWidget(),
+ i18n("<qt>The selected file will now be downloaded and saved \
as\n<b>'%1'</b>.</qt>") + .arg(file),
+ QString::null,
+ "NewStuffDownloadLocation");
return file;
}
--- trunk/KDE/kdeedu/kwordquiz/src/kwqnewstuff.h #422169:422170
@@ -20,6 +20,8 @@
#include <knewstuff/knewstuff.h>
+class KWordQuizApp;
+
/**
@author Peter Hedlund
*/
@@ -57,6 +59,8 @@
private:
QString destinationPath(KNS::Entry *entry);
+
+ KWordQuizApp * m_app;
};
#endif
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic