summaryrefslogtreecommitdiffstats
path: root/tdecore/tdeglobalsettings.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'tdecore/tdeglobalsettings.cpp')
-rw-r--r--tdecore/tdeglobalsettings.cpp50
1 files changed, 25 insertions, 25 deletions
diff --git a/tdecore/tdeglobalsettings.cpp b/tdecore/tdeglobalsettings.cpp
index 79cd4586a..f03b4d9a5 100644
--- a/tdecore/tdeglobalsettings.cpp
+++ b/tdecore/tdeglobalsettings.cpp
@@ -24,16 +24,16 @@
#include <tqcursor.h>
#include <tdeconfig.h>
-#include <ksimpleconfig.h>
+#include <tdesimpleconfig.h>
#include <tdeapplication.h>
#include <kipc.h>
-#ifdef Q_WS_WIN
+#ifdef TQ_WS_WIN
#include <windows.h>
#include "qt_windows.h"
#include <win32_utils.h>
-static QRgb qt_colorref2qrgb(COLORREF col)
+static TQRgb qt_colorref2qrgb(COLORREF col)
{
return tqRgb(GetRValue(col),GetGValue(col),GetBValue(col));
}
@@ -42,7 +42,7 @@ static QRgb qt_colorref2qrgb(COLORREF col)
#include <kdebug.h>
#include <tdeglobal.h>
#include <tdeshortcut.h>
-#include <kstandarddirs.h>
+#include <tdestandarddirs.h>
#include <kcharsets.h>
#include <tdeaccel.h>
#include <tdelocale.h>
@@ -54,7 +54,7 @@ static QRgb qt_colorref2qrgb(COLORREF col)
#include <tqtextstream.h>
#include <tqfile.h>
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
#include <X11/Xlib.h>
#endif
@@ -315,7 +315,7 @@ TQColor TDEGlobalSettings::toolBarHighlightColor()
TQColor TDEGlobalSettings::inactiveTitleColor()
{
-#ifdef Q_WS_WIN
+#ifdef TQ_WS_WIN
return qt_colorref2qrgb(GetSysColor(COLOR_INACTIVECAPTION));
#else
if (!_inactiveBackground)
@@ -327,7 +327,7 @@ TQColor TDEGlobalSettings::inactiveTitleColor()
TQColor TDEGlobalSettings::inactiveTextColor()
{
-#ifdef Q_WS_WIN
+#ifdef TQ_WS_WIN
return qt_colorref2qrgb(GetSysColor(COLOR_INACTIVECAPTIONTEXT));
#else
if (!_inactiveForeground)
@@ -339,7 +339,7 @@ TQColor TDEGlobalSettings::inactiveTextColor()
TQColor TDEGlobalSettings::activeTitleColor()
{
-#ifdef Q_WS_WIN
+#ifdef TQ_WS_WIN
return qt_colorref2qrgb(GetSysColor(COLOR_ACTIVECAPTION));
#else
initColors();
@@ -352,11 +352,11 @@ TQColor TDEGlobalSettings::activeTitleColor()
TQColor TDEGlobalSettings::activeTextColor()
{
-#ifdef Q_WS_WIN
+#ifdef TQ_WS_WIN
return qt_colorref2qrgb(GetSysColor(COLOR_CAPTIONTEXT));
#else
TDEConfigGroup g( TDEGlobal::config(), "WM" );
- return g.readColorEntry( "activeForeground", tqwhiteptr );
+ return g.readColorEntry( "activeForeground", &TQt::white );
#endif
}
@@ -377,7 +377,7 @@ TQColor TDEGlobalSettings::buttonBackground()
TQColor TDEGlobalSettings::buttonTextColor()
{
TDEConfigGroup g( TDEGlobal::config(), "General" );
- return g.readColorEntry( "buttonForeground", tqblackptr );
+ return g.readColorEntry( "buttonForeground", &TQt::black );
}
// IMPORTANT:
@@ -386,7 +386,7 @@ TQColor TDEGlobalSettings::buttonTextColor()
TQColor TDEGlobalSettings::baseColor()
{
TDEConfigGroup g( TDEGlobal::config(), "General" );
- return g.readColorEntry( "windowBackground", tqwhiteptr );
+ return g.readColorEntry( "windowBackground", &TQt::white );
}
// IMPORTANT:
@@ -395,7 +395,7 @@ TQColor TDEGlobalSettings::baseColor()
TQColor TDEGlobalSettings::textColor()
{
TDEConfigGroup g( TDEGlobal::config(), "General" );
- return g.readColorEntry( "windowForeground", tqblackptr );
+ return g.readColorEntry( "windowForeground", &TQt::black );
}
// IMPORTANT:
@@ -404,7 +404,7 @@ TQColor TDEGlobalSettings::textColor()
TQColor TDEGlobalSettings::highlightedTextColor()
{
TDEConfigGroup g( TDEGlobal::config(), "General" );
- return g.readColorEntry( "selectForeground", tqwhiteptr );
+ return g.readColorEntry( "selectForeground", &TQt::white );
}
// IMPORTANT:
@@ -429,7 +429,7 @@ TQColor TDEGlobalSettings::alternateBackgroundColor()
TQColor TDEGlobalSettings::calculateAlternateBackgroundColor(const TQColor& base)
{
- if (base == Qt::white)
+ if (base == TQt::white)
return TQColor(238,246,255);
else
{
@@ -437,7 +437,7 @@ TQColor TDEGlobalSettings::calculateAlternateBackgroundColor(const TQColor& base
base.hsv( &h, &s, &v );
if (v > 128)
return base.dark(106);
- else if (base != Qt::black)
+ else if (base != TQt::black)
return base.light(110);
return TQColor(32,32,32);
@@ -724,8 +724,8 @@ void TDEGlobalSettings::initPaths()
}
// Make sure this app gets the notifications about those paths
- if (kapp)
- kapp->addKipcEventMask(KIPC::SettingsChanged);
+ if (tdeApp)
+ tdeApp->addKipcEventMask(KIPC::SettingsChanged);
}
void TDEGlobalSettings::initColors()
@@ -788,7 +788,7 @@ TDEGlobalSettings::KMouseSettings & TDEGlobalSettings::mouseSettings()
s_mouseSettings = new KMouseSettings;
KMouseSettings & s = *s_mouseSettings; // for convenience
-#ifndef Q_WS_WIN
+#ifndef TQ_WS_WIN
TDEConfigGroup g( TDEGlobal::config(), "Mouse" );
TQString setting = g.readEntry("MouseButtonMapping");
if (setting == "RightHanded")
@@ -797,13 +797,13 @@ TDEGlobalSettings::KMouseSettings & TDEGlobalSettings::mouseSettings()
s.handed = KMouseSettings::LeftHanded;
else
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
// get settings from X server
// This is a simplified version of the code in input/mouse.cpp
// Keep in sync !
s.handed = KMouseSettings::RightHanded;
unsigned char map[20];
- int num_buttons = XGetPointerMapping(kapp->getDisplay(), map, 20);
+ int num_buttons = XGetPointerMapping(tdeApp->getDisplay(), map, 20);
if( num_buttons == 2 )
{
if ( (int)map[0] == 1 && (int)map[1] == 2 )
@@ -822,9 +822,9 @@ TDEGlobalSettings::KMouseSettings & TDEGlobalSettings::mouseSettings()
// FIXME(E): Implement in Qt Embedded
#endif
}
-#endif //Q_WS_WIN
+#endif //TQ_WS_WIN
}
-#ifdef Q_WS_WIN
+#ifdef TQ_WS_WIN
//not cached
s_mouseSettings->handed = (GetSystemMetrics(SM_SWAPBUTTON) ? KMouseSettings::LeftHanded : KMouseSettings::RightHanded);
#endif
@@ -833,7 +833,7 @@ TDEGlobalSettings::KMouseSettings & TDEGlobalSettings::mouseSettings()
void TDEGlobalSettings::rereadMouseSettings()
{
-#ifndef Q_WS_WIN
+#ifndef TQ_WS_WIN
delete s_mouseSettings;
s_mouseSettings = 0L;
#endif
@@ -841,7 +841,7 @@ void TDEGlobalSettings::rereadMouseSettings()
bool TDEGlobalSettings::isMultiHead()
{
-#ifdef Q_WS_WIN
+#ifdef TQ_WS_WIN
return GetSystemMetrics(SM_CMONITORS) > 1;
#else
TQCString multiHead = getenv("TDE_MULTIHEAD");