summaryrefslogtreecommitdiffstats
path: root/krandr
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2010-07-31 19:46:43 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2010-07-31 19:46:43 +0000
commitffe8a83e053396df448e9413828527613ca3bd46 (patch)
treea73d4169e02df4a50f9a12cb165fcd0ab5bac7c6 /krandr
parent682bf3bfdcbcbb1fca85e8a36ed03e062e0555d5 (diff)
downloadtdelibs-ffe8a83e053396df448e9413828527613ca3bd46.tar.gz
tdelibs-ffe8a83e053396df448e9413828527613ca3bd46.zip
Trinity Qt initial conversion
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdelibs@1157647 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'krandr')
-rw-r--r--krandr/ktimerdialog.cpp40
-rw-r--r--krandr/ktimerdialog.h22
-rw-r--r--krandr/libkrandr.cc44
-rw-r--r--krandr/libkrandr.h12
-rw-r--r--krandr/randr.cpp68
-rw-r--r--krandr/randr.h26
6 files changed, 106 insertions, 106 deletions
diff --git a/krandr/ktimerdialog.cpp b/krandr/ktimerdialog.cpp
index 071088e9b..55302b407 100644
--- a/krandr/ktimerdialog.cpp
+++ b/krandr/ktimerdialog.cpp
@@ -19,12 +19,12 @@
*
*/
-#include <qhbox.h>
-#include <qlayout.h>
-#include <qvbox.h>
-#include <qtimer.h>
-#include <qprogressbar.h>
-#include <qlabel.h>
+#include <tqhbox.h>
+#include <tqlayout.h>
+#include <tqvbox.h>
+#include <tqtimer.h>
+#include <tqprogressbar.h>
+#include <tqlabel.h>
#include <kwin.h>
#include <kiconloader.h>
@@ -35,9 +35,9 @@
#include "ktimerdialog.h"
#include "ktimerdialog.moc"
-KTimerDialog::KTimerDialog( int msec, TimerStyle style, QWidget *parent,
+KTimerDialog::KTimerDialog( int msec, TimerStyle style, TQWidget *parent,
const char *name, bool modal,
- const QString &caption,
+ const TQString &caption,
int buttonMask, ButtonCode defaultButton,
bool separator,
const KGuiItem &user1,
@@ -46,8 +46,8 @@ KTimerDialog::KTimerDialog( int msec, TimerStyle style, QWidget *parent,
: KDialogBase(parent, name, modal, caption, buttonMask, defaultButton,
separator, user1, user2, user3 )
{
- totalTimer = new QTimer( this );
- updateTimer = new QTimer( this );
+ totalTimer = new TQTimer( this );
+ updateTimer = new TQTimer( this );
msecTotal = msecRemaining = msec;
updateInterval = 1000;
tStyle = style;
@@ -56,14 +56,14 @@ KTimerDialog::KTimerDialog( int msec, TimerStyle style, QWidget *parent,
if ( buttonMask & Cancel )
buttonOnTimeout = Cancel;
- connect( totalTimer, SIGNAL( timeout() ), SLOT( slotInternalTimeout() ) );
- connect( updateTimer, SIGNAL( timeout() ), SLOT( slotUpdateTime() ) );
+ connect( totalTimer, TQT_SIGNAL( timeout() ), TQT_SLOT( slotInternalTimeout() ) );
+ connect( updateTimer, TQT_SIGNAL( timeout() ), TQT_SLOT( slotUpdateTime() ) );
// create the widgets
- mainWidget = new QVBox( this, "mainWidget" );
- timerWidget = new QHBox( mainWidget, "timerWidget" );
- timerLabel = new QLabel( timerWidget );
- timerProgress = new QProgressBar( timerWidget );
+ mainWidget = new TQVBox( this, "mainWidget" );
+ timerWidget = new TQHBox( mainWidget, "timerWidget" );
+ timerLabel = new TQLabel( timerWidget );
+ timerProgress = new TQProgressBar( timerWidget );
timerProgress->setTotalSteps( msecTotal );
timerProgress->setPercentageVisible( false );
@@ -90,18 +90,18 @@ int KTimerDialog::exec()
return KDialogBase::exec();
}
-void KTimerDialog::setMainWidget( QWidget *widget )
+void KTimerDialog::setMainWidget( TQWidget *widget )
{
// yuck, here goes.
- QVBox *newWidget = new QVBox( this );
+ TQVBox *newWidget = new TQVBox( this );
if ( widget->parentWidget() != mainWidget ) {
- widget->reparent( newWidget, 0, QPoint(0,0) );
+ widget->reparent( newWidget, 0, TQPoint(0,0) );
} else {
newWidget->insertChild( widget );
}
- timerWidget->reparent( newWidget, 0, QPoint(0, 0) );
+ timerWidget->reparent( newWidget, 0, TQPoint(0, 0) );
delete mainWidget;
mainWidget = newWidget;
diff --git a/krandr/ktimerdialog.h b/krandr/ktimerdialog.h
index 23b4a92b0..8abe09d4b 100644
--- a/krandr/ktimerdialog.h
+++ b/krandr/ktimerdialog.h
@@ -67,9 +67,9 @@ class KTimerDialog : public KDialogBase
*
* For the rest of the arguments, See @see KDialogBase .
*/
- KTimerDialog( int msec, TimerStyle style=CountDown, QWidget *parent=0,
+ KTimerDialog( int msec, TimerStyle style=CountDown, TQWidget *parent=0,
const char *name=0, bool modal=true,
- const QString &caption=QString::null,
+ const TQString &caption=TQString::null,
int buttonMask=Ok|Apply|Cancel, ButtonCode defaultButton=Ok,
bool separator=false,
const KGuiItem &user1=KGuiItem(),
@@ -82,7 +82,7 @@ class KTimerDialog : public KDialogBase
~KTimerDialog();
/**
- * Execute the dialog modelessly - see @see QDialog .
+ * Execute the dialog modelessly - see @see TQDialog .
*/
virtual void show();
@@ -117,7 +117,7 @@ class KTimerDialog : public KDialogBase
* Overridden function which is used to set the main widget of the dialog.
* @see KDialogBase::setMainWidget.
*/
- void setMainWidget( QWidget *widget );
+ void setMainWidget( TQWidget *widget );
signals:
/**
@@ -127,7 +127,7 @@ class KTimerDialog : public KDialogBase
public slots:
/**
- * Execute the dialog modally - see @see QDialog .
+ * Execute the dialog modally - see @see TQDialog .
*/
int exec();
@@ -148,17 +148,17 @@ class KTimerDialog : public KDialogBase
*/
void setupLayout();
- QTimer *totalTimer;
- QTimer *updateTimer;
+ TQTimer *totalTimer;
+ TQTimer *updateTimer;
int msecRemaining, updateInterval, msecTotal;
ButtonCode buttonOnTimeout;
TimerStyle tStyle;
- QHBox *timerWidget;
- QProgressBar *timerProgress;
- QLabel *timerLabel;
- QVBox *mainWidget;
+ TQHBox *timerWidget;
+ TQProgressBar *timerProgress;
+ TQLabel *timerLabel;
+ TQVBox *mainWidget;
class KTimerDialogPrivate;
KTimerDialogPrivate *d;
diff --git a/krandr/libkrandr.cc b/krandr/libkrandr.cc
index f2080f287..cbb023e4f 100644
--- a/krandr/libkrandr.cc
+++ b/krandr/libkrandr.cc
@@ -24,18 +24,18 @@
#include "libkrandr.h"
-QString KRandrSimpleAPI::getIccFileName(QString profileName, QString screenName, QString kde_confdir) {
+TQString KRandrSimpleAPI::getIccFileName(TQString profileName, TQString screenName, TQString kde_confdir) {
KSimpleConfig *t_config;
KSimpleConfig *t_systemconfig;
int t_numberOfProfiles;
- QStringList t_cfgProfiles;
- QString retval;
+ TQStringList t_cfgProfiles;
+ TQString retval;
if (profileName != NULL) {
- t_config = new KSimpleConfig( QString::fromLatin1( "kiccconfigrc" ));
+ t_config = new KSimpleConfig( TQString::fromLatin1( "kiccconfigrc" ));
}
else {
- t_systemconfig = new KSimpleConfig( kde_confdir + QString("/kicc/kiccconfigrc") );
+ t_systemconfig = new KSimpleConfig( kde_confdir + TQString("/kicc/kiccconfigrc") );
}
if (profileName != NULL) {
@@ -68,7 +68,7 @@ QString KRandrSimpleAPI::getIccFileName(QString profileName, QString screenName,
return retval;
}
-QString KRandrSimpleAPI::applyIccFile(QString screenName, QString fileName) {
+TQString KRandrSimpleAPI::applyIccFile(TQString screenName, TQString fileName) {
int i;
int j;
Display *randr_display;
@@ -113,13 +113,13 @@ QString KRandrSimpleAPI::applyIccFile(QString screenName, QString fileName) {
if (screenNumber >= 0) {
// Apply ICC settings with XCalib
- QString icc_command;
+ TQString icc_command;
FILE *pipe_xcalib;
char xcalib_result[2048];
int i;
xcalib_result[0]=0;
- icc_command = QString("xcalib %1").arg(fileName);
+ icc_command = TQString("xcalib %1").arg(fileName);
if ((pipe_xcalib = popen(icc_command.ascii(), "r")) == NULL)
{
printf("Xcalib pipe error\n\r");
@@ -177,13 +177,13 @@ QString KRandrSimpleAPI::applyIccFile(QString screenName, QString fileName) {
if (screenNumber >= 0) {
// Apply ICC settings with XCalib
- QString icc_command;
+ TQString icc_command;
FILE *pipe_xcalib;
char xcalib_result[2048];
int i;
xcalib_result[0]=0;
- icc_command = QString("xcalib -c");
+ icc_command = TQString("xcalib -c");
if ((pipe_xcalib = popen(icc_command.ascii(), "r")) == NULL)
{
printf("Xcalib pipe error\n\r");
@@ -206,7 +206,7 @@ QString KRandrSimpleAPI::applyIccFile(QString screenName, QString fileName) {
return "";
}
-QString KRandrSimpleAPI::applyIccConfiguration(QString profileName, QString kde_confdir) {
+TQString KRandrSimpleAPI::applyIccConfiguration(TQString profileName, TQString kde_confdir) {
int i;
Display *randr_display;
ScreenInfo *randr_screen_info;
@@ -214,9 +214,9 @@ QString KRandrSimpleAPI::applyIccConfiguration(QString profileName, QString kde_
KSimpleConfig *t_config;
int screenNumber = 0;
- QString errorstr = "";
+ TQString errorstr = "";
- t_config = new KSimpleConfig( QString::fromLatin1( "kiccconfigrc" ));
+ t_config = new KSimpleConfig( TQString::fromLatin1( "kiccconfigrc" ));
// Find all screens
if (isValid() == true) {
@@ -244,25 +244,25 @@ QString KRandrSimpleAPI::applyIccConfiguration(QString profileName, QString kde_
return "";
}
-QString KRandrSimpleAPI::getCurrentProfile () {
- QString profileName;
+TQString KRandrSimpleAPI::getCurrentProfile () {
+ TQString profileName;
KSimpleConfig *t_config;
- t_config = new KSimpleConfig( QString::fromLatin1( "kiccconfigrc" ));
+ t_config = new KSimpleConfig( TQString::fromLatin1( "kiccconfigrc" ));
profileName = t_config->readEntry("CurrentProfile");
delete t_config;
return profileName;
}
-QString KRandrSimpleAPI::applySystemWideIccConfiguration(QString kde_confdir) {
+TQString KRandrSimpleAPI::applySystemWideIccConfiguration(TQString kde_confdir) {
// Apply ICC settings with XCalib
- QString icc_command;
+ TQString icc_command;
FILE *pipe_xcalib;
char xcalib_result[2048];
int i;
xcalib_result[0]=0;
- icc_command = QString("xcalib %1").arg(getIccFileName(NULL, "Default", kde_confdir));
+ icc_command = TQString("xcalib %1").arg(getIccFileName(NULL, "Default", kde_confdir));
if ((pipe_xcalib = popen(icc_command.ascii(), "r")) == NULL)
{
printf("Xcalib pipe error\n\r");
@@ -283,15 +283,15 @@ QString KRandrSimpleAPI::applySystemWideIccConfiguration(QString kde_confdir) {
return "";
}
-QString KRandrSimpleAPI::clearIccConfiguration() {
+TQString KRandrSimpleAPI::clearIccConfiguration() {
// Clear ICC settings with XCalib
- QString icc_command;
+ TQString icc_command;
FILE *pipe_xcalib;
char xcalib_result[2048];
int i;
xcalib_result[0]=0;
- icc_command = QString("xcalib -c");
+ icc_command = TQString("xcalib -c");
if ((pipe_xcalib = popen(icc_command.ascii(), "r")) == NULL)
{
printf("Xcalib pipe error\n\r");
diff --git a/krandr/libkrandr.h b/krandr/libkrandr.h
index 2135eb9f8..ced69a68d 100644
--- a/krandr/libkrandr.h
+++ b/krandr/libkrandr.h
@@ -51,34 +51,34 @@ class KRANDR_EXPORT KRandrSimpleAPI : public RandRDisplay
/**
* Retrieves the specificed ICC profile filename from the configuration database
*/
- QString getIccFileName(QString profileName, QString screenName, QString kde_confdir);
+ TQString getIccFileName(TQString profileName, TQString screenName, TQString kde_confdir);
/**
* Applies the specificed ICC profile filename to the specified RandR output
* If RandR is not available, the specified file is applied to the current display
*/
- QString applyIccFile(QString screenName, QString fileName);
+ TQString applyIccFile(TQString screenName, TQString fileName);
/**
* Applies all saved ICC profile settings to all RandR outputs
* If RandR is not available, the settings are applied to the current display
*/
- QString applyIccConfiguration(QString profileName, QString kde_confdir);
+ TQString applyIccConfiguration(TQString profileName, TQString kde_confdir);
/**
* Applies saved system wide settings to the current display
*/
- QString applySystemWideIccConfiguration(QString kde_confdir);
+ TQString applySystemWideIccConfiguration(TQString kde_confdir);
/**
* Resets the current display
*/
- QString clearIccConfiguration(void);
+ TQString clearIccConfiguration(void);
/**
* Retrieves current profile name
*/
- QString getCurrentProfile(void);
+ TQString getCurrentProfile(void);
/**
* Reads current screen information.
diff --git a/krandr/randr.cpp b/krandr/randr.cpp
index d56b37481..e891c8a2d 100644
--- a/krandr/randr.cpp
+++ b/krandr/randr.cpp
@@ -18,7 +18,7 @@
#include "randr.h"
-#include <qtimer.h>
+#include <tqtimer.h>
#include <kdebug.h>
#include <klocale.h>
@@ -83,8 +83,8 @@ void RandRScreen::loadSettings()
int numSizes;
XRRScreenSize* sizes = XRRSizes(qt_xdisplay(), m_screen, &numSizes);
for (int i = 0; i < numSizes; i++) {
- m_pixelSizes.append(QSize(sizes[i].width, sizes[i].height));
- m_mmSizes.append(QSize(sizes[i].mwidth, sizes[i].mheight));
+ m_pixelSizes.append(TQSize(sizes[i].width, sizes[i].height));
+ m_mmSizes.append(TQSize(sizes[i].mwidth, sizes[i].mheight));
}
m_rotations = XRRRotations(qt_xdisplay(), m_screen, &rotation);
@@ -114,7 +114,7 @@ bool RandRScreen::applyProposed()
status = XRRSetScreenConfigAndRate(qt_xdisplay(), d->config, DefaultRootWindow(qt_xdisplay()), (SizeID)proposedSize(), (Rotation)proposedRotation(), refreshRateIndexToHz(proposedSize(), proposedRefreshRate()), CurrentTime);
}
- //kdDebug() << "New size: " << WidthOfScreen(ScreenOfDisplay(QPaintDevice::x11AppDisplay(), screen)) << ", " << HeightOfScreen(ScreenOfDisplay(QPaintDevice::x11AppDisplay(), screen)) << endl;
+ //kdDebug() << "New size: " << WidthOfScreen(ScreenOfDisplay(TQPaintDevice::x11AppDisplay(), screen)) << ", " << HeightOfScreen(ScreenOfDisplay(TQPaintDevice::x11AppDisplay(), screen)) << endl;
if (status == RRSetConfigSuccess) {
m_currentSize = m_proposedSize;
@@ -173,8 +173,8 @@ bool RandRScreen::confirm()
KDialog::centerOnScreen(&acceptDialog, m_screen);
m_shownDialog = &acceptDialog;
- connect( m_shownDialog, SIGNAL( destroyed()), this, SLOT( shownDialogDestroyed()));
- connect( kapp->desktop(), SIGNAL( resized(int)), this, SLOT( desktopResized()));
+ connect( m_shownDialog, TQT_SIGNAL( destroyed()), this, TQT_SLOT( shownDialogDestroyed()));
+ connect( kapp->desktop(), TQT_SIGNAL( resized(int)), this, TQT_SLOT( desktopResized()));
return acceptDialog.exec();
}
@@ -182,7 +182,7 @@ bool RandRScreen::confirm()
void RandRScreen::shownDialogDestroyed()
{
m_shownDialog = NULL;
- disconnect( kapp->desktop(), SIGNAL( resized(int)), this, SLOT( desktopResized()));
+ disconnect( kapp->desktop(), TQT_SIGNAL( resized(int)), this, TQT_SLOT( desktopResized()));
}
void RandRScreen::desktopResized()
@@ -191,7 +191,7 @@ void RandRScreen::desktopResized()
KDialog::centerOnScreen(m_shownDialog, m_screen);
}
-QString RandRScreen::changedMessage() const
+TQString RandRScreen::changedMessage() const
{
if (currentRefreshRate() == -1)
return i18n("New configuration:\nResolution: %1 x %2\nOrientation: %3")
@@ -223,7 +223,7 @@ bool RandRScreen::proposedChanged() const
return m_currentSize != m_proposedSize || m_currentRotation != m_proposedRotation || m_currentRefreshRate != m_proposedRefreshRate;
}
-QString RandRScreen::rotationName(int rotation, bool pastTense, bool capitalised)
+TQString RandRScreen::rotationName(int rotation, bool pastTense, bool capitalised)
{
if (!pastTense)
switch (rotation) {
@@ -277,7 +277,7 @@ QString RandRScreen::rotationName(int rotation, bool pastTense, bool capitalised
}
}
-QPixmap RandRScreen::rotationIcon(int rotation) const
+TQPixmap RandRScreen::rotationIcon(int rotation) const
{
// Adjust icons for current screen orientation
if (!(m_currentRotation & RR_Rotate_0) && rotation & (RR_Rotate_0 | RR_Rotate_90 | RR_Rotate_180 | RR_Rotate_270)) {
@@ -316,9 +316,9 @@ QPixmap RandRScreen::rotationIcon(int rotation) const
}
}
-QString RandRScreen::currentRotationDescription() const
+TQString RandRScreen::currentRotationDescription() const
{
- QString ret = rotationName(m_currentRotation & RotateMask);
+ TQString ret = rotationName(m_currentRotation & RotateMask);
if (m_currentRotation != m_currentRotation & RotateMask)
if (m_currentRotation & RR_Rotate_0)
@@ -383,29 +383,29 @@ int RandRScreen::currentMMHeight() const
return m_pixelSizes[m_currentSize].height();
}
-QStringList RandRScreen::refreshRates(int size) const
+TQStringList RandRScreen::refreshRates(int size) const
{
int nrates;
short* rates = XRRRates(qt_xdisplay(), m_screen, (SizeID)size, &nrates);
- QStringList ret;
+ TQStringList ret;
for (int i = 0; i < nrates; i++)
ret << refreshRateDirectDescription(rates[i]);
return ret;
}
-QString RandRScreen::refreshRateDirectDescription(int rate) const
+TQString RandRScreen::refreshRateDirectDescription(int rate) const
{
return i18n("Refresh rate in Hertz (Hz)", "%1 Hz").arg(rate);
}
-QString RandRScreen::refreshRateIndirectDescription(int size, int index) const
+TQString RandRScreen::refreshRateIndirectDescription(int size, int index) const
{
return i18n("Refresh rate in Hertz (Hz)", "%1 Hz").arg(refreshRateIndexToHz(size, index));
}
-QString RandRScreen::refreshRateDescription(int size, int index) const
+TQString RandRScreen::refreshRateDescription(int size, int index) const
{
return refreshRates(size)[index];
}
@@ -425,7 +425,7 @@ int RandRScreen::currentRefreshRate() const
return m_currentRefreshRate;
}
-QString RandRScreen::currentRefreshRateDescription() const
+TQString RandRScreen::currentRefreshRateDescription() const
{
return refreshRateIndirectDescription(m_currentSize, m_currentRefreshRate);
}
@@ -471,17 +471,17 @@ int RandRScreen::numSizes() const
return m_pixelSizes.count();
}
-const QSize& RandRScreen::pixelSize(int index) const
+const TQSize& RandRScreen::pixelSize(int index) const
{
return m_pixelSizes[index];
}
-const QSize& RandRScreen::mmSize(int index) const
+const TQSize& RandRScreen::mmSize(int index) const
{
return m_mmSizes[index];
}
-int RandRScreen::sizeIndex(QSize pixelSize) const
+int RandRScreen::sizeIndex(TQSize pixelSize) const
{
for (uint i = 0; i < m_pixelSizes.count(); i++)
if (m_pixelSizes[i] == pixelSize)
@@ -532,9 +532,9 @@ bool RandRScreen::proposeSize(int newSize)
void RandRScreen::load(KConfig& config)
{
- config.setGroup(QString("Screen%1").arg(m_screen));
+ config.setGroup(TQString("Screen%1").arg(m_screen));
- if (proposeSize(sizeIndex(QSize(config.readNumEntry("width", currentPixelWidth()), config.readNumEntry("height", currentPixelHeight())))))
+ if (proposeSize(sizeIndex(TQSize(config.readNumEntry("width", currentPixelWidth()), config.readNumEntry("height", currentPixelHeight())))))
proposeRefreshRate(refreshRateHzToIndex(proposedSize(), config.readNumEntry("refresh", currentRefreshRate())));
proposeRotation(rotationDegreeToIndex(config.readNumEntry("rotation", 0)) + (config.readBoolEntry("reflectX") ? ReflectX : 0) + (config.readBoolEntry("reflectY") ? ReflectY : 0));
@@ -542,7 +542,7 @@ void RandRScreen::load(KConfig& config)
void RandRScreen::save(KConfig& config) const
{
- config.setGroup(QString("Screen%1").arg(m_screen));
+ config.setGroup(TQString("Screen%1").arg(m_screen));
config.writeEntry("width", currentPixelWidth());
config.writeEntry("height", currentPixelHeight());
config.writeEntry("refresh", refreshRateIndexToHz(currentSize(), currentRefreshRate()));
@@ -557,7 +557,7 @@ RandRDisplay::RandRDisplay()
// Check extension
Status s = XRRQueryExtension(qt_xdisplay(), &m_eventBase, &m_errorBase);
if (!s) {
- m_errorCode = QString("%1, base %1").arg(s).arg(m_errorBase);
+ m_errorCode = TQString("%1, base %1").arg(s).arg(m_errorBase);
m_valid = false;
return;
}
@@ -579,19 +579,19 @@ RandRDisplay::RandRDisplay()
int major_version, minor_version;
XRRQueryVersion(qt_xdisplay(), &major_version, &minor_version);
- m_version = QString("X Resize and Rotate extension version %1.%1").arg(major_version).arg(minor_version);
+ m_version = TQString("X Resize and Rotate extension version %1.%1").arg(major_version).arg(minor_version);
m_numScreens = ScreenCount(qt_xdisplay());
// This assumption is WRONG with Xinerama
- // Q_ASSERT(QApplication::desktop()->numScreens() == ScreenCount(qt_xdisplay()));
+ // Q_ASSERT(TQApplication::desktop()->numScreens() == ScreenCount(qt_xdisplay()));
m_screens.setAutoDelete(true);
for (int i = 0; i < m_numScreens; i++) {
m_screens.append(new RandRScreen(i));
}
- setCurrentScreen(QApplication::desktop()->primaryScreen());
+ setCurrentScreen(TQApplication::desktop()->primaryScreen());
}
bool RandRDisplay::isValid() const
@@ -599,7 +599,7 @@ bool RandRDisplay::isValid() const
return m_valid;
}
-const QString& RandRDisplay::errorCode() const
+const TQString& RandRDisplay::errorCode() const
{
return m_errorCode;
}
@@ -619,7 +619,7 @@ int RandRDisplay::errorBase() const
return m_errorBase;
}
-const QString& RandRDisplay::version() const
+const TQString& RandRDisplay::version() const
{
return m_version;
}
@@ -631,10 +631,10 @@ void RandRDisplay::setCurrentScreen(int index)
Q_ASSERT(m_currentScreen);
}
-int RandRDisplay::screenIndexOfWidget(QWidget* widget)
+int RandRDisplay::screenIndexOfWidget(TQWidget* widget)
{
- int ret = QApplication::desktop()->screenNumber(widget);
- return ret != -1 ? ret : QApplication::desktop()->primaryScreen();
+ int ret = TQApplication::desktop()->screenNumber(widget);
+ return ret != -1 ? ret : TQApplication::desktop()->primaryScreen();
}
int RandRDisplay::currentScreenIndex() const
@@ -710,7 +710,7 @@ void RandRDisplay::applyProposed(bool confirm)
int RandRScreen::pixelCount( int index ) const
{
- QSize sz = pixelSize(index);
+ TQSize sz = pixelSize(index);
return sz.width() * sz.height();
}
diff --git a/krandr/randr.h b/krandr/randr.h
index c7eb240cf..355f3d866 100644
--- a/krandr/randr.h
+++ b/krandr/randr.h
@@ -19,9 +19,9 @@
#ifndef __RANDR_H__
#define __RANDR_H__
-#include <qobject.h>
-#include <qstringlist.h>
-#include <qptrlist.h>
+#include <tqobject.h>
+#include <tqstringlist.h>
+#include <tqptrlist.h>
#include <kcmodule.h>
#include <kconfig.h>
@@ -82,7 +82,7 @@ public:
/**
* Refresh rate functions.
*/
- QStringList refreshRates(int size) const;
+ TQStringList refreshRates(int size) const;
QString refreshRateDirectDescription(int rate) const;
QString refreshRateIndirectDescription(int size, int index) const;
@@ -99,8 +99,8 @@ public:
* Screen size functions.
*/
int numSizes() const;
- const QSize& pixelSize(int index) const;
- const QSize& mmSize(int index) const;
+ const TQSize& pixelSize(int index) const;
+ const TQSize& mmSize(int index) const;
int pixelCount(int index) const;
/**
@@ -109,7 +109,7 @@ public:
* @param pixelSize dimensions of the screen in pixels
* @returns the index of the requested screen size
*/
- int sizeIndex(QSize pixelSize) const;
+ int sizeIndex(TQSize pixelSize) const;
int rotations() const;
@@ -154,8 +154,8 @@ private:
int m_screen;
- QValueList<QSize> m_pixelSizes;
- QValueList<QSize> m_mmSizes;
+ TQValueList<TQSize> m_pixelSizes;
+ TQValueList<TQSize> m_mmSizes;
int m_rotations;
int m_originalRotation;
@@ -177,7 +177,7 @@ private slots:
void shownDialogDestroyed();
};
-typedef QPtrList<RandRScreen> ScreenList;
+typedef TQPtrList<RandRScreen> ScreenList;
class RandRDisplay
{
@@ -185,14 +185,14 @@ public:
RandRDisplay();
bool isValid() const;
- const QString& errorCode() const;
- const QString& version() const;
+ const TQString& errorCode() const;
+ const TQString& version() const;
int eventBase() const;
int screenChangeNotifyEvent() const;
int errorBase() const;
- int screenIndexOfWidget(QWidget* widget);
+ int screenIndexOfWidget(TQWidget* widget);
int numScreens() const;
RandRScreen* screen(int index);