diff options
Diffstat (limited to 'quanta/treeviews/structtreeview.cpp')
-rw-r--r-- | quanta/treeviews/structtreeview.cpp | 38 |
1 files changed, 19 insertions, 19 deletions
diff --git a/quanta/treeviews/structtreeview.cpp b/quanta/treeviews/structtreeview.cpp index 8519f72b..f2154208 100644 --- a/quanta/treeviews/structtreeview.cpp +++ b/quanta/treeviews/structtreeview.cpp @@ -159,7 +159,7 @@ void StructTreeView::buildTree(Node *baseNode, int openLevel, bool groupOnly) Node *currentNode = baseNode; StructTreeTag *currentItem = top; //after this StructTreeTag *item = 0L; - StructTreeTag *tqparentItem = top; //under this + StructTreeTag *parentItem = top; //under this int level = 0; TQString title; TQString tagStr; @@ -219,7 +219,7 @@ void StructTreeView::buildTree(Node *baseNode, int openLevel, bool groupOnly) if (!groupOnly) { title = ""; - item = new StructTreeTag(tqparentItem, currentNode, title, currentItem); + item = new StructTreeTag(parentItem, currentNode, title, currentItem); item->setOpen(level < openLevel); currentNode->mainListItem = item; @@ -264,7 +264,7 @@ void StructTreeView::buildTree(Node *baseNode, int openLevel, bool groupOnly) if (currentNode->child) { currentNode = currentNode->child; - tqparentItem = item; + parentItem = item; currentItem = 0L; level++; } else @@ -280,7 +280,7 @@ void StructTreeView::buildTree(Node *baseNode, int openLevel, bool groupOnly) while (currentNode) { level--; - //tqparentItem = dynamic_cast<StructTreeTag*>(tqparentItem->tqparent()); + //parentItem = dynamic_cast<StructTreeTag*>(parentItem->tqparent()); if (currentNode->tqparent && currentNode->tqparent->next) { currentNode = currentNode->tqparent->next; @@ -296,15 +296,15 @@ void StructTreeView::buildTree(Node *baseNode, int openLevel, bool groupOnly) currentItem = static_cast<StructTreeTag*>(currentNode->prev->mainListItem); if (currentNode->tqparent) { - tqparentItem = static_cast<StructTreeTag*>(currentNode->tqparent->mainListItem); - if (!tqparentItem) + parentItem = static_cast<StructTreeTag*>(currentNode->tqparent->mainListItem); + if (!parentItem) { - tqparentItem = top; + parentItem = top; } } else { - tqparentItem = top; + parentItem = top; } } @@ -877,9 +877,9 @@ void StructTreeView::contentsMousePressEvent(TQMouseEvent* e) void StructTreeView::copySelectedItems(TQListViewItem* tqparent, TQListViewItem* after) { - StructTreeTag* tqparent_item = dynamic_cast<StructTreeTag*> (tqparent); + StructTreeTag* parent_item = dynamic_cast<StructTreeTag*> (tqparent); StructTreeTag* after_item = dynamic_cast<StructTreeTag*> (after); - if(!tqparent_item/* || !after_item*/) // can happen if the element is inserted as the first child + if(!parent_item/* || !after_item*/) // can happen if the element is inserted as the first child return; TQPtrList<TQListViewItem> selected_items = selectedItems(false); @@ -896,28 +896,28 @@ void StructTreeView::copySelectedItems(TQListViewItem* tqparent, TQListViewItem* else start_node_subtree = kafkaCommon::getNodeSubtree(start_node, 0, end_node, end_node->tag->tagStr().length()); - Node* tqparent_node = tqparent_item->node; - if(!tqparent_node) + Node* parent_node = parent_item->node; + if(!parent_node) return; Node* next_node = 0; if(after_item) next_node = after_item->node->SNext(); else - next_node = tqparent_node->firstChild(); + next_node = parent_node->firstChild(); NodeSelection cursor_holder; NodeModifsSet *modifs = new NodeModifsSet(); - kafkaCommon::DTDInsertNodeSubtree(start_node_subtree, tqparent_node, next_node, cursor_holder, modifs); + kafkaCommon::DTDInsertNodeSubtree(start_node_subtree, parent_node, next_node, cursor_holder, modifs); write->docUndoRedo->addNewModifsSet(modifs, undoRedo::NodeTreeModif, 0, false); } void StructTreeView::moveSelectedItems(TQListViewItem* tqparent, TQListViewItem* after) { - StructTreeTag* tqparent_item = dynamic_cast<StructTreeTag*> (tqparent); + StructTreeTag* parent_item = dynamic_cast<StructTreeTag*> (tqparent); StructTreeTag* after_item = dynamic_cast<StructTreeTag*> (after); - if(!tqparent_item || !after_item) + if(!parent_item || !after_item) return; TQPtrList<TQListViewItem> selected_items = selectedItems(false); @@ -939,14 +939,14 @@ void StructTreeView::moveSelectedItems(TQListViewItem* tqparent, TQListViewItem* start_node_subtree = kafkaCommon::DTDExtractNodeSubtree(start_node, 0, end_node, end_node->tag->tagStr().length(), &cursor_node, cursor_offset, modifs); - Node* tqparent_node = tqparent_item->node; - if(!tqparent_node) + Node* parent_node = parent_item->node; + if(!parent_node) return; Node* next_node = after_item->node->SNext(); NodeSelection cursor_holder(cursor_node, cursor_offset); - kafkaCommon::DTDInsertNodeSubtree(start_node_subtree, tqparent_node, next_node, cursor_holder, modifs); + kafkaCommon::DTDInsertNodeSubtree(start_node_subtree, parent_node, next_node, cursor_holder, modifs); write->docUndoRedo->addNewModifsSet(modifs, undoRedo::NodeTreeModif, &cursor_holder, false); } |