From a9360ae6833bd5e95d36e0b62767725a121f4198 Mon Sep 17 00:00:00 2001 From: gregory guy Date: Fri, 10 Sep 2021 17:24:58 +0200 Subject: [PATCH] Remove KDE_IS_VERSION definition. Signed-off-by: gregory guy (cherry picked from commit c0822095d4f1706dc80a7b01a77516cd77d6e77d) --- kftpgrabber/src/kftpbookmarkaction.cpp | 2 -- kftpgrabber/src/kftpbookmarkaction.h | 5 ----- kftpgrabber/src/kftpbookmarks.cpp | 8 -------- kftpgrabber/src/misc/kftpzeroconf.cpp | 4 ---- kftpgrabber/src/misc/kftpzeroconf.h | 5 ----- kftpgrabber/src/widgets/kftpzeroconflistview.cpp | 8 -------- 6 files changed, 32 deletions(-) diff --git a/kftpgrabber/src/kftpbookmarkaction.cpp b/kftpgrabber/src/kftpbookmarkaction.cpp index c988ae7..650baf5 100644 --- a/kftpgrabber/src/kftpbookmarkaction.cpp +++ b/kftpgrabber/src/kftpbookmarkaction.cpp @@ -45,12 +45,10 @@ KFTPZeroconfAction::KFTPZeroconfAction(const TQString &text, const TQString &pix { } -#if KDE_IS_VERSION(3,4,0) void KFTPZeroconfAction::setSite(DNSSD::RemoteService::Ptr service) { m_service = service; } -#endif KFTPBookmarkAction::KFTPBookmarkAction(const TQString &text, const TQString &pix, const TDEShortcut &cut, const TQObject *receiver, const char *slot, TDEActionCollection *parent, const char *name) : TDEAction(text, pix, cut, receiver, slot, parent, name) diff --git a/kftpgrabber/src/kftpbookmarkaction.h b/kftpgrabber/src/kftpbookmarkaction.h index 02caafc..d8cac7b 100644 --- a/kftpgrabber/src/kftpbookmarkaction.h +++ b/kftpgrabber/src/kftpbookmarkaction.h @@ -42,9 +42,7 @@ #include -#if KDE_IS_VERSION(3,4,0) #include "kftpzeroconf.h" -#endif namespace KFTPBookmarks { class Site; @@ -79,13 +77,10 @@ class KFTPZeroconfAction : public TDEAction Q_OBJECT public: KFTPZeroconfAction(const TQString &text, const TQString &pix, const TDEShortcut &cut, const TQObject *receiver, const char *slot, TDEActionCollection *parent, const char *name = 0); - -#if KDE_IS_VERSION(3,4,0) void setSite(DNSSD::RemoteService::Ptr service); DNSSD::RemoteService::Ptr getSite() { return m_service; } private: DNSSD::RemoteService::Ptr m_service; -#endif }; /** diff --git a/kftpgrabber/src/kftpbookmarks.cpp b/kftpgrabber/src/kftpbookmarks.cpp index c117dd4..08422f4 100644 --- a/kftpgrabber/src/kftpbookmarks.cpp +++ b/kftpgrabber/src/kftpbookmarks.cpp @@ -808,7 +808,6 @@ void Manager::guiPopulateZeroconfMenu(TDEActionMenu *parentMenu) // Clear the menu parentMenu->popupMenu()->clear(); -#if KDE_IS_VERSION(3,4,0) // Populate TQValueList list = KFTPAPI::getInstance()->zeroConfInterface()->getServiceList(); @@ -826,11 +825,6 @@ void Manager::guiPopulateZeroconfMenu(TDEActionMenu *parentMenu) disabledAction->setEnabled(false); parentMenu->insert(disabledAction); } -#else - TDEAction *disabledAction = new TDEAction(i18n("")); - disabledAction->setEnabled(false); - parentMenu->insert(disabledAction); -#endif } void Manager::guiPopulateWalletMenu(TDEActionMenu *parentMenu) @@ -933,13 +927,11 @@ void Manager::slotWalletExecuted() void Manager::slotZeroconfExecuted() { -#if KDE_IS_VERSION(3,4,0) // Get the sender KFTPZeroconfAction *action = (KFTPZeroconfAction*) TQObject::sender(); DNSSD::RemoteService::Ptr service = action->getSite(); KFTPAPI::getInstance()->mainWindow()->slotQuickConnect(service->serviceName(), service->hostName(), service->port()); -#endif } } diff --git a/kftpgrabber/src/misc/kftpzeroconf.cpp b/kftpgrabber/src/misc/kftpzeroconf.cpp index d49f5d6..37a73c4 100644 --- a/kftpgrabber/src/misc/kftpzeroconf.cpp +++ b/kftpgrabber/src/misc/kftpzeroconf.cpp @@ -38,13 +38,11 @@ KFTPZeroConf::KFTPZeroConf(TQObject *parent, const char *name) : TQObject(parent, name) { -#if KDE_IS_VERSION(3,4,0) m_browser = new DNSSD::ServiceBrowser("_ftp._tcp", 0, true); connect(m_browser, SIGNAL(finished()), this, SLOT(slotServiceChanged())); m_browser->startBrowse(); -#endif } @@ -52,12 +50,10 @@ KFTPZeroConf::~KFTPZeroConf() { } -#if KDE_IS_VERSION(3,4,0) const TQValueList &KFTPZeroConf::getServiceList() const { return m_browser->services(); } -#endif void KFTPZeroConf::slotServiceChanged() { diff --git a/kftpgrabber/src/misc/kftpzeroconf.h b/kftpgrabber/src/misc/kftpzeroconf.h index 425fb7e..6628706 100644 --- a/kftpgrabber/src/misc/kftpzeroconf.h +++ b/kftpgrabber/src/misc/kftpzeroconf.h @@ -40,9 +40,7 @@ #include -#if KDE_IS_VERSION(3,4,0) #include -#endif /** * This class provides an interface to TDEDNSSD (that is available from KDE 3.4). @@ -55,12 +53,9 @@ Q_OBJECT public: KFTPZeroConf(TQObject *parent = 0, const char *name = 0); ~KFTPZeroConf(); - -#if KDE_IS_VERSION(3,4,0) const TQValueList &getServiceList() const; private: DNSSD::ServiceBrowser *m_browser; -#endif private slots: void slotServiceChanged(); signals: diff --git a/kftpgrabber/src/widgets/kftpzeroconflistview.cpp b/kftpgrabber/src/widgets/kftpzeroconflistview.cpp index b64da05..383cdb8 100644 --- a/kftpgrabber/src/widgets/kftpzeroconflistview.cpp +++ b/kftpgrabber/src/widgets/kftpzeroconflistview.cpp @@ -39,9 +39,7 @@ #include -#if KDE_IS_VERSION(3,4,0) #include "kftpzeroconf.h" -#endif #include #include @@ -57,17 +55,14 @@ KFTPZeroConfListView::KFTPZeroConfListView(TQWidget *parent, const char *name) setEmptyListText(i18n("No sites published.")); setItemsRenameable(false); -#if KDE_IS_VERSION(3,4,0) connect(KFTPAPI::getInstance()->zeroConfInterface(), SIGNAL(servicesUpdated()), this, SLOT(slotSitesChanged())); connect(this, SIGNAL(executed(TQListViewItem*)), this, SLOT(slotSiteExecuted(TQListViewItem*))); slotSitesChanged(); -#endif } void KFTPZeroConfListView::slotSitesChanged() { -#if KDE_IS_VERSION(3,4,0) // Update the site list TQValueList list = KFTPAPI::getInstance()->zeroConfInterface()->getServiceList(); @@ -84,15 +79,12 @@ void KFTPZeroConfListView::slotSitesChanged() site->setPixmap(0, SmallIcon("lan")); } } -#endif } void KFTPZeroConfListView::slotSiteExecuted(TQListViewItem *item) { -#if KDE_IS_VERSION(3,4,0) // Connect to the site KFTPAPI::getInstance()->mainWindow()->slotQuickConnect(item->text(0), item->text(1), item->text(2).toInt()); -#endif } #include "kftpzeroconflistview.moc"