diff options
author | Timothy Pearson <kb9vqf@pearsoncomputing.net> | 2011-12-16 09:59:50 -0600 |
---|---|---|
committer | Timothy Pearson <kb9vqf@pearsoncomputing.net> | 2011-12-16 09:59:50 -0600 |
commit | 9cc13dcbb01a96c9e60a07ca63c61d24b374f50d (patch) | |
tree | ab537a329b9613e11dce8195761f93ffe82aed24 /akregator/src/folder.cpp | |
parent | 3ca10fd9a2dc631429d3b5d5c5e42a7d211d5a12 (diff) | |
download | tdepim-9cc13dcbb01a96c9e60a07ca63c61d24b374f50d.tar.gz tdepim-9cc13dcbb01a96c9e60a07ca63c61d24b374f50d.zip |
Revert "Rename a number of old tq methods that are no longer tq specific"
This reverts commit 3ca10fd9a2dc631429d3b5d5c5e42a7d211d5a12.
Diffstat (limited to 'akregator/src/folder.cpp')
-rw-r--r-- | akregator/src/folder.cpp | 72 |
1 files changed, 36 insertions, 36 deletions
diff --git a/akregator/src/folder.cpp b/akregator/src/folder.cpp index 739b0cf19..1d2c6a5cf 100644 --- a/akregator/src/folder.cpp +++ b/akregator/src/folder.cpp @@ -39,9 +39,9 @@ namespace Akregator { class Folder::FolderPrivate { public: - /** List of children */ - TQValueList<TreeNode*> children; - /** caching unread count of children */ + /** List of tqchildren */ + TQValueList<TreeNode*> tqchildren; + /** caching unread count of tqchildren */ int unread; /** whether or not the folder is expanded */ bool open; @@ -62,9 +62,9 @@ bool Folder::accept(TreeNodeVisitor* visitor) Folder* Folder::fromOPML(TQDomElement e) { - Folder* fg = new Folder(e.hasAttribute(TQString::fromLatin1("text")) ? e.attribute(TQString::fromLatin1("text")) : e.attribute(TQString::fromLatin1("title"))); - fg->setOpen( e.attribute(TQString::fromLatin1("isOpen")) != TQString::fromLatin1(("false"))); - fg->setId( e.attribute(TQString::fromLatin1("id")).toUInt() ); + Folder* fg = new Folder(e.hasAttribute(TQString::tqfromLatin1("text")) ? e.attribute(TQString::tqfromLatin1("text")) : e.attribute(TQString::tqfromLatin1("title"))); + fg->setOpen( e.attribute(TQString::tqfromLatin1("isOpen")) != TQString::tqfromLatin1(("false"))); + fg->setId( e.attribute(TQString::tqfromLatin1("id")).toUInt() ); return fg; } @@ -77,7 +77,7 @@ Folder::Folder(const TQString& title) : TreeNode(), d(new FolderPrivate) Folder::~Folder() { TreeNode* tmp = 0; - for (TQValueList<TreeNode*>::ConstIterator it = d->children.begin(); it != d->children.end(); ++it) + for (TQValueList<TreeNode*>::ConstIterator it = d->tqchildren.begin(); it != d->tqchildren.end(); ++it) { delete tmp; tmp = *it; @@ -93,8 +93,8 @@ Folder::~Folder() TQStringList Folder::tags() const { TQStringList t; - TQValueList<TreeNode*>::ConstIterator en = d->children.end(); - for (TQValueList<TreeNode*>::ConstIterator it = d->children.begin(); it != en; ++it) + TQValueList<TreeNode*>::ConstIterator en = d->tqchildren.end(); + for (TQValueList<TreeNode*>::ConstIterator it = d->tqchildren.begin(); it != en; ++it) { // intersect tag sets instead of appending lists, to avoid dupes. This sucks. Definitely. I want TQSet. Now. TQStringList t2 = (*it)->tags(); @@ -108,8 +108,8 @@ TQStringList Folder::tags() const TQValueList<Article> Folder::articles(const TQString& tag) { TQValueList<Article> seq; - TQValueList<TreeNode*>::ConstIterator en = d->children.end(); - for (TQValueList<TreeNode*>::ConstIterator it = d->children.begin(); it != en; ++it) + TQValueList<TreeNode*>::ConstIterator en = d->tqchildren.end(); + for (TQValueList<TreeNode*>::ConstIterator it = d->tqchildren.begin(); it != en; ++it) seq += (*it)->articles(tag); return seq; @@ -123,21 +123,21 @@ TQDomElement Folder::toOPML( TQDomElement parent, TQDomDocument document ) const el.setAttribute("isOpen", d->open ? "true" : "false"); el.setAttribute( "id", TQString::number(id()) ); - TQValueList<TreeNode*>::ConstIterator en = d->children.end(); - for (TQValueList<TreeNode*>::ConstIterator it = d->children.begin(); it != en; ++it) + TQValueList<TreeNode*>::ConstIterator en = d->tqchildren.end(); + for (TQValueList<TreeNode*>::ConstIterator it = d->tqchildren.begin(); it != en; ++it) el.appendChild( (*it)->toOPML(el, document) ); return el; } -TQValueList<TreeNode*> Folder::children() const +TQValueList<TreeNode*> Folder::tqchildren() const { - return d->children; + return d->tqchildren; } void Folder::insertChild(TreeNode* node, TreeNode* after) { - int pos = d->children.findIndex(after); + int pos = d->tqchildren.findIndex(after); if (pos < 0) prependChild(node); @@ -150,10 +150,10 @@ void Folder::insertChild(uint index, TreeNode* node) // kdDebug() << "enter Folder::insertChild(int, node) " << node->title() << endl; if (node) { - if (index >= d->children.size()) - d->children.append(node); + if (index >= d->tqchildren.size()) + d->tqchildren.append(node); else - d->children.insert(d->children.at(index), node); + d->tqchildren.insert(d->tqchildren.at(index), node); node->setParent(this); connectToNode(node); updateUnreadCount(); @@ -170,7 +170,7 @@ void Folder::appendChild(TreeNode* node) // kdDebug() << "enter Folder::appendChild() " << node->title() << endl; if (node) { - d->children.append(node); + d->tqchildren.append(node); node->setParent(this); connectToNode(node); updateUnreadCount(); @@ -187,7 +187,7 @@ void Folder::prependChild(TreeNode* node) // kdDebug() << "enter Folder::prependChild() " << node->title() << endl; if (node) { - d->children.prepend(node); + d->tqchildren.prepend(node); node->setParent(this); connectToNode(node); updateUnreadCount(); @@ -202,10 +202,10 @@ void Folder::prependChild(TreeNode* node) void Folder::removeChild(TreeNode* node) { // kdDebug() << "enter Folder::removeChild() node:" << (node ? node->title() : "null") << endl; - if (node && d->children.contains(node)) + if (node && d->tqchildren.contains(node)) { node->setParent(0); - d->children.remove(node); + d->tqchildren.remove(node); disconnectFromNode(node); updateUnreadCount(); emit signalChildRemoved(this, node); @@ -219,12 +219,12 @@ void Folder::removeChild(TreeNode* node) TreeNode* Folder::firstChild() { - return d->children.isEmpty() ? 0 : d->children.first(); + return d->tqchildren.isEmpty() ? 0 : d->tqchildren.first(); } TreeNode* Folder::lastChild() { - return d->children.isEmpty() ? 0 : d->children.last(); + return d->tqchildren.isEmpty() ? 0 : d->tqchildren.last(); } bool Folder::isOpen() const @@ -246,8 +246,8 @@ int Folder::totalCount() const { int totalCount = 0; - TQValueList<TreeNode*>::ConstIterator en = d->children.end(); - for (TQValueList<TreeNode*>::ConstIterator it = d->children.begin(); it != en; ++it) + TQValueList<TreeNode*>::ConstIterator en = d->tqchildren.end(); + for (TQValueList<TreeNode*>::ConstIterator it = d->tqchildren.begin(); it != en; ++it) totalCount += (*it)->totalCount(); return totalCount; @@ -257,8 +257,8 @@ void Folder::updateUnreadCount() { int unread = 0; - TQValueList<TreeNode*>::ConstIterator en = d->children.end(); - for (TQValueList<TreeNode*>::ConstIterator it = d->children.begin(); it != en; ++it) + TQValueList<TreeNode*>::ConstIterator en = d->tqchildren.end(); + for (TQValueList<TreeNode*>::ConstIterator it = d->tqchildren.begin(); it != en; ++it) unread += (*it)->unread(); d->unread = unread; @@ -267,8 +267,8 @@ void Folder::updateUnreadCount() void Folder::slotMarkAllArticlesAsRead() { setNotificationMode(false); - TQValueList<TreeNode*>::ConstIterator en = d->children.end(); - for (TQValueList<TreeNode*>::ConstIterator it = d->children.begin(); it != en; ++it) + TQValueList<TreeNode*>::ConstIterator en = d->tqchildren.end(); + for (TQValueList<TreeNode*>::ConstIterator it = d->tqchildren.begin(); it != en; ++it) (*it)->slotMarkAllArticlesAsRead(); setNotificationMode(true, true); } @@ -281,7 +281,7 @@ void Folder::slotChildChanged(TreeNode* /*node*/) void Folder::slotChildDestroyed(TreeNode* node) { - d->children.remove(node); + d->tqchildren.remove(node); updateUnreadCount(); nodeModified(); } @@ -289,16 +289,16 @@ void Folder::slotChildDestroyed(TreeNode* node) void Folder::slotDeleteExpiredArticles() { setNotificationMode(false); - TQValueList<TreeNode*>::ConstIterator en = d->children.end(); - for (TQValueList<TreeNode*>::ConstIterator it = d->children.begin(); it != en; ++it) + TQValueList<TreeNode*>::ConstIterator en = d->tqchildren.end(); + for (TQValueList<TreeNode*>::ConstIterator it = d->tqchildren.begin(); it != en; ++it) (*it)->slotDeleteExpiredArticles(); setNotificationMode(true, true); } void Folder::slotAddToFetchQueue(FetchQueue* queue, bool intervalFetchOnly) { - TQValueList<TreeNode*>::ConstIterator en = d->children.end(); - for (TQValueList<TreeNode*>::ConstIterator it = d->children.begin(); it != en; ++it) + TQValueList<TreeNode*>::ConstIterator en = d->tqchildren.end(); + for (TQValueList<TreeNode*>::ConstIterator it = d->tqchildren.begin(); it != en; ++it) (*it)->slotAddToFetchQueue(queue, intervalFetchOnly); } |