summaryrefslogtreecommitdiffstats
path: root/src/newstuff
diff options
context:
space:
mode:
authorMichele Calgaro <michele.calgaro@yahoo.it>2026-03-07 11:06:50 +0900
committerMichele Calgaro <michele.calgaro@yahoo.it>2026-03-08 11:23:38 +0900
commit180ea1fc8d5e4c89a5082649aa9d2ba4190ef0dd (patch)
tree16989b14ce1f4239405eca7fcc2a38ca172c41ae /src/newstuff
parent41a6fb44cdeab6944d6db766b473f675930af8e6 (diff)
downloadtellico-remove/kde-is-version.tar.gz
tellico-remove/kde-is-version.zip
Remove use of KDE_IS_VERSIONremove/kde-is-version
Signed-off-by: Michele Calgaro <michele.calgaro@yahoo.it>
Diffstat (limited to 'src/newstuff')
-rw-r--r--src/newstuff/dialog.cpp16
-rw-r--r--src/newstuff/manager.cpp2
-rw-r--r--src/newstuff/newscript.cpp13
-rw-r--r--src/newstuff/newscript.h15
4 files changed, 5 insertions, 41 deletions
diff --git a/src/newstuff/dialog.cpp b/src/newstuff/dialog.cpp
index 6e59499..43a5414 100644
--- a/src/newstuff/dialog.cpp
+++ b/src/newstuff/dialog.cpp
@@ -42,16 +42,6 @@
#include <tqtimer.h>
#include <tqprogressbar.h>
-#if KDE_IS_VERSION(3,4,90)
-#define ENTRYNAME(e) e->name(m_lang)
-#define ENTRYSUMM(e) e->summary(m_lang)
-#define ENTRYEMAIL(e) e->authorEmail()
-#else
-#define ENTRYNAME(e) e->name()
-#define ENTRYSUMM(e) e->summary()
-#define ENTRYEMAIL(e) TQString()
-#endif
-
#define OPENDESKTOP_REDIRECT_URL "opendesktop.org/content/download.php?content="
#define OPENDESKTOP_REDIRECT_TEXT "If the download does not start in 3 seconds:</span><span class=\"defaulttext\">&nbsp;<a href=\""
@@ -322,7 +312,7 @@ void Dialog::slotResult(TDEIO::Job* job_) {
if(stuff.tagName() == Latin1Literal("content")) {
KNS::Entry* entry = new KNS::Entry(stuff);
if(!entry->type().isEmpty() && entry->type() != m_typeName) {
- myLog() << "NewStuff::Dialog::slotResult() - type mismatch, skipping " << ENTRYNAME(entry) << endl;
+ myLog() << "NewStuff::Dialog::slotResult() - type mismatch, skipping " << entry->name(m_lang) << endl;
continue;
}
@@ -343,7 +333,7 @@ void Dialog::addEntry(KNS::Entry* entry_) {
}
Item* item = new Item(m_listView);
- item->setText(0, ENTRYNAME(entry_));
+ item->setText(0, entry_->name(m_lang));
item->setText(1, entry_->version());
item->setText(2, TQString::number(entry_->rating()));
item->setText(3, TQString::number(entry_->downloads()));
@@ -389,7 +379,7 @@ void Dialog::slotSelected(TQListViewItem* item_) {
if(!license.isEmpty()) {
license.prepend('(').append(')');
}
- TQString name = TQString::fromLatin1("%1 %2").arg(ENTRYNAME(entry)).arg(license);
+ TQString name = TQString::fromLatin1("%1 %2").arg(entry->name(m_lang)).arg(license);
TQFont font = m_nameLabel->font();
font.setBold(true);
font.setItalic(false);
diff --git a/src/newstuff/manager.cpp b/src/newstuff/manager.cpp
index f6d6e1b..4ad3f5f 100644
--- a/src/newstuff/manager.cpp
+++ b/src/newstuff/manager.cpp
@@ -374,7 +374,6 @@ void Manager::slotDownloadJobResult(TDEIO::Job* job_) {
emit signalInstalled(0);
}
} else {
-#if KDE_IS_VERSION(3,3,90)
// needed so the GPG signature can be checked
NewScript* newScript = new NewScript(this, Kernel::self()->widget());
connect(newScript, TQ_SIGNAL(installFinished()), this, TQ_SLOT(slotInstallFinished()));
@@ -382,7 +381,6 @@ void Manager::slotDownloadJobResult(TDEIO::Job* job_) {
// if it was a success, it gets deleted later
deleteTempFile = !newScript->install(job->destURL().path());
m_scriptEntryMap.insert(newScript, entry);
-#endif
// if failed, emit empty signal now
if(deleteTempFile) {
emit signalInstalled(0);
diff --git a/src/newstuff/newscript.cpp b/src/newstuff/newscript.cpp
index 4ec83e3..a0d2b8d 100644
--- a/src/newstuff/newscript.cpp
+++ b/src/newstuff/newscript.cpp
@@ -17,15 +17,12 @@
#include <kurl.h>
#include <tqwidget.h>
+#include <tdenewstuff/knewstuffsecure.h>
using Tellico::NewStuff::NewScript;
NewScript::NewScript(Manager* manager_, TQWidget* parentWidget_)
-#if KDE_IS_VERSION(3,3,90)
: TDENewStuffSecure(TQString::fromLatin1("tellico script"), parentWidget_)
-#else
- : TQObject(parentWidget_)
-#endif
, m_manager(manager_), m_success(false) {
}
@@ -37,12 +34,4 @@ void NewScript::installResource() {
m_url = u;
}
-#if KDE_IS_VERSION(3,3,90)
-#include <tdenewstuff/knewstuffsecure.h>
-#define SUPERCLASS TDENewStuffSecure
-#else
-#define SUPERCLASS TQObject
-#endif
-
#include "newscript.moc"
-#undef SUPERCLASS
diff --git a/src/newstuff/newscript.h b/src/newstuff/newscript.h
index dbbfc9f..463f2a5 100644
--- a/src/newstuff/newscript.h
+++ b/src/newstuff/newscript.h
@@ -14,16 +14,8 @@
#ifndef TELLICO_NEWSTUFF_NEWSCRIPT_H
#define TELLICO_NEWSTUFF_NEWSCRIPT_H
-#include <tdeversion.h>
#include <kurl.h>
-
-#if KDE_IS_VERSION(3,3,90)
#include <tdenewstuff/knewstuffsecure.h>
-#define SUPERCLASS TDENewStuffSecure
-#else
-#define SUPERCLASS TQObject
-#endif
-
#include <tqobject.h>
namespace Tellico {
@@ -31,7 +23,7 @@ namespace Tellico {
class Manager;
-class NewScript : public SUPERCLASS {
+class NewScript : public TDENewStuffSecure {
TQ_OBJECT
@@ -46,10 +38,6 @@ private:
virtual void installResource();
Manager* m_manager;
-#if !KDE_IS_VERSION(3,3,90)
- // TDENewStuffSecure has a protected variable
- TQString m_tarName;
-#endif
KURL m_url;
bool m_success : 1;
};
@@ -57,5 +45,4 @@ private:
}
}
-#undef SUPERCLASS
#endif