summaryrefslogtreecommitdiffstats
path: root/bibletime/frontend/mainindex
diff options
context:
space:
mode:
Diffstat (limited to 'bibletime/frontend/mainindex')
-rw-r--r--bibletime/frontend/mainindex/cindexitem.cpp64
-rw-r--r--bibletime/frontend/mainindex/cindexitem.h18
-rw-r--r--bibletime/frontend/mainindex/cmainindex.cpp16
3 files changed, 49 insertions, 49 deletions
diff --git a/bibletime/frontend/mainindex/cindexitem.cpp b/bibletime/frontend/mainindex/cindexitem.cpp
index de83db5..0842ae3 100644
--- a/bibletime/frontend/mainindex/cindexitem.cpp
+++ b/bibletime/frontend/mainindex/cindexitem.cpp
@@ -57,8 +57,8 @@ CItemBase::CItemBase(CMainIndex* mainIndex, const Type type)
m_type(type),
m_sortingEnabled(true) {}
-CItemBase::CItemBase(CItemBase* tqparentItem, const Type type)
-: KListViewItem(tqparentItem),
+CItemBase::CItemBase(CItemBase* parentItem, const Type type)
+: KListViewItem(parentItem),
m_type(type),
m_sortingEnabled(true) {}
@@ -140,7 +140,7 @@ void CItemBase::sort() {
/* ---------- new class: CModuleItem ------------ */
/* ---------------------------------------------- */
-CModuleItem::CModuleItem(CTreeFolder* tqparentItem, CSwordModuleInfo* module) : CItemBase(tqparentItem), m_module(module) {}
+CModuleItem::CModuleItem(CTreeFolder* parentItem, CSwordModuleInfo* module) : CItemBase(parentItem), m_module(module) {}
CModuleItem::~CModuleItem() {}
@@ -252,8 +252,8 @@ const bool CModuleItem::enableAction( const MenuAction action ) {
/* ---------- new class: CBookmarkItem ------------*/
/* ----------------------------------------------*/
-CBookmarkItem::CBookmarkItem(CFolderBase* tqparentItem, CSwordModuleInfo* module, const TQString& key, const TQString& description)
-: CItemBase(tqparentItem),
+CBookmarkItem::CBookmarkItem(CFolderBase* parentItem, CSwordModuleInfo* module, const TQString& key, const TQString& description)
+: CItemBase(parentItem),
m_description(description),
m_moduleName(module ? module->name() : TQString()) {
if ((module && (module->type() == CSwordModuleInfo::Bible) || (module->type() == CSwordModuleInfo::Commentary)) ) {
@@ -269,8 +269,8 @@ m_moduleName(module ? module->name() : TQString()) {
m_startupXML = TQDomElement(); //empty XML code
}
-CBookmarkItem::CBookmarkItem(CFolderBase* tqparentItem, TQDomElement& xml )
-: CItemBase(tqparentItem),
+CBookmarkItem::CBookmarkItem(CFolderBase* parentItem, TQDomElement& xml )
+: CItemBase(parentItem),
m_key(TQString()),
m_description(TQString()),
m_moduleName(TQString()) {
@@ -445,9 +445,9 @@ bool CBookmarkItem::acceptDrop(const TQMimeSource* /*src*/) const {
CFolderBase::CFolderBase(CMainIndex* mainIndex, const Type type) : CItemBase(mainIndex, type) {}
-CFolderBase::CFolderBase(CFolderBase* tqparentItem, const Type type) : CItemBase(tqparentItem, type) {}
+CFolderBase::CFolderBase(CFolderBase* parentItem, const Type type) : CItemBase(parentItem, type) {}
-CFolderBase::CFolderBase(CFolderBase* tqparentFolder, const TQString& caption) : CItemBase(tqparentFolder) {
+CFolderBase::CFolderBase(CFolderBase* parentFolder, const TQString& caption) : CItemBase(parentFolder) {
setText(0, caption);
}
@@ -715,54 +715,54 @@ namespace Bookmarks {
doc.appendChild(content);
//first create the bookmark groups in the XML document, then add the bookmarks to each tqparent
- TQMap<int, TQDomElement> tqparentMap; //maps tqparent ids to dom elements
+ TQMap<int, TQDomElement> parentMap; //maps tqparent ids to dom elements
TQStringList groupList = config->readListEntry("Groups");
- TQValueList<int> tqparentList = config->readIntListEntry("Group tqparents");
+ TQValueList<int> parentList = config->readIntListEntry("Group parents");
TQStringList::Iterator it_groups = groupList.begin();
- TQValueList<int>::Iterator it_parents = tqparentList.begin();
+ TQValueList<int>::Iterator it_parents = parentList.begin();
- int tqparentIDCounter = 0;
- while ( (it_groups != groupList.end()) && (it_parents != tqparentList.end()) ) {
- TQDomElement tqparentElement = (*it_parents == -1) ? content : tqparentMap[*it_parents];
- if (tqparentElement.isNull()) {
+ int parentIDCounter = 0;
+ while ( (it_groups != groupList.end()) && (it_parents != parentList.end()) ) {
+ TQDomElement parentElement = (*it_parents == -1) ? content : parentMap[*it_parents];
+ if (parentElement.isNull()) {
qWarning("EMPTY PARENT FOUND!");
- tqparentElement = content;
+ parentElement = content;
};
TQDomElement elem = doc.createElement("Folder");
elem.setAttribute("caption", (*it_groups));
- tqparentMap.insert(tqparentIDCounter, elem);
+ parentMap.insert(parentIDCounter, elem);
- tqparentElement.appendChild( elem );
+ parentElement.appendChild( elem );
++it_parents;
++it_groups;
- ++tqparentIDCounter;
+ ++parentIDCounter;
}
//groups are now read in, create now the bookmarks
- tqparentList = config->readIntListEntry("Bookmark tqparents");
+ parentList = config->readIntListEntry("Bookmark parents");
TQStringList bookmarkList = config->readListEntry("Bookmarks");
TQStringList bookmarkModulesList = config->readListEntry("Bookmark modules");
TQStringList bookmarkDescriptionsList = config->readListEntry("Bookmark descriptions");
- it_parents = tqparentList.begin();
+ it_parents = parentList.begin();
TQStringList::Iterator it_bookmarks = bookmarkList.begin();
TQStringList::Iterator it_modules = bookmarkModulesList.begin();
TQStringList::Iterator it_descriptions = bookmarkDescriptionsList.begin();
while ( it_bookmarks != bookmarkList.end()
- && it_parents != tqparentList.end()
+ && it_parents != parentList.end()
&& it_modules != bookmarkModulesList.end()
) {
- TQDomElement tqparentElement = ((*it_parents) == -1) ? content : tqparentMap[(*it_parents)];
- if (tqparentElement.isNull()) {
+ TQDomElement parentElement = ((*it_parents) == -1) ? content : parentMap[(*it_parents)];
+ if (parentElement.isNull()) {
qWarning("EMPTY PARENT FOUND!");
- tqparentElement = content;
+ parentElement = content;
};
TQDomElement elem = doc.createElement("Bookmark");
@@ -773,7 +773,7 @@ namespace Bookmarks {
CSwordModuleInfo* m = CPointers::backend()->findModuleByName( *it_modules );
elem.setAttribute("moduledescription", m ? m->config(CSwordModuleInfo::Description) : TQString());
- tqparentElement.appendChild( elem );
+ parentElement.appendChild( elem );
++it_parents;
@@ -833,12 +833,12 @@ OldBookmarksFolder::OldBookmarksFolder(CTreeFolder* folder) : CBookmarkFolder(fo
// New class SubFolder
-SubFolder::SubFolder(CFolderBase* tqparentItem, const TQString& caption) : CBookmarkFolder(tqparentItem, BookmarkFolder) {
+SubFolder::SubFolder(CFolderBase* parentItem, const TQString& caption) : CBookmarkFolder(parentItem, BookmarkFolder) {
m_startupXML = TQDomElement();
setText( 0, caption );
}
-SubFolder::SubFolder(CFolderBase* tqparentItem, TQDomElement& xml ) : CBookmarkFolder(tqparentItem, BookmarkFolder) {
+SubFolder::SubFolder(CFolderBase* parentItem, TQDomElement& xml ) : CBookmarkFolder(parentItem, BookmarkFolder) {
m_startupXML = xml;
}
@@ -912,7 +912,7 @@ SubFolder::SubFolder(CFolderBase* tqparentItem, TQDomElement& xml ) : CBookmarkF
//restore all child items
TQDomElement child = elem.firstChild().toElement();
CItemBase* oldItem = 0;
- while ( !child.isNull() && child.tqparentNode() == elem ) {
+ while ( !child.isNull() && child.parentNode() == elem ) {
CItemBase* i = 0;
if (child.tagName() == "Folder") {
i = new Bookmarks::SubFolder(this, child);
@@ -939,7 +939,7 @@ CBookmarkFolder::CBookmarkFolder(CMainIndex* mainIndex, const Type type) : CTree
setSortingEnabled(false);
}
-CBookmarkFolder::CBookmarkFolder(CFolderBase* tqparentItem, const Type type) : CTreeFolder(tqparentItem, type, "*") {
+CBookmarkFolder::CBookmarkFolder(CFolderBase* parentItem, const Type type) : CTreeFolder(parentItem, type, "*") {
setSortingEnabled(false);
}
@@ -1059,7 +1059,7 @@ const bool CBookmarkFolder::loadBookmarksFromXML( const TQString& xml ) {
CItemBase* oldItem = 0;
//restore all child items
TQDomElement child = document.firstChild().toElement();
- while ( !child.isNull() && child.tqparentNode() == document) {
+ while ( !child.isNull() && child.parentNode() == document) {
CItemBase* i = 0;
if (child.tagName() == "Folder") {
i = new Bookmarks::SubFolder(this, child);
diff --git a/bibletime/frontend/mainindex/cindexitem.h b/bibletime/frontend/mainindex/cindexitem.h
index bdc1f3a..ba80afd 100644
--- a/bibletime/frontend/mainindex/cindexitem.h
+++ b/bibletime/frontend/mainindex/cindexitem.h
@@ -167,8 +167,8 @@ private:
class CBookmarkItem : public CItemBase {
public:
- CBookmarkItem(CFolderBase* tqparentItem, CSwordModuleInfo* module, const TQString& key, const TQString& description);
- CBookmarkItem(CFolderBase* tqparentItem, TQDomElement& xml);
+ CBookmarkItem(CFolderBase* parentItem, CSwordModuleInfo* module, const TQString& key, const TQString& description);
+ CBookmarkItem(CFolderBase* parentItem, TQDomElement& xml);
virtual ~CBookmarkItem();
CSwordModuleInfo* const module();
const TQString key();
@@ -228,8 +228,8 @@ private: // Private methods
class CFolderBase : public CItemBase {
public:
CFolderBase(CMainIndex* mainIndex, const Type type);
- CFolderBase(CFolderBase* tqparentFolder, const Type type);
- CFolderBase(CFolderBase* tqparentFolder, const TQString& caption);
+ CFolderBase(CFolderBase* parentFolder, const Type type);
+ CFolderBase(CFolderBase* parentFolder, const TQString& caption);
virtual ~CFolderBase();
virtual const bool isFolder();
@@ -263,7 +263,7 @@ protected:
class CTreeFolder : public CFolderBase {
public:
CTreeFolder(CMainIndex* mainIndex, const Type type, const TQString& language );
- CTreeFolder(CFolderBase* tqparentFolder, const Type type, const TQString& language );
+ CTreeFolder(CFolderBase* parentFolder, const Type type, const TQString& language );
virtual ~CTreeFolder();
virtual void addGroup(const Type type, const TQString language);
@@ -284,7 +284,7 @@ private:
class CGlossaryFolder : public CTreeFolder {
public:
CGlossaryFolder(CMainIndex* mainIndex, const Type type, const TQString& fromLanguage, const TQString& toLanguage );
- CGlossaryFolder(CFolderBase* tqparentFolder, const Type type, const TQString& fromLanguage, const TQString& toLanguage );
+ CGlossaryFolder(CFolderBase* parentFolder, const Type type, const TQString& fromLanguage, const TQString& toLanguage );
virtual ~CGlossaryFolder();
virtual void initTree();
@@ -309,7 +309,7 @@ private:
class CBookmarkFolder : public CTreeFolder {
public:
CBookmarkFolder(CMainIndex* mainIndex, const Type type = BookmarkFolder);
- CBookmarkFolder(CFolderBase* tqparentItem, const Type type = BookmarkFolder);
+ CBookmarkFolder(CFolderBase* parentItem, const Type type = BookmarkFolder);
virtual ~CBookmarkFolder();
virtual const bool enableAction(const MenuAction action);
virtual void exportBookmarks();
@@ -365,8 +365,8 @@ private:
class SubFolder : public CBookmarkFolder {
public:
- SubFolder(CFolderBase* tqparentItem, const TQString& caption);
- SubFolder(CFolderBase* tqparentItem, TQDomElement& xml);
+ SubFolder(CFolderBase* parentItem, const TQString& caption);
+ SubFolder(CFolderBase* parentItem, TQDomElement& xml);
virtual ~SubFolder();
virtual void init();
/**
diff --git a/bibletime/frontend/mainindex/cmainindex.cpp b/bibletime/frontend/mainindex/cmainindex.cpp
index 613aed3..9762164 100644
--- a/bibletime/frontend/mainindex/cmainindex.cpp
+++ b/bibletime/frontend/mainindex/cmainindex.cpp
@@ -292,7 +292,7 @@ void CMainIndex::dropped( TQDropEvent* e, TQListViewItem* tqparent, TQListViewIt
}
//finally do the drop, either with external drop data or with the moved items' data
- CItemBase* const tqparentItem = dynamic_cast<CItemBase*>(tqparent);
+ CItemBase* const parentItem = dynamic_cast<CItemBase*>(tqparent);
CItemBase* const afterItem = dynamic_cast<CItemBase*>(after);
bool removeSelectedItems = true;
@@ -305,11 +305,11 @@ void CMainIndex::dropped( TQDropEvent* e, TQListViewItem* tqparent, TQListViewIt
afterItem->setOpen(true);
afterItem->dropped(e); //inserts new items, moving only works on the same level
}
- else if (afterItem && !afterItem->isFolder() && tqparentItem) {
+ else if (afterItem && !afterItem->isFolder() && parentItem) {
const bool justMoveSelected =
(e->source() == viewport())
&& m_itemsMovable
- && tqparentItem->acceptDrop(e)
+ && parentItem->acceptDrop(e)
&& !afterItem->acceptDrop(e);
if (justMoveSelected) {
@@ -324,18 +324,18 @@ void CMainIndex::dropped( TQDropEvent* e, TQListViewItem* tqparent, TQListViewIt
afterItem->dropped(e, after);
}
else { //insert in the tqparent folder and then move the inserted items
- tqparentItem->dropped(e, after);
+ parentItem->dropped(e, after);
}
}
- tqparentItem->setOpen(true);
+ parentItem->setOpen(true);
}
- else if (tqparentItem) { //no after item present, but a tqparent is there
+ else if (parentItem) { //no after item present, but a tqparent is there
moveSelectedItems = false;
removeSelectedItems = false;
- tqparentItem->setOpen(true);
- tqparentItem->dropped(e);
+ parentItem->setOpen(true);
+ parentItem->dropped(e);
}
if (moveSelectedItems) {