diff options
| author | Michele Calgaro <michele.calgaro@yahoo.it> | 2025-12-26 14:08:52 +0900 |
|---|---|---|
| committer | Michele Calgaro <michele.calgaro@yahoo.it> | 2025-12-27 22:38:28 +0900 |
| commit | 50326e196a9245af21604da7dc3a36eea52784ed (patch) | |
| tree | 955f50c739379c59d3846c5c6ec25c8f5856fb91 /src/widgets/tqtabwidget.cpp | |
| parent | 854c5d5c9cfd48a2d5a17366fb6805219eab4859 (diff) | |
| download | tqt-50326e196a9245af21604da7dc3a36eea52784ed.tar.gz tqt-50326e196a9245af21604da7dc3a36eea52784ed.zip | |
Replace TRUE/FALSE with boolean values true/false - part 10
Signed-off-by: Michele Calgaro <michele.calgaro@yahoo.it>
Diffstat (limited to 'src/widgets/tqtabwidget.cpp')
| -rw-r--r-- | src/widgets/tqtabwidget.cpp | 30 |
1 files changed, 15 insertions, 15 deletions
diff --git a/src/widgets/tqtabwidget.cpp b/src/widgets/tqtabwidget.cpp index ea294e76a..15383cbdf 100644 --- a/src/widgets/tqtabwidget.cpp +++ b/src/widgets/tqtabwidget.cpp @@ -203,7 +203,7 @@ class TQTabWidgetData { public: TQTabWidgetData() - : tabs(0), tabBase(0), stack(0), dirty( TRUE ), + : tabs(0), tabBase(0), stack(0), dirty( true ), pos( TQTabWidget::Top ), shape( TQTabWidget::Rounded ), leftCornerWidget(0), rightCornerWidget(0) {}; ~TQTabWidgetData(){}; @@ -373,7 +373,7 @@ void TQTabWidget::insertTab( TQWidget *child, const TQIconSet& iconset, const TQ */ void TQTabWidget::insertTab( TQWidget *child, TQTab* tab, int index) { - tab->enabled = TRUE; + tab->enabled = true; int id = d->tabs->insertTab( tab, index ); d->stack->addWidget( child, id ); if ( d->stack->frameStyle() != ( TQFrame::TabWidgetPanel | TQFrame::Raised ) ) @@ -428,7 +428,7 @@ void TQTabWidget::changeTab( TQWidget *w, const TQIconSet& iconset, const TQStri } /*! - Returns TRUE if the page \a w is enabled; otherwise returns FALSE. + Returns true if the page \a w is enabled; otherwise returns false. \sa setTabEnabled(), TQWidget::isEnabled() */ @@ -439,11 +439,11 @@ bool TQTabWidget::isTabEnabled( TQWidget* w ) const if ( id >= 0 ) return w->isEnabled(); else - return FALSE; + return false; } /*! - If \a enable is TRUE, page \a w is enabled; otherwise page \a w is + If \a enable is true, page \a w is enabled; otherwise page \a w is disabled. The page's tab is redrawn appropriately. TQTabWidget uses TQWidget::setEnabled() internally, rather than @@ -527,7 +527,7 @@ void TQTabWidget::removePage( TQWidget * w ) int oldId = d->stack->id(currentPage()); bool fixCurrentTab = oldId == id; //switches to the next enabled tab - d->tabs->setTabEnabled( id, FALSE ); + d->tabs->setTabEnabled( id, false ); //if no next enabled page we fix the current page fixCurrentTab = fixCurrentTab && oldId == d->stack->id(currentPage()); @@ -632,7 +632,7 @@ void TQTabWidget::resizeEvent( TQResizeEvent *e ) void TQTabWidget::setTabBar( TQTabBar* tb) { if ( tb->parentWidget() != this ) - tb->reparent( this, TQPoint(0,0), TRUE ); + tb->reparent( this, TQPoint(0,0), true ); delete d->tabs; d->tabs = tb; setFocusProxy( d->tabs ); @@ -675,7 +675,7 @@ void TQTabWidget::setUpLayout( bool onlyCheck ) return; // nothing to do if ( !isVisible() ) { - d->dirty = TRUE; + d->dirty = true; return; // we'll do it later } @@ -737,7 +737,7 @@ void TQTabWidget::setUpLayout( bool onlyCheck ) d->stack->setGeometry( 0, stacky, width(), height() - (exth-overlap) - t.height()+TQMAX(0, lw-2)); - d->dirty = FALSE; + d->dirty = false; // move cornerwidgets if ( d->leftCornerWidget ) { @@ -770,7 +770,7 @@ TQSize TQTabWidget::sizeHint() const rc = d->rightCornerWidget->sizeHint(); if ( !d->dirty ) { TQTabWidget *that = (TQTabWidget*)this; - that->setUpLayout( TRUE ); + that->setUpLayout( true ); } TQSize s( d->stack->sizeHint() ); TQSize t( d->tabs->sizeHint() ); @@ -800,7 +800,7 @@ TQSize TQTabWidget::minimumSizeHint() const rc = d->rightCornerWidget->minimumSizeHint(); if ( !d->dirty ) { TQTabWidget *that = (TQTabWidget*)this; - that->setUpLayout( TRUE ); + that->setUpLayout( true ); } TQSize s( d->stack->minimumSizeHint() ); TQSize t( d->tabs->minimumSizeHint() ); @@ -942,7 +942,7 @@ bool TQTabWidget::eventFilter( TQObject *o, TQEvent * e) { if ( o == this ) { if ( e->type() == TQEvent::LanguageChange || e->type() == TQEvent::LayoutHint ) { - d->dirty = TRUE; + d->dirty = true; setUpLayout(); updateGeometry(); } else if ( e->type() == TQEvent::KeyPress ) { @@ -963,7 +963,7 @@ bool TQTabWidget::eventFilter( TQObject *o, TQEvent * e) setCurrentPage( page ); if ( !tqApp->focusWidget() ) d->tabs->setFocus(); - return TRUE; + return true; } } @@ -971,12 +971,12 @@ bool TQTabWidget::eventFilter( TQObject *o, TQEvent * e) if ( e->type() == TQEvent::ChildRemoved && ( (TQChildEvent*)e )->child()->isWidgetType() ) { removePage( (TQWidget*) ( (TQChildEvent*)e )->child() ); - return TRUE; + return true; } else if ( e->type() == TQEvent::LayoutHint ) { updateGeometry(); } } - return FALSE; + return false; } /*! |
