diff options
| author | Michele Calgaro <michele.calgaro@yahoo.it> | 2025-07-01 22:09:14 +0900 |
|---|---|---|
| committer | Michele Calgaro <michele.calgaro@yahoo.it> | 2025-07-08 09:01:42 +0900 |
| commit | 81ade129093a279e6537db25710583fd2bba9427 (patch) | |
| tree | a210834cbccc8aee2e9de7a8b7f41e1d31e2ced0 /examples/qmag | |
| parent | 35ced32e331ee29fda1642616c803637952f5b22 (diff) | |
| download | tqt-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/qmag')
| -rw-r--r-- | examples/qmag/qmag.cpp | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/examples/qmag/qmag.cpp b/examples/qmag/qmag.cpp index b5705df6a..c89d686fb 100644 --- a/examples/qmag/qmag.cpp +++ b/examples/qmag/qmag.cpp @@ -57,7 +57,7 @@ private: int yoffset; // pixels in addition to the actual picture int z; // magnification factor int r; // autorefresh rate (index into refreshrates) - bool grabbing; // TRUE if qmag is currently grabbing + bool grabbing; // true if qmag is currently grabbing int grabx, graby; TQString multifn; // filename for multisave }; @@ -87,12 +87,12 @@ MagWidget::MagWidget( TQWidget *parent, const char *name ) #ifdef COMPLEX_GUI int w=0, x=0, n; - zoom = new TQComboBox( FALSE, this ); + zoom = new TQComboBox( false, this ); TQ_CHECK_PTR(zoom); zoom->insertStrList( zoomfactors, 9 ); connect( zoom, TQ_SIGNAL(activated(int)), TQ_SLOT(setZoom(int)) ); - refresh = new TQComboBox( FALSE, this ); + refresh = new TQComboBox( false, this ); TQ_CHECK_PTR(refresh); refresh->insertStrList( refreshrates, 9 ); connect( refresh, TQ_SIGNAL(activated(int)), TQ_SLOT(setRefresh(int)) ); @@ -119,7 +119,7 @@ MagWidget::MagWidget( TQWidget *parent, const char *name ) 10+saveButton->fontMetrics().width("Save"), 20 ); multiSaveButton = new TQPushButton( this ); - multiSaveButton->setToggleButton(TRUE); + multiSaveButton->setToggleButton(true); TQ_CHECK_PTR(multiSaveButton); connect( multiSaveButton, TQ_SIGNAL(clicked()), this, TQ_SLOT(multiSave()) ); multiSaveButton->setText( "MultiSave" ); @@ -158,9 +158,9 @@ MagWidget::MagWidget( TQWidget *parent, const char *name ) #endif grabx = graby = -1; - grabbing = FALSE; + grabbing = false; - setMouseTracking( TRUE ); // and do let me know what pixel I'm at, eh? + setMouseTracking( true ); // and do let me know what pixel I'm at, eh? grabAround( TQPoint(grabx=tqApp->desktop()->width()/2, graby=tqApp->desktop()->height()/2) ); } @@ -203,11 +203,11 @@ void MagWidget::multiSave() multifn = ""; // stops saving multifn = TQFileDialog::getSaveFileName(); if ( multifn.isEmpty() ) - multiSaveButton->setOn(FALSE); + multiSaveButton->setOn(false); if ( !r ) p.save( multifn, "BMP" ); } else { - multiSaveButton->setOn(FALSE); + multiSaveButton->setOn(false); } } @@ -245,7 +245,7 @@ void MagWidget::grab() pm = p.xForm( m ); if ( !multiSaveButton || !multiSaveButton->isOn() ) - repaint( FALSE ); // and finally repaint, flicker-free + repaint( false ); // and finally repaint, flicker-free } @@ -262,7 +262,7 @@ void MagWidget::paintEvent( TQPaintEvent * ) void MagWidget::mousePressEvent( TQMouseEvent *e ) { if ( !grabbing ) { // prepare to grab... - grabbing = TRUE; + grabbing = true; killTimers(); grabMouse( crossCursor ); grabx = -1; @@ -278,7 +278,7 @@ void MagWidget::mousePressEvent( TQMouseEvent *e ) void MagWidget::mouseReleaseEvent( TQMouseEvent * e ) { if ( grabbing && grabx >= 0 && graby >= 0 ) { - grabbing = FALSE; + grabbing = false; grabAround(e->pos()); releaseMouse(); } |
