From 47c8a359c5276062c4bc17f0e82410f29081b502 Mon Sep 17 00:00:00 2001 From: tpearson Date: Sat, 31 Jul 2010 19:48:06 +0000 Subject: Trinity Qt initial conversion git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdenetwork@1157648 283d02a7-25f6-0310-bc7c-ecb5cbfe19da --- .../kntsrcfilepropsdlg/kntsrcfilepropsdlg.cpp | 42 +++++++++++----------- .../kntsrcfilepropsdlg/kntsrcfilepropsdlg.h | 10 +++--- 2 files changed, 26 insertions(+), 26 deletions(-) (limited to 'knewsticker/kntsrcfilepropsdlg') diff --git a/knewsticker/kntsrcfilepropsdlg/kntsrcfilepropsdlg.cpp b/knewsticker/kntsrcfilepropsdlg/kntsrcfilepropsdlg.cpp index 93bc71cc..14ca80d0 100644 --- a/knewsticker/kntsrcfilepropsdlg/kntsrcfilepropsdlg.cpp +++ b/knewsticker/kntsrcfilepropsdlg/kntsrcfilepropsdlg.cpp @@ -25,15 +25,15 @@ #include #include -#include -#include +#include +#include using namespace RSS; class ArticleListBoxItem : public QListBoxText { public: - ArticleListBoxItem( QListBox *listbox, const Article &article ); + ArticleListBoxItem( TQListBox *listbox, const Article &article ); const Article &article() const { return m_article; } @@ -41,8 +41,8 @@ class ArticleListBoxItem : public QListBoxText Article m_article; }; -ArticleListBoxItem::ArticleListBoxItem( QListBox *listbox, const Article &article ) - : QListBoxText( listbox ), +ArticleListBoxItem::ArticleListBoxItem( TQListBox *listbox, const Article &article ) + : TQListBoxText( listbox ), m_article( article ) { setText( article.title() ); @@ -52,18 +52,18 @@ KntSrcFilePropsDlg::KntSrcFilePropsDlg(KPropertiesDialog *props) : KPropsDlgPlugin(props) { m_child = new KntSrcFilePropsDlgWidget(properties->addVBoxPage(i18n("News Resource"))); - connect(m_child->urlName, SIGNAL(leftClickedURL(const QString &)), - SLOT(slotOpenURL(const QString &))); - connect(m_child->lbArticles, SIGNAL(executed(QListBoxItem *)), - SLOT(slotClickedArticle(QListBoxItem *))); + connect(m_child->urlName, TQT_SIGNAL(leftClickedURL(const TQString &)), + TQT_SLOT(slotOpenURL(const TQString &))); + connect(m_child->lbArticles, TQT_SIGNAL(executed(TQListBoxItem *)), + TQT_SLOT(slotClickedArticle(TQListBoxItem *))); Loader *loader = Loader::create(); - connect(loader, SIGNAL(loadingComplete(Loader *, Document, Status)), - SLOT(slotConstructUI(Loader *, Document, Status))); + connect(loader, TQT_SIGNAL(loadingComplete(Loader *, Document, Status)), + TQT_SLOT(slotConstructUI(Loader *, Document, Status))); loader->loadFrom(props->item()->url(), new FileRetriever); - connect(NewsIconMgr::self(), SIGNAL(gotIcon(const KURL &, const QPixmap &)), - SLOT(slotGotIcon(const KURL &, const QPixmap &))); + connect(NewsIconMgr::self(), TQT_SIGNAL(gotIcon(const KURL &, const TQPixmap &)), + TQT_SLOT(slotGotIcon(const KURL &, const TQPixmap &))); m_child->show(); } @@ -74,7 +74,7 @@ void KntSrcFilePropsDlg::slotConstructUI(Loader *, Document doc, Status status) return; KURL iconURL = doc.link(); - iconURL.setEncodedPathAndQuery(QString::fromLatin1("/favicon.ico")); + iconURL.setEncodedPathAndQuery(TQString::fromLatin1("/favicon.ico")); NewsIconMgr::self()->getIcon(iconURL); m_child->urlName->setText(doc.title()); @@ -88,31 +88,31 @@ void KntSrcFilePropsDlg::slotConstructUI(Loader *, Document doc, Status status) new ArticleListBoxItem(m_child->lbArticles, *it); } -void KntSrcFilePropsDlg::slotOpenURL(const QString &url) +void KntSrcFilePropsDlg::slotOpenURL(const TQString &url) { kapp->invokeBrowser(url); } -void KntSrcFilePropsDlg::slotGotIcon(const KURL &, const QPixmap &pixmap) +void KntSrcFilePropsDlg::slotGotIcon(const KURL &, const TQPixmap &pixmap) { m_child->pixmapIcon->setPixmap(pixmap); } -void KntSrcFilePropsDlg::slotClickedArticle(QListBoxItem *item) +void KntSrcFilePropsDlg::slotClickedArticle(TQListBoxItem *item) { ArticleListBoxItem *articleItem = static_cast(item); slotOpenURL(articleItem->article().link().url()); } -QObject *KntSrcFilePropsFactory::createObject(QObject *parent, const char *, - const char *classname, const QStringList &) +TQObject *KntSrcFilePropsFactory::createObject(TQObject *parent, const char *, + const char *classname, const TQStringList &) { - if (QString::fromLatin1(classname) == "KPropsDlgPlugin") + if (TQString::fromLatin1(classname) == "KPropsDlgPlugin") { if (!parent->inherits("KPropertiesDialog")) return 0L; - QObject *obj = new KntSrcFilePropsDlg(static_cast(parent)); + TQObject *obj = new KntSrcFilePropsDlg(static_cast(parent)); return obj; } return 0L; diff --git a/knewsticker/kntsrcfilepropsdlg/kntsrcfilepropsdlg.h b/knewsticker/kntsrcfilepropsdlg/kntsrcfilepropsdlg.h index 8fe1be58..0d41682e 100644 --- a/knewsticker/kntsrcfilepropsdlg/kntsrcfilepropsdlg.h +++ b/knewsticker/kntsrcfilepropsdlg/kntsrcfilepropsdlg.h @@ -33,8 +33,8 @@ class KntSrcFilePropsFactory : public KLibFactory Q_OBJECT public: - virtual QObject *createObject(QObject * = 0, const char * = 0, - const char * = "QObject", const QStringList & = QStringList()); + virtual TQObject *createObject(TQObject * = 0, const char * = 0, + const char * = "TQObject", const TQStringList & = TQStringList()); }; class KntSrcFilePropsDlg : public KPropsDlgPlugin @@ -45,10 +45,10 @@ class KntSrcFilePropsDlg : public KPropsDlgPlugin KntSrcFilePropsDlg(KPropertiesDialog *); protected slots: - void slotOpenURL(const QString &); + void slotOpenURL(const TQString &); void slotConstructUI(Loader *loader, Document doc, Status status); - void slotGotIcon(const KURL &, const QPixmap &); - void slotClickedArticle(QListBoxItem *); + void slotGotIcon(const KURL &, const TQPixmap &); + void slotClickedArticle(TQListBoxItem *); private: KntSrcFilePropsDlgWidget *m_child; -- cgit v1.2.1