summaryrefslogtreecommitdiffstats
path: root/kregexpeditor/multicontainerwidget.cpp
diff options
context:
space:
mode:
authorTimothy Pearson <kb9vqf@pearsoncomputing.net>2011-12-16 10:00:17 -0600
committerTimothy Pearson <kb9vqf@pearsoncomputing.net>2011-12-16 10:00:17 -0600
commit955e20356d63ed405198c8143617a8a0ca8bfc02 (patch)
tree9a9ab22c86d212a5655014ad752e96b04c0c86a9 /kregexpeditor/multicontainerwidget.cpp
parentbf280726d5d22f33d33e4f9e771220c725249407 (diff)
downloadtdeutils-955e20356d63ed405198c8143617a8a0ca8bfc02.tar.gz
tdeutils-955e20356d63ed405198c8143617a8a0ca8bfc02.zip
Revert "Rename a number of old tq methods that are no longer tq specific"
This reverts commit bf280726d5d22f33d33e4f9e771220c725249407.
Diffstat (limited to 'kregexpeditor/multicontainerwidget.cpp')
-rw-r--r--kregexpeditor/multicontainerwidget.cpp76
1 files changed, 38 insertions, 38 deletions
diff --git a/kregexpeditor/multicontainerwidget.cpp b/kregexpeditor/multicontainerwidget.cpp
index bd578d2..d8bef97 100644
--- a/kregexpeditor/multicontainerwidget.cpp
+++ b/kregexpeditor/multicontainerwidget.cpp
@@ -27,8 +27,8 @@ MultiContainerWidget::MultiContainerWidget( RegExpEditorWindow* editorWindow,
void MultiContainerWidget::append( RegExpWidget* child )
{
child->reparent( this, TQPoint(0,0), false );
- _children.append( child );
- _children.append( new DragAccepter( _editorWindow, this ) );
+ _tqchildren.append( child );
+ _tqchildren.append( new DragAccepter( _editorWindow, this ) );
}
bool MultiContainerWidget::hasSelection() const
@@ -36,7 +36,7 @@ bool MultiContainerWidget::hasSelection() const
if ( _isSelected )
return true;
- TQPtrListIterator<RegExpWidget> it(_children);
+ TQPtrListIterator<RegExpWidget> it(_tqchildren);
++it; // Move past the first dragAccepter
for ( ; *it; it += 2 ) {
if ( (*it)->hasSelection() ) {
@@ -49,8 +49,8 @@ bool MultiContainerWidget::hasSelection() const
void MultiContainerWidget::clearSelection()
{
_isSelected = false;
- for ( unsigned int i = 0; i< _children.count(); i++ ) {
- _children.at(i)->clearSelection();
+ for ( unsigned int i = 0; i< _tqchildren.count(); i++ ) {
+ _tqchildren.at(i)->clearSelection();
}
}
@@ -58,15 +58,15 @@ void MultiContainerWidget::clearSelection()
void MultiContainerWidget::deleteSelection()
{
// run from the back to the front (which we do since we delete items on the run)
- // When deleting children, delete the drag accepter to its right.
- for ( int i = (int) _children.count()-2; i > 0; i -=2 ) {
+ // When deleting tqchildren, delete the drag accepter to its right.
+ for ( int i = (int) _tqchildren.count()-2; i > 0; i -=2 ) {
- RegExpWidget* child = _children.at( i );
+ RegExpWidget* child = _tqchildren.at( i );
if ( child->isSelected() ) {
- delete _children.at( i+1 );
- _children.remove( i+1 );
+ delete _tqchildren.at( i+1 );
+ _tqchildren.remove( i+1 );
delete child;
- _children.remove(i);
+ _tqchildren.remove(i);
}
else if ( child->hasSelection() ) {
child->deleteSelection();
@@ -78,16 +78,16 @@ void MultiContainerWidget::deleteSelection()
void MultiContainerWidget::addNewChild(DragAccepter *accepter, RegExpWidget *child)
{
- for ( unsigned int i=0; i<_children.count(); i+= 2 ) {
- RegExpWidget *ch = _children.at( i );
+ for ( unsigned int i=0; i<_tqchildren.count(); i+= 2 ) {
+ RegExpWidget *ch = _tqchildren.at( i );
if ( ch == accepter ) {
// Insert the new child
- _children.insert( i+1, child );
+ _tqchildren.insert( i+1, child );
// Insert an accepter as the next element.
DragAccepter *accepter = new DragAccepter( _editorWindow, this );
- _children.insert( i+2, accepter );
+ _tqchildren.insert( i+2, accepter );
// These two show's must come here otherwise a paintevent
// will be invoked, where the invariant, that a accepter is located at
@@ -107,11 +107,11 @@ bool MultiContainerWidget::updateSelection(bool parentSelected)
{
bool changed = false;
bool isSel = _isSelected;
- TQMemArray<bool> oldState(_children.count());
- TQMemArray<bool> newState(_children.count());
+ TQMemArray<bool> oldState(_tqchildren.count());
+ TQMemArray<bool> newState(_tqchildren.count());
- for (int i = 0; i< (int)_children.count();i++) {
- oldState[i] = _children.at(i)->isSelected();
+ for (int i = 0; i< (int)_tqchildren.count();i++) {
+ oldState[i] = _tqchildren.at(i)->isSelected();
}
RegExpWidget::updateSelection( parentSelected );
@@ -120,8 +120,8 @@ bool MultiContainerWidget::updateSelection(bool parentSelected)
int last;
// scan for the first selected item.
- for (first = 1; first < (int) _children.count(); first+= 2 ) {
- RegExpWidget* child = _children.at(first);
+ for (first = 1; first < (int) _tqchildren.count(); first+= 2 ) {
+ RegExpWidget* child = _tqchildren.at(first);
changed = child->updateSelection( _isSelected ) || changed;
newState[first] = child->isSelected();
if ( child->isSelected() )
@@ -129,8 +129,8 @@ bool MultiContainerWidget::updateSelection(bool parentSelected)
}
// scan for the last selected item
- for (last = _children.count()-2; last>first; last -= 2) {
- RegExpWidget* child = _children.at(last);
+ for (last = _tqchildren.count()-2; last>first; last -= 2) {
+ RegExpWidget* child = _tqchildren.at(last);
changed = child->updateSelection( _isSelected ) || changed;
newState[last] = child->isSelected();
if ( child->isSelected() )
@@ -139,17 +139,17 @@ bool MultiContainerWidget::updateSelection(bool parentSelected)
// everything between first and last must be selected.
for (int j = first+2; j<last; j+=2) {
- RegExpWidget* child = _children.at(j);
+ RegExpWidget* child = _tqchildren.at(j);
changed = child->updateSelection( true ) || changed;
newState[j] = true;
}
// update drag accepters.
- for (int k = 0; k< (int) _children.count(); k+=2) {
- RegExpWidget* child = _children.at(k);
+ for (int k = 0; k< (int) _tqchildren.count(); k+=2) {
+ RegExpWidget* child = _tqchildren.at(k);
bool select;
- if ( k == 0 || k == (int)_children.count()-1) {
+ if ( k == 0 || k == (int)_tqchildren.count()-1) {
// The elements at the border is only selected if the parent is selected.
select = _isSelected;
}
@@ -164,12 +164,12 @@ bool MultiContainerWidget::updateSelection(bool parentSelected)
if (accepter)
accepter->_isSelected = select;
if ( select != isChildSel )
- child->repaint();
+ child->tqrepaint();
}
changed = changed || isSel != _isSelected;
if ( changed ) {
- repaint();
+ tqrepaint();
}
return changed;
@@ -183,7 +183,7 @@ TQRect MultiContainerWidget::selectionRect() const
return TQRect( mapToGlobal( TQPoint(0,0) ), size() );
else {
TQRect res;
- TQPtrListIterator<RegExpWidget> it(_children);
+ TQPtrListIterator<RegExpWidget> it(_tqchildren);
++it; // Move past the first dragAccepter
for ( ; *it; it +=2 ) {
if ( (*it)->hasSelection() ) {
@@ -216,8 +216,8 @@ RegExpWidget* MultiContainerWidget::widgetUnderPoint( TQPoint globalPos, bool ju
incr = 1;
}
- for ( unsigned int i = start; i < _children.count(); i+=incr ) {
- RegExpWidget* wid = _children.at(i)->widgetUnderPoint( globalPos, justVisibleWidgets );
+ for ( unsigned int i = start; i < _tqchildren.count(); i+=incr ) {
+ RegExpWidget* wid = _tqchildren.at(i)->widgetUnderPoint( globalPos, justVisibleWidgets );
if ( wid )
return wid;
}
@@ -230,8 +230,8 @@ RegExpWidget* MultiContainerWidget::widgetUnderPoint( TQPoint globalPos, bool ju
RegExpWidget* MultiContainerWidget::findWidgetToEdit( TQPoint globalPos )
{
- for ( unsigned int i = 1; i < _children.count(); i+=2 ) {
- RegExpWidget* wid = _children.at(i)->findWidgetToEdit( globalPos );
+ for ( unsigned int i = 1; i < _tqchildren.count(); i+=2 ) {
+ RegExpWidget* wid = _tqchildren.at(i)->findWidgetToEdit( globalPos );
if ( wid )
return wid;
}
@@ -241,7 +241,7 @@ RegExpWidget* MultiContainerWidget::findWidgetToEdit( TQPoint globalPos )
void MultiContainerWidget::selectWidget( bool sel )
{
RegExpWidget::selectWidget( sel );
- TQPtrListIterator<RegExpWidget> it(_children);
+ TQPtrListIterator<RegExpWidget> it(_tqchildren);
for ( ; *it ; ++it ) {
(*it)->selectWidget( sel );
}
@@ -250,7 +250,7 @@ void MultiContainerWidget::selectWidget( bool sel )
void MultiContainerWidget::updateAll()
{
- for ( TQPtrListIterator<RegExpWidget> it(_children); *it ; ++it ) {
+ for ( TQPtrListIterator<RegExpWidget> it(_tqchildren); *it ; ++it ) {
(*it)->updateAll();
}
RegExpWidget::updateAll();
@@ -258,8 +258,8 @@ void MultiContainerWidget::updateAll()
void MultiContainerWidget::updateCursorRecursively()
{
- for ( TQPtrListIterator<RegExpWidget> it(_children); *it ; ++it ) {
+ for ( TQPtrListIterator<RegExpWidget> it(_tqchildren); *it ; ++it ) {
(*it)->updateCursorRecursively();
}
- updateCursorShape();
+ updatetqCursorShape();
}