summaryrefslogtreecommitdiffstats
path: root/kdevdesigner/designer/designerapp.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'kdevdesigner/designer/designerapp.cpp')
-rw-r--r--kdevdesigner/designer/designerapp.cpp76
1 files changed, 38 insertions, 38 deletions
diff --git a/kdevdesigner/designer/designerapp.cpp b/kdevdesigner/designer/designerapp.cpp
index 480bc65b..3a0016c4 100644
--- a/kdevdesigner/designer/designerapp.cpp
+++ b/kdevdesigner/designer/designerapp.cpp
@@ -31,30 +31,30 @@
#include <kiconloader.h>
-#include <qfile.h>
-#include <qdir.h>
-#include <qsettings.h>
-#include <qsplashscreen.h>
+#include <tqfile.h>
+#include <tqdir.h>
+#include <tqsettings.h>
+#include <tqsplashscreen.h>
#ifdef Q_WS_WIN
#include <qt_windows.h>
#include <process.h>
#endif
-static QSplashScreen *splash = 0;
+static TQSplashScreen *splash = 0;
-void set_splash_status( const QString &txt )
+void set_splash_status( const TQString &txt )
{
if ( !splash )
return;
- QString splashText = "Licensed to "
- + QString::fromLatin1( QT_PRODUCT_LICENSEE ) + "\n"
+ TQString splashText = "Licensed to "
+ + TQString::fromLatin1( QT_PRODUCT_LICENSEE ) + "\n"
+ txt;
splash->message( splashText, Qt::AlignRight|Qt::AlignTop );
}
DesignerApplication::DesignerApplication( int &argc, char **argv )
- : QApplication( argc, argv )
+ : TQApplication( argc, argv )
{
#if defined(Q_WS_WIN)
if ( winVersion() & Qt::WV_NT_based )
@@ -64,23 +64,23 @@ DesignerApplication::DesignerApplication( int &argc, char **argv )
#endif
}
-QSplashScreen *DesignerApplication::showSplash()
+TQSplashScreen *DesignerApplication::showSplash()
{
- QRect screen = QApplication::desktop()->screenGeometry();
- QSettings config;
- config.insertSearchPath( QSettings::Windows, "/Trolltech" );
+ TQRect screen = TQApplication::desktop()->screenGeometry();
+ TQSettings config;
+ config.insertSearchPath( TQSettings::Windows, "/Trolltech" );
- QRect mainRect;
- QString keybase = settingsKey();
+ TQRect mainRect;
+ TQString keybase = settingsKey();
bool show = config.readBoolEntry( keybase + "SplashScreen", TRUE );
mainRect.setX( config.readNumEntry( keybase + "Geometries/MainwindowX", 0 ) );
mainRect.setY( config.readNumEntry( keybase + "Geometries/MainwindowY", 0 ) );
mainRect.setWidth( config.readNumEntry( keybase + "Geometries/MainwindowWidth", 500 ) );
mainRect.setHeight( config.readNumEntry( keybase + "Geometries/MainwindowHeight", 500 ) );
- screen = QApplication::desktop()->screenGeometry( QApplication::desktop()->screenNumber( mainRect.center() ) );
+ screen = TQApplication::desktop()->screenGeometry( TQApplication::desktop()->screenNumber( mainRect.center() ) );
if ( show ) {
- splash = new QSplashScreen( UserIcon("designer_splash.png") );
+ splash = new TQSplashScreen( UserIcon("designer_splash.png") );
splash->show();
set_splash_status( "Initializing..." );
}
@@ -93,19 +93,19 @@ void DesignerApplication::closeSplash()
splash->hide();
}
-static QString *settings_key = 0;
-static QString *old_settings_key = 0;
+static TQString *settings_key = 0;
+static TQString *old_settings_key = 0;
-QString DesignerApplication::settingsKey()
+TQString DesignerApplication::settingsKey()
{
if ( !settings_key )
- settings_key = new QString( "/Qt Designer/" +
- QString::number( (QT_VERSION >> 16) & 0xff ) +
- "." + QString::number( (QT_VERSION >> 8) & 0xff ) + "/" );
+ settings_key = new TQString( "/Qt Designer/" +
+ TQString::number( (QT_VERSION >> 16) & 0xff ) +
+ "." + TQString::number( (QT_VERSION >> 8) & 0xff ) + "/" );
return *settings_key;
}
-QString DesignerApplication::oldSettingsKey()
+TQString DesignerApplication::oldSettingsKey()
{
if ( !old_settings_key ) {
int majorVer = (QT_VERSION >> 16) & 0xff;
@@ -116,17 +116,17 @@ QString DesignerApplication::oldSettingsKey()
if ( !minorVer == 0 )
minorVer--;
- old_settings_key = new QString( "/Qt Designer/" +
- QString::number( majorVer ) +
- "." + QString::number( minorVer ) + "/" );
+ old_settings_key = new TQString( "/Qt Designer/" +
+ TQString::number( majorVer ) +
+ "." + TQString::number( minorVer ) + "/" );
}
return *old_settings_key;
}
-void DesignerApplication::setSettingsKey( const QString &key )
+void DesignerApplication::setSettingsKey( const TQString &key )
{
if ( !settings_key )
- settings_key = new QString( key );
+ settings_key = new TQString( key );
else
*settings_key = key;
}
@@ -135,20 +135,20 @@ void DesignerApplication::setSettingsKey( const QString &key )
bool DesignerApplication::winEventFilter( MSG *msg )
{
if ( msg->message == DESIGNER_OPENFILE ) {
- QFile f( QDir::homeDirPath() + "/.designerargs" );
- QFileInfo fi(f);
+ TQFile f( TQDir::homeDirPath() + "/.designerargs" );
+ TQFileInfo fi(f);
if ( fi.lastModified() == lastMod )
- return QApplication::winEventFilter( msg );
+ return TQApplication::winEventFilter( msg );
lastMod = fi.lastModified();
f.open( IO_ReadOnly );
- QString args;
+ TQString args;
f.readLine( args, f.size() );
- QStringList lst = QStringList::split( " ", args );
+ TQStringList lst = TQStringList::split( " ", args );
- for ( QStringList::Iterator it = lst.begin(); it != lst.end(); ++it ) {
- QString arg = (*it).stripWhiteSpace();
+ for ( TQStringList::Iterator it = lst.begin(); it != lst.end(); ++it ) {
+ TQString arg = (*it).stripWhiteSpace();
if ( arg[0] != '-' ) {
- QObjectList* l = MainWindow::self->queryList( "FormWindow" );
+ TQObjectList* l = MainWindow::self->queryList( "FormWindow" );
FormWindow* fw = (FormWindow*) l->first();
FormWindow* totop = 0;
bool haveit = FALSE;
@@ -171,6 +171,6 @@ bool DesignerApplication::winEventFilter( MSG *msg )
}
return TRUE;
}
- return QApplication::winEventFilter( msg );
+ return TQApplication::winEventFilter( msg );
}
#endif