diff options
Diffstat (limited to 'src/dialogs/tqwizard.cpp')
| -rw-r--r-- | src/dialogs/tqwizard.cpp | 48 |
1 files changed, 24 insertions, 24 deletions
diff --git a/src/dialogs/tqwizard.cpp b/src/dialogs/tqwizard.cpp index 78b7431b2..5e2ebaff8 100644 --- a/src/dialogs/tqwizard.cpp +++ b/src/dialogs/tqwizard.cpp @@ -112,9 +112,9 @@ public: struct Page { Page( TQWidget * widget, const TQString & title ): w( widget ), t( title ), - backEnabled( TRUE ), nextEnabled( TRUE ), finishEnabled( FALSE ), - helpEnabled( TRUE ), - appropriate( TRUE ) + backEnabled( true ), nextEnabled( true ), finishEnabled( false ), + helpEnabled( true ), + appropriate( true ) {} TQWidget * w; TQString t; @@ -168,7 +168,7 @@ TQWizard::TQWizard( TQWidget *parent, const char *name, bool modal, d = new TQWizardPrivate(); d->current = 0; // not quite true, but... d->ws = new TQWidgetStack( this, "qt_widgetstack" ); - d->pages.setAutoDelete( TRUE ); + d->pages.setAutoDelete( true ); d->title = new TQLabel( this, "title label" ); // create in nice tab order @@ -190,7 +190,7 @@ TQWizard::TQWizard( TQWidget *parent, const char *name, bool modal, d->finishButton->setText( tr( "&Finish" ) ); d->helpButton->setText( tr( "&Help" ) ); - d->nextButton->setDefault( TRUE ); + d->nextButton->setDefault( true ); connect( d->backButton, TQ_SIGNAL(clicked()), this, TQ_SLOT(back()) ); @@ -273,7 +273,7 @@ void TQWizard::addPage( TQWidget * page, const TQString & title ) int i = d->pages.count(); if( i > 0 ) - d->pages.at( i - 1 )->nextEnabled = TRUE; + d->pages.at( i - 1 )->nextEnabled = true; TQWizardPrivate::Page * p = new TQWizardPrivate::Page( page, title ); p->backEnabled = ( i > 0 ); @@ -304,7 +304,7 @@ void TQWizard::insertPage( TQWidget * page, const TQString & title, int index ) index = d->pages.count(); if( index > 0 && ( index == (int)d->pages.count() ) ) - d->pages.at( index - 1 )->nextEnabled = TRUE; + d->pages.at( index - 1 )->nextEnabled = true; TQWizardPrivate::Page * p = new TQWizardPrivate::Page( page, title ); p->backEnabled = ( index > 0 ); @@ -337,7 +337,7 @@ void TQWizard::showPage( TQWidget * page ) if ( p ) { int i; for( i = 0; i < (int)d->pages.count() && d->pages.at( i ) != p; i++ ); - bool notFirst( FALSE ); + bool notFirst( false ); if( i ) { i--; @@ -347,7 +347,7 @@ void TQWizard::showPage( TQWidget * page ) } } setBackEnabled( notFirst ); - setNextEnabled( TRUE ); + setNextEnabled( true ); d->ws->raiseWidget( page ); d->current = p; } @@ -486,7 +486,7 @@ void TQWizard::setHelpEnabled( bool enable ) */ /*! - If \a enable is TRUE, page \a page has a Back button; otherwise \a + If \a enable is true, page \a page has a Back button; otherwise \a page has no Back button. By default all pages have this button. */ void TQWizard::setBackEnabled( TQWidget * page, bool enable ) @@ -501,7 +501,7 @@ void TQWizard::setBackEnabled( TQWidget * page, bool enable ) /*! - If \a enable is TRUE, page \a page has a Next button; otherwise + If \a enable is true, page \a page has a Next button; otherwise the Next button on \a page is disabled. By default all pages have this button. */ @@ -518,7 +518,7 @@ void TQWizard::setNextEnabled( TQWidget * page, bool enable ) /*! - If \a enable is TRUE, page \a page has a Finish button; otherwise + If \a enable is true, page \a page has a Finish button; otherwise \a page has no Finish button. By default \e no page has this button. */ @@ -534,7 +534,7 @@ void TQWizard::setFinishEnabled( TQWidget * page, bool enable ) /*! - If \a enable is TRUE, page \a page has a Help button; otherwise \a + If \a enable is true, page \a page has a Help button; otherwise \a page has no Help button. By default all pages have this button. */ void TQWizard::setHelpEnabled( TQWidget * page, bool enable ) @@ -550,10 +550,10 @@ void TQWizard::setHelpEnabled( TQWidget * page, bool enable ) /*! Called when the Next button is clicked; this virtual function - returns TRUE if \a page is relevant for display in the current - context; otherwise it is ignored by TQWizard and returns FALSE. The + returns true if \a page is relevant for display in the current + context; otherwise it is ignored by TQWizard and returns false. The default implementation returns the value set using - setAppropriate(). The ultimate default is TRUE. + setAppropriate(). The ultimate default is true. \warning The last page of the wizard will be displayed if no page is relevant in the current context. @@ -562,12 +562,12 @@ void TQWizard::setHelpEnabled( TQWidget * page, bool enable ) bool TQWizard::appropriate( TQWidget * page ) const { TQWizardPrivate::Page * p = d->page( page ); - return p ? p->appropriate : TRUE; + return p ? p->appropriate : true; } /*! - If \a appropriate is TRUE then page \a page is considered relevant + If \a appropriate is true then page \a page is considered relevant in the current context and should be displayed in the page sequence; otherwise \a page should not be displayed in the page sequence. @@ -589,7 +589,7 @@ void TQWizard::updateButtons() int i; for( i = 0; i < (int)d->pages.count() && d->pages.at( i ) != d->current; i++ ); - bool notFirst( FALSE ); + bool notFirst( false ); if( i ) { i--; while( ( i >= 0 ) && !notFirst ) { @@ -736,19 +736,19 @@ TQPushButton * TQWizard::helpButton() const void TQWizard::layOutButtonRow( TQHBoxLayout * layout ) { - bool hasHelp = FALSE; - bool hasEarlyFinish = FALSE; + bool hasHelp = false; + bool hasEarlyFinish = false; int i = d->pages.count() - 2; while ( !hasEarlyFinish && i >= 0 ) { if ( d->pages.at( i ) && d->pages.at( i )->finishEnabled ) - hasEarlyFinish = TRUE; + hasEarlyFinish = true; i--; } i = 0; while ( !hasHelp && i < (int)d->pages.count() ) { if ( d->pages.at( i ) && d->pages.at( i )->helpEnabled ) - hasHelp = TRUE; + hasHelp = true; i++; } @@ -767,7 +767,7 @@ void TQWizard::layOutButtonRow( TQHBoxLayout * layout ) h->addSpacing( 6 ); if (d->current == d->pages.at( d->pages.count()-1 )) - hasEarlyFinish = FALSE; + hasEarlyFinish = false; if ( hasEarlyFinish ) { d->nextButton->show(); |
