summaryrefslogtreecommitdiffstats
path: root/examples/iconview/simple_dd
diff options
context:
space:
mode:
authorMichele Calgaro <michele.calgaro@yahoo.it>2025-07-01 22:09:14 +0900
committerMichele Calgaro <michele.calgaro@yahoo.it>2025-07-08 09:01:42 +0900
commit81ade129093a279e6537db25710583fd2bba9427 (patch)
treea210834cbccc8aee2e9de7a8b7f41e1d31e2ced0 /examples/iconview/simple_dd
parent35ced32e331ee29fda1642616c803637952f5b22 (diff)
downloadtqt-81ade129.tar.gz
tqt-81ade129.zip
Replace TRUE/FALSE with boolean values true/false - part 2
Signed-off-by: Michele Calgaro <michele.calgaro@yahoo.it> (cherry picked from commit c03a4800879ab62692e017e01c825ba12a421ad0)
Diffstat (limited to 'examples/iconview/simple_dd')
-rw-r--r--examples/iconview/simple_dd/main.cpp20
1 files changed, 10 insertions, 10 deletions
diff --git a/examples/iconview/simple_dd/main.cpp b/examples/iconview/simple_dd/main.cpp
index 16d3b53c5..e638bcdc3 100644
--- a/examples/iconview/simple_dd/main.cpp
+++ b/examples/iconview/simple_dd/main.cpp
@@ -78,8 +78,8 @@ const char* green_icon[]={
DDListBox::DDListBox( TQWidget * parent, const char * name, WFlags f ) :
TQListBox( parent, name, f )
{
- setAcceptDrops( TRUE );
- dragging = FALSE;
+ setAcceptDrops( true );
+ dragging = false;
}
@@ -102,7 +102,7 @@ void DDListBox::dropEvent( TQDropEvent *evt )
void DDListBox::mousePressEvent( TQMouseEvent *evt )
{
TQListBox::mousePressEvent( evt );
- dragging = TRUE;
+ dragging = true;
}
@@ -111,7 +111,7 @@ void DDListBox::mouseMoveEvent( TQMouseEvent * )
if ( dragging ) {
TQDragObject *d = new TQTextDrag( currentText(), this );
d->dragCopy(); // do NOT delete d.
- dragging = FALSE;
+ dragging = false;
}
}
@@ -122,8 +122,8 @@ void DDListBox::mouseMoveEvent( TQMouseEvent * )
bool DDIconViewItem::acceptDrop( const TQMimeSource *mime ) const
{
if ( mime->provides( "text/plain" ) )
- return TRUE;
- return FALSE;
+ return true;
+ return false;
}
@@ -149,7 +149,7 @@ void DDIconView::slotNewItem( TQDropEvent *evt, const TQValueList<TQIconDragItem
if ( TQTextDrag::decode( evt, label ) ) {
DDIconViewItem *item = new DDIconViewItem( this, label );
- item->setRenameEnabled( TRUE );
+ item->setRenameEnabled( true );
}
}
@@ -175,11 +175,11 @@ int main( int argc, char *argv[] )
// Populate the TQIconView with icons
DDIconViewItem *item;
item = new DDIconViewItem( iv, "Red", TQPixmap( red_icon ) );
- item->setRenameEnabled( TRUE );
+ item->setRenameEnabled( true );
item = new DDIconViewItem( iv, "Green", TQPixmap( green_icon ) );
- item->setRenameEnabled( TRUE );
+ item->setRenameEnabled( true );
item = new DDIconViewItem( iv, "Blue", TQPixmap( blue_icon ) );
- item->setRenameEnabled( TRUE );
+ item->setRenameEnabled( true );
return app.exec();
}