summaryrefslogtreecommitdiffstats
path: root/akregator/src/feedlist.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'akregator/src/feedlist.cpp')
-rw-r--r--akregator/src/feedlist.cpp62
1 files changed, 31 insertions, 31 deletions
diff --git a/akregator/src/feedlist.cpp b/akregator/src/feedlist.cpp
index 814f82e1a..4076c6231 100644
--- a/akregator/src/feedlist.cpp
+++ b/akregator/src/feedlist.cpp
@@ -23,10 +23,10 @@
*/
#include "feedlist.h"
-#include <qdatetime.h>
-#include <qdom.h>
-#include <qmap.h>
-#include <qvaluelist.h>
+#include <tqdatetime.h>
+#include <tqdom.h>
+#include <tqmap.h>
+#include <tqvaluelist.h>
#include <kdebug.h>
#include <klocale.h>
@@ -43,7 +43,7 @@ class FeedList::FeedListPrivate
{
public:
- QMap<QString, QValueList<Feed*> > urlMap;
+ TQMap<TQString, TQValueList<Feed*> > urlMap;
AddNodeVisitor* addNodeVisitor;
RemoveNodeVisitor* removeNodeVisitor;
};
@@ -80,7 +80,7 @@ class FeedList::RemoveNodeVisitor : public TreeNodeVisitor
FeedList* m_list;
};
-FeedList::FeedList(QObject *parent, const char *name)
+FeedList::FeedList(TQObject *parent, const char *name)
: NodeList(parent, name), d(new FeedListPrivate)
{
d->addNodeVisitor = new AddNodeVisitor(this);
@@ -104,13 +104,13 @@ void FeedList::removeNode(TreeNode* node)
d->removeNodeVisitor->visit(node);
}
-void FeedList::parseChildNodes(QDomNode &node, Folder* parent)
+void FeedList::parseChildNodes(TQDomNode &node, Folder* parent)
{
- QDomElement e = node.toElement(); // try to convert the node to an element.
+ TQDomElement e = node.toElement(); // try to convert the node to an element.
if( !e.isNull() )
{
- QString title = e.hasAttribute("text") ? e.attribute("text") : e.attribute("title");
+ TQString title = e.hasAttribute("text") ? e.attribute("text") : e.attribute("title");
if (e.hasAttribute("xmlUrl") || e.hasAttribute("xmlurl") || e.hasAttribute("xmlURL") )
{
@@ -129,7 +129,7 @@ void FeedList::parseChildNodes(QDomNode &node, Folder* parent)
if (e.hasChildNodes())
{
- QDomNode child = e.firstChild();
+ TQDomNode child = e.firstChild();
while(!child.isNull())
{
parseChildNodes(child, fg);
@@ -140,21 +140,21 @@ void FeedList::parseChildNodes(QDomNode &node, Folder* parent)
}
}
-bool FeedList::readFromXML(const QDomDocument& doc)
+bool FeedList::readFromXML(const TQDomDocument& doc)
{
- QDomElement root = doc.documentElement();
+ TQDomElement root = doc.documentElement();
kdDebug() << "loading OPML feed " << root.tagName().lower() << endl;
kdDebug() << "measuring startup time: START" << endl;
- QTime spent;
+ TQTime spent;
spent.start();
if (root.tagName().lower() != "opml")
{
return false;
}
- QDomNode bodyNode = root.firstChild();
+ TQDomNode bodyNode = root.firstChild();
while (!bodyNode.isNull() && bodyNode.toElement().tagName().lower() != "body")
bodyNode = bodyNode.nextSibling();
@@ -166,9 +166,9 @@ bool FeedList::readFromXML(const QDomDocument& doc)
return false;
}
- QDomElement body = bodyNode.toElement();
+ TQDomElement body = bodyNode.toElement();
- QDomNode i = body.firstChild();
+ TQDomNode i = body.firstChild();
while( !i.isNull() )
{
@@ -199,7 +199,7 @@ FeedList::~FeedList()
d = 0;
}
-Feed* FeedList::findByURL(const QString& feedURL) const
+Feed* FeedList::findByURL(const TQString& feedURL) const
{
if (d->urlMap[feedURL].isEmpty())
return 0;
@@ -207,7 +207,7 @@ Feed* FeedList::findByURL(const QString& feedURL) const
return *(d->urlMap[feedURL].begin());
}
-Article FeedList::findArticle(const QString& feedURL, const QString& guid) const
+Article FeedList::findArticle(const TQString& feedURL, const TQString& guid) const
{
Feed* feed = findByURL(feedURL);
@@ -222,10 +222,10 @@ void FeedList::append(FeedList* list, Folder* parent, TreeNode* after)
if ( !flatList()->contains(parent) )
parent = rootNode();
- QValueList<TreeNode*> children = list->rootNode()->children();
+ TQValueList<TreeNode*> children = list->rootNode()->children();
- QValueList<TreeNode*>::ConstIterator end( children.end() );
- for (QValueList<TreeNode*>::ConstIterator it = children.begin(); it != end; ++it)
+ TQValueList<TreeNode*>::ConstIterator end( children.end() );
+ for (TQValueList<TreeNode*>::ConstIterator it = children.begin(); it != end; ++it)
{
list->rootNode()->removeChild(*it);
parent->insertChild(*it, after);
@@ -233,32 +233,32 @@ void FeedList::append(FeedList* list, Folder* parent, TreeNode* after)
}
}
-QDomDocument FeedList::toXML() const
+TQDomDocument FeedList::toXML() const
{
- QDomDocument doc;
+ TQDomDocument doc;
doc.appendChild( doc.createProcessingInstruction( "xml", "version=\"1.0\" encoding=\"UTF-8\"" ) );
- QDomElement root = doc.createElement( "opml" );
+ TQDomElement root = doc.createElement( "opml" );
root.setAttribute( "version", "1.0" );
doc.appendChild( root );
- QDomElement head = doc.createElement( "head" );
+ TQDomElement head = doc.createElement( "head" );
root.appendChild( head );
- QDomElement ti = doc.createElement( "text" );
+ TQDomElement ti = doc.createElement( "text" );
head.appendChild( ti );
- QDomText t = doc.createTextNode( title() );
+ TQDomText t = doc.createTextNode( title() );
ti.appendChild( t );
- QDomElement body = doc.createElement( "body" );
+ TQDomElement body = doc.createElement( "body" );
root.appendChild( body );
- QValueList<TreeNode*> children = rootNode()->children();
+ TQValueList<TreeNode*> children = rootNode()->children();
- QValueList<TreeNode*>::ConstIterator end( children.end() );
+ TQValueList<TreeNode*>::ConstIterator end( children.end() );
- for (QValueList<TreeNode*>::ConstIterator it = children.begin(); it != end; ++it)
+ for (TQValueList<TreeNode*>::ConstIterator it = children.begin(); it != end; ++it)
body.appendChild( (*it)->toOPML(body, doc) );
return doc;