diff options
Diffstat (limited to 'kdialog/widgets.cpp')
-rw-r--r-- | kdialog/widgets.cpp | 34 |
1 files changed, 17 insertions, 17 deletions
diff --git a/kdialog/widgets.cpp b/kdialog/widgets.cpp index f68acfe4f..8a92a5dd3 100644 --- a/kdialog/widgets.cpp +++ b/kdialog/widgets.cpp @@ -35,17 +35,17 @@ #include <tqvbox.h> #include <tqfile.h> -#if defined Q_WS_X11 && ! defined K_WS_QTONLY +#if defined TQ_WS_X11 && ! defined K_WS_QTONLY #include <netwm.h> #endif void Widgets::handleXGeometry(TQWidget * dlg) { -#ifdef Q_WS_X11 - if ( ! kapp->geometryArgument().isEmpty()) { +#ifdef TQ_WS_X11 + if ( ! tdeApp->geometryArgument().isEmpty()) { int x, y; int w, h; - int m = XParseGeometry( kapp->geometryArgument().latin1(), &x, &y, (unsigned int*)&w, (unsigned int*)&h); + int m = XParseGeometry( tdeApp->geometryArgument().latin1(), &x, &y, (unsigned int*)&w, (unsigned int*)&h); if ( (m & XNegative) ) x = TDEApplication::desktop()->width() + x - w; if ( (m & YNegative) ) @@ -69,7 +69,7 @@ bool Widgets::passwordBox(TQWidget *parent, const TQString& title, const TQStrin { KPasswordDialog dlg( KPasswordDialog::Password, false, 0, parent ); - kapp->setTopWidget( &dlg ); + tdeApp->setTopWidget( &dlg ); dlg.setCaption(title); dlg.setPrompt(text); @@ -83,12 +83,12 @@ bool Widgets::passwordBox(TQWidget *parent, const TQString& title, const TQStrin int Widgets::textBox(TQWidget *parent, int width, int height, const TQString& title, const TQString& file) { -// KTextBox dlg(parent, 0, TRUE, width, height, file); +// KTextBox dlg(parent, 0, true, width, height, file); KDialogBase dlg( parent, 0, true, title, KDialogBase::Ok, KDialogBase::Ok ); - kapp->setTopWidget( &dlg ); + tdeApp->setTopWidget( &dlg ); KTextEdit *edit = new KTextEdit( dlg.makeVBoxMainWidget() ); - edit->setReadOnly(TRUE); + edit->setReadOnly(true); TQFile f(file); if (!f.open(IO_ReadOnly)) @@ -116,10 +116,10 @@ int Widgets::textBox(TQWidget *parent, int width, int height, const TQString& ti int Widgets::textInputBox(TQWidget *parent, int width, int height, const TQString& title, const TQStringList& args, TQCString &result) { -// KTextBox dlg(parent, 0, TRUE, width, height, file); +// KTextBox dlg(parent, 0, true, width, height, file); KDialogBase dlg( parent, 0, true, title, KDialogBase::Ok, KDialogBase::Ok ); - kapp->setTopWidget( &dlg ); + tdeApp->setTopWidget( &dlg ); TQVBox* vbox = dlg.makeVBoxMainWidget(); if( args.count() > 0 ) @@ -129,7 +129,7 @@ int Widgets::textInputBox(TQWidget *parent, int width, int height, const TQStrin } KTextEdit *edit = new KTextEdit( vbox ); - edit->setReadOnly(FALSE); + edit->setReadOnly(false); edit->setTextFormat( TQt::PlainText ); edit->setFocus(); @@ -152,7 +152,7 @@ bool Widgets::comboBox(TQWidget *parent, const TQString& title, const TQString& KDialogBase dlg( parent, 0, true, title, KDialogBase::Ok|KDialogBase::Cancel, KDialogBase::Ok ); - kapp->setTopWidget( &dlg ); + tdeApp->setTopWidget( &dlg ); dlg.setCaption(title); TQVBox* vbox = dlg.makeVBoxMainWidget(); @@ -177,7 +177,7 @@ bool Widgets::listBox(TQWidget *parent, const TQString& title, const TQString& t { TDEListBoxDialog box(text,parent); - kapp->setTopWidget( &box ); + tdeApp->setTopWidget( &box ); box.setCaption(title); for (unsigned int i = 0; i+1<args.count(); i += 2) { @@ -205,7 +205,7 @@ bool Widgets::checkList(TQWidget *parent, const TQString& title, const TQString& TQListBox &table = box.getTable(); - kapp->setTopWidget( &box ); + tdeApp->setTopWidget( &box ); box.setCaption(title); for (unsigned int i=0; i+2<args.count(); i += 3) { @@ -214,7 +214,7 @@ bool Widgets::checkList(TQWidget *parent, const TQString& title, const TQString& } table.insertStringList(entries); - table.setMultiSelection(TRUE); + table.setMultiSelection(true); table.setCurrentItem(0); // This is to circumvent a Qt bug for (unsigned int i=0; i+2<args.count(); i += 3) { @@ -249,7 +249,7 @@ bool Widgets::radioBox(TQWidget *parent, const TQString& title, const TQString& TQListBox &table = box.getTable(); - kapp->setTopWidget( &box ); + tdeApp->setTopWidget( &box ); box.setCaption(title); for (unsigned int i=0; i+2<args.count(); i += 3) { @@ -274,7 +274,7 @@ bool Widgets::radioBox(TQWidget *parent, const TQString& title, const TQString& bool Widgets::progressBar(TQWidget *parent, const TQString& title, const TQString& text, int totalSteps) { ProgressDialog dlg( parent, title, text, totalSteps ); - kapp->setTopWidget( &dlg ); + tdeApp->setTopWidget( &dlg ); dlg.setCaption( title ); handleXGeometry(&dlg); dlg.exec(); |