diff options
author | Timothy Pearson <kb9vqf@pearsoncomputing.net> | 2012-02-27 02:13:42 -0600 |
---|---|---|
committer | Timothy Pearson <kb9vqf@pearsoncomputing.net> | 2012-02-27 02:13:42 -0600 |
commit | 520c05ef06ce203ad32470730f68402bc7719157 (patch) | |
tree | 8d0bb18bbbecb4c837e232848905e5819db84b81 /src/dialogs | |
parent | b82553bf90cb5311cfe8e673b07cf6cffc95fd3c (diff) | |
download | tqt3-520c05ef06ce203ad32470730f68402bc7719157.tar.gz tqt3-520c05ef06ce203ad32470730f68402bc7719157.zip |
Automated update from qt3
Diffstat (limited to 'src/dialogs')
-rw-r--r-- | src/dialogs/ntqmessagebox.h | 2 | ||||
-rw-r--r-- | src/dialogs/qcolordialog.cpp | 34 | ||||
-rw-r--r-- | src/dialogs/qdialog.cpp | 30 | ||||
-rw-r--r-- | src/dialogs/qerrormessage.cpp | 4 | ||||
-rw-r--r-- | src/dialogs/qfiledialog.cpp | 30 | ||||
-rw-r--r-- | src/dialogs/qmessagebox.cpp | 6 | ||||
-rw-r--r-- | src/dialogs/qprogressdialog.cpp | 4 |
7 files changed, 55 insertions, 55 deletions
diff --git a/src/dialogs/ntqmessagebox.h b/src/dialogs/ntqmessagebox.h index 0296612ac..11b79fc3f 100644 --- a/src/dialogs/ntqmessagebox.h +++ b/src/dialogs/ntqmessagebox.h @@ -211,7 +211,7 @@ private: // Disabled copy constructor and operator= #define QT_REQUIRE_VERSION( argc, argv, str ) { TQString s=TQString::fromLatin1(str);\ TQString sq=TQString::fromLatin1(qVersion()); if ( (sq.section('.',0,0).toInt()<<16)+\ (sq.section('.',1,1).toInt()<<8)+sq.section('.',2,2).toInt()<(s.section('.',0,0).toInt()<<16)+\ -(s.section('.',1,1).toInt()<<8)+s.section('.',2,2).toInt() ){if ( !qApp){ int c=0; new \ +(s.section('.',1,1).toInt()<<8)+s.section('.',2,2).toInt() ){if ( !tqApp){ int c=0; new \ TQApplication(argc,argv);} TQString s = TQApplication::tr("Executable '%1' requires TQt "\ "%2, found TQt %3.").arg(TQString::fromLatin1(tqAppName())).arg(TQString::fromLatin1(\ str)).arg(TQString::fromLatin1(qVersion()) ); TQMessageBox::critical( 0, TQApplication::tr(\ diff --git a/src/dialogs/qcolordialog.cpp b/src/dialogs/qcolordialog.cpp index 68838c45f..d365e96f7 100644 --- a/src/dialogs/qcolordialog.cpp +++ b/src/dialogs/qcolordialog.cpp @@ -448,10 +448,10 @@ static void initRGB() for ( int g = 0; g < 4; g++ ) for ( int r = 0; r < 4; r++ ) for ( int b = 0; b < 3; b++ ) - stdrgb[i++] = qRgb( r*255/3, g*255/3, b*255/2 ); + stdrgb[i++] = tqRgb( r*255/3, g*255/3, b*255/2 ); for ( i = 0; i < 2*8; i++ ) - cusrgb[i] = qRgb(0xff,0xff,0xff); + cusrgb[i] = tqRgb(0xff,0xff,0xff); } /*! @@ -1077,7 +1077,7 @@ void TQColorShowLabel::mouseReleaseEvent( TQMouseEvent * ) TQColorShower::TQColorShower( TQWidget *parent, const char *name ) :TQWidget( parent, name) { - curCol = qRgb( -1, -1, -1 ); + curCol = tqRgb( -1, -1, -1 ); TQColIntValidator *val256 = new TQColIntValidator( 0, 255, this ); TQColIntValidator *val360 = new TQColIntValidator( 0, 360, this ); @@ -1161,9 +1161,9 @@ void TQColorShower::rgbEd() { rgbOriginal = TRUE; if ( alphaEd->isVisible() ) - curCol = qRgba( rEd->val(), gEd->val(), bEd->val(), currentAlpha() ); + curCol = tqRgba( rEd->val(), gEd->val(), bEd->val(), currentAlpha() ); else - curCol = qRgb( rEd->val(), gEd->val(), bEd->val() ); + curCol = tqRgb( rEd->val(), gEd->val(), bEd->val() ); rgb2hsv(currentColor(), hue, sat, val ); @@ -1184,9 +1184,9 @@ void TQColorShower::hsvEd() curCol = TQColor( hue, sat, val, TQColor::Hsv ).rgb(); - rEd->setNum( qRed(currentColor()) ); - gEd->setNum( qGreen(currentColor()) ); - bEd->setNum( qBlue(currentColor()) ); + rEd->setNum( tqRed(currentColor()) ); + gEd->setNum( tqGreen(currentColor()) ); + bEd->setNum( tqBlue(currentColor()) ); showCurrentColor(); emit newCol( currentColor() ); @@ -1203,9 +1203,9 @@ void TQColorShower::setRgb( TQRgb rgb ) sEd->setNum( sat ); vEd->setNum( val ); - rEd->setNum( qRed(currentColor()) ); - gEd->setNum( qGreen(currentColor()) ); - bEd->setNum( qBlue(currentColor()) ); + rEd->setNum( tqRed(currentColor()) ); + gEd->setNum( tqGreen(currentColor()) ); + bEd->setNum( tqBlue(currentColor()) ); showCurrentColor(); } @@ -1220,9 +1220,9 @@ void TQColorShower::setHsv( int h, int s, int v ) sEd->setNum( sat ); vEd->setNum( val ); - rEd->setNum( qRed(currentColor()) ); - gEd->setNum( qGreen(currentColor()) ); - bEd->setNum( qBlue(currentColor()) ); + rEd->setNum( tqRed(currentColor()) ); + gEd->setNum( tqGreen(currentColor()) ); + bEd->setNum( tqBlue(currentColor()) ); showCurrentColor(); } @@ -1303,7 +1303,7 @@ TQColorDialogPrivate::TQColorDialogPrivate( TQColorDialog *dialog ) : compact = FALSE; // small displays (e.g. PDAs cannot fit the full color dialog, // so just use the color picker. - if ( qApp->desktop()->width() < 480 || qApp->desktop()->height() < 350 ) + if ( tqApp->desktop()->width() < 480 || tqApp->desktop()->height() < 350 ) compact = TRUE; nextCust = 0; @@ -1545,14 +1545,14 @@ TQRgb TQColorDialog::getRgba( TQRgb initial, bool *ok, #endif dlg->setColor( initial ); dlg->selectColor( initial ); - dlg->setSelectedAlpha( qAlpha(initial) ); + dlg->setSelectedAlpha( tqAlpha(initial) ); int resultCode = dlg->exec(); TQColor::leaveAllocContext(); TQRgb result = initial; if ( resultCode == TQDialog::Accepted ) { TQRgb c = dlg->color().rgb(); int alpha = dlg->selectedAlpha(); - result = qRgba( qRed(c), qGreen(c), qBlue(c), alpha ); + result = tqRgba( tqRed(c), tqGreen(c), tqBlue(c), alpha ); } if ( ok ) *ok = resultCode == TQDialog::Accepted; diff --git a/src/dialogs/qdialog.cpp b/src/dialogs/qdialog.cpp index 1ef49e0c0..a25ad609f 100644 --- a/src/dialogs/qdialog.cpp +++ b/src/dialogs/qdialog.cpp @@ -359,15 +359,15 @@ void TQDialog::hideSpecial() TQPushButton *pb; while ( (pb = (TQPushButton*)it.current()) ) { if ( !showOK && - pb->text() == qApp->translate( "TQMessageBox", mb_texts[TQMessageBox::Ok] ) ) { + pb->text() == tqApp->translate( "TQMessageBox", mb_texts[TQMessageBox::Ok] ) ) { pb->hide(); showOK = TRUE; } else if ( !showX && - pb->text() == qApp->translate( "TQMessageBox", mb_texts[TQMessageBox::Cancel] ) ) { + pb->text() == tqApp->translate( "TQMessageBox", mb_texts[TQMessageBox::Cancel] ) ) { pb->hide(); showX = TRUE; } else if ( !showQ && - pb->text() == qApp->tr("Help") ) { + pb->text() == tqApp->tr("Help") ) { pb->hide(); showQ = TRUE; } @@ -432,7 +432,7 @@ int TQDialog::exec() show(); in_loop = TRUE; - qApp->enter_loop(); + tqApp->enter_loop(); if ( !wasShowModal ) clearWFlags( WShowModal ); @@ -465,14 +465,14 @@ void TQDialog::done( int r ) setResult( r ); // emulate TQWidget::close() - bool isMain = qApp->mainWidget() == this; + bool isMain = tqApp->mainWidget() == this; bool checkLastWindowClosed = isTopLevel() && !isPopup(); if ( checkLastWindowClosed - && qApp->receivers(SIGNAL(lastWindowClosed())) ) { + && tqApp->receivers(SIGNAL(lastWindowClosed())) ) { /* if there is no non-withdrawn top level window left (except the desktop, popups, or dialogs with parents), we emit the lastWindowClosed signal */ - TQWidgetList *list = qApp->topLevelWidgets(); + TQWidgetList *list = tqApp->topLevelWidgets(); TQWidget *widget = list->first(); while ( widget ) { if ( !widget->isHidden() @@ -484,10 +484,10 @@ void TQDialog::done( int r ) } delete list; if ( widget == 0 ) - emit qApp->lastWindowClosed(); + emit tqApp->lastWindowClosed(); } if ( isMain ) - qApp->quit(); + tqApp->quit(); else if ( testWFlags(WDestructiveClose) ) { clearWFlags(WDestructiveClose); deleteLater(); @@ -644,8 +644,8 @@ bool TQDialog::event( TQEvent *e ) { TQString bName = (e->type() == TQEvent::OkRequest) - ? qApp->translate( "TQMessageBox", mb_texts[TQMessageBox::Ok] ) - : qApp->tr( "Help" ); + ? tqApp->translate( "TQMessageBox", mb_texts[TQMessageBox::Ok] ) + : tqApp->tr( "Help" ); TQObjectList *list = queryList( "TQPushButton" ); TQObjectListIt it( *list ); @@ -712,10 +712,10 @@ void TQDialog::show() #if defined(Q_WS_X11) if (!parentWidget() && testWFlags(WShowModal) - && qApp->mainWidget() && qApp->mainWidget()->isVisible() - && !qApp->mainWidget()->isMinimized()) { + && tqApp->mainWidget() && tqApp->mainWidget()->isVisible() + && !tqApp->mainWidget()->isMinimized()) { // make sure the transient for hint is set properly for modal dialogs - x11SetWindowTransient( qApp->mainWidget()); + x11SetWindowTransient( tqApp->mainWidget()); } #endif // Q_WS_X11 @@ -900,7 +900,7 @@ void TQDialog::hide() TQWidget::hide(); if ( in_loop ) { in_loop = FALSE; - qApp->exit_loop(); + tqApp->exit_loop(); } } diff --git a/src/dialogs/qerrormessage.cpp b/src/dialogs/qerrormessage.cpp index a33872bb8..70e670689 100644 --- a/src/dialogs/qerrormessage.cpp +++ b/src/dialogs/qerrormessage.cpp @@ -226,8 +226,8 @@ TQErrorMessage * TQErrorMessage::qtHandler() qtMessageHandler = new TQErrorMessage( 0, "automatic message handler" ); qAddPostRoutine( deleteStaticcTQErrorMessage ); // clean up #ifndef QT_NO_WIDGET_TOPEXTRA - if ( qApp->mainWidget() ) - qtMessageHandler->setCaption( qApp->mainWidget()->caption() ); + if ( tqApp->mainWidget() ) + qtMessageHandler->setCaption( tqApp->mainWidget()->caption() ); #endif qInstallMsgHandler( jump ); } diff --git a/src/dialogs/qfiledialog.cpp b/src/dialogs/qfiledialog.cpp index fddc5716a..019d3d56c 100644 --- a/src/dialogs/qfiledialog.cpp +++ b/src/dialogs/qfiledialog.cpp @@ -616,7 +616,7 @@ static void makeVariables() { detailViewMode = FALSE; #if defined(Q_WS_WIN) if ( !fileIconProvider ) - fileIconProvider = new TQWindowsIconProvider( qApp ); + fileIconProvider = new TQWindowsIconProvider( tqApp ); #endif } } @@ -3498,12 +3498,12 @@ TQString TQFileDialog::getOpenFileName( const TQString & startWith, return TQKDEIntegration::getOpenFileNames( filter, workingDirectory, parent, name, caption, selectedFilter, false ).first(); #elif defined(Q_WS_WIN) - if ( qt_use_native_dialogs && qApp->style().styleHint( TQStyle::SH_GUIStyle ) == WindowsStyle ) + if ( qt_use_native_dialogs && tqApp->style().styleHint( TQStyle::SH_GUIStyle ) == WindowsStyle ) return winGetOpenFileName( initialSelection, filter, workingDirectory, parent, name, caption, selectedFilter ); #elif defined(Q_WS_MAC) - if (qt_use_native_dialogs && (qApp->style().inherits(TQMAC_DEFAULT_STYLE) - || qApp->style().inherits("TQMacStyle"))) + if (qt_use_native_dialogs && (tqApp->style().inherits(TQMAC_DEFAULT_STYLE) + || tqApp->style().inherits("TQMacStyle"))) return qt_mac_precomposeFileName(macGetOpenFileNames(filter, startWith.isEmpty() ? 0 : workingDirectory, parent, name, caption, selectedFilter, FALSE).first()); @@ -3623,12 +3623,12 @@ TQString TQFileDialog::getSaveFileName( const TQString & startWith, return TQKDEIntegration::getSaveFileName( initialSelection, filter, workingDirectory, parent, name, caption, selectedFilter ); #elif defined(Q_WS_WIN) - if ( qt_use_native_dialogs && qApp->style().styleHint( TQStyle::SH_GUIStyle ) == WindowsStyle ) + if ( qt_use_native_dialogs && tqApp->style().styleHint( TQStyle::SH_GUIStyle ) == WindowsStyle ) return winGetSaveFileName( initialSelection, filter, workingDirectory, parent, name, caption, selectedFilter ); #elif defined(Q_WS_MAC) - if (qt_use_native_dialogs && (qApp->style().inherits(TQMAC_DEFAULT_STYLE) - || qApp->style().inherits("TQMacStyle"))) + if (qt_use_native_dialogs && (tqApp->style().inherits(TQMAC_DEFAULT_STYLE) + || tqApp->style().inherits("TQMacStyle"))) return qt_mac_precomposeFileName(macGetSaveFileName(initialSelection, filter, startWith.isEmpty() ? 0 : workingDirectory, parent, name, caption, selectedFilter)); @@ -4530,7 +4530,7 @@ TQString TQFileDialog::getExistingDirectory( const TQString & dir, initialDir = dir; } else initialDir = TQString::null; - if ( qt_use_native_dialogs && qApp->style().styleHint( TQStyle::SH_GUIStyle ) == WindowsStyle && dirOnly ) + if ( qt_use_native_dialogs && tqApp->style().styleHint( TQStyle::SH_GUIStyle ) == WindowsStyle && dirOnly ) return winGetExistingDirectory( initialDir, parent, name, caption ); #endif #if defined(Q_WS_MAC) @@ -4540,8 +4540,8 @@ TQString TQFileDialog::getExistingDirectory( const TQString & dir, if (TQFileInfo(u.path()).isDir()) initialDir = (TQString *)&dir; } - if( qt_use_native_dialogs && (qApp->style().inherits(TQMAC_DEFAULT_STYLE) - || qApp->style().inherits("TQMacStyle"))) + if( qt_use_native_dialogs && (tqApp->style().inherits(TQMAC_DEFAULT_STYLE) + || tqApp->style().inherits("TQMacStyle"))) return qt_mac_precomposeFileName(macGetOpenFileNames("", initialDir, parent, name, caption, 0, FALSE, TRUE).first()); #endif @@ -5690,11 +5690,11 @@ TQStringList TQFileDialog::getOpenFileNames( const TQString & filter, if ( qt_use_native_dialogs && TQKDEIntegration::enabled()) return TQKDEIntegration::getOpenFileNames( filter, workingDirectory, parent, name, caption, selectedFilter, true ); #elif defined(Q_WS_WIN) - if ( qt_use_native_dialogs && qApp->style().styleHint( TQStyle::SH_GUIStyle ) == WindowsStyle ) + if ( qt_use_native_dialogs && tqApp->style().styleHint( TQStyle::SH_GUIStyle ) == WindowsStyle ) return winGetOpenFileNames( filter, workingDirectory, parent, name, caption, selectedFilter ); #elif defined(Q_WS_MAC) - if (qt_use_native_dialogs && (qApp->style().inherits(TQMAC_DEFAULT_STYLE) - || qApp->style().inherits("TQMacStyle"))) { + if (qt_use_native_dialogs && (tqApp->style().inherits(TQMAC_DEFAULT_STYLE) + || tqApp->style().inherits("TQMacStyle"))) { TQStringList sl = macGetOpenFileNames(filter, dir.isEmpty() ? 0 : workingDirectory, parent, name, caption, selectedFilter); TQStringList::iterator it = sl.begin(); @@ -6375,7 +6375,7 @@ void TQFileDialog::doMimeTypeLookup() // evil hack to avoid much too much repaints! TQGuardedPtr<TQFileDialog> that( this ); // this may be deleted by an event handler - qApp->processEvents(); + tqApp->processEvents(); if ( that.isNull() ) return; files->setUpdatesEnabled( FALSE ); @@ -6383,7 +6383,7 @@ void TQFileDialog::doMimeTypeLookup() if ( item != d->pendingItems.first() ) return; item->setPixmap( 0, *p ); - qApp->processEvents(); + tqApp->processEvents(); if ( that.isNull() ) return; files->setUpdatesEnabled( TRUE ); diff --git a/src/dialogs/qmessagebox.cpp b/src/dialogs/qmessagebox.cpp index ce6c505b0..96aabc066 100644 --- a/src/dialogs/qmessagebox.cpp +++ b/src/dialogs/qmessagebox.cpp @@ -1324,7 +1324,7 @@ void TQMessageBox::about( TQWidget *parent, const TQString &caption, if ( pm && !pm->isNull() ) mb->setIconPixmap( *pm ); else { - pm = qApp && qApp->mainWidget() ? qApp->mainWidget()->icon() : 0; + pm = tqApp && tqApp->mainWidget() ? tqApp->mainWidget()->icon() : 0; if ( pm && !pm->isNull() ) mb->setIconPixmap( *pm ); } @@ -1607,8 +1607,8 @@ void TQMessageBox::aboutTQt( TQWidget *parent, const TQString &caption ) #ifndef QT_NO_IMAGEIO TQPixmap pm; TQImage logo( (const char **)qtlogo_xpm); - if ( qGray(mb->palette().active().text().rgb()) > - qGray(mb->palette().active().base().rgb()) ) + if ( tqGray(mb->palette().active().text().rgb()) > + tqGray(mb->palette().active().base().rgb()) ) { // light on dark, adjust some colors (where's 10?) logo.setColor( 0, 0xffffffff ); diff --git a/src/dialogs/qprogressdialog.cpp b/src/dialogs/qprogressdialog.cpp index d29b4c581..fe5168a03 100644 --- a/src/dialogs/qprogressdialog.cpp +++ b/src/dialogs/qprogressdialog.cpp @@ -143,7 +143,7 @@ TQProgressDialog progress( "Copying files...", "Abort Copy", numFiles, this, "progress", TRUE ); for ( int i = 0; i < numFiles; i++ ) { progress.setProgress( i ); - qApp->processEvents(); + tqApp->processEvents(); if ( progress.wasCanceled() ) break; @@ -580,7 +580,7 @@ void TQProgressDialog::setProgress( int progress ) if ( d->shown_once ) { if (testWFlags(WShowModal)) - qApp->processEvents(); + tqApp->processEvents(); } else { if ( progress == 0 ) { #ifndef QT_NO_CURSOR |