summaryrefslogtreecommitdiffstats
path: root/examples/tqdir/tqdir.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'examples/tqdir/tqdir.cpp')
-rw-r--r--examples/tqdir/tqdir.cpp28
1 files changed, 14 insertions, 14 deletions
diff --git a/examples/tqdir/tqdir.cpp b/examples/tqdir/tqdir.cpp
index dc087f73a..f0f8415ea 100644
--- a/examples/tqdir/tqdir.cpp
+++ b/examples/tqdir/tqdir.cpp
@@ -94,7 +94,7 @@ void PixmapView::setPixmap( const TQPixmap &pix )
{
pixmap = pix;
resizeContents( pixmap.size().width(), pixmap.size().height() );
- viewport()->repaint( FALSE );
+ viewport()->repaint( false );
}
void PixmapView::drawContents( TQPainter *p, int cx, int cy, int cw, int ch )
@@ -109,7 +109,7 @@ Preview::Preview( TQWidget *parent )
: TQWidgetStack( parent )
{
normalText = new TQMultiLineEdit( this );
- normalText->setReadOnly( TRUE );
+ normalText->setReadOnly( true );
html = new TQTextView( this );
pixmap = new PixmapView( this );
raiseWidget( normalText );
@@ -183,15 +183,15 @@ void PreviewWidget::previewUrl( const TQUrl &u )
// ****************************************************************************************************
CustomFileDialog::CustomFileDialog()
- : TQFileDialog( 0, 0, TRUE )
+ : TQFileDialog( 0, 0, true )
{
setDir( "/" );
- dirView = new DirectoryView( this, 0, TRUE );
+ dirView = new DirectoryView( this, 0, true );
dirView->addColumn( "" );
dirView->header()->hide();
::Directory *root = new ::Directory( dirView, "/" );
- root->setOpen( TRUE );
+ root->setOpen( true );
dirView->setFixedWidth( 150 );
addLeftWidget( dirView );
@@ -220,7 +220,7 @@ CustomFileDialog::CustomFileDialog()
p->setPopup( bookmarkMenu );
- addToolButton( p, TRUE );
+ addToolButton( p, true );
connect( dirView, TQ_SIGNAL( folderSelected( const TQString & ) ),
this, TQ_SLOT( setDir2( const TQString & ) ) );
@@ -252,9 +252,9 @@ CustomFileDialog::~CustomFileDialog()
void CustomFileDialog::setDir2( const TQString &s )
{
- blockSignals( TRUE );
+ blockSignals( true );
setDir( s );
- blockSignals( FALSE );
+ blockSignals( false );
}
void CustomFileDialog::showEvent( TQShowEvent *e )
@@ -289,8 +289,8 @@ int main( int argc, char ** argv )
TQString start;
TQString filter;
TQString caption;
- bool preview = FALSE;
- bool custom = FALSE;
+ bool preview = false;
+ bool custom = false;
TQApplication a( argc, argv );
for (int i=1; i<argc; i++) {
TQString arg = argv[i];
@@ -303,9 +303,9 @@ int main( int argc, char ** argv )
else if ( arg == "-filter" )
filter = argv[++i];
else if ( arg == "-preview" )
- preview = TRUE;
+ preview = true;
else if ( arg == "-custom" )
- custom = TRUE;
+ custom = true;
else if ( arg[0] == '-' ) {
tqDebug("Usage: tqdir [-any | -dir | -custom] [-preview] [-default f] {-filter f} [caption ...]\n"
" -any Get any filename, need not exist.\n"
@@ -333,10 +333,10 @@ int main( int argc, char ** argv )
? "Choose directory..." : "Choose file...";
if ( !custom ) {
- TQFileDialog fd( TQString::null, filter, 0, 0, TRUE );
+ TQFileDialog fd( TQString::null, filter, 0, 0, true );
fd.setMode( mode );
if ( preview ) {
- fd.setContentsPreviewEnabled( TRUE );
+ fd.setContentsPreviewEnabled( true );
PreviewWidget *pw = new PreviewWidget( &fd );
fd.setContentsPreview( pw, pw );
fd.setViewMode( TQFileDialog::List );