summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--kcminit/main.cpp2
-rw-r--r--kcontrol/access/kaccess.cpp36
-rw-r--r--kcontrol/access/main.cpp4
-rw-r--r--kcontrol/background/bgadvanced.cpp4
-rw-r--r--kcontrol/background/bgrender.cpp10
-rw-r--r--kcontrol/background/bgsettings.cpp6
-rw-r--r--kcontrol/background/main.cpp8
-rw-r--r--kcontrol/colors/colorscm.cpp2
-rw-r--r--kcontrol/displayconfig/displayconfig.cpp2
-rw-r--r--kcontrol/energy/energy.cpp6
-rw-r--r--kcontrol/filetypes/keditfiletype.cpp2
-rw-r--r--kcontrol/fonts/fonts.cpp4
-rw-r--r--kcontrol/input/main.cpp14
-rw-r--r--kcontrol/input/xcursor/previewwidget.cpp8
-rw-r--r--kcontrol/kcontrol/modules.cpp4
-rw-r--r--kcontrol/keys/modifiers.cpp16
-rw-r--r--kcontrol/kicker/main.cpp2
-rw-r--r--kcontrol/konq/desktop.cpp14
-rw-r--r--kcontrol/krdb/krdb.cpp4
-rw-r--r--kcontrol/kthememanager/ktheme.cpp2
-rw-r--r--kcontrol/randr/krandrmodule.cpp2
-rw-r--r--kcontrol/randr/krandrpassivepopup.cpp10
-rw-r--r--kcontrol/screensaver/scrnsave.cpp4
-rw-r--r--kcontrol/style/kcmstyle.cpp6
-rw-r--r--kdesktop/bgmanager.cc24
-rw-r--r--kdesktop/desktop.cc30
-rw-r--r--kdesktop/kdesktopapp.cpp10
-rw-r--r--kdesktop/krootwm.cc4
-rw-r--r--kdesktop/lock/autologout.cc4
-rw-r--r--kdesktop/lock/infodlg.cc4
-rw-r--r--kdesktop/lock/lockdlg.cc14
-rw-r--r--kdesktop/lock/lockprocess.cc132
-rw-r--r--kdesktop/lock/querydlg.cc4
-rw-r--r--kdesktop/lock/sakdlg.cc4
-rw-r--r--kdesktop/lock/securedlg.cc4
-rw-r--r--kdesktop/lockeng.cc24
-rw-r--r--kdesktop/minicli.cpp2
-rw-r--r--kdesktop/pixmapserver.cc26
-rw-r--r--kdesktop/startupid.cpp16
-rw-r--r--kdesktop/xautolock.cc26
-rw-r--r--khotkeys/kcontrol/windowselector.cpp6
-rw-r--r--khotkeys/shared/actions.cpp2
-rw-r--r--khotkeys/shared/gestures.cpp12
-rw-r--r--khotkeys/shared/input.cpp26
-rw-r--r--khotkeys/shared/windows.cpp16
-rw-r--r--kicker/applets/lockout/lockout.cpp2
-rw-r--r--kicker/applets/menu/menuapplet.cpp24
-rw-r--r--kicker/applets/minipager/pagerapplet.cpp4
-rw-r--r--kicker/applets/minipager/pagerbutton.cpp2
-rw-r--r--kicker/applets/swallow/swallow.cpp4
-rw-r--r--kicker/applets/systemtray/systemtrayapplet.cpp12
-rw-r--r--kicker/extensions/dockbar/dockbarextension.cpp8
-rw-r--r--kicker/extensions/dockbar/dockcontainer.cpp18
-rw-r--r--kicker/kicker/core/container_extension.cpp2
-rw-r--r--kicker/kicker/core/kmenubase.ui.h2
-rw-r--r--kicker/kicker/core/showdesktop.cpp10
-rw-r--r--kicker/kicker/ui/k_new_mnu.cpp2
-rw-r--r--kicker/libkicker/kickertip.cpp4
-rw-r--r--kicker/proxy/appletproxy.cpp16
-rw-r--r--kicker/proxy/extensionproxy.cpp12
-rw-r--r--kicker/taskmanager/taskmanager.cpp36
-rw-r--r--klipper/clipboardpoll.cpp24
-rw-r--r--klipper/toplevel.cpp24
-rw-r--r--klipper/urlgrabber.cpp2
-rw-r--r--konqueror/KonquerorIface.cc2
-rw-r--r--konqueror/client/kfmclient.cc8
-rw-r--r--konqueror/konq_main.cc2
-rw-r--r--konqueror/konq_mainwindow.cc20
-rw-r--r--konsole/konsole/TEmuVt102.cpp12
-rw-r--r--konsole/konsole/konsole.cpp4
-rw-r--r--kpager/desktop.cpp2
-rw-r--r--kpager/kpager.cpp8
-rw-r--r--krootbacking/krootbacking.cpp6
-rw-r--r--kscreensaver/random.cpp10
-rw-r--r--ksmserver/legacy.cpp24
-rw-r--r--ksmserver/main.cpp4
-rw-r--r--ksmserver/server.cpp2
-rw-r--r--ksmserver/shutdowndlg.cpp6
-rw-r--r--ksmserver/startup.cpp8
-rw-r--r--ksplashml/themeengine/themeengine.cpp14
-rw-r--r--kstart/kstart.cpp30
-rw-r--r--ksystraycmd/ksystraycmd.cpp20
-rw-r--r--ksystraycmd/main.cpp2
-rw-r--r--kxkb/extension.cpp2
-rw-r--r--kxkb/kcmmisc.cpp6
-rw-r--r--kxkb/layoutmap.cpp4
-rw-r--r--kxkb/rules.cpp2
-rw-r--r--libkonq/konq_operations.cc2
-rw-r--r--nsplugins/viewer/kxt.cpp34
-rw-r--r--nsplugins/viewer/nsplugin.cpp30
-rw-r--r--tdm/kfrontend/kfdialog.cpp4
-rw-r--r--tdm/kfrontend/kgapp.cpp6
-rw-r--r--tdm/kfrontend/kgverify.cpp2
-rw-r--r--tdm/kfrontend/krootimage.cpp6
-rw-r--r--tdm/kfrontend/sakdlg.cc4
-rw-r--r--tqt3integration/libqtkde/qtkde.cpp8
-rw-r--r--tqt3integration/module/module.cpp2
-rw-r--r--tqt3integration/utils/gen.cpp6
-rw-r--r--twin/activation.cpp2
-rw-r--r--twin/atoms.cpp2
-rw-r--r--twin/client.cpp158
-rw-r--r--twin/clients/b2/b2client.cpp6
-rw-r--r--twin/clients/keramik/keramik.cpp4
-rw-r--r--twin/events.cpp106
-rw-r--r--twin/geometry.cpp48
-rw-r--r--twin/geometrytip.cpp2
-rw-r--r--twin/group.cpp8
-rw-r--r--twin/kcmtwin/twindecoration/preview.cpp4
-rw-r--r--twin/kcmtwin/twinrules/detectwidget.cpp8
-rw-r--r--twin/killer/killer.cpp2
-rw-r--r--twin/killwindow.cpp16
-rw-r--r--twin/layers.cpp4
-rw-r--r--twin/lib/kcommondecoration.cpp4
-rw-r--r--twin/main.cpp24
-rw-r--r--twin/manage.cpp36
-rw-r--r--twin/popupinfo.cpp2
-rw-r--r--twin/tabbox.cpp100
-rw-r--r--twin/tools/decobenchmark/preview.cpp4
-rw-r--r--twin/utils.cpp42
-rw-r--r--twin/workspace.cpp164
120 files changed, 909 insertions, 909 deletions
diff --git a/kcminit/main.cpp b/kcminit/main.cpp
index bdb3bbfdc..addf5a6f6 100644
--- a/kcminit/main.cpp
+++ b/kcminit/main.cpp
@@ -178,7 +178,7 @@ KCMInit::KCMInit( KCmdLineArgs* args )
KConfig config("kcmdisplayrc", true );
config.setGroup("X11");
bool multihead = !config.readBoolEntry( "disableMultihead", false) &&
- (ScreenCount(qt_xdisplay()) > 1);
+ (ScreenCount(tqt_xdisplay()) > 1);
// Pass env. var to tdeinit.
TQCString name = "TDE_MULTIHEAD";
TQCString value = multihead ? "true" : "false";
diff --git a/kcontrol/access/kaccess.cpp b/kcontrol/access/kaccess.cpp
index be6b11204..188353d5c 100644
--- a/kcontrol/access/kaccess.cpp
+++ b/kcontrol/access/kaccess.cpp
@@ -107,7 +107,7 @@ KAccessApp::KAccessApp(bool allowStyles, bool GUIenabled)
initMasks();
XkbStateRec state_return;
- XkbGetState (qt_xdisplay(), XkbUseCoreKbd, &state_return);
+ XkbGetState (tqt_xdisplay(), XkbUseCoreKbd, &state_return);
unsigned char latched = XkbStateMods (&state_return);
unsigned char locked = XkbModLocks (&state_return);
state = ((int)locked)<<8 | latched;
@@ -138,23 +138,23 @@ void KAccessApp::readSettings()
// select bell events if we need them
int state = (_artsBell || _visibleBell) ? XkbBellNotifyMask : 0;
- XkbSelectEvents(qt_xdisplay(), XkbUseCoreKbd, XkbBellNotifyMask, state);
+ XkbSelectEvents(tqt_xdisplay(), XkbUseCoreKbd, XkbBellNotifyMask, state);
// deactivate system bell if not needed
if (!_systemBell)
- XkbChangeEnabledControls(qt_xdisplay(), XkbUseCoreKbd, XkbAudibleBellMask, 0);
+ XkbChangeEnabledControls(tqt_xdisplay(), XkbUseCoreKbd, XkbAudibleBellMask, 0);
else
- XkbChangeEnabledControls(qt_xdisplay(), XkbUseCoreKbd, XkbAudibleBellMask, XkbAudibleBellMask);
+ XkbChangeEnabledControls(tqt_xdisplay(), XkbUseCoreKbd, XkbAudibleBellMask, XkbAudibleBellMask);
// keyboard -------------------------------------------------------------
config->setGroup("Keyboard");
// get keyboard state
- XkbDescPtr xkb = XkbGetMap(qt_xdisplay(), 0, XkbUseCoreKbd);
+ XkbDescPtr xkb = XkbGetMap(tqt_xdisplay(), 0, XkbUseCoreKbd);
if (!xkb)
return;
- if (XkbGetControls(qt_xdisplay(), XkbAllControlsMask, xkb) != Success)
+ if (XkbGetControls(tqt_xdisplay(), XkbAllControlsMask, xkb) != Success)
return;
// sticky keys
@@ -279,10 +279,10 @@ void KAccessApp::readSettings()
if (dialog == 0)
requestedFeatures = features;
// set state
- XkbSetControls(qt_xdisplay(), XkbControlsEnabledMask | XkbMouseKeysAccelMask | XkbStickyKeysMask | XkbSlowKeysMask | XkbBounceKeysMask | XkbAccessXKeysMask | XkbAccessXTimeoutMask, xkb);
+ XkbSetControls(tqt_xdisplay(), XkbControlsEnabledMask | XkbMouseKeysAccelMask | XkbStickyKeysMask | XkbSlowKeysMask | XkbBounceKeysMask | XkbAccessXKeysMask | XkbAccessXTimeoutMask, xkb);
// select AccessX events
- XkbSelectEvents(qt_xdisplay(), XkbUseCoreKbd, XkbAllEventsMask, XkbAllEventsMask);
+ XkbSelectEvents(tqt_xdisplay(), XkbUseCoreKbd, XkbAllEventsMask, XkbAllEventsMask);
if (!_artsBell && !_visibleBell && !_gestureConfirmation
&& !_kNotifyModifiers && !_kNotifyAccessX) {
@@ -290,13 +290,13 @@ void KAccessApp::readSettings()
// We will exit, but the features need to stay configured
uint ctrls = XkbStickyKeysMask | XkbSlowKeysMask | XkbBounceKeysMask | XkbMouseKeysMask | XkbAudibleBellMask | XkbControlsNotifyMask;
uint values = xkb->ctrls->enabled_ctrls & ctrls;
- XkbSetAutoResetControls(qt_xdisplay(), ctrls, &ctrls, &values);
+ XkbSetAutoResetControls(tqt_xdisplay(), ctrls, &ctrls, &values);
exit(0);
} else {
// reset them after program exit
uint ctrls = XkbStickyKeysMask | XkbSlowKeysMask | XkbBounceKeysMask | XkbMouseKeysMask | XkbAudibleBellMask | XkbControlsNotifyMask;
uint values = XkbAudibleBellMask;
- XkbSetAutoResetControls(qt_xdisplay(), ctrls, &ctrls, &values);
+ XkbSetAutoResetControls(tqt_xdisplay(), ctrls, &ctrls, &values);
}
delete overlay;
@@ -319,14 +319,14 @@ void KAccessApp::initMasks() {
int mask = modifierKeys[i].mask;
if (mask == 0)
if (modifierKeys[i].keysym != 0)
- mask = XkbKeysymToModifiers (qt_xdisplay(), modifierKeys[i].keysym);
+ mask = XkbKeysymToModifiers (tqt_xdisplay(), modifierKeys[i].keysym);
else if (!strcmp(modifierKeys[i].name, "Win"))
mask = KKeyNative::modX(KKey::WIN);
else
- mask = XkbKeysymToModifiers (qt_xdisplay(), XK_Mode_switch)
- | XkbKeysymToModifiers (qt_xdisplay(), XK_ISO_Level3_Shift)
- | XkbKeysymToModifiers (qt_xdisplay(), XK_ISO_Level3_Latch)
- | XkbKeysymToModifiers (qt_xdisplay(), XK_ISO_Level3_Lock);
+ mask = XkbKeysymToModifiers (tqt_xdisplay(), XK_Mode_switch)
+ | XkbKeysymToModifiers (tqt_xdisplay(), XK_ISO_Level3_Shift)
+ | XkbKeysymToModifiers (tqt_xdisplay(), XK_ISO_Level3_Latch)
+ | XkbKeysymToModifiers (tqt_xdisplay(), XK_ISO_Level3_Lock);
int bit = maskToBit (mask);
if (bit != -1 && keys[bit] == -1)
@@ -376,7 +376,7 @@ void KAccessApp::activeWindowChanged(WId wid)
void KAccessApp::xkbStateNotify () {
XkbStateRec state_return;
- XkbGetState (qt_xdisplay(), XkbUseCoreKbd, &state_return);
+ XkbGetState (tqt_xdisplay(), XkbUseCoreKbd, &state_return);
unsigned char latched = XkbStateMods (&state_return);
unsigned char locked = XkbModLocks (&state_return);
int mods = ((int)locked)<<8 | latched;
@@ -430,7 +430,7 @@ void KAccessApp::xkbBellNotify(XkbBellNotifyEvent *event)
WId id = _activeWindow;
NETRect frame, window;
- NETWinInfo net(qt_xdisplay(), id, desktop()->winId(), 0);
+ NETWinInfo net(tqt_xdisplay(), id, desktop()->winId(), 0);
net.kdeGeometry(frame, window);
@@ -733,7 +733,7 @@ void KAccessApp::xkbControlsNotify(XkbControlsNotifyEvent *event)
else if ((enabled | disabled) == XkbStickyKeysMask)
explanation = i18n("You pressed the Shift key 5 consecutive times or an application has requested to change this setting.");
else if ((enabled | disabled) == XkbMouseKeysMask) {
- TQString shortcut = mouseKeysShortcut(qt_xdisplay());
+ TQString shortcut = mouseKeysShortcut(tqt_xdisplay());
if (!shortcut.isEmpty() && !shortcut.isNull())
explanation = i18n("You pressed %1 or an application has requested to change this setting.").arg(shortcut);
}
diff --git a/kcontrol/access/main.cpp b/kcontrol/access/main.cpp
index a2dd0d5c7..48c9e8423 100644
--- a/kcontrol/access/main.cpp
+++ b/kcontrol/access/main.cpp
@@ -27,7 +27,7 @@ extern "C" KDE_EXPORT int kdemain(int argc, char * argv[] )
}
kdDebug() << "Xlib XKB extension major=" << major << " minor=" << minor << endl;
- // we need an application object for qt_xdisplay()
+ // we need an application object for tqt_xdisplay()
KAccessApp app;
// verify the X server has matching XKB extension
@@ -35,7 +35,7 @@ extern "C" KDE_EXPORT int kdemain(int argc, char * argv[] )
int opcode_rtrn;
int error_rtrn;
int xkb_opcode;
- if (!XkbQueryExtension(qt_xdisplay(), &opcode_rtrn, &xkb_opcode, &error_rtrn,
+ if (!XkbQueryExtension(tqt_xdisplay(), &opcode_rtrn, &xkb_opcode, &error_rtrn,
&major, &minor))
{
kdError() << "X server has not matching XKB extension" << endl;
diff --git a/kcontrol/background/bgadvanced.cpp b/kcontrol/background/bgadvanced.cpp
index 0917bfe0f..da216aaf3 100644
--- a/kcontrol/background/bgadvanced.cpp
+++ b/kcontrol/background/bgadvanced.cpp
@@ -51,8 +51,8 @@
static TQCString desktopConfigname()
{
int desktop=0;
- if (qt_xdisplay())
- desktop = DefaultScreen(qt_xdisplay());
+ if (tqt_xdisplay())
+ desktop = DefaultScreen(tqt_xdisplay());
TQCString name;
if (desktop == 0)
name = "kdesktoprc";
diff --git a/kcontrol/background/bgrender.cpp b/kcontrol/background/bgrender.cpp
index 5842412e8..d65d9b038 100644
--- a/kcontrol/background/bgrender.cpp
+++ b/kcontrol/background/bgrender.cpp
@@ -192,7 +192,7 @@ int KBackgroundRenderer::doBackground(bool quit)
// some dithering may be needed even with bpb==15/16, so don't use tileWidth==1
// for them
// with tileWidth>2, repainting the desktop causes nasty effect (XFree86 4.1.0 )
- if( XQueryBestTile( qt_xdisplay(), qt_xrootwin(), tile_val, tile_val,
+ if( XQueryBestTile( tqt_xdisplay(), tqt_xrootwin(), tile_val, tile_val,
&tileWidth, &tileHeight ) != Success )
tileWidth = tileHeight = tile_val; // some defaults
}
@@ -549,12 +549,12 @@ bool KBackgroundRenderer::canTile() const
return m_TilingEnabled && optimize();
}
-extern bool qt_use_xrender; // in Qt ( qapplication_x11.cpp )
+extern bool tqt_use_xrender; // in Qt ( qapplication_x11.cpp )
void KBackgroundRenderer::wallpaperBlend()
{
if( !enabled() || wallpaperMode() == NoWallpaper
- || (blendMode() == NoBlending && ( qt_use_xrender || !m_Wallpaper.hasAlphaBuffer()))) {
+ || (blendMode() == NoBlending && ( tqt_use_xrender || !m_Wallpaper.hasAlphaBuffer()))) {
fastWallpaperBlend();
}
else {
@@ -1030,8 +1030,8 @@ KVirtualBGRenderer::KVirtualBGRenderer( int desk, KConfig *config )
// The following code is borrowed from KBackgroundSettings::KBackgroundSettings
if (!config) {
int screen_number = 0;
- if (qt_xdisplay())
- screen_number = DefaultScreen(qt_xdisplay());
+ if (tqt_xdisplay())
+ screen_number = DefaultScreen(tqt_xdisplay());
TQCString configname;
if (screen_number == 0)
configname = "kdesktoprc";
diff --git a/kcontrol/background/bgsettings.cpp b/kcontrol/background/bgsettings.cpp
index 818a00f31..b89731c42 100644
--- a/kcontrol/background/bgsettings.cpp
+++ b/kcontrol/background/bgsettings.cpp
@@ -493,8 +493,8 @@ KBackgroundSettings::KBackgroundSettings(int desk, int screen, bool drawBackgrou
if (!config) {
int screen_number = 0;
- if (qt_xdisplay())
- screen_number = DefaultScreen(qt_xdisplay());
+ if (tqt_xdisplay())
+ screen_number = DefaultScreen(tqt_xdisplay());
TQCString configname;
if (screen_number == 0)
configname = "kdesktoprc";
@@ -1215,7 +1215,7 @@ void KGlobalBackgroundSettings::readSettings()
m_CacheSize = m_pConfig->readNumEntry("CacheSize", _defCacheSize);
m_Names.clear();
- NETRootInfo info( qt_xdisplay(), NET::DesktopNames | NET::NumberOfDesktops );
+ NETRootInfo info( tqt_xdisplay(), NET::DesktopNames | NET::NumberOfDesktops );
m_bDrawBackgroundPerScreen.resize(info.numberOfDesktops());
for ( int i = 0 ; i < info.numberOfDesktops() ; ++i )
m_bDrawBackgroundPerScreen[i] = m_pConfig->readBoolEntry( TQString("DrawBackgroundPerScreen_%1").arg(i), _defDrawBackgroundPerScreen );
diff --git a/kcontrol/background/main.cpp b/kcontrol/background/main.cpp
index 321eef90a..6d22d2384 100644
--- a/kcontrol/background/main.cpp
+++ b/kcontrol/background/main.cpp
@@ -45,8 +45,8 @@ KBackground::KBackground(TQWidget *parent, const char *name, const TQStringList
: KCModule(KBackGndFactory::instance(), parent, name)
{
int screen_number = 0;
- if (qt_xdisplay())
- screen_number = DefaultScreen(qt_xdisplay());
+ if (tqt_xdisplay())
+ screen_number = DefaultScreen(tqt_xdisplay());
TQCString configname;
if (screen_number == 0)
configname = "kdesktoprc";
@@ -105,8 +105,8 @@ void KBackground::save()
client->attach();
int screen_number = 0;
- if (qt_xdisplay())
- screen_number = DefaultScreen(qt_xdisplay());
+ if (tqt_xdisplay())
+ screen_number = DefaultScreen(tqt_xdisplay());
TQCString appname;
if (screen_number == 0)
appname = "kdesktop";
diff --git a/kcontrol/colors/colorscm.cpp b/kcontrol/colors/colorscm.cpp
index b66d839fc..3a67306a6 100644
--- a/kcontrol/colors/colorscm.cpp
+++ b/kcontrol/colors/colorscm.cpp
@@ -399,7 +399,7 @@ void KColorScheme::save()
#if defined Q_WS_X11 && !defined K_WS_QTONLY
// Undo the property xrdb has placed on the root window (if any),
// i.e. remove all entries, including ours
- XDeleteProperty( qt_xdisplay(), qt_xrootwin(), XA_RESOURCE_MANAGER );
+ XDeleteProperty( tqt_xdisplay(), tqt_xrootwin(), XA_RESOURCE_MANAGER );
#endif
}
runRdb( flags ); // Save the palette to qtrc for KStyles
diff --git a/kcontrol/displayconfig/displayconfig.cpp b/kcontrol/displayconfig/displayconfig.cpp
index 5cb1fb71c..7d610b6c5 100644
--- a/kcontrol/displayconfig/displayconfig.cpp
+++ b/kcontrol/displayconfig/displayconfig.cpp
@@ -856,7 +856,7 @@ void KDisplayConfig::identifyMonitors () {
ScreenInfo *randr_screen_info;
XRROutputInfo *output_info;
- randr_display = qt_xdisplay();
+ randr_display = tqt_xdisplay();
randr_screen_info = m_randrsimple->read_screen_info(randr_display);
for (i = 0; i < m_screenInfoArray.count(); i++) {
diff --git a/kcontrol/energy/energy.cpp b/kcontrol/energy/energy.cpp
index d9fa4cb08..40495aaa3 100644
--- a/kcontrol/energy/energy.cpp
+++ b/kcontrol/energy/energy.cpp
@@ -94,7 +94,7 @@ extern "C" {
KConfig *cfg = new KConfig("kcmdisplayrc", true /*readonly*/, false /*no globals*/);
cfg->setGroup("DisplayEnergy");
- Display *dpy = qt_xdisplay();
+ Display *dpy = tqt_xdisplay();
CARD16 pre_configured_status;
BOOL pre_configured_enabled;
CARD16 pre_configured_standby;
@@ -153,7 +153,7 @@ KEnergy::KEnergy(TQWidget *parent, const char *name)
#ifdef HAVE_DPMS
int dummy;
- m_bDPMS = DPMSQueryExtension(qt_xdisplay(), &dummy, &dummy);
+ m_bDPMS = DPMSQueryExtension(tqt_xdisplay(), &dummy, &dummy);
#endif
TQVBoxLayout *top = new TQVBoxLayout(this, 0, KDialog::spacingHint());
@@ -333,7 +333,7 @@ void KEnergy::applySettings(bool enable, int standby, int suspend, int off)
XErrFunc defaultHandler;
defaultHandler = XSetErrorHandler(dropError);
- Display *dpy = qt_xdisplay();
+ Display *dpy = tqt_xdisplay();
int dummy;
bool hasDPMS = DPMSQueryExtension(dpy, &dummy, &dummy);
diff --git a/kcontrol/filetypes/keditfiletype.cpp b/kcontrol/filetypes/keditfiletype.cpp
index 48f9e14c5..8196cfd6c 100644
--- a/kcontrol/filetypes/keditfiletype.cpp
+++ b/kcontrol/filetypes/keditfiletype.cpp
@@ -164,7 +164,7 @@ int main(int argc, char ** argv)
bool ok;
long id = args->getOption("parent").toLong(&ok);
if (ok)
- XSetTransientForHint( qt_xdisplay(), dlg.winId(), id );
+ XSetTransientForHint( tqt_xdisplay(), dlg.winId(), id );
}
#endif
args->clear();
diff --git a/kcontrol/fonts/fonts.cpp b/kcontrol/fonts/fonts.cpp
index 3bea0f1e4..70bbd162e 100644
--- a/kcontrol/fonts/fonts.cpp
+++ b/kcontrol/fonts/fonts.cpp
@@ -495,8 +495,8 @@ int FontAASettings::exec()
static TQCString desktopConfigName()
{
int desktop=0;
- if (qt_xdisplay())
- desktop = DefaultScreen(qt_xdisplay());
+ if (tqt_xdisplay())
+ desktop = DefaultScreen(tqt_xdisplay());
TQCString name;
if (desktop == 0)
name = "kdesktoprc";
diff --git a/kcontrol/input/main.cpp b/kcontrol/input/main.cpp
index f42498aab..439e5f676 100644
--- a/kcontrol/input/main.cpp
+++ b/kcontrol/input/main.cpp
@@ -62,23 +62,23 @@ extern "C"
// use a default value for theme only if it's not configured at all, not even in X resources
if( theme.isEmpty()
- && TQCString( XGetDefault( qt_xdisplay(), "Xcursor", "theme" )).isEmpty()
- && TQCString( XcursorGetTheme( qt_xdisplay())).isEmpty())
+ && TQCString( XGetDefault( tqt_xdisplay(), "Xcursor", "theme" )).isEmpty()
+ && TQCString( XcursorGetTheme( tqt_xdisplay())).isEmpty())
{
theme = "default";
}
// Apply the KDE cursor theme to ourselves
if( !theme.isEmpty())
- XcursorSetTheme(qt_xdisplay(), theme.data());
+ XcursorSetTheme(tqt_xdisplay(), theme.data());
if (!size.isEmpty())
- XcursorSetDefaultSize(qt_xdisplay(), size.toUInt());
+ XcursorSetDefaultSize(tqt_xdisplay(), size.toUInt());
// Load the default cursor from the theme and apply it to the root window.
- Cursor handle = XcursorLibraryLoadCursor(qt_xdisplay(), "left_ptr");
- XDefineCursor(qt_xdisplay(), qt_xrootwin(), handle);
- XFreeCursor(qt_xdisplay(), handle); // Don't leak the cursor
+ Cursor handle = XcursorLibraryLoadCursor(tqt_xdisplay(), "left_ptr");
+ XDefineCursor(tqt_xdisplay(), tqt_xrootwin(), handle);
+ XFreeCursor(tqt_xdisplay(), handle); // Don't leak the cursor
// Tell klauncher to set the XCURSOR_THEME and XCURSOR_SIZE environment
// variables when launching applications.
diff --git a/kcontrol/input/xcursor/previewwidget.cpp b/kcontrol/input/xcursor/previewwidget.cpp
index ceb399648..326178a7a 100644
--- a/kcontrol/input/xcursor/previewwidget.cpp
+++ b/kcontrol/input/xcursor/previewwidget.cpp
@@ -34,8 +34,8 @@
#include "previewwidget.h"
-extern bool qt_has_xft;
-extern bool qt_use_xrender;
+extern bool tqt_has_xft;
+extern bool tqt_use_xrender;
namespace {
@@ -314,7 +314,7 @@ void PreviewWidget::paintEvent( TQPaintEvent * )
p.fillRect( rect(), colorGroup().brush( TQColorGroup::Background ) );
Picture dest;
- if ( !qt_has_xft || !qt_use_xrender ) {
+ if ( !tqt_has_xft || !tqt_use_xrender ) {
XRenderPictFormat *fmt = XRenderFindVisualFormat( x11Display(), (Visual*)buffer.x11Visual() );
dest = XRenderCreatePicture( x11Display(), buffer.handle(), fmt, 0, NULL );
} else
@@ -334,7 +334,7 @@ void PreviewWidget::paintEvent( TQPaintEvent * )
bitBlt( this, 0, 0, &buffer );
- if ( !qt_has_xft || !qt_use_xrender )
+ if ( !tqt_has_xft || !tqt_use_xrender )
XRenderFreePicture( x11Display(), dest );
}
diff --git a/kcontrol/kcontrol/modules.cpp b/kcontrol/kcontrol/modules.cpp
index 5ec30ef76..5be813dc0 100644
--- a/kcontrol/kcontrol/modules.cpp
+++ b/kcontrol/kcontrol/modules.cpp
@@ -90,7 +90,7 @@ ProxyWidget *ConfigModule::module()
void ConfigModule::deleteClient()
{
if (_embedWidget)
- XKillClient(qt_xdisplay(), _embedWidget->embeddedWinId());
+ XKillClient(tqt_xdisplay(), _embedWidget->embeddedWinId());
delete _rootProcess;
_rootProcess = 0;
@@ -229,7 +229,7 @@ void ConfigModule::runAsRoot()
void ConfigModule::rootExited(KProcess *)
{
if (_embedWidget->embeddedWinId())
- XDestroyWindow(qt_xdisplay(), _embedWidget->embeddedWinId());
+ XDestroyWindow(tqt_xdisplay(), _embedWidget->embeddedWinId());
delete _embedWidget;
_embedWidget = 0;
diff --git a/kcontrol/keys/modifiers.cpp b/kcontrol/keys/modifiers.cpp
index 8cde6989e..ebe099aa5 100644
--- a/kcontrol/keys/modifiers.cpp
+++ b/kcontrol/keys/modifiers.cpp
@@ -139,10 +139,10 @@ void ModifiersModule::setupMacModifierKeys()
//const int CODE_Alt_L = 0x40, CODE_Alt_R = 0x71;
int keyCodeMin, keyCodeMax, nKeyCodes, nSymsPerCode;
- XDisplayKeycodes( qt_xdisplay(), &keyCodeMin, &keyCodeMax );
+ XDisplayKeycodes( tqt_xdisplay(), &keyCodeMin, &keyCodeMax );
nKeyCodes = keyCodeMax - keyCodeMin + 1;
- KeySym* rgKeySyms = XGetKeyboardMapping( qt_xdisplay(), keyCodeMin, nKeyCodes, &nSymsPerCode );
- XModifierKeymap* xmk = XGetModifierMapping( qt_xdisplay() );
+ KeySym* rgKeySyms = XGetKeyboardMapping( tqt_xdisplay(), keyCodeMin, nKeyCodes, &nSymsPerCode );
+ XModifierKeymap* xmk = XGetModifierMapping( tqt_xdisplay() );
SET_CODE_SYM( CODE_Ctrl_L, XK_Super_L )
SET_CODE_SYM( CODE_Ctrl_R, XK_Super_R )
@@ -159,8 +159,8 @@ void ModifiersModule::setupMacModifierKeys()
//SET_MOD_CODE( Mod1MapIndex, CODE_Win_L, CODE_Win_R );
//SET_MOD_CODE( Mod4MapIndex, CODE_Ctrl_L, CODE_Ctrl_R );
- XSetModifierMapping( qt_xdisplay(), xmk );
- XChangeKeyboardMapping( qt_xdisplay(), keyCodeMin, nSymsPerCode, rgKeySyms, nKeyCodes );
+ XSetModifierMapping( tqt_xdisplay(), xmk );
+ XChangeKeyboardMapping( tqt_xdisplay(), keyCodeMin, nSymsPerCode, rgKeySyms, nKeyCodes );
XFree( rgKeySyms );
XFreeModifiermap( xmk );
}
@@ -291,7 +291,7 @@ void ModifiersModule::updateWidgets()
m_pchkMacSwap->setEnabled( false );
}
- XModifierKeymap* xmk = XGetModifierMapping( qt_xdisplay() );
+ XModifierKeymap* xmk = XGetModifierMapping( tqt_xdisplay() );
for( int iKey = m_plstXMods->columns()-1; iKey < xmk->max_keypermod; iKey++ )
m_plstXMods->addColumn( i18n("Key %1").arg(iKey+1) );
@@ -300,7 +300,7 @@ void ModifiersModule::updateWidgets()
for( int iMod = 0; iMod < 8; iMod++ ) {
// Find the default modifier index for the Win key.
/*if( iMod > Mod2Index ) {
- uint symX = XKeycodeToKeysym( qt_xdisplay(), xmk->modifiermap[xmk->max_keypermod * iMod], 0 );
+ uint symX = XKeycodeToKeysym( tqt_xdisplay(), xmk->modifiermap[xmk->max_keypermod * iMod], 0 );
if( symX == XK_Super_L || symX == XK_Super_R )
iModWinDef = iMod;
else if( iModWinDef == -1 && (symX == XK_Meta_L || symX == XK_Meta_R) )
@@ -309,7 +309,7 @@ void ModifiersModule::updateWidgets()
// Insert items into X modifier map list
for( int iKey = 0; iKey < xmk->max_keypermod; iKey++ ) {
- uint symX = XKeycodeToKeysym( qt_xdisplay(), xmk->modifiermap[xmk->max_keypermod * iMod + iKey], 0 );
+ uint symX = XKeycodeToKeysym( tqt_xdisplay(), xmk->modifiermap[xmk->max_keypermod * iMod + iKey], 0 );
m_plstXMods->itemAtIndex( iMod )->setText( 1 + iKey, XKeysymToString( symX ) );
}
}
diff --git a/kcontrol/kicker/main.cpp b/kcontrol/kicker/main.cpp
index 95d80cc31..1117e49a0 100644
--- a/kcontrol/kicker/main.cpp
+++ b/kcontrol/kicker/main.cpp
@@ -57,7 +57,7 @@ KickerConfig::KickerConfig(TQWidget *parent, const char *name)
configFileWatch(new KDirWatch(this)),
m_currentPanelIndex(0)
{
- m_screenNumber = qt_xdisplay() ? DefaultScreen(qt_xdisplay()) : 0;
+ m_screenNumber = tqt_xdisplay() ? DefaultScreen(tqt_xdisplay()) : 0;
KickerSettings::instance(configName().latin1());
diff --git a/kcontrol/konq/desktop.cpp b/kcontrol/konq/desktop.cpp
index cf884c0be..4be13ef3f 100644
--- a/kcontrol/konq/desktop.cpp
+++ b/kcontrol/konq/desktop.cpp
@@ -128,12 +128,12 @@ void KDesktopConfig::load()
void KDesktopConfig::load( bool useDefaults )
{
// get number of desktops
- NETRootInfo info( qt_xdisplay(), NET::NumberOfDesktops | NET::DesktopNames );
+ NETRootInfo info( tqt_xdisplay(), NET::NumberOfDesktops | NET::DesktopNames );
int n = info.numberOfDesktops();
int konq_screen_number = 0;
- if (qt_xdisplay())
- konq_screen_number = DefaultScreen(qt_xdisplay());
+ if (tqt_xdisplay())
+ konq_screen_number = DefaultScreen(tqt_xdisplay());
TQCString groupname;
if (konq_screen_number == 0)
@@ -193,7 +193,7 @@ void KDesktopConfig::load( bool useDefaults )
void KDesktopConfig::save()
{
- NETRootInfo info( qt_xdisplay(), NET::NumberOfDesktops | NET::DesktopNames );
+ NETRootInfo info( tqt_xdisplay(), NET::NumberOfDesktops | NET::DesktopNames );
// set desktop names
for(int i = 1; i <= maxDesktops; i++)
{
@@ -204,11 +204,11 @@ void KDesktopConfig::save()
info.setNumberOfDesktops(_numInput->value());
info.activate();
- XSync(qt_xdisplay(), FALSE);
+ XSync(tqt_xdisplay(), FALSE);
int konq_screen_number = 0;
- if (qt_xdisplay())
- konq_screen_number = DefaultScreen(qt_xdisplay());
+ if (tqt_xdisplay())
+ konq_screen_number = DefaultScreen(tqt_xdisplay());
TQCString appname;
if (konq_screen_number == 0)
diff --git a/kcontrol/krdb/krdb.cpp b/kcontrol/krdb/krdb.cpp
index b31b1ae6b..60ee13bfe 100644
--- a/kcontrol/krdb/krdb.cpp
+++ b/kcontrol/krdb/krdb.cpp
@@ -596,13 +596,13 @@ void runRdb( uint flags )
if (!qt_settings_timestamp) {
TQString atomname("_QT_SETTINGS_TIMESTAMP_");
atomname += XDisplayName( 0 ); // Use the $DISPLAY envvar.
- qt_settings_timestamp = XInternAtom( qt_xdisplay(), atomname.latin1(), False);
+ qt_settings_timestamp = XInternAtom( tqt_xdisplay(), atomname.latin1(), False);
}
TQBuffer stamp;
TQDataStream s(stamp.buffer(), IO_WriteOnly);
s << settingsstamp;
- XChangeProperty( qt_xdisplay(), qt_xrootwin(), qt_settings_timestamp,
+ XChangeProperty( tqt_xdisplay(), tqt_xrootwin(), qt_settings_timestamp,
qt_settings_timestamp, 8, PropModeReplace,
(unsigned char*) stamp.buffer().data(),
stamp.buffer().size() );
diff --git a/kcontrol/kthememanager/ktheme.cpp b/kcontrol/kthememanager/ktheme.cpp
index 0eba57304..064b5ab10 100644
--- a/kcontrol/kthememanager/ktheme.cpp
+++ b/kcontrol/kthememanager/ktheme.cpp
@@ -869,7 +869,7 @@ void KTheme::addPreview()
{
TQString file = m_kgd->saveLocation( "themes", m_name + "/" ) + m_name + ".preview.png";
kdDebug() << "Adding preview: " << file << endl;
- TQPixmap snapshot = TQPixmap::grabWindow( qt_xrootwin() );
+ TQPixmap snapshot = TQPixmap::grabWindow( tqt_xrootwin() );
snapshot.save( file, "PNG" );
}
diff --git a/kcontrol/randr/krandrmodule.cpp b/kcontrol/randr/krandrmodule.cpp
index c32073243..48dbb475d 100644
--- a/kcontrol/randr/krandrmodule.cpp
+++ b/kcontrol/randr/krandrmodule.cpp
@@ -56,7 +56,7 @@ extern "C"
KDE_EXPORT bool test_randr()
{
int eventBase, errorBase;
- if( XRRQueryExtension(qt_xdisplay(), &eventBase, &errorBase ) )
+ if( XRRQueryExtension(tqt_xdisplay(), &eventBase, &errorBase ) )
return true;
return false;
}
diff --git a/kcontrol/randr/krandrpassivepopup.cpp b/kcontrol/randr/krandrpassivepopup.cpp
index 8f340bdee..12d9f8a3f 100644
--- a/kcontrol/randr/krandrpassivepopup.cpp
+++ b/kcontrol/randr/krandrpassivepopup.cpp
@@ -45,7 +45,7 @@ KRandrPassivePopup* KRandrPassivePopup::message( const TQString &caption, const
void KRandrPassivePopup::startWatchingWidget( TQWidget* widget_P )
{
- static Atom wm_state = XInternAtom( qt_xdisplay() , "WM_STATE", False );
+ static Atom wm_state = XInternAtom( tqt_xdisplay() , "WM_STATE", False );
Window win = widget_P->winId();
bool x11_events = false;
for(;;)
@@ -53,7 +53,7 @@ void KRandrPassivePopup::startWatchingWidget( TQWidget* widget_P )
Window root, parent;
Window* children;
unsigned int nchildren;
- XQueryTree( qt_xdisplay(), win, &root, &parent, &children, &nchildren );
+ XQueryTree( tqt_xdisplay(), win, &root, &parent, &children, &nchildren );
if( children != NULL )
XFree( children );
if( win == root ) // huh?
@@ -69,8 +69,8 @@ void KRandrPassivePopup::startWatchingWidget( TQWidget* widget_P )
else
{
XWindowAttributes attrs;
- XGetWindowAttributes( qt_xdisplay(), win, &attrs );
- XSelectInput( qt_xdisplay(), win, attrs.your_event_mask | StructureNotifyMask );
+ XGetWindowAttributes( tqt_xdisplay(), win, &attrs );
+ XSelectInput( tqt_xdisplay(), win, attrs.your_event_mask | StructureNotifyMask );
watched_windows.append( win );
x11_events = true;
}
@@ -78,7 +78,7 @@ void KRandrPassivePopup::startWatchingWidget( TQWidget* widget_P )
int format;
unsigned long nitems, after;
unsigned char* data;
- if( XGetWindowProperty( qt_xdisplay(), win, wm_state, 0, 0, False, AnyPropertyType,
+ if( XGetWindowProperty( tqt_xdisplay(), win, wm_state, 0, 0, False, AnyPropertyType,
&type, &format, &nitems, &after, &data ) == Success )
{
if( data != NULL )
diff --git a/kcontrol/screensaver/scrnsave.cpp b/kcontrol/screensaver/scrnsave.cpp
index 4764f0605..d24f260eb 100644
--- a/kcontrol/screensaver/scrnsave.cpp
+++ b/kcontrol/screensaver/scrnsave.cpp
@@ -582,7 +582,7 @@ void KScreenSaver::slotPreviewExited(KProcess *)
(mMonitorLabel->height()-186)/2+14, 151, 115);
mMonitor->show();
// So that hacks can XSelectInput ButtonPressMask
- XSelectInput(qt_xdisplay(), mMonitor->winId(), widgetEventMask );
+ XSelectInput(tqt_xdisplay(), mMonitor->winId(), widgetEventMask );
if (mSelected >= 0) {
mPreviewProc->clearArguments();
@@ -781,7 +781,7 @@ void KScreenSaver::slotTest()
mTestWin->raise();
mTestWin->setFocus();
// So that hacks can XSelectInput ButtonPressMask
- XSelectInput(qt_xdisplay(), mTestWin->winId(), widgetEventMask );
+ XSelectInput(tqt_xdisplay(), mTestWin->winId(), widgetEventMask );
grabMouse();
grabKeyboard();
diff --git a/kcontrol/style/kcmstyle.cpp b/kcontrol/style/kcmstyle.cpp
index 16ff43b68..21a4ef424 100644
--- a/kcontrol/style/kcmstyle.cpp
+++ b/kcontrol/style/kcmstyle.cpp
@@ -97,12 +97,12 @@ extern "C"
TQDataStream d(properties, IO_WriteOnly);
d.setVersion( 3 ); // Qt2 apps need this.
d << kapp->palette() << KGlobalSettings::generalFont();
- Atom a = XInternAtom(qt_xdisplay(), "_QT_DESKTOP_PROPERTIES", false);
+ Atom a = XInternAtom(tqt_xdisplay(), "_QT_DESKTOP_PROPERTIES", false);
// do it for all root windows - multihead support
- int screen_count = ScreenCount(qt_xdisplay());
+ int screen_count = ScreenCount(tqt_xdisplay());
for (int i = 0; i < screen_count; i++)
- XChangeProperty(qt_xdisplay(), RootWindow(qt_xdisplay(), i),
+ XChangeProperty(tqt_xdisplay(), RootWindow(tqt_xdisplay(), i),
a, a, 8, PropModeReplace,
(unsigned char*) properties.data(), properties.size());
#endif
diff --git a/kdesktop/bgmanager.cc b/kdesktop/bgmanager.cc
index 341cc5b88..b36219692 100644
--- a/kdesktop/bgmanager.cc
+++ b/kdesktop/bgmanager.cc
@@ -64,7 +64,7 @@ KBackgroundManager::KBackgroundManager(TQWidget *desktop, KWinModule* twinModule
{
if( !properties_inited )
{
- prop_root = XInternAtom(qt_xdisplay(), "_XROOTPMAP_ID", False);
+ prop_root = XInternAtom(tqt_xdisplay(), "_XROOTPMAP_ID", False);
properties_inited = true;
}
m_bBgInitDone = false;
@@ -146,7 +146,7 @@ KBackgroundManager::~KBackgroundManager()
int format;
unsigned long length, after;
unsigned char* data_root;
- if( XGetWindowProperty( qt_xdisplay(), qt_xrootwin(), prop_root, 0L, 1L, False, AnyPropertyType,
+ if( XGetWindowProperty( tqt_xdisplay(), tqt_xrootwin(), prop_root, 0L, 1L, False, AnyPropertyType,
&type, &format, &length, &after, &data_root) == Success && data_root != NULL )
{
if (type == XA_PIXMAP)
@@ -155,7 +155,7 @@ KBackgroundManager::~KBackgroundManager()
}
// only if it's our pixmap
if( pm == m_xrootpmap )
- XDeleteProperty(qt_xdisplay(), qt_xrootwin(), prop_root);
+ XDeleteProperty(tqt_xdisplay(), tqt_xrootwin(), prop_root);
m_xrootpmap = None;
if (m_bExport)
@@ -488,7 +488,7 @@ void KBackgroundManager::setPixmap(KPixmap *pm, int hash, int desk)
&& !myApp->cmBackground())
{
XRenderPictFormat *format;
- format = XRenderFindStandardFormat (qt_xdisplay(), PictStandardARGB32);
+ format = XRenderFindStandardFormat (tqt_xdisplay(), PictStandardARGB32);
XRenderColor fillColor;
@@ -498,18 +498,18 @@ void KBackgroundManager::setPixmap(KPixmap *pm, int hash, int desk)
fillColor.blue = color;
fillColor.alpha = color;
- Picture fill = XRenderCreateSolidFill (qt_xdisplay(), &fillColor);
- Picture src = XRenderCreatePicture(qt_xdisplay(), pm->handle(),
+ Picture fill = XRenderCreateSolidFill (tqt_xdisplay(), &fillColor);
+ Picture src = XRenderCreatePicture(tqt_xdisplay(), pm->handle(),
format, 0, NULL);
- Picture dst = XRenderCreatePicture(qt_xdisplay(), ep->handle(),
+ Picture dst = XRenderCreatePicture(tqt_xdisplay(), ep->handle(),
format, 0, NULL);
- XRenderComposite (qt_xdisplay(), PictOpSrc, src, fill, dst, 0, 0, 0,
+ XRenderComposite (tqt_xdisplay(), PictOpSrc, src, fill, dst, 0, 0, 0,
0, 0, 0, pm->width(), pm->height());
- XRenderFreePicture (qt_xdisplay(), fill);
- XRenderFreePicture (qt_xdisplay(), src);
- XRenderFreePicture (qt_xdisplay(), dst);
+ XRenderFreePicture (tqt_xdisplay(), fill);
+ XRenderFreePicture (tqt_xdisplay(), src);
+ XRenderFreePicture (tqt_xdisplay(), dst);
}
}
#endif
@@ -546,7 +546,7 @@ void KBackgroundManager::setPixmap(KPixmap *pm, int hash, int desk)
// don't set the ESETROOT_PMAP_ID property - that would result in possible XKillClient()
// done on kdesktop
- XChangeProperty(qt_xdisplay(), qt_xrootwin(), prop_root, XA_PIXMAP, 32, PropModeReplace,
+ XChangeProperty(tqt_xdisplay(), tqt_xrootwin(), prop_root, XA_PIXMAP, 32, PropModeReplace,
(unsigned char *) &bgPm, 1);
m_xrootpmap = bgPm;
diff --git a/kdesktop/desktop.cc b/kdesktop/desktop.cc
index 2690f0341..9b37e3ccc 100644
--- a/kdesktop/desktop.cc
+++ b/kdesktop/desktop.cc
@@ -140,7 +140,7 @@ KDesktop::KDesktop( bool x_root_hack, bool wait_for_kded ) :
// those two WStyle_ break kdesktop when the root-hack isn't used (no Dnd)
startup_id( NULL ), m_waitForKicker(0)
{
- NETRootInfo i( qt_xdisplay(), NET::Supported );
+ NETRootInfo i( tqt_xdisplay(), NET::Supported );
m_wmSupport = i.isSupported( NET::WM2ShowingDesktop );
m_bWaitForKded = wait_for_kded;
@@ -173,8 +173,8 @@ KDesktop::KDesktop( bool x_root_hack, bool wait_for_kded ) :
unsigned long data[2];
data[0] = (unsigned long) 1;
data[1] = (unsigned long) 0; // None; (Werner)
- Atom wm_state = XInternAtom(qt_xdisplay(), "WM_STATE", False);
- XChangeProperty(qt_xdisplay(), winId(), wm_state, wm_state, 32,
+ Atom wm_state = XInternAtom(tqt_xdisplay(), "WM_STATE", False);
+ XChangeProperty(tqt_xdisplay(), winId(), wm_state, wm_state, 32,
PropModeReplace, (unsigned char *)data, 2);
}
@@ -210,7 +210,7 @@ KDesktop::KDesktop( bool x_root_hack, bool wait_for_kded ) :
void
KDesktop::initRoot()
{
- Display *dpy = qt_xdisplay();
+ Display *dpy = tqt_xdisplay();
Window root = RootWindow(dpy, kdesktop_screen_number);
XDefineCursor(dpy, root, cursor().handle());
@@ -515,7 +515,7 @@ void KDesktop::popupExecuteCommand(const TQString& command)
m_miniCli->setCommand(command);
// Move minicli to the current desktop
- NETWinInfo info( qt_xdisplay(), m_miniCli->winId(), qt_xrootwin(), NET::WMDesktop );
+ NETWinInfo info( tqt_xdisplay(), m_miniCli->winId(), tqt_xrootwin(), NET::WMDesktop );
int currentDesktop = twinModule()->currentDesktop();
if ( info.desktop() != currentDesktop )
info.setDesktop( currentDesktop );
@@ -523,7 +523,7 @@ void KDesktop::popupExecuteCommand(const TQString& command)
if ( m_miniCli->isVisible() ) {
KWin::forceActiveWindow( m_miniCli->winId() );
} else {
- NETRootInfo i( qt_xdisplay(), NET::Supported );
+ NETRootInfo i( tqt_xdisplay(), NET::Supported );
if( !i.isSupported( NET::WM2FullPlacement )) {
TQRect rect = KGlobalSettings::desktopGeometry(TQCursor::pos());
m_miniCli->move(rect.x() + (rect.width() - m_miniCli->width())/2,
@@ -607,7 +607,7 @@ void KDesktop::setShowDesktop( bool b )
if( m_wmSupport )
{
- NETRootInfo i( qt_xdisplay(), 0 );
+ NETRootInfo i( tqt_xdisplay(), 0 );
i.setShowingDesktop( b );
return;
}
@@ -624,7 +624,7 @@ void KDesktop::setShowDesktop( bool b )
{
WId w = *it;
- NETWinInfo info( qt_xdisplay(), w, qt_xrootwin(),
+ NETWinInfo info( tqt_xdisplay(), w, tqt_xrootwin(),
NET::XAWMState | NET::WMDesktop );
if (info.mappingState() == NET::Visible &&
@@ -689,7 +689,7 @@ void KDesktop::slotWindowAdded(WId w)
return;
}
- NETWinInfo inf(qt_xdisplay(), w, qt_xrootwin(),
+ NETWinInfo inf(tqt_xdisplay(), w, tqt_xrootwin(),
NET::XAWMState | NET::WMWindowType);
NET::WindowType windowType = inf.windowType(NET::AllTypesMask);
@@ -723,7 +723,7 @@ void KDesktop::slotWindowChanged(WId w, unsigned int dirty)
if (dirty & NET::XAWMState)
{
- NETWinInfo inf(qt_xdisplay(), w, qt_xrootwin(),
+ NETWinInfo inf(tqt_xdisplay(), w, tqt_xrootwin(),
NET::XAWMState | NET::WMWindowType);
NET::WindowType windowType = inf.windowType(NET::AllTypesMask);
@@ -852,15 +852,15 @@ void KDesktop::slotSetVRoot()
return;
}
- unsigned long rw = RootWindowOfScreen(ScreenOfDisplay(qt_xdisplay(), qt_xscreen()));
+ unsigned long rw = RootWindowOfScreen(ScreenOfDisplay(tqt_xdisplay(), tqt_xscreen()));
unsigned long vroot_data[1] = { m_pIconView->viewport()->winId() };
- static Atom vroot = XInternAtom(qt_xdisplay(), "__SWM_VROOT", False);
+ static Atom vroot = XInternAtom(tqt_xdisplay(), "__SWM_VROOT", False);
Window rootReturn, parentReturn, *children;
unsigned int numChildren;
Window top = winId();
while (1) {
- /*int ret = */XQueryTree(qt_xdisplay(), top , &rootReturn, &parentReturn,
+ /*int ret = */XQueryTree(tqt_xdisplay(), top , &rootReturn, &parentReturn,
&children, &numChildren);
if (children)
XFree((char *)children);
@@ -870,10 +870,10 @@ void KDesktop::slotSetVRoot()
top = parentReturn;
}
if ( set_vroot )
- XChangeProperty(qt_xdisplay(), top, vroot, XA_WINDOW, 32,
+ XChangeProperty(tqt_xdisplay(), top, vroot, XA_WINDOW, 32,
PropModeReplace, (unsigned char *)vroot_data, 1);
else
- XDeleteProperty (qt_xdisplay(), top, vroot);
+ XDeleteProperty (tqt_xdisplay(), top, vroot);
}
// -----------------------------------------------------------------------------
diff --git a/kdesktop/kdesktopapp.cpp b/kdesktop/kdesktopapp.cpp
index f7324362c..ba05dc655 100644
--- a/kdesktop/kdesktopapp.cpp
+++ b/kdesktop/kdesktopapp.cpp
@@ -45,11 +45,11 @@ void KDesktopApp::initCmBackground()
m_bgSupported = false;
m_cmBackground =
- XInternAtom (qt_xdisplay(), "_COMPIZ_WALLPAPER_SUPPORTED", false);
+ XInternAtom (tqt_xdisplay(), "_COMPIZ_WALLPAPER_SUPPORTED", false);
- XSelectInput (qt_xdisplay(), qt_xrootwin(), PropertyChangeMask);
+ XSelectInput (tqt_xdisplay(), tqt_xrootwin(), PropertyChangeMask);
- if (XGetWindowProperty (qt_xdisplay(), qt_xrootwin(), m_cmBackground,
+ if (XGetWindowProperty (tqt_xdisplay(), tqt_xrootwin(), m_cmBackground,
0, 1, FALSE, XA_CARDINAL, &type, &format, &num,
&rest, &data) == Success && num)
{
@@ -62,7 +62,7 @@ void KDesktopApp::initCmBackground()
bool KDesktopApp::x11EventFilter (XEvent * xevent)
{
if (xevent->type == PropertyNotify &&
- xevent->xproperty.window == qt_xrootwin() &&
+ xevent->xproperty.window == tqt_xrootwin() &&
xevent->xproperty.atom == m_cmBackground)
{
Atom type;
@@ -72,7 +72,7 @@ bool KDesktopApp::x11EventFilter (XEvent * xevent)
Bool supported = false;
- if (XGetWindowProperty (qt_xdisplay(), qt_xrootwin(), m_cmBackground,
+ if (XGetWindowProperty (tqt_xdisplay(), tqt_xrootwin(), m_cmBackground,
0, 1, FALSE, XA_CARDINAL, &type, &format, &num,
&rest, &data) == Success && num)
{
diff --git a/kdesktop/krootwm.cc b/kdesktop/krootwm.cc
index 1f5aee86f..f7f8de0ef 100644
--- a/kdesktop/krootwm.cc
+++ b/kdesktop/krootwm.cc
@@ -579,8 +579,8 @@ void KRootWm::activateMenu( menuChoice choice, const TQPoint& global )
case APPMENU:
{
// This allows the menu to disappear when clicking on the background another time
- XUngrabPointer(qt_xdisplay(), CurrentTime);
- XSync(qt_xdisplay(), False);
+ XUngrabPointer(tqt_xdisplay(), CurrentTime);
+ XSync(tqt_xdisplay(), False);
// Ask kicker to showup the menu
DCOPRef( kicker_name, kicker_name ).send( "popupKMenu", global );
diff --git a/kdesktop/lock/autologout.cc b/kdesktop/lock/autologout.cc
index bef39ddf0..024425d2c 100644
--- a/kdesktop/lock/autologout.cc
+++ b/kdesktop/lock/autologout.cc
@@ -36,8 +36,8 @@ AutoLogout::AutoLogout(LockProcess *parent) : TQDialog(parent, "password dialog"
if (trinity_desktop_lock_use_system_modal_dialogs) {
// Signal that we do not want any window controls to be shown at all
Atom kde_wm_system_modal_notification;
- kde_wm_system_modal_notification = XInternAtom(qt_xdisplay(), "_KDE_WM_MODAL_SYS_NOTIFICATION", False);
- XChangeProperty(qt_xdisplay(), winId(), kde_wm_system_modal_notification, XA_INTEGER, 32, PropModeReplace, (unsigned char *) "TRUE", 1L);
+ kde_wm_system_modal_notification = XInternAtom(tqt_xdisplay(), "_KDE_WM_MODAL_SYS_NOTIFICATION", False);
+ XChangeProperty(tqt_xdisplay(), winId(), kde_wm_system_modal_notification, XA_INTEGER, 32, PropModeReplace, (unsigned char *) "TRUE", 1L);
}
setCaption(i18n("Automatic Logout Notification"));
diff --git a/kdesktop/lock/infodlg.cc b/kdesktop/lock/infodlg.cc
index 3fbc276f4..725122134 100644
--- a/kdesktop/lock/infodlg.cc
+++ b/kdesktop/lock/infodlg.cc
@@ -68,8 +68,8 @@ InfoDlg::InfoDlg(LockProcess *parent)
if (trinity_desktop_lock_use_system_modal_dialogs) {
// Signal that we do not want any window controls to be shown at all
Atom kde_wm_system_modal_notification;
- kde_wm_system_modal_notification = XInternAtom(qt_xdisplay(), "_KDE_WM_MODAL_SYS_NOTIFICATION", False);
- XChangeProperty(qt_xdisplay(), winId(), kde_wm_system_modal_notification, XA_INTEGER, 32, PropModeReplace, (unsigned char *) "TRUE", 1L);
+ kde_wm_system_modal_notification = XInternAtom(tqt_xdisplay(), "_KDE_WM_MODAL_SYS_NOTIFICATION", False);
+ XChangeProperty(tqt_xdisplay(), winId(), kde_wm_system_modal_notification, XA_INTEGER, 32, PropModeReplace, (unsigned char *) "TRUE", 1L);
}
setCaption(i18n("Information"));
diff --git a/kdesktop/lock/lockdlg.cc b/kdesktop/lock/lockdlg.cc
index f3eeee0b8..1ae046520 100644
--- a/kdesktop/lock/lockdlg.cc
+++ b/kdesktop/lock/lockdlg.cc
@@ -103,8 +103,8 @@ void PasswordDlg::init(GreeterPluginHandle *plugin)
if (trinity_desktop_lock_use_system_modal_dialogs) {
// Signal that we do not want any window controls to be shown at all
Atom kde_wm_system_modal_notification;
- kde_wm_system_modal_notification = XInternAtom(qt_xdisplay(), "_KDE_WM_MODAL_SYS_NOTIFICATION", False);
- XChangeProperty(qt_xdisplay(), winId(), kde_wm_system_modal_notification, XA_INTEGER, 32, PropModeReplace, (unsigned char *) "TRUE", 1L);
+ kde_wm_system_modal_notification = XInternAtom(tqt_xdisplay(), "_KDE_WM_MODAL_SYS_NOTIFICATION", False);
+ XChangeProperty(tqt_xdisplay(), winId(), kde_wm_system_modal_notification, XA_INTEGER, 32, PropModeReplace, (unsigned char *) "TRUE", 1L);
}
setCaption(i18n("Desktop Session Locked"));
@@ -617,8 +617,8 @@ void PasswordDlg::slotStartNewSession()
if (trinity_desktop_lock_use_system_modal_dialogs) {
// Signal that we do not want any window controls to be shown at all
Atom kde_wm_system_modal_notification;
- kde_wm_system_modal_notification = XInternAtom(qt_xdisplay(), "_KDE_WM_MODAL_SYS_NOTIFICATION", False);
- XChangeProperty(qt_xdisplay(), dialog->winId(), kde_wm_system_modal_notification, XA_INTEGER, 32, PropModeReplace, (unsigned char *) "TRUE", 1L);
+ kde_wm_system_modal_notification = XInternAtom(tqt_xdisplay(), "_KDE_WM_MODAL_SYS_NOTIFICATION", False);
+ XChangeProperty(tqt_xdisplay(), dialog->winId(), kde_wm_system_modal_notification, XA_INTEGER, 32, PropModeReplace, (unsigned char *) "TRUE", 1L);
}
dialog->setCaption(i18n("New Session"));
@@ -743,8 +743,8 @@ void PasswordDlg::slotSwitchUser()
if (trinity_desktop_lock_use_system_modal_dialogs) {
// Signal that we do not want any window controls to be shown at all
Atom kde_wm_system_modal_notification;
- kde_wm_system_modal_notification = XInternAtom(qt_xdisplay(), "_KDE_WM_MODAL_SYS_NOTIFICATION", False);
- XChangeProperty(qt_xdisplay(), dialog.winId(), kde_wm_system_modal_notification, XA_INTEGER, 32, PropModeReplace, (unsigned char *) "TRUE", 1L);
+ kde_wm_system_modal_notification = XInternAtom(tqt_xdisplay(), "_KDE_WM_MODAL_SYS_NOTIFICATION", False);
+ XChangeProperty(tqt_xdisplay(), dialog.winId(), kde_wm_system_modal_notification, XA_INTEGER, 32, PropModeReplace, (unsigned char *) "TRUE", 1L);
}
dialog.setCaption(i18n("Switch User"));
@@ -840,7 +840,7 @@ void PasswordDlg::capsLocked()
unsigned int lmask;
Window dummy1, dummy2;
int dummy3, dummy4, dummy5, dummy6;
- XQueryPointer(qt_xdisplay(), DefaultRootWindow( qt_xdisplay() ), &dummy1, &dummy2, &dummy3, &dummy4, &dummy5, &dummy6, &lmask);
+ XQueryPointer(tqt_xdisplay(), DefaultRootWindow( tqt_xdisplay() ), &dummy1, &dummy2, &dummy3, &dummy4, &dummy5, &dummy6, &lmask);
mCapsLocked = lmask & LockMask;
updateLabel();
}
diff --git a/kdesktop/lock/lockprocess.cc b/kdesktop/lock/lockprocess.cc
index 22862d2ba..ad075ba22 100644
--- a/kdesktop/lock/lockprocess.cc
+++ b/kdesktop/lock/lockprocess.cc
@@ -132,7 +132,7 @@ static void segv_handler(int)
sleep(1);
}
-extern Atom qt_wm_state;
+extern Atom tqt_wm_state;
extern bool trinity_desktop_lock_use_system_modal_dialogs;
extern bool trinity_desktop_lock_delay_screensaver_start;
extern bool trinity_desktop_lock_use_sak;
@@ -220,15 +220,15 @@ LockProcess::LockProcess(bool child, bool useBlankOnly)
// Get root window size
XWindowAttributes rootAttr;
- XGetWindowAttributes(qt_xdisplay(), RootWindow(qt_xdisplay(),
- qt_xscreen()), &rootAttr);
+ XGetWindowAttributes(tqt_xdisplay(), RootWindow(tqt_xdisplay(),
+ tqt_xscreen()), &rootAttr);
mRootWidth = rootAttr.width;
mRootHeight = rootAttr.height;
{ // trigger creation of QToolTipManager, it does XSelectInput() on the root window
TQWidget w;
TQToolTip::add( &w, "foo" );
}
- XSelectInput( qt_xdisplay(), qt_xrootwin(),
+ XSelectInput( tqt_xdisplay(), tqt_xrootwin(),
SubstructureNotifyMask | rootAttr.your_event_mask );
// Add non-KDE path
@@ -249,8 +249,8 @@ LockProcess::LockProcess(bool child, bool useBlankOnly)
relPath);
// virtual root property
- gXA_VROOT = XInternAtom (qt_xdisplay(), "__SWM_VROOT", False);
- gXA_SCREENSAVER_VERSION = XInternAtom (qt_xdisplay(), "_SCREENSAVER_VERSION", False);
+ gXA_VROOT = XInternAtom (tqt_xdisplay(), "__SWM_VROOT", False);
+ gXA_SCREENSAVER_VERSION = XInternAtom (tqt_xdisplay(), "_SCREENSAVER_VERSION", False);
connect(&mHackProc, TQT_SIGNAL(processExited(KProcess *)),
TQT_SLOT(hackExited(KProcess *)));
@@ -270,7 +270,7 @@ LockProcess::LockProcess(bool child, bool useBlankOnly)
if (mDPMSDepend) {
BOOL on;
CARD16 state;
- DPMSInfo(qt_xdisplay(), &state, &on);
+ DPMSInfo(tqt_xdisplay(), &state, &on);
if (on)
{
connect(&mCheckDPMS, TQT_SIGNAL(timeout()), TQT_SLOT(checkDPMSActive()));
@@ -876,14 +876,14 @@ void LockProcess::createSaverWindow()
// Some xscreensaver hacks check for this property
const char *version = "KDE 2.0";
- XChangeProperty (qt_xdisplay(), winId(),
+ XChangeProperty (tqt_xdisplay(), winId(),
gXA_SCREENSAVER_VERSION, XA_STRING, 8, PropModeReplace,
(unsigned char *) version, strlen(version));
XSetWindowAttributes attr;
attr.event_mask = KeyPressMask | ButtonPressMask | PointerMotionMask |
VisibilityChangeMask | ExposureMask;
- XChangeWindowAttributes(qt_xdisplay(), winId(),
+ XChangeWindowAttributes(tqt_xdisplay(), winId(),
CWEventMask, &attr);
// erase();
@@ -905,7 +905,7 @@ void LockProcess::desktopResized()
// Get root window size
XWindowAttributes rootAttr;
- XGetWindowAttributes(qt_xdisplay(), RootWindow(qt_xdisplay(), qt_xscreen()), &rootAttr);
+ XGetWindowAttributes(tqt_xdisplay(), RootWindow(tqt_xdisplay(), tqt_xscreen()), &rootAttr);
mRootWidth = rootAttr.width;
mRootHeight = rootAttr.height;
@@ -958,14 +958,14 @@ void LockProcess::hideSaverWindow()
hide();
lower();
removeVRoot(winId());
- XDeleteProperty(qt_xdisplay(), winId(), gXA_SCREENSAVER_VERSION);
+ XDeleteProperty(tqt_xdisplay(), winId(), gXA_SCREENSAVER_VERSION);
if ( gVRoot ) {
unsigned long vroot_data[1] = { gVRootData };
- XChangeProperty(qt_xdisplay(), gVRoot, gXA_VROOT, XA_WINDOW, 32,
+ XChangeProperty(tqt_xdisplay(), gVRoot, gXA_VROOT, XA_WINDOW, 32,
PropModeReplace, (unsigned char *)vroot_data, 1);
gVRoot = 0;
}
- XSync(qt_xdisplay(), False);
+ XSync(tqt_xdisplay(), False);
}
//---------------------------------------------------------------------------
@@ -982,7 +982,7 @@ void LockProcess::saveVRoot()
{
Window rootReturn, parentReturn, *children;
unsigned int numChildren;
- Window root = RootWindowOfScreen(ScreenOfDisplay(qt_xdisplay(), qt_xscreen()));
+ Window root = RootWindowOfScreen(ScreenOfDisplay(tqt_xdisplay(), tqt_xscreen()));
gVRoot = 0;
gVRootData = 0;
@@ -990,7 +990,7 @@ void LockProcess::saveVRoot()
int (*oldHandler)(Display *, XErrorEvent *);
oldHandler = XSetErrorHandler(ignoreXError);
- if (XQueryTree(qt_xdisplay(), root, &rootReturn, &parentReturn,
+ if (XQueryTree(tqt_xdisplay(), root, &rootReturn, &parentReturn,
&children, &numChildren))
{
for (unsigned int i = 0; i < numChildren; i++)
@@ -1000,7 +1000,7 @@ void LockProcess::saveVRoot()
unsigned long nitems, bytesafter;
unsigned char *newRoot = 0;
- if ((XGetWindowProperty(qt_xdisplay(), children[i], gXA_VROOT, 0, 1,
+ if ((XGetWindowProperty(tqt_xdisplay(), children[i], gXA_VROOT, 0, 1,
False, XA_WINDOW, &actual_type, &actual_format, &nitems, &bytesafter,
&newRoot) == Success) && newRoot)
{
@@ -1029,14 +1029,14 @@ void LockProcess::setVRoot(Window win, Window vr)
if (gVRoot)
removeVRoot(gVRoot);
- unsigned long rw = RootWindowOfScreen(ScreenOfDisplay(qt_xdisplay(), qt_xscreen()));
+ unsigned long rw = RootWindowOfScreen(ScreenOfDisplay(tqt_xdisplay(), tqt_xscreen()));
unsigned long vroot_data[1] = { vr };
Window rootReturn, parentReturn, *children;
unsigned int numChildren;
Window top = win;
while (1) {
- XQueryTree(qt_xdisplay(), top , &rootReturn, &parentReturn,
+ XQueryTree(tqt_xdisplay(), top , &rootReturn, &parentReturn,
&children, &numChildren);
if (children)
XFree((char *)children);
@@ -1046,7 +1046,7 @@ void LockProcess::setVRoot(Window win, Window vr)
top = parentReturn;
}
- XChangeProperty(qt_xdisplay(), top, gXA_VROOT, XA_WINDOW, 32,
+ XChangeProperty(tqt_xdisplay(), top, gXA_VROOT, XA_WINDOW, 32,
PropModeReplace, (unsigned char *)vroot_data, 1);
}
@@ -1056,7 +1056,7 @@ void LockProcess::setVRoot(Window win, Window vr)
//
void LockProcess::removeVRoot(Window win)
{
- XDeleteProperty (qt_xdisplay(), win, gXA_VROOT);
+ XDeleteProperty (tqt_xdisplay(), win, gXA_VROOT);
}
//---------------------------------------------------------------------------
@@ -1065,7 +1065,7 @@ void LockProcess::removeVRoot(Window win)
//
bool LockProcess::grabKeyboard()
{
- int rv = XGrabKeyboard( qt_xdisplay(), TQApplication::desktop()->winId(),
+ int rv = XGrabKeyboard( tqt_xdisplay(), TQApplication::desktop()->winId(),
True, GrabModeAsync, GrabModeAsync, CurrentTime );
return (rv == GrabSuccess);
@@ -1080,7 +1080,7 @@ bool LockProcess::grabKeyboard()
//
bool LockProcess::grabMouse()
{
- int rv = XGrabPointer( qt_xdisplay(), TQApplication::desktop()->winId(),
+ int rv = XGrabPointer( tqt_xdisplay(), TQApplication::desktop()->winId(),
True, GRABEVENTS, GrabModeAsync, GrabModeAsync, None,
TQCursor(tqbusyCursor).handle(), CurrentTime );
@@ -1093,7 +1093,7 @@ bool LockProcess::grabMouse()
//
bool LockProcess::grabInput()
{
- XSync(qt_xdisplay(), False);
+ XSync(tqt_xdisplay(), False);
if (!grabKeyboard())
{
@@ -1110,7 +1110,7 @@ bool LockProcess::grabInput()
usleep(100000);
if (!grabMouse())
{
- XUngrabKeyboard(qt_xdisplay(), CurrentTime);
+ XUngrabKeyboard(tqt_xdisplay(), CurrentTime);
return false;
}
}
@@ -1127,8 +1127,8 @@ bool LockProcess::grabInput()
//
void LockProcess::ungrabInput()
{
- XUngrabKeyboard(qt_xdisplay(), CurrentTime);
- XUngrabPointer(qt_xdisplay(), CurrentTime);
+ XUngrabKeyboard(tqt_xdisplay(), CurrentTime);
+ XUngrabPointer(tqt_xdisplay(), CurrentTime);
unlockXF86();
}
@@ -1171,7 +1171,7 @@ bool LockProcess::startSaver()
show();
raise();
- XSync(qt_xdisplay(), False);
+ XSync(tqt_xdisplay(), False);
setVRoot( winId(), winId() );
if (!(trinity_desktop_lock_delay_screensaver_start && (trinity_desktop_lock_forced || trinity_desktop_lock_in_sec_dlg))) {
if (backingPixmap.isNull())
@@ -1551,7 +1551,7 @@ void LockProcess::resume( bool force )
}
if ((mSuspended) && (mHackProc.isRunning()))
{
- XForceScreenSaver(qt_xdisplay(), ScreenSaverReset );
+ XForceScreenSaver(tqt_xdisplay(), ScreenSaverReset );
bitBlt( this, 0, 0, &mSavedScreen );
TQApplication::syncX();
mHackProc.kill(SIGCONT);
@@ -1597,12 +1597,12 @@ bool LockProcess::checkPass()
mForceReject = false;
XWindowAttributes rootAttr;
- XGetWindowAttributes(qt_xdisplay(), RootWindow(qt_xdisplay(),
- qt_xscreen()), &rootAttr);
+ XGetWindowAttributes(tqt_xdisplay(), RootWindow(tqt_xdisplay(),
+ tqt_xscreen()), &rootAttr);
if(( rootAttr.your_event_mask & SubstructureNotifyMask ) == 0 )
{
kdWarning() << "ERROR: Something removed SubstructureNotifyMask from the root window!!!" << endl;
- XSelectInput( qt_xdisplay(), qt_xrootwin(),
+ XSelectInput( tqt_xdisplay(), tqt_xrootwin(),
SubstructureNotifyMask | rootAttr.your_event_mask );
}
@@ -1621,12 +1621,12 @@ static void fakeFocusIn( WId window )
// window, so that it will correctly show cursor in the dialog.
XEvent ev;
memset(&ev, 0, sizeof(ev));
- ev.xfocus.display = qt_xdisplay();
+ ev.xfocus.display = tqt_xdisplay();
ev.xfocus.type = FocusIn;
ev.xfocus.window = window;
ev.xfocus.mode = NotifyNormal;
ev.xfocus.detail = NotifyAncestor;
- XSendEvent( qt_xdisplay(), window, False, NoEventMask, &ev );
+ XSendEvent( tqt_xdisplay(), window, False, NoEventMask, &ev );
}
void LockProcess::resumeUnforced()
@@ -1646,7 +1646,7 @@ int LockProcess::execDialog( TQDialog *dlg )
if (mDialogs.isEmpty())
{
suspend();
- XChangeActivePointerGrab( qt_xdisplay(), GRABEVENTS,
+ XChangeActivePointerGrab( tqt_xdisplay(), GRABEVENTS,
TQCursor(tqarrowCursor).handle(), CurrentTime);
}
mDialogs.prepend( dlg );
@@ -1661,7 +1661,7 @@ int LockProcess::execDialog( TQDialog *dlg )
currentDialog = NULL;
mDialogs.remove( dlg );
if( mDialogs.isEmpty() ) {
- XChangeActivePointerGrab( qt_xdisplay(), GRABEVENTS,
+ XChangeActivePointerGrab( tqt_xdisplay(), GRABEVENTS,
TQCursor(tqbusyCursor).handle(), CurrentTime);
if (trinity_desktop_lock_use_system_modal_dialogs) {
// Slight delay before screensaver resume to allow the dialog window to fully disappear
@@ -1744,7 +1744,7 @@ void LockProcess::doFunctionKeyBroadcast() {
if ((!trinity_desktop_lock_use_system_modal_dialogs) && (!trinity_desktop_lock_use_sak)) {
mBusy=true;
TQTimer::singleShot(1000, this, TQT_SLOT(slotDeadTimePassed()));
- if (mkeyCode == XKeysymToKeycode(qt_xdisplay(), XF86XK_Display)) {
+ if (mkeyCode == XKeysymToKeycode(tqt_xdisplay(), XF86XK_Display)) {
while (mDialogControlLock == true) usleep(100000);
mDialogControlLock = true;
currentDialog->close(); // DO NOT use closeCurrentWindow() here!
@@ -1845,7 +1845,7 @@ bool LockProcess::x11Event(XEvent *event)
break;
case ConfigureNotify: // from SubstructureNotifyMask on the root window
- if(event->xconfigure.event == qt_xrootwin())
+ if(event->xconfigure.event == tqt_xrootwin())
stayOnTop();
for( TQValueList< VkbdWindow >::Iterator it = mVkbdWindows.begin();
it != mVkbdWindows.end();
@@ -1859,7 +1859,7 @@ bool LockProcess::x11Event(XEvent *event)
break;
case MapNotify: // from SubstructureNotifyMask on the root window
windowAdded( event->xmap.window, false );
- if( event->xmap.event == qt_xrootwin())
+ if( event->xmap.event == tqt_xrootwin())
stayOnTop();
break;
case DestroyNotify:
@@ -1903,9 +1903,9 @@ void LockProcess::stayOnTop()
// and no ConfigureNotify will be generated,
// thus avoiding possible infinite loops
if( !mVkbdWindows.isEmpty())
- XRaiseWindow( qt_xdisplay(), mVkbdWindows.first().id );
+ XRaiseWindow( tqt_xdisplay(), mVkbdWindows.first().id );
else
- XRaiseWindow( qt_xdisplay(), mDialogs.first()->winId()); // raise topmost
+ XRaiseWindow( tqt_xdisplay(), mDialogs.first()->winId()); // raise topmost
// and stack others below it
Window* stack = new Window[ mDialogs.count() + mVkbdWindows.count() + 1 ];
int count = 0;
@@ -1922,7 +1922,7 @@ void LockProcess::stayOnTop()
delete[] stack;
}
else
- XRaiseWindow(qt_xdisplay(), winId());
+ XRaiseWindow(tqt_xdisplay(), winId());
}
void LockProcess::checkDPMSActive()
@@ -1930,7 +1930,7 @@ void LockProcess::checkDPMSActive()
#ifdef HAVE_DPMS
BOOL on;
CARD16 state;
- DPMSInfo(qt_xdisplay(), &state, &on);
+ DPMSInfo(tqt_xdisplay(), &state, &on);
//kdDebug() << "checkDPMSActive " << on << " " << state << endl;
if (state == DPMSModeStandby || state == DPMSModeSuspend || state == DPMSModeOff)
{
@@ -1952,7 +1952,7 @@ void LockProcess::lockXF86()
if( can_do_xf86_lock == Unknown )
{
int major, minor;
- if( XF86MiscQueryVersion( qt_xdisplay(), &major, &minor )
+ if( XF86MiscQueryVersion( tqt_xdisplay(), &major, &minor )
&& major >= 0 && minor >= 5 )
can_do_xf86_lock = Yes;
else
@@ -1962,7 +1962,7 @@ void LockProcess::lockXF86()
return;
if( mRestoreXF86Lock )
return;
- if( XF86MiscSetGrabKeysState( qt_xdisplay(), False ) != MiscExtGrabStateSuccess )
+ if( XF86MiscSetGrabKeysState( tqt_xdisplay(), False ) != MiscExtGrabStateSuccess )
return;
// success
mRestoreXF86Lock = true;
@@ -1974,7 +1974,7 @@ void LockProcess::unlockXF86()
return;
if( !mRestoreXF86Lock )
return;
- XF86MiscSetGrabKeysState( qt_xdisplay(), True );
+ XF86MiscSetGrabKeysState( tqt_xdisplay(), True );
mRestoreXF86Lock = false;
}
#else
@@ -2059,13 +2059,13 @@ void LockProcess::windowAdded( WId w, bool managed )
if( managed ) {
// withdraw the window, wait for it to be withdrawn, reparent it directly
// to root at the right position
- XWithdrawWindow( qt_xdisplay(), w, qt_xscreen());
+ XWithdrawWindow( tqt_xdisplay(), w, tqt_xscreen());
for(;;) {
Atom type;
int format;
unsigned long length, after;
unsigned char *data;
- int r = XGetWindowProperty( qt_xdisplay(), w, qt_wm_state, 0, 2,
+ int r = XGetWindowProperty( tqt_xdisplay(), w, tqt_wm_state, 0, 2,
false, AnyPropertyType, &type, &format,
&length, &after, &data );
bool withdrawn = true;
@@ -2078,18 +2078,18 @@ void LockProcess::windowAdded( WId w, bool managed )
break;
}
}
- XSelectInput( qt_xdisplay(), w, StructureNotifyMask );
+ XSelectInput( tqt_xdisplay(), w, StructureNotifyMask );
XWindowAttributes attr_geom;
- if( !XGetWindowAttributes( qt_xdisplay(), w, &attr_geom ))
+ if( !XGetWindowAttributes( tqt_xdisplay(), w, &attr_geom ))
return;
- int x = XDisplayWidth( qt_xdisplay(), qt_xscreen()) - attr_geom.width;
- int y = XDisplayHeight( qt_xdisplay(), qt_xscreen()) - attr_geom.height;
+ int x = XDisplayWidth( tqt_xdisplay(), tqt_xscreen()) - attr_geom.width;
+ int y = XDisplayHeight( tqt_xdisplay(), tqt_xscreen()) - attr_geom.height;
if( managed ) {
XSetWindowAttributes attr;
attr.override_redirect = True;
- XChangeWindowAttributes( qt_xdisplay(), w, CWOverrideRedirect, &attr );
- XReparentWindow( qt_xdisplay(), w, qt_xrootwin(), x, y );
- XMapWindow( qt_xdisplay(), w );
+ XChangeWindowAttributes( tqt_xdisplay(), w, CWOverrideRedirect, &attr );
+ XReparentWindow( tqt_xdisplay(), w, tqt_xrootwin(), x, y );
+ XMapWindow( tqt_xdisplay(), w );
}
VkbdWindow data;
data.id = w;
@@ -2129,7 +2129,7 @@ bool LockProcess::forwardVkbdEvent( XEvent* event )
int root_x, root_y, x, y;
unsigned int mask;
for(;;) {
- if( !XQueryPointer( qt_xdisplay(), window, &root, &child, &root_x, &root_y, &x, &y, &mask ))
+ if( !XQueryPointer( tqt_xdisplay(), window, &root, &child, &root_x, &root_y, &x, &y, &mask ))
return false;
if( child == None )
break;
@@ -2151,7 +2151,7 @@ bool LockProcess::forwardVkbdEvent( XEvent* event )
}
event->xany.window = window;
sendVkbdFocusInOut( window, time );
- XSendEvent( qt_xdisplay(), window, False, 0, event );
+ XSendEvent( tqt_xdisplay(), window, False, 0, event );
return true;
}
}
@@ -2169,9 +2169,9 @@ void LockProcess::sendVkbdFocusInOut( WId window, Time t )
if( mVkbdLastEventWindow != None ) {
XEvent e;
e.xcrossing.type = LeaveNotify;
- e.xcrossing.display = qt_xdisplay();
+ e.xcrossing.display = tqt_xdisplay();
e.xcrossing.window = mVkbdLastEventWindow;
- e.xcrossing.root = qt_xrootwin();
+ e.xcrossing.root = tqt_xrootwin();
e.xcrossing.subwindow = None;
e.xcrossing.time = t;
e.xcrossing.x = 0;
@@ -2183,15 +2183,15 @@ void LockProcess::sendVkbdFocusInOut( WId window, Time t )
e.xcrossing.same_screen = True;
e.xcrossing.focus = False;
e.xcrossing.state = 0;
- XSendEvent( qt_xdisplay(), mVkbdLastEventWindow, False, 0, &e );
+ XSendEvent( tqt_xdisplay(), mVkbdLastEventWindow, False, 0, &e );
}
mVkbdLastEventWindow = window;
if( mVkbdLastEventWindow != None ) {
XEvent e;
e.xcrossing.type = EnterNotify;
- e.xcrossing.display = qt_xdisplay();
+ e.xcrossing.display = tqt_xdisplay();
e.xcrossing.window = mVkbdLastEventWindow;
- e.xcrossing.root = qt_xrootwin();
+ e.xcrossing.root = tqt_xrootwin();
e.xcrossing.subwindow = None;
e.xcrossing.time = t;
e.xcrossing.x = 0;
@@ -2203,7 +2203,7 @@ void LockProcess::sendVkbdFocusInOut( WId window, Time t )
e.xcrossing.same_screen = True;
e.xcrossing.focus = False;
e.xcrossing.state = 0;
- XSendEvent( qt_xdisplay(), mVkbdLastEventWindow, False, 0, &e );
+ XSendEvent( tqt_xdisplay(), mVkbdLastEventWindow, False, 0, &e );
}
}
@@ -2228,10 +2228,10 @@ void LockProcess::slotMouseActivity(XEvent *event)
// Clicked inside dialog; set focus
if (inFrame == TRUE) {
WId window = mDialogs.first()->winId();
- XSetInputFocus(qt_xdisplay(), window, RevertToParent, CurrentTime);
+ XSetInputFocus(tqt_xdisplay(), window, RevertToParent, CurrentTime);
fakeFocusIn(window);
// Why this needs to be repeated I have no idea...
- XSetInputFocus(qt_xdisplay(), window, RevertToParent, CurrentTime);
+ XSetInputFocus(tqt_xdisplay(), window, RevertToParent, CurrentTime);
fakeFocusIn(window);
}
@@ -2243,7 +2243,7 @@ void LockProcess::slotMouseActivity(XEvent *event)
m_dialogPrevY = oldPoint.y();
m_mousePrevX = be->x_root;
m_mousePrevY = be->y_root;
- XChangeActivePointerGrab( qt_xdisplay(), GRABEVENTS, TQCursor(tqsizeAllCursor).handle(), CurrentTime);
+ XChangeActivePointerGrab( tqt_xdisplay(), GRABEVENTS, TQCursor(tqsizeAllCursor).handle(), CurrentTime);
}
}
@@ -2263,7 +2263,7 @@ void LockProcess::slotMouseActivity(XEvent *event)
if (event->type == ButtonRelease) {
m_mouseDown = 0;
- XChangeActivePointerGrab( qt_xdisplay(), GRABEVENTS, TQCursor(tqarrowCursor).handle(), CurrentTime);
+ XChangeActivePointerGrab( tqt_xdisplay(), GRABEVENTS, TQCursor(tqarrowCursor).handle(), CurrentTime);
}
}
diff --git a/kdesktop/lock/querydlg.cc b/kdesktop/lock/querydlg.cc
index 5f50cbe25..401370b21 100644
--- a/kdesktop/lock/querydlg.cc
+++ b/kdesktop/lock/querydlg.cc
@@ -68,8 +68,8 @@ QueryDlg::QueryDlg(LockProcess *parent)
if (trinity_desktop_lock_use_system_modal_dialogs) {
// Signal that we do not want any window controls to be shown at all
Atom kde_wm_system_modal_notification;
- kde_wm_system_modal_notification = XInternAtom(qt_xdisplay(), "_KDE_WM_MODAL_SYS_NOTIFICATION", False);
- XChangeProperty(qt_xdisplay(), winId(), kde_wm_system_modal_notification, XA_INTEGER, 32, PropModeReplace, (unsigned char *) "TRUE", 1L);
+ kde_wm_system_modal_notification = XInternAtom(tqt_xdisplay(), "_KDE_WM_MODAL_SYS_NOTIFICATION", False);
+ XChangeProperty(tqt_xdisplay(), winId(), kde_wm_system_modal_notification, XA_INTEGER, 32, PropModeReplace, (unsigned char *) "TRUE", 1L);
}
setCaption(i18n("Information Needed"));
diff --git a/kdesktop/lock/sakdlg.cc b/kdesktop/lock/sakdlg.cc
index d96e0afc3..a79d0e508 100644
--- a/kdesktop/lock/sakdlg.cc
+++ b/kdesktop/lock/sakdlg.cc
@@ -70,8 +70,8 @@ SAKDlg::SAKDlg(LockProcess *parent)
if (trinity_desktop_lock_use_system_modal_dialogs) {
// Signal that we do not want any window controls to be shown at all
Atom kde_wm_system_modal_notification;
- kde_wm_system_modal_notification = XInternAtom(qt_xdisplay(), "_KDE_WM_MODAL_SYS_NOTIFICATION", False);
- XChangeProperty(qt_xdisplay(), winId(), kde_wm_system_modal_notification, XA_INTEGER, 32, PropModeReplace, (unsigned char *) "TRUE", 1L);
+ kde_wm_system_modal_notification = XInternAtom(tqt_xdisplay(), "_KDE_WM_MODAL_SYS_NOTIFICATION", False);
+ XChangeProperty(tqt_xdisplay(), winId(), kde_wm_system_modal_notification, XA_INTEGER, 32, PropModeReplace, (unsigned char *) "TRUE", 1L);
}
setCaption(i18n("Desktop Session Locked"));
diff --git a/kdesktop/lock/securedlg.cc b/kdesktop/lock/securedlg.cc
index 37524f762..7f203f0c0 100644
--- a/kdesktop/lock/securedlg.cc
+++ b/kdesktop/lock/securedlg.cc
@@ -70,8 +70,8 @@ SecureDlg::SecureDlg(LockProcess *parent)
if (trinity_desktop_lock_use_system_modal_dialogs) {
// Signal that we do not want any window controls to be shown at all
Atom kde_wm_system_modal_notification;
- kde_wm_system_modal_notification = XInternAtom(qt_xdisplay(), "_KDE_WM_MODAL_SYS_NOTIFICATION", False);
- XChangeProperty(qt_xdisplay(), winId(), kde_wm_system_modal_notification, XA_INTEGER, 32, PropModeReplace, (unsigned char *) "TRUE", 1L);
+ kde_wm_system_modal_notification = XInternAtom(tqt_xdisplay(), "_KDE_WM_MODAL_SYS_NOTIFICATION", False);
+ XChangeProperty(tqt_xdisplay(), winId(), kde_wm_system_modal_notification, XA_INTEGER, 32, PropModeReplace, (unsigned char *) "TRUE", 1L);
}
setCaption(i18n("Secure Desktop Area"));
diff --git a/kdesktop/lockeng.cc b/kdesktop/lockeng.cc
index 79d27dbcb..3abfd495d 100644
--- a/kdesktop/lockeng.cc
+++ b/kdesktop/lockeng.cc
@@ -62,7 +62,7 @@ SaverEngine::SaverEngine()
sigaction(SIGUSR1, &act, 0L);
// Save X screensaver parameters
- XGetScreenSaver(qt_xdisplay(), &mXTimeout, &mXInterval,
+ XGetScreenSaver(tqt_xdisplay(), &mXTimeout, &mXInterval,
&mXBlanking, &mXExposures);
mState = Waiting;
@@ -108,7 +108,7 @@ SaverEngine::~SaverEngine()
delete mXAutoLock;
// Restore X screensaver parameters
- XSetScreenSaver(qt_xdisplay(), mXTimeout, mXInterval, mXBlanking,
+ XSetScreenSaver(tqt_xdisplay(), mXTimeout, mXInterval, mXBlanking,
mXExposures);
}
@@ -208,7 +208,7 @@ bool SaverEngine::enable( bool e )
//mXAutoLock->changeCornerLockStatus( mLockCornerTopLeft, mLockCornerTopRight, mLockCornerBottomLeft, mLockCornerBottomRight);
// We'll handle blanking
- XSetScreenSaver(qt_xdisplay(), mTimeout + 10, mXInterval, PreferBlanking, mXExposures);
+ XSetScreenSaver(tqt_xdisplay(), mTimeout + 10, mXInterval, PreferBlanking, mXExposures);
kdDebug() << "XSetScreenSaver " << mTimeout + 10 << endl;
mXAutoLock->start();
@@ -223,8 +223,8 @@ bool SaverEngine::enable( bool e )
mXAutoLock = 0;
}
- XForceScreenSaver(qt_xdisplay(), ScreenSaverReset );
- XSetScreenSaver(qt_xdisplay(), 0, mXInterval, PreferBlanking, DontAllowExposures);
+ XForceScreenSaver(tqt_xdisplay(), ScreenSaverReset );
+ XSetScreenSaver(tqt_xdisplay(), 0, mXInterval, PreferBlanking, DontAllowExposures);
kdDebug(1204) << "Saver Engine disabled" << endl;
}
@@ -355,7 +355,7 @@ bool SaverEngine::startLockProcess( LockType lock_type )
}
mLockProcess.kill(SIGTTOU); // Start lock
- XSetScreenSaver(qt_xdisplay(), 0, mXInterval, PreferBlanking, mXExposures);
+ XSetScreenSaver(tqt_xdisplay(), 0, mXInterval, PreferBlanking, mXExposures);
mState = Preparing;
if (mXAutoLock)
@@ -388,8 +388,8 @@ void SaverEngine::stopLockProcess()
{
mXAutoLock->start();
}
- XForceScreenSaver(qt_xdisplay(), ScreenSaverReset );
- XSetScreenSaver(qt_xdisplay(), mTimeout + 10, mXInterval, PreferBlanking, mXExposures);
+ XForceScreenSaver(tqt_xdisplay(), ScreenSaverReset );
+ XSetScreenSaver(tqt_xdisplay(), mTimeout + 10, mXInterval, PreferBlanking, mXExposures);
}
processLockTransactions();
mState = Waiting;
@@ -457,8 +457,8 @@ void SaverEngine::lockProcessWaiting()
{
mXAutoLock->start();
}
- XForceScreenSaver(qt_xdisplay(), ScreenSaverReset );
- XSetScreenSaver(qt_xdisplay(), mTimeout + 10, mXInterval, PreferBlanking, mXExposures);
+ XForceScreenSaver(tqt_xdisplay(), ScreenSaverReset );
+ XSetScreenSaver(tqt_xdisplay(), mTimeout + 10, mXInterval, PreferBlanking, mXExposures);
}
processLockTransactions();
mState = Waiting;
@@ -471,8 +471,8 @@ void SaverEngine::lockProcessWaiting()
void SaverEngine::idleTimeout()
{
// disable X screensaver
- XForceScreenSaver(qt_xdisplay(), ScreenSaverReset );
- XSetScreenSaver(qt_xdisplay(), 0, mXInterval, PreferBlanking, DontAllowExposures);
+ XForceScreenSaver(tqt_xdisplay(), ScreenSaverReset );
+ XSetScreenSaver(tqt_xdisplay(), 0, mXInterval, PreferBlanking, DontAllowExposures);
mSAKProcess->kill(SIGTERM);
startLockProcess( DefaultLock );
}
diff --git a/kdesktop/minicli.cpp b/kdesktop/minicli.cpp
index d5350339d..51520b9e7 100644
--- a/kdesktop/minicli.cpp
+++ b/kdesktop/minicli.cpp
@@ -322,7 +322,7 @@ void Minicli::accept()
if ( lock )
{
TQCString appname( "kdesktop" );
- int kicker_screen_number = qt_xscreen();
+ int kicker_screen_number = tqt_xscreen();
if ( kicker_screen_number )
appname.sprintf("kdesktop-screen-%d", kicker_screen_number);
kapp->dcopClient()->send(appname, "KScreensaverIface", "lock()", TQString(""));
diff --git a/kdesktop/pixmapserver.cc b/kdesktop/pixmapserver.cc
index bc869d341..58389ae56 100644
--- a/kdesktop/pixmapserver.cc
+++ b/kdesktop/pixmapserver.cc
@@ -40,7 +40,7 @@ KPixmapServer::KPixmapServer()
: TQWidget(0L, "shpixmap comm window")
{
kapp->installX11EventFilter(this);
- pixmap = XInternAtom(qt_xdisplay(), "PIXMAP", false);
+ pixmap = XInternAtom(tqt_xdisplay(), "PIXMAP", false);
}
@@ -48,7 +48,7 @@ KPixmapServer::~KPixmapServer()
{
SelectionIterator it;
for (it=m_Selections.begin(); it!=m_Selections.end(); it++)
- XSetSelectionOwner(qt_xdisplay(), it.key(), None, CurrentTime);
+ XSetSelectionOwner(tqt_xdisplay(), it.key(), None, CurrentTime);
DataIterator it2;
for (it2=m_Data.begin(); it2!=m_Data.end(); it2++)
@@ -66,7 +66,7 @@ void KPixmapServer::add(TQString name, TQPixmap *pm, bool overwrite)
}
TQString str = TQString("KDESHPIXMAP:%1").arg(name);
- Atom sel = XInternAtom(qt_xdisplay(), str.latin1(), false);
+ Atom sel = XInternAtom(tqt_xdisplay(), str.latin1(), false);
KPixmapInode pi;
pi.handle = pm->handle();
pi.selection = sel;
@@ -88,7 +88,7 @@ void KPixmapServer::add(TQString name, TQPixmap *pm, bool overwrite)
} else
it.data().refcount++;
- XSetSelectionOwner(qt_xdisplay(), sel, winId(), CurrentTime);
+ XSetSelectionOwner(tqt_xdisplay(), sel, winId(), CurrentTime);
}
@@ -105,7 +105,7 @@ void KPixmapServer::remove(TQString name)
SelectionIterator it2 = m_Selections.find(pi.selection);
assert(it2 != m_Selections.end());
m_Selections.remove(it2);
- XSetSelectionOwner(qt_xdisplay(), pi.selection, None, CurrentTime);
+ XSetSelectionOwner(tqt_xdisplay(), pi.selection, None, CurrentTime);
// Decrease refcount on data
DataIterator it3 = m_Data.find(pi.handle);
@@ -135,7 +135,7 @@ void KPixmapServer::setOwner(TQString name)
if (it == m_Names.end())
return;
- XSetSelectionOwner(qt_xdisplay(), it.data().selection, winId(), CurrentTime);
+ XSetSelectionOwner(tqt_xdisplay(), it.data().selection, winId(), CurrentTime);
}
@@ -151,7 +151,7 @@ bool KPixmapServer::x11Event(XEvent *event)
// Build negative reply
XEvent reply;
reply.type = SelectionNotify;
- reply.xselection.display = qt_xdisplay();
+ reply.xselection.display = tqt_xdisplay();
reply.xselection.requestor = ev->requestor;
reply.xselection.selection = ev->selection;
reply.xselection.target = pixmap;
@@ -169,7 +169,7 @@ bool KPixmapServer::x11Event(XEvent *event)
if (ev->target != pixmap)
{
kdDebug(1204) << ID << "illegal target\n";
- XSendEvent(qt_xdisplay(), ev->requestor, false, 0, &reply);
+ XSendEvent(tqt_xdisplay(), ev->requestor, false, 0, &reply);
return true;
}
@@ -177,7 +177,7 @@ bool KPixmapServer::x11Event(XEvent *event)
if (m_Active.contains(ev->property))
{
kdDebug(1204) << ID << "selection is busy.\n";
- XSendEvent(qt_xdisplay(), ev->requestor, false, 0, &reply);
+ XSendEvent(tqt_xdisplay(), ev->requestor, false, 0, &reply);
return true;
}
@@ -186,25 +186,25 @@ bool KPixmapServer::x11Event(XEvent *event)
if (it2 == m_Data.end())
{
kdDebug(1204) << ID << "selection has been deleted.\n";
- XSendEvent(qt_xdisplay(), ev->requestor, false, 0, &reply);
+ XSendEvent(tqt_xdisplay(), ev->requestor, false, 0, &reply);
return true;
}
kdDebug(1204) << ID << "request for " << si.name << "\n";
// All OK: pass the pixmap handle.
- XChangeProperty(qt_xdisplay(), ev->requestor, ev->property, pixmap,
+ XChangeProperty(tqt_xdisplay(), ev->requestor, ev->property, pixmap,
32, PropModeReplace, (unsigned char *) &si.handle, 1);
it2.data().usecount++;
m_Active[ev->property] = si.handle;
// Request PropertyNotify events for the target window
// XXX: The target window better not be handled by us!
- XSelectInput(qt_xdisplay(), ev->requestor, PropertyChangeMask);
+ XSelectInput(tqt_xdisplay(), ev->requestor, PropertyChangeMask);
// Acknowledge to the client and return
reply.xselection.property = ev->property;
- XSendEvent(qt_xdisplay(), ev->requestor, false, 0, &reply);
+ XSendEvent(tqt_xdisplay(), ev->requestor, false, 0, &reply);
return true;
}
diff --git a/kdesktop/startupid.cpp b/kdesktop/startupid.cpp
index fdde3dbde..3bec0f9af 100644
--- a/kdesktop/startupid.cpp
+++ b/kdesktop/startupid.cpp
@@ -50,10 +50,10 @@ StartupId::StartupId( TQWidget* parent, const char* name )
hide(); // is TQWidget only because of x11Event()
if( kde_startup_status == StartupPre )
{
- kde_splash_progress = XInternAtom( qt_xdisplay(), "_KDE_SPLASH_PROGRESS", False );
+ kde_splash_progress = XInternAtom( tqt_xdisplay(), "_KDE_SPLASH_PROGRESS", False );
XWindowAttributes attrs;
- XGetWindowAttributes( qt_xdisplay(), qt_xrootwin(), &attrs);
- XSelectInput( qt_xdisplay(), qt_xrootwin(), attrs.your_event_mask | SubstructureNotifyMask);
+ XGetWindowAttributes( tqt_xdisplay(), tqt_xrootwin(), &attrs);
+ XSelectInput( tqt_xdisplay(), tqt_xrootwin(), attrs.your_event_mask | SubstructureNotifyMask);
kapp->installX11EventFilter( this );
}
connect( &update_timer, TQT_SIGNAL( timeout()), TQT_SLOT( update_startupid()));
@@ -119,7 +119,7 @@ void StartupId::gotRemoveStartup( const KStartupInfoId& id_P )
bool StartupId::x11Event( XEvent* e )
{
- if( e->type == ClientMessage && e->xclient.window == qt_xrootwin()
+ if( e->type == ClientMessage && e->xclient.window == tqt_xrootwin()
&& e->xclient.message_type == kde_splash_progress )
{
const char* s = e->xclient.data.b;
@@ -188,7 +188,7 @@ void StartupId::start_startupid( const TQString& icon_P )
startup_widget = new TQWidget( NULL, NULL, WX11BypassWM );
XSetWindowAttributes attr;
attr.save_under = True; // useful saveunder if possible to avoid redrawing
- XChangeWindowAttributes( qt_xdisplay(), startup_widget->winId(), CWSaveUnder, &attr );
+ XChangeWindowAttributes( tqt_xdisplay(), startup_widget->winId(), CWSaveUnder, &attr );
}
startup_widget->resize( icon_pixmap.width(), icon_pixmap.height());
if( blinking )
@@ -268,7 +268,7 @@ void StartupId::update_startupid()
int x, y;
int dummy3, dummy4;
unsigned int dummy5;
- if( !XQueryPointer( qt_xdisplay(), qt_xrootwin(), &dummy1, &dummy2, &x, &y, &dummy3, &dummy4, &dummy5 ))
+ if( !XQueryPointer( tqt_xdisplay(), tqt_xrootwin(), &dummy1, &dummy2, &x, &y, &dummy3, &dummy4, &dummy5 ))
{
startup_widget->hide();
update_timer.start( 100, true );
@@ -277,7 +277,7 @@ void StartupId::update_startupid()
TQPoint c_pos( x, y );
int cursor_size = 0;
#ifdef HAVE_XCURSOR
- cursor_size = XcursorGetDefaultSize( qt_xdisplay());
+ cursor_size = XcursorGetDefaultSize( tqt_xdisplay());
#endif
int X_DIFF;
if( cursor_size <= 16 )
@@ -293,7 +293,7 @@ void StartupId::update_startupid()
|| startup_widget->y() != c_pos.y() + Y_DIFF + yoffset )
startup_widget->move( c_pos.x() + X_DIFF, c_pos.y() + Y_DIFF + yoffset );
startup_widget->show();
- XRaiseWindow( qt_xdisplay(), startup_widget->winId());
+ XRaiseWindow( tqt_xdisplay(), startup_widget->winId());
update_timer.start( bouncing ? 30 : 100, true );
TQApplication::flushX();
}
diff --git a/kdesktop/xautolock.cc b/kdesktop/xautolock.cc
index b69325f17..a2e18a0cd 100644
--- a/kdesktop/xautolock.cc
+++ b/kdesktop/xautolock.cc
@@ -62,21 +62,21 @@ XAutoLock::XAutoLock()
xautolock_useMit = 0;
#ifdef HAVE_XIDLE
int dummy1;
- xautolock_useXidle = XidleQueryExtension( qt_xdisplay(), &dummy1, &dummy1 );
+ xautolock_useXidle = XidleQueryExtension( tqt_xdisplay(), &dummy1, &dummy1 );
#endif
#ifdef HAVE_XSCREENSAVER
int dummy2;
if( !xautolock_useXidle )
- xautolock_useMit = XScreenSaverQueryExtension( qt_xdisplay(), &dummy2, &dummy2 );
+ xautolock_useMit = XScreenSaverQueryExtension( tqt_xdisplay(), &dummy2, &dummy2 );
#endif
if( !xautolock_useXidle && !xautolock_useMit )
{
kapp->installX11EventFilter( this );
int (*oldHandler)(Display *, XErrorEvent *);
oldHandler = XSetErrorHandler(catchFalseAlarms);
- XSync(qt_xdisplay(), False );
- xautolock_initDiy( qt_xdisplay());
- XSync(qt_xdisplay(), False );
+ XSync(tqt_xdisplay(), False );
+ xautolock_initDiy( tqt_xdisplay());
+ XSync(tqt_xdisplay(), False );
XSetErrorHandler(oldHandler);
}
@@ -115,7 +115,7 @@ void XAutoLock::setDPMS(bool s)
#ifdef HAVE_DPMS
BOOL on;
CARD16 state;
- DPMSInfo( qt_xdisplay(), &state, &on );
+ DPMSInfo( tqt_xdisplay(), &state, &on );
if (!on)
s = false;
#endif
@@ -184,7 +184,7 @@ void XAutoLock::timerEvent(TQTimerEvent *ev)
int (*oldHandler)(Display *, XErrorEvent *) = NULL;
if( !xautolock_useXidle && !xautolock_useMit )
{ // only the diy way needs special X handler
- XSync( qt_xdisplay(), False );
+ XSync( tqt_xdisplay(), False );
oldHandler = XSetErrorHandler(catchFalseAlarms);
}
@@ -202,8 +202,8 @@ void XAutoLock::timerEvent(TQTimerEvent *ev)
mLastTimeout = now;
- xautolock_queryIdleTime( qt_xdisplay());
- xautolock_queryPointer( qt_xdisplay());
+ xautolock_queryIdleTime( tqt_xdisplay());
+ xautolock_queryPointer( tqt_xdisplay());
if( !xautolock_useXidle && !xautolock_useMit )
XSetErrorHandler(oldHandler);
@@ -220,7 +220,7 @@ void XAutoLock::timerEvent(TQTimerEvent *ev)
#ifdef HAVE_DPMS
BOOL on;
CARD16 state;
- DPMSInfo( qt_xdisplay(), &state, &on );
+ DPMSInfo( tqt_xdisplay(), &state, &on );
//kdDebug() << "DPMSInfo " << state << " " << on << endl;
// If DPMS is active, it makes XScreenSaverQueryInfo() report idle time
@@ -232,7 +232,7 @@ void XAutoLock::timerEvent(TQTimerEvent *ev)
if(!on && mDPMS) {
activate = false;
#ifdef HAVE_XSCREENSAVER
- XForceScreenSaver(qt_xdisplay(), ScreenSaverReset );
+ XForceScreenSaver(tqt_xdisplay(), ScreenSaverReset );
#endif
resetTrigger();
}
@@ -241,7 +241,7 @@ void XAutoLock::timerEvent(TQTimerEvent *ev)
#ifdef HAVE_XSCREENSAVER
static XScreenSaverInfo* mitInfo = 0;
if (!mitInfo) mitInfo = XScreenSaverAllocInfo ();
- if (XScreenSaverQueryInfo (qt_xdisplay(), DefaultRootWindow (qt_xdisplay()), mitInfo)) {
+ if (XScreenSaverQueryInfo (tqt_xdisplay(), DefaultRootWindow (tqt_xdisplay()), mitInfo)) {
//kdDebug() << "XScreenSaverQueryInfo " << mitInfo->state << " " << ScreenSaverDisabled << endl;
if (mitInfo->state == ScreenSaverDisabled)
activate = false;
@@ -265,7 +265,7 @@ bool XAutoLock::x11Event( XEvent* ev )
bool XAutoLock::ignoreWindow( WId w )
{
- if( w != qt_xrootwin() && TQWidget::find( w ))
+ if( w != tqt_xrootwin() && TQWidget::find( w ))
return true;
return false;
}
diff --git a/khotkeys/kcontrol/windowselector.cpp b/khotkeys/kcontrol/windowselector.cpp
index e2942201c..8e2c20113 100644
--- a/khotkeys/kcontrol/windowselector.cpp
+++ b/khotkeys/kcontrol/windowselector.cpp
@@ -57,12 +57,12 @@ WId WindowSelector::findRealWindow( WId w, int depth )
{
if( depth > 5 )
return None;
- static Atom wm_state = XInternAtom( qt_xdisplay(), "WM_STATE", False );
+ static Atom wm_state = XInternAtom( tqt_xdisplay(), "WM_STATE", False );
Atom type;
int format;
unsigned long nitems, after;
unsigned char* prop;
- if( XGetWindowProperty( qt_xdisplay(), w, wm_state, 0, 0, False, AnyPropertyType,
+ if( XGetWindowProperty( tqt_xdisplay(), w, wm_state, 0, 0, False, AnyPropertyType,
&type, &format, &nitems, &after, &prop ) == Success )
{
if( prop != NULL )
@@ -74,7 +74,7 @@ WId WindowSelector::findRealWindow( WId w, int depth )
Window* children;
unsigned int nchildren;
Window ret = None;
- if( XQueryTree( qt_xdisplay(), w, &root, &parent, &children, &nchildren ) != 0 )
+ if( XQueryTree( tqt_xdisplay(), w, &root, &parent, &children, &nchildren ) != 0 )
{
for( unsigned int i = 0;
i < nchildren && ret == None;
diff --git a/khotkeys/shared/actions.cpp b/khotkeys/shared/actions.cpp
index e37ef395f..cb13893ca 100644
--- a/khotkeys/shared/actions.cpp
+++ b/khotkeys/shared/actions.cpp
@@ -385,7 +385,7 @@ void Keyboard_input_action::execute()
if( key == "Enter" && KKey( key ).keyCodeQt() == 0 )
key = "Return";
keyboard_handler->send_macro_key( KKey( key ), w ); // the rest
- XFlush( qt_xdisplay());
+ XFlush( tqt_xdisplay());
}
TQString Keyboard_input_action::description() const
diff --git a/khotkeys/shared/gestures.cpp b/khotkeys/shared/gestures.cpp
index 60b1d93b4..f98c44e18 100644
--- a/khotkeys/shared/gestures.cpp
+++ b/khotkeys/shared/gestures.cpp
@@ -154,8 +154,8 @@ bool Gesture::x11Event( XEvent* ev_P )
if( gesture.isEmpty())
{
kdDebug( 1217 ) << "GESTURE: replay" << endl;
- XAllowEvents( qt_xdisplay(), AsyncPointer, CurrentTime );
- XUngrabPointer( qt_xdisplay(), CurrentTime );
+ XAllowEvents( tqt_xdisplay(), AsyncPointer, CurrentTime );
+ XUngrabPointer( tqt_xdisplay(), CurrentTime );
mouse_replay( true );
return true;
}
@@ -178,8 +178,8 @@ bool Gesture::x11Event( XEvent* ev_P )
void Gesture::stroke_timeout()
{
kdDebug( 1217 ) << "GESTURE: timeout" << endl;
- XAllowEvents( qt_xdisplay(), AsyncPointer, CurrentTime );
- XUngrabPointer( qt_xdisplay(), CurrentTime );
+ XAllowEvents( tqt_xdisplay(), AsyncPointer, CurrentTime );
+ XUngrabPointer( tqt_xdisplay(), CurrentTime );
mouse_replay( false );
recording = false;
}
@@ -215,7 +215,7 @@ void Gesture::grab_mouse( bool grab_P )
for( int i = 0;
i < 8;
++i )
- XGrabButton( qt_xdisplay(), button, mods[ i ], qt_xrootwin(), False,
+ XGrabButton( tqt_xdisplay(), button, mods[ i ], tqt_xrootwin(), False,
ButtonPressMask | ButtonReleaseMask | mask[ button ], GrabModeAsync, GrabModeAsync,
None, None );
bool err = handler.error( true );
@@ -224,7 +224,7 @@ void Gesture::grab_mouse( bool grab_P )
else
{
kdDebug( 1217 ) << "Gesture ungrab" << endl;
- XUngrabButton( qt_xdisplay(), button, AnyModifier, qt_xrootwin());
+ XUngrabButton( tqt_xdisplay(), button, AnyModifier, tqt_xrootwin());
}
}
diff --git a/khotkeys/shared/input.cpp b/khotkeys/shared/input.cpp
index 19536a5e9..10a52a554 100644
--- a/khotkeys/shared/input.cpp
+++ b/khotkeys/shared/input.cpp
@@ -169,7 +169,7 @@ static bool xtest()
xtest_inited = true;
int dummy1, dummy2, dummy3, dummy4;
xtest_available =
- ( XTestQueryExtension( qt_xdisplay(), &dummy1, &dummy2, &dummy3, &dummy4 ) == True );
+ ( XTestQueryExtension( tqt_xdisplay(), &dummy1, &dummy2, &dummy3, &dummy4 ) == True );
return xtest_available;
}
#endif
@@ -178,7 +178,7 @@ static bool xtest()
bool Kbd::send_macro_key( const KKey& key, Window window_P )
{
unsigned int keysym = KKeyNative( key ).sym();
- KeyCode x_keycode = XKeysymToKeycode( qt_xdisplay(), keysym );
+ KeyCode x_keycode = XKeysymToKeycode( tqt_xdisplay(), keysym );
if( x_keycode == NoSymbol )
return false;
unsigned int x_mod = KKeyNative( key ).mod();
@@ -186,8 +186,8 @@ bool Kbd::send_macro_key( const KKey& key, Window window_P )
if( xtest() && window_P == None )
{
// CHECKME tohle jeste potrebuje modifikatory
- bool ret = XTestFakeKeyEvent( qt_xdisplay(), x_keycode, True, CurrentTime );
- ret = ret && XTestFakeKeyEvent( qt_xdisplay(), x_keycode, False, CurrentTime );
+ bool ret = XTestFakeKeyEvent( tqt_xdisplay(), x_keycode, True, CurrentTime );
+ ret = ret && XTestFakeKeyEvent( tqt_xdisplay(), x_keycode, False, CurrentTime );
return ret;
}
#endif
@@ -197,9 +197,9 @@ bool Kbd::send_macro_key( const KKey& key, Window window_P )
window_P = InputFocus;
XEvent ev;
ev.type = KeyPress;
- ev.xkey.display = qt_xdisplay();
+ ev.xkey.display = tqt_xdisplay();
ev.xkey.window = window_P;
- ev.xkey.root = qt_xrootwin(); // I don't know whether these have to be set
+ ev.xkey.root = tqt_xrootwin(); // I don't know whether these have to be set
ev.xkey.subwindow = None; // to these values, but it seems to work, hmm
ev.xkey.time = CurrentTime;
ev.xkey.x = 0;
@@ -209,12 +209,12 @@ bool Kbd::send_macro_key( const KKey& key, Window window_P )
ev.xkey.keycode = x_keycode;
ev.xkey.state = x_mod;
ev.xkey.same_screen = True;
- bool ret = XSendEvent( qt_xdisplay(), window_P, True, KeyPressMask, &ev );
+ bool ret = XSendEvent( tqt_xdisplay(), window_P, True, KeyPressMask, &ev );
#if 1
ev.type = KeyRelease; // is this actually really needed ??
- ev.xkey.display = qt_xdisplay();
+ ev.xkey.display = tqt_xdisplay();
ev.xkey.window = window_P;
- ev.xkey.root = qt_xrootwin();
+ ev.xkey.root = tqt_xrootwin();
ev.xkey.subwindow = None;
ev.xkey.time = CurrentTime;
ev.xkey.x = 0;
@@ -224,11 +224,11 @@ bool Kbd::send_macro_key( const KKey& key, Window window_P )
ev.xkey.state = x_mod;
ev.xkey.keycode = x_keycode;
ev.xkey.same_screen = True;
- ret = ret && XSendEvent( qt_xdisplay(), window_P, True, KeyReleaseMask, &ev );
+ ret = ret && XSendEvent( tqt_xdisplay(), window_P, True, KeyReleaseMask, &ev );
#endif
// Qt's autorepeat compression is broken and can create "aab" from "aba"
// XSync() should create delay longer than Qt's max autorepeat interval
- XSync( qt_xdisplay(), False );
+ XSync( tqt_xdisplay(), False );
return ret;
}
@@ -239,9 +239,9 @@ bool Mouse::send_mouse_button( int button_P, bool release_P )
{
// CHECKME tohle jeste potrebuje modifikatory
// a asi i spravnou timestamp misto CurrentTime
- bool ret = XTestFakeButtonEvent( qt_xdisplay(), button_P, True, CurrentTime );
+ bool ret = XTestFakeButtonEvent( tqt_xdisplay(), button_P, True, CurrentTime );
if( release_P )
- ret = ret && XTestFakeButtonEvent( qt_xdisplay(), button_P, False, CurrentTime );
+ ret = ret && XTestFakeButtonEvent( tqt_xdisplay(), button_P, False, CurrentTime );
return ret;
}
#endif
diff --git a/khotkeys/shared/windows.cpp b/khotkeys/shared/windows.cpp
index bd77ba446..4b009ace3 100644
--- a/khotkeys/shared/windows.cpp
+++ b/khotkeys/shared/windows.cpp
@@ -30,7 +30,7 @@
#include <X11/Xlib.h>
#include <X11/Xutil.h>
-extern Atom qt_window_role;
+extern Atom tqt_window_role;
namespace KHotKeys
{
@@ -94,13 +94,13 @@ void Windows::window_changed_slot( WId window_P, unsigned int flags_P )
TQString Windows::get_window_role( WId id_P )
{
// TODO this is probably just a hack
- return KWin::readNameProperty( id_P, qt_window_role );
+ return KWin::readNameProperty( id_P, tqt_window_role );
}
TQString Windows::get_window_class( WId id_P )
{
XClassHint hints_ret;
- if( XGetClassHint( qt_xdisplay(), id_P, &hints_ret ) == 0 ) // 0 means error
+ if( XGetClassHint( tqt_xdisplay(), id_P, &hints_ret ) == 0 ) // 0 means error
return "";
TQString ret( hints_ret.res_name );
ret += ' ';
@@ -141,19 +141,19 @@ WId Windows::find_window( const Windowdef_list* window_P )
WId Windows::window_at_position( int x, int y )
{
Window child, dummy;
- Window parent = qt_xrootwin();
- Atom wm_state = XInternAtom( qt_xdisplay(), "WM_STATE", False );
+ Window parent = tqt_xrootwin();
+ Atom wm_state = XInternAtom( tqt_xdisplay(), "WM_STATE", False );
for( int i = 0;
i < 10;
++i )
{
int destx, desty;
// find child at that position
- if( !XTranslateCoordinates( qt_xdisplay(), parent, parent, x, y, &destx, &desty, &child )
+ if( !XTranslateCoordinates( tqt_xdisplay(), parent, parent, x, y, &destx, &desty, &child )
|| child == None )
return 0;
// and now transform coordinates to the child
- if( !XTranslateCoordinates( qt_xdisplay(), parent, child, x, y, &destx, &desty, &dummy ))
+ if( !XTranslateCoordinates( tqt_xdisplay(), parent, child, x, y, &destx, &desty, &dummy ))
return 0;
x = destx;
y = desty;
@@ -161,7 +161,7 @@ WId Windows::window_at_position( int x, int y )
int format;
unsigned long nitems, after;
unsigned char* prop;
- if( XGetWindowProperty( qt_xdisplay(), child, wm_state, 0, 0, False, AnyPropertyType,
+ if( XGetWindowProperty( tqt_xdisplay(), child, wm_state, 0, 0, False, AnyPropertyType,
&type, &format, &nitems, &after, &prop ) == Success )
{
if( prop != NULL )
diff --git a/kicker/applets/lockout/lockout.cpp b/kicker/applets/lockout/lockout.cpp
index 82aa51c87..daec7a98f 100644
--- a/kicker/applets/lockout/lockout.cpp
+++ b/kicker/applets/lockout/lockout.cpp
@@ -143,7 +143,7 @@ int Lockout::heightForWidth( int width ) const
void Lockout::lock()
{
TQCString appname( "kdesktop" );
- int kicker_screen_number = qt_xscreen();
+ int kicker_screen_number = tqt_xscreen();
if ( kicker_screen_number )
appname.sprintf("kdesktop-screen-%d", kicker_screen_number);
kapp->dcopClient()->send(appname, "KScreensaverIface", "lock()", TQString(""));
diff --git a/kicker/applets/menu/menuapplet.cpp b/kicker/applets/menu/menuapplet.cpp
index 0798c84b3..2b864e33a 100644
--- a/kicker/applets/menu/menuapplet.cpp
+++ b/kicker/applets/menu/menuapplet.cpp
@@ -107,7 +107,7 @@ Applet::~Applet()
void Applet::windowAdded( WId w_P )
{
- NETWinInfo info( qt_xdisplay(), w_P, qt_xrootwin(), NET::WMWindowType );
+ NETWinInfo info( tqt_xdisplay(), w_P, tqt_xrootwin(), NET::WMWindowType );
if( info.windowType( SUPPORTED_WINDOW_TYPES ) != NET::TopMenu )
return;
// kdDebug() << "embedding:" << w_P << endl;
@@ -115,7 +115,7 @@ void Applet::windowAdded( WId w_P )
if( transient_for == None )
return;
MenuEmbed* embed;
- if( transient_for == qt_xrootwin())
+ if( transient_for == tqt_xrootwin())
{
embed = new MenuEmbed( transient_for, true, this );
}
@@ -224,7 +224,7 @@ WId Applet::tryTransientFor( WId w_P )
if( info.state() & NET::Modal )
return None;
WId ret = KWin::transientFor( w_P );
- if( ret == qt_xrootwin())
+ if( ret == tqt_xrootwin())
ret = None;
return ret;
}
@@ -292,7 +292,7 @@ void Applet::setBackground()
void Applet::claimSelection()
{
assert( selection == NULL );
- selection = new KSelectionOwner( makeSelectionAtom(), DefaultScreen( qt_xdisplay()));
+ selection = new KSelectionOwner( makeSelectionAtom(), DefaultScreen( tqt_xdisplay()));
// force taking the selection, but don't kill previous owner
if( selection->claim( true, false ))
{
@@ -327,7 +327,7 @@ void Applet::lostSelection()
active_menu = NULL;
if( selection_watcher == NULL )
{
- selection_watcher = new KSelectionWatcher( makeSelectionAtom(), DefaultScreen( qt_xdisplay()));
+ selection_watcher = new KSelectionWatcher( makeSelectionAtom(), DefaultScreen( tqt_xdisplay()));
connect( selection_watcher, TQT_SIGNAL( lostOwner()), this, TQT_SLOT( claimSelection()));
}
delete module;
@@ -378,11 +378,11 @@ static
void initAtoms()
{
char nm[ 100 ];
- sprintf( nm, "_KDE_TOPMENU_OWNER_S%d", DefaultScreen( qt_xdisplay()));
+ sprintf( nm, "_KDE_TOPMENU_OWNER_S%d", DefaultScreen( tqt_xdisplay()));
char nm2[] = "_KDE_TOPMENU_MINSIZE";
char* names[ 2 ] = { nm, nm2 };
Atom atoms[ 2 ];
- XInternAtoms( qt_xdisplay(), names, 2, False, atoms );
+ XInternAtoms( tqt_xdisplay(), names, 2, False, atoms );
selection_atom = atoms[ 0 ];
msg_type_atom = atoms[ 1 ];
}
@@ -432,7 +432,7 @@ bool MenuEmbed::x11Event( XEvent* ev_P )
// int x, y;
// unsigned int w, h, d, b;
// Window root;
-// XGetGeometry( qt_xdisplay(), embeddedWinId(), &root, &x, &y, &w, &h, &b, &d );
+// XGetGeometry( tqt_xdisplay(), embeddedWinId(), &root, &x, &y, &w, &h, &b, &d );
// kdDebug() << "RES3:" << width() << ":" << height() << ":" << w << ":" << h << endl;
return true;
}
@@ -446,7 +446,7 @@ void MenuEmbed::sendSyntheticConfigureNotifyEvent()
XConfigureEvent c;
memset(&c, 0, sizeof(c));
c.type = ConfigureNotify;
- c.display = qt_xdisplay();
+ c.display = tqt_xdisplay();
c.send_event = True;
c.event = embeddedWinId();
c.window = winId();
@@ -457,7 +457,7 @@ void MenuEmbed::sendSyntheticConfigureNotifyEvent()
c.border_width = 0;
c.above = None;
c.override_redirect = 0;
- XSendEvent(qt_xdisplay(), c.event, true, StructureNotifyMask, (XEvent*)&c);
+ XSendEvent(tqt_xdisplay(), c.event, true, StructureNotifyMask, (XEvent*)&c);
}
}
@@ -470,7 +470,7 @@ void MenuEmbed::setMinimumSize( int w, int h )
{
// kdDebug() << "RES2:" << width() << ":" << height() << ":" << minimumWidth() << ":" << minimumHeight() << endl;
XEvent ev;
- ev.xclient.display = qt_xdisplay();
+ ev.xclient.display = tqt_xdisplay();
ev.xclient.type = ClientMessage;
ev.xclient.window = embeddedWinId();
assert( msg_type_atom != None );
@@ -481,7 +481,7 @@ void MenuEmbed::setMinimumSize( int w, int h )
ev.xclient.data.l[2] = minimumHeight();
ev.xclient.data.l[3] = 0;
ev.xclient.data.l[4] = 0;
- XSendEvent( qt_xdisplay(), embeddedWinId(), False, NoEventMask, &ev );
+ XSendEvent( tqt_xdisplay(), embeddedWinId(), False, NoEventMask, &ev );
}
}
diff --git a/kicker/applets/minipager/pagerapplet.cpp b/kicker/applets/minipager/pagerapplet.cpp
index f60f87f64..4379da6c0 100644
--- a/kicker/applets/minipager/pagerapplet.cpp
+++ b/kicker/applets/minipager/pagerapplet.cpp
@@ -364,7 +364,7 @@ void KMiniPager::updateDesktopLayout(int o, int x, int y)
y = 0;
if( m_desktopLayoutOwner == NULL )
{ // must own manager selection before setting global desktop layout
- int screen = DefaultScreen( qt_xdisplay());
+ int screen = DefaultScreen( tqt_xdisplay());
m_desktopLayoutOwner = new KSelectionOwner( TQString( "_NET_DESKTOP_LAYOUT_S%1" ).arg( screen ).latin1(),
screen, TQT_TQOBJECT(this) );
if( !m_desktopLayoutOwner->claim( false ))
@@ -375,7 +375,7 @@ void KMiniPager::updateDesktopLayout(int o, int x, int y)
}
}
NET::Orientation orient = o == Qt::Horizontal ? NET::OrientationHorizontal : NET::OrientationVertical;
- NETRootInfo i( qt_xdisplay(), 0 );
+ NETRootInfo i( tqt_xdisplay(), 0 );
i.setDesktopLayout( orient, x, y, NET::DesktopLayoutCornerTopLeft );
}
diff --git a/kicker/applets/minipager/pagerbutton.cpp b/kicker/applets/minipager/pagerbutton.cpp
index 1c1663366..b7a1590c5 100644
--- a/kicker/applets/minipager/pagerbutton.cpp
+++ b/kicker/applets/minipager/pagerbutton.cpp
@@ -220,7 +220,7 @@ void KMiniPagerButton::loadBgPixmap()
}
TQCString kdesktop_name;
- int screen_number = DefaultScreen(qt_xdisplay());
+ int screen_number = DefaultScreen(tqt_xdisplay());
if (screen_number == 0)
kdesktop_name = "kdesktop";
else
diff --git a/kicker/applets/swallow/swallow.cpp b/kicker/applets/swallow/swallow.cpp
index 03be831e3..21a36f35b 100644
--- a/kicker/applets/swallow/swallow.cpp
+++ b/kicker/applets/swallow/swallow.cpp
@@ -307,7 +307,7 @@ void SwallowApp::windowAdded(WId win)
{
// determine title of newly mapped window
XTextProperty nameProp;
- XGetWMName(qt_xdisplay(), win, &nameProp);
+ XGetWMName(tqt_xdisplay(), win, &nameProp);
char **names;
int count;
XTextPropertyToStringList(&nameProp, &names, &count);
@@ -328,7 +328,7 @@ void SwallowApp::windowAdded(WId win)
resize( r.width(), r.height() );
embed(win);
- XReparentWindow(qt_xdisplay(), win, winId(), 0, 0);
+ XReparentWindow(tqt_xdisplay(), win, winId(), 0, 0);
disconnect(SwallowApplet::winModule(), TQT_SIGNAL(windowAdded(WId)),
this, TQT_SLOT(windowAdded(WId)));
diff --git a/kicker/applets/systemtray/systemtrayapplet.cpp b/kicker/applets/systemtray/systemtrayapplet.cpp
index 3303135b3..0079ee9f4 100644
--- a/kicker/applets/systemtray/systemtrayapplet.cpp
+++ b/kicker/applets/systemtray/systemtrayapplet.cpp
@@ -145,10 +145,10 @@ void SystemTrayApplet::initialize()
this, TQT_SLOT( updateTrayWindows() ) );
TQCString screenstr;
- screenstr.setNum(qt_xscreen());
+ screenstr.setNum(tqt_xscreen());
TQCString trayatom = "_NET_SYSTEM_TRAY_S" + screenstr;
- Display *display = qt_xdisplay();
+ Display *display = tqt_xdisplay();
net_system_tray_selection = XInternAtom(display, trayatom, false);
net_system_tray_opcode = XInternAtom(display, "_NET_SYSTEM_TRAY_OPCODE", false);
@@ -159,7 +159,7 @@ void SystemTrayApplet::initialize()
winId(),
CurrentTime);
- WId root = qt_xrootwin();
+ WId root = tqt_xrootwin();
if (XGetSelectionOwner (display, net_system_tray_selection) == winId())
{
@@ -531,10 +531,10 @@ void SystemTrayApplet::embedWindow( WId w, bool kde_tray )
if (kde_tray)
{
- static Atom hack_atom = XInternAtom( qt_xdisplay(), "_KDE_SYSTEM_TRAY_EMBEDDING", False );
- XChangeProperty( qt_xdisplay(), w, hack_atom, hack_atom, 32, PropModeReplace, NULL, 0 );
+ static Atom hack_atom = XInternAtom( tqt_xdisplay(), "_KDE_SYSTEM_TRAY_EMBEDDING", False );
+ XChangeProperty( tqt_xdisplay(), w, hack_atom, hack_atom, 32, PropModeReplace, NULL, 0 );
emb->embed(w);
- XDeleteProperty( qt_xdisplay(), w, hack_atom );
+ XDeleteProperty( tqt_xdisplay(), w, hack_atom );
}
else
{
diff --git a/kicker/extensions/dockbar/dockbarextension.cpp b/kicker/extensions/dockbar/dockbarextension.cpp
index 2a4944c20..63944e710 100644
--- a/kicker/extensions/dockbar/dockbarextension.cpp
+++ b/kicker/extensions/dockbar/dockbarextension.cpp
@@ -97,14 +97,14 @@ void DockBarExtension::windowAdded(WId win)
int argc;
char **argv;
TQString command;
- if (XGetCommand(qt_xdisplay(), win, &argv, &argc)) {
+ if (XGetCommand(tqt_xdisplay(), win, &argv, &argc)) {
command = KShell::joinArgs(argv, argc);
XFreeStringList(argv);
}
// try to read wm hints
WId resIconwin = 0;
- XWMHints *wmhints = XGetWMHints(qt_xdisplay(), win);
+ XWMHints *wmhints = XGetWMHints(tqt_xdisplay(), win);
if (0 != wmhints) { // we managed to read wm hints
// read IconWindowHint
bool is_valid = false;
@@ -146,7 +146,7 @@ void DockBarExtension::windowAdded(WId win)
// try to read class hint
XClassHint hint;
TQString resClass, resName;
- if (XGetClassHint(qt_xdisplay(), win, &hint)) {
+ if (XGetClassHint(tqt_xdisplay(), win, &hint)) {
resName = hint.res_name;
resClass = hint.res_class;
}
@@ -158,7 +158,7 @@ void DockBarExtension::windowAdded(WId win)
which causes the double-launch bug (one instance from the twin
session, and one from the dockbar) bug when kde is restarted */
if (resIconwin != win) {
- XWithdrawWindow( qt_xdisplay(), win, qt_xscreen() );
+ XWithdrawWindow( tqt_xdisplay(), win, tqt_xscreen() );
while( KWin::windowInfo(win, NET::XAWMState).mappingState() != NET::Withdrawn );
}
diff --git a/kicker/extensions/dockbar/dockcontainer.cpp b/kicker/extensions/dockbar/dockcontainer.cpp
index f6ac6bd33..181884276 100644
--- a/kicker/extensions/dockbar/dockcontainer.cpp
+++ b/kicker/extensions/dockbar/dockcontainer.cpp
@@ -49,7 +49,7 @@ DockContainer::DockContainer( TQString command, TQWidget *parent,
_resName(resname),
_resClass(resclass)
{
- XSelectInput( qt_xdisplay(), winId(),
+ XSelectInput( tqt_xdisplay(), winId(),
KeyPressMask | KeyReleaseMask |
ButtonPressMask | ButtonReleaseMask |
KeymapStateMask |
@@ -79,21 +79,21 @@ void DockContainer::embed( WId id )
TQRect geom = KWin::windowInfo(id,NET::WMKDEFrameStrut).frameGeometry();
// does the same as KWM::prepareForSwallowing()
- XWithdrawWindow( qt_xdisplay(), id, qt_xscreen() );
+ XWithdrawWindow( tqt_xdisplay(), id, tqt_xscreen() );
while( KWin::windowInfo(id, NET::XAWMState).mappingState() != NET::Withdrawn );
- XReparentWindow( qt_xdisplay(), id, winId(), 0, 0 );
+ XReparentWindow( tqt_xdisplay(), id, winId(), 0, 0 );
// resize if window is bigger than frame
if( (geom.width() > width()) ||
(geom.height() > height()) )
- XResizeWindow( qt_xdisplay(), id, width(), height() );
+ XResizeWindow( tqt_xdisplay(), id, width(), height() );
else
- XMoveWindow(qt_xdisplay(), id,
+ XMoveWindow(tqt_xdisplay(), id,
(sz() - geom.width())/2 - border(),
(sz() - geom.height())/2 - border());
- XMapWindow( qt_xdisplay(), id );
- XUngrabButton( qt_xdisplay(), AnyButton, AnyModifier, winId() );
+ XMapWindow( tqt_xdisplay(), id );
+ XUngrabButton( tqt_xdisplay(), AnyButton, AnyModifier, winId() );
_embeddedWinId = id;
}
@@ -101,13 +101,13 @@ void DockContainer::embed( WId id )
void DockContainer::unembed()
{
if( _embeddedWinId )
- XReparentWindow( qt_xdisplay(), _embeddedWinId, qt_xrootwin(), 0, 0 );
+ XReparentWindow( tqt_xdisplay(), _embeddedWinId, tqt_xrootwin(), 0, 0 );
}
void DockContainer::kill()
{
if ( _embeddedWinId ) {
- XKillClient( qt_xdisplay(), _embeddedWinId );
+ XKillClient( tqt_xdisplay(), _embeddedWinId );
_embeddedWinId = 0; // in case the window does not exist anymore..
}
else emit embeddedWindowDestroyed(this); /* enable killing of empty windows.. */
diff --git a/kicker/kicker/core/container_extension.cpp b/kicker/kicker/core/container_extension.cpp
index 4679d9d31..87ed34267 100644
--- a/kicker/kicker/core/container_extension.cpp
+++ b/kicker/kicker/core/container_extension.cpp
@@ -292,7 +292,7 @@ TQSize ExtensionContainer::sizeHint(KPanelExtension::Position p, const TQSize &m
static bool isnetwm12_below()
{
- NETRootInfo info( qt_xdisplay(), NET::Supported );
+ NETRootInfo info( tqt_xdisplay(), NET::Supported );
return info.supportedProperties()[ NETRootInfo::STATES ] & NET::KeepBelow;
}
diff --git a/kicker/kicker/core/kmenubase.ui.h b/kicker/kicker/core/kmenubase.ui.h
index 492ae4aab..5d8f7f9c6 100644
--- a/kicker/kicker/core/kmenubase.ui.h
+++ b/kicker/kicker/core/kmenubase.ui.h
@@ -4,6 +4,6 @@ void KMenuBase::init()
{
XSetWindowAttributes attrs;
attrs.override_redirect = True;
- XChangeWindowAttributes( qt_xdisplay(), winId(), CWOverrideRedirect, &attrs );
+ XChangeWindowAttributes( tqt_xdisplay(), winId(), CWOverrideRedirect, &attrs );
setWFlags( (WFlags)TQt::WType_Popup );
}
diff --git a/kicker/kicker/core/showdesktop.cpp b/kicker/kicker/core/showdesktop.cpp
index e41ddb549..748850eee 100644
--- a/kicker/kicker/core/showdesktop.cpp
+++ b/kicker/kicker/core/showdesktop.cpp
@@ -45,7 +45,7 @@ ShowDesktop::ShowDesktop()
{
// This feature is implemented in KWin. Keep old code in Kicker for the case
// KDE is running with another WM without the feature.
- NETRootInfo i( qt_xdisplay(), NET::Supported );
+ NETRootInfo i( tqt_xdisplay(), NET::Supported );
m_wmSupport = i.isSupported( NET::WM2ShowingDesktop );
if( m_wmSupport )
{
@@ -67,7 +67,7 @@ void ShowDesktop::slotWindowAdded(WId w)
return;
}
- NETWinInfo inf(qt_xdisplay(), w, qt_xrootwin(),
+ NETWinInfo inf(tqt_xdisplay(), w, tqt_xrootwin(),
NET::XAWMState | NET::WMWindowType);
NET::WindowType windowType = inf.windowType(NET::AllTypesMask);
@@ -99,7 +99,7 @@ void ShowDesktop::slotWindowChanged(WId w, unsigned int dirty)
if (dirty & NET::XAWMState)
{
- NETWinInfo inf(qt_xdisplay(), w, qt_xrootwin(),
+ NETWinInfo inf(tqt_xdisplay(), w, tqt_xrootwin(),
NET::XAWMState | NET::WMWindowType);
NET::WindowType windowType = inf.windowType(NET::AllTypesMask);
@@ -123,7 +123,7 @@ void ShowDesktop::showDesktop( bool b )
if( m_wmSupport )
{
- NETRootInfo i( qt_xdisplay(), 0 );
+ NETRootInfo i( tqt_xdisplay(), 0 );
i.setShowingDesktop( b );
return;
}
@@ -140,7 +140,7 @@ void ShowDesktop::showDesktop( bool b )
{
WId w = *it;
- NETWinInfo info( qt_xdisplay(), w, qt_xrootwin(),
+ NETWinInfo info( tqt_xdisplay(), w, tqt_xrootwin(),
NET::XAWMState | NET::WMDesktop );
if (info.mappingState() == NET::Visible &&
diff --git a/kicker/kicker/ui/k_new_mnu.cpp b/kicker/kicker/ui/k_new_mnu.cpp
index 3d78f18ec..0ed6d03f7 100644
--- a/kicker/kicker/ui/k_new_mnu.cpp
+++ b/kicker/kicker/ui/k_new_mnu.cpp
@@ -1509,7 +1509,7 @@ void KMenu::searchAccept()
if ( lock )
{
TQCString appname( "kdesktop" );
- int kicker_screen_number = qt_xscreen();
+ int kicker_screen_number = tqt_xscreen();
if ( kicker_screen_number )
appname.sprintf("kdesktop-screen-%d", kicker_screen_number);
kapp->dcopClient()->send(appname, "KScreensaverIface", "lock()", TQString(""));
diff --git a/kicker/libkicker/kickertip.cpp b/kicker/libkicker/kickertip.cpp
index 490f5bbfe..351b59084 100644
--- a/kicker/libkicker/kickertip.cpp
+++ b/kicker/libkicker/kickertip.cpp
@@ -105,8 +105,8 @@ void KickerTip::display()
{
// prevent tips from showing when the active window is fullscreened
- NETRootInfo ri(qt_xdisplay(), NET::ActiveWindow);
- NETWinInfo wi(qt_xdisplay(), ri.activeWindow(), ri.rootWindow(), NET::WMState);
+ NETRootInfo ri(tqt_xdisplay(), NET::ActiveWindow);
+ NETWinInfo wi(tqt_xdisplay(), ri.activeWindow(), ri.rootWindow(), NET::WMState);
if (wi.state() & NET::FullScreen)
{
return;
diff --git a/kicker/proxy/appletproxy.cpp b/kicker/proxy/appletproxy.cpp
index b472356e1..e427cbe74 100644
--- a/kicker/proxy/appletproxy.cpp
+++ b/kicker/proxy/appletproxy.cpp
@@ -280,8 +280,8 @@ void AppletProxy::dock(const TQCString& callbackID)
// we use "call" to know whether it was sucessful
int screen_number = 0;
- if (qt_xdisplay())
- screen_number = DefaultScreen(qt_xdisplay());
+ if (tqt_xdisplay())
+ screen_number = DefaultScreen(tqt_xdisplay());
TQCString appname;
if (screen_number == 0)
appname = "kicker";
@@ -455,8 +455,8 @@ void AppletProxy::slotUpdateLayout()
TQByteArray data;
int screen_number = 0;
- if (qt_xdisplay())
- screen_number = DefaultScreen(qt_xdisplay());
+ if (tqt_xdisplay())
+ screen_number = DefaultScreen(tqt_xdisplay());
TQCString appname;
if (screen_number == 0)
appname = "kicker";
@@ -472,8 +472,8 @@ void AppletProxy::slotRequestFocus()
TQByteArray data;
int screen_number = 0;
- if (qt_xdisplay())
- screen_number = DefaultScreen(qt_xdisplay());
+ if (tqt_xdisplay())
+ screen_number = DefaultScreen(tqt_xdisplay());
TQCString appname;
if (screen_number == 0)
appname = "kicker";
@@ -486,8 +486,8 @@ void AppletProxy::slotRequestFocus()
void AppletProxy::slotApplicationRemoved(const TQCString& appId)
{
int screen_number = 0;
- if (qt_xdisplay())
- screen_number = DefaultScreen(qt_xdisplay());
+ if (tqt_xdisplay())
+ screen_number = DefaultScreen(tqt_xdisplay());
TQCString appname;
if (screen_number == 0)
appname = "kicker";
diff --git a/kicker/proxy/extensionproxy.cpp b/kicker/proxy/extensionproxy.cpp
index 48a64c612..0bce08e91 100644
--- a/kicker/proxy/extensionproxy.cpp
+++ b/kicker/proxy/extensionproxy.cpp
@@ -220,8 +220,8 @@ void ExtensionProxy::dock(const TQCString& callbackID)
// we use "call" to know whether it was sucessful
int screen_number = 0;
- if (qt_xdisplay())
- screen_number = DefaultScreen(qt_xdisplay());
+ if (tqt_xdisplay())
+ screen_number = DefaultScreen(tqt_xdisplay());
TQCString appname;
if (screen_number == 0)
appname = "kicker";
@@ -372,8 +372,8 @@ void ExtensionProxy::slotUpdateLayout()
TQByteArray data;
int screen_number = 0;
- if (qt_xdisplay())
- screen_number = DefaultScreen(qt_xdisplay());
+ if (tqt_xdisplay())
+ screen_number = DefaultScreen(tqt_xdisplay());
TQCString appname;
if (screen_number == 0)
appname = "kicker";
@@ -386,8 +386,8 @@ void ExtensionProxy::slotUpdateLayout()
void ExtensionProxy::slotApplicationRemoved(const TQCString& appId)
{
int screen_number = 0;
- if (qt_xdisplay())
- screen_number = DefaultScreen(qt_xdisplay());
+ if (tqt_xdisplay())
+ screen_number = DefaultScreen(tqt_xdisplay());
TQCString appname;
if (screen_number == 0)
appname = "kicker";
diff --git a/kicker/taskmanager/taskmanager.cpp b/kicker/taskmanager/taskmanager.cpp
index 6f84efae4..2ae85819c 100644
--- a/kicker/taskmanager/taskmanager.cpp
+++ b/kicker/taskmanager/taskmanager.cpp
@@ -263,7 +263,7 @@ Task::Ptr TaskManager::findTask(int desktop, const TQPoint& p)
void TaskManager::windowAdded(WId w )
{
- NETWinInfo info(qt_xdisplay(), w, qt_xrootwin(),
+ NETWinInfo info(tqt_xdisplay(), w, tqt_xrootwin(),
NET::WMWindowType | NET::WMPid | NET::WMState);
// ignore NET::Tool and other special window types
@@ -290,7 +290,7 @@ void TaskManager::windowAdded(WId w )
}
Window transient_for_tmp;
- if (XGetTransientForHint( qt_xdisplay(), (Window) w, &transient_for_tmp ))
+ if (XGetTransientForHint( tqt_xdisplay(), (Window) w, &transient_for_tmp ))
{
WId transient_for = (WId) transient_for_tmp;
@@ -299,7 +299,7 @@ void TaskManager::windowAdded(WId w )
return;
// lets see if this is a transient for an existing task
- if( transient_for != qt_xrootwin()
+ if( transient_for != tqt_xrootwin()
&& transient_for != 0
&& wType != NET::Utility )
{
@@ -358,7 +358,7 @@ void TaskManager::windowChanged(WId w, unsigned int dirty)
{
if (dirty & NET::WMState)
{
- NETWinInfo info (qt_xdisplay(), w, qt_xrootwin(),
+ NETWinInfo info (tqt_xdisplay(), w, tqt_xrootwin(),
NET::WMState | NET::XAWMState);
if (info.state() & NET::SkipTaskbar)
{
@@ -828,7 +828,7 @@ void Task::updateDemandsAttentionState( WId w )
if (window() != w)
{
// 'w' is a transient for this task
- NETWinInfo i( qt_xdisplay(), w, qt_xrootwin(), NET::WMState );
+ NETWinInfo i( tqt_xdisplay(), w, tqt_xrootwin(), NET::WMState );
if(i.state() & NET::DemandsAttention)
{
if (!_transients_demanding_attention.contains(w))
@@ -862,7 +862,7 @@ void Task::removeTransient(WId w)
TQString Task::className()
{
XClassHint hint;
- if(XGetClassHint(qt_xdisplay(), _win, &hint)) {
+ if(XGetClassHint(tqt_xdisplay(), _win, &hint)) {
TQString nh( hint.res_name );
XFree( hint.res_name );
XFree( hint.res_class );
@@ -874,7 +874,7 @@ TQString Task::className()
TQString Task::classClass()
{
XClassHint hint;
- if(XGetClassHint(qt_xdisplay(), _win, &hint)) {
+ if(XGetClassHint(tqt_xdisplay(), _win, &hint)) {
TQString ch( hint.res_class );
XFree( hint.res_name );
XFree( hint.res_class );
@@ -1012,7 +1012,7 @@ void Task::move()
TQRect geom = _info.geometry();
TQCursor::setPos(geom.center());
- NETRootInfo ri(qt_xdisplay(), NET::WMMoveResize);
+ NETRootInfo ri(tqt_xdisplay(), NET::WMMoveResize);
ri.moveResizeRequest(_win, geom.center().x(),
geom.center().y(), NET::Move);
}
@@ -1035,7 +1035,7 @@ void Task::resize()
TQRect geom = _info.geometry();
TQCursor::setPos(geom.bottomRight());
- NETRootInfo ri(qt_xdisplay(), NET::WMMoveResize);
+ NETRootInfo ri(tqt_xdisplay(), NET::WMMoveResize);
ri.moveResizeRequest(_win, geom.bottomRight().x(),
geom.bottomRight().y(), NET::BottomRight);
}
@@ -1055,7 +1055,7 @@ void Task::setMaximized(bool maximize)
KWin::deIconifyWindow(_win);
}
- NETWinInfo ni(qt_xdisplay(), _win, qt_xrootwin(), NET::WMState);
+ NETWinInfo ni(tqt_xdisplay(), _win, tqt_xrootwin(), NET::WMState);
if (maximize)
{
@@ -1092,7 +1092,7 @@ void Task::restore()
KWin::deIconifyWindow(_win);
}
- NETWinInfo ni(qt_xdisplay(), _win, qt_xrootwin(), NET::WMState);
+ NETWinInfo ni(tqt_xdisplay(), _win, tqt_xrootwin(), NET::WMState);
ni.setState(0, NET::Max);
if (!on_current)
@@ -1133,7 +1133,7 @@ void Task::toggleIconified()
void Task::close()
{
- NETRootInfo ri( qt_xdisplay(), NET::CloseWindow );
+ NETRootInfo ri( tqt_xdisplay(), NET::CloseWindow );
ri.closeWindowRequest( _win );
}
@@ -1178,7 +1178,7 @@ void Task::activateRaiseOrIconify()
void Task::toDesktop(int desk)
{
- NETWinInfo ni(qt_xdisplay(), _win, qt_xrootwin(), NET::WMDesktop);
+ NETWinInfo ni(tqt_xdisplay(), _win, tqt_xrootwin(), NET::WMDesktop);
if (desk == 0)
{
if (_info.valid() && _info.onAllDesktops())
@@ -1205,7 +1205,7 @@ void Task::toCurrentDesktop()
void Task::setAlwaysOnTop(bool stay)
{
- NETWinInfo ni( qt_xdisplay(), _win, qt_xrootwin(), NET::WMState);
+ NETWinInfo ni( tqt_xdisplay(), _win, tqt_xrootwin(), NET::WMState);
if(stay)
ni.setState( NET::StaysOnTop, NET::StaysOnTop );
else
@@ -1219,7 +1219,7 @@ void Task::toggleAlwaysOnTop()
void Task::setKeptBelowOthers(bool below)
{
- NETWinInfo ni(qt_xdisplay(), _win, qt_xrootwin(), NET::WMState);
+ NETWinInfo ni(tqt_xdisplay(), _win, tqt_xrootwin(), NET::WMState);
if (below)
{
@@ -1238,7 +1238,7 @@ void Task::toggleKeptBelowOthers()
void Task::setFullScreen(bool fullscreen)
{
- NETWinInfo ni(qt_xdisplay(), _win, qt_xrootwin(), NET::WMState);
+ NETWinInfo ni(tqt_xdisplay(), _win, tqt_xrootwin(), NET::WMState);
if (fullscreen)
{
@@ -1257,7 +1257,7 @@ void Task::toggleFullScreen()
void Task::setShaded(bool shade)
{
- NETWinInfo ni( qt_xdisplay(), _win, qt_xrootwin(), NET::WMState);
+ NETWinInfo ni( tqt_xdisplay(), _win, tqt_xrootwin(), NET::WMState);
if(shade)
ni.setState( NET::Shaded, NET::Shaded );
else
@@ -1277,7 +1277,7 @@ void Task::publishIconGeometry(TQRect rect)
}
m_iconGeometry = rect;
- NETWinInfo ni(qt_xdisplay(), _win, qt_xrootwin(), 0);
+ NETWinInfo ni(tqt_xdisplay(), _win, tqt_xrootwin(), 0);
NETRect r;
if (rect.isValid())
diff --git a/klipper/clipboardpoll.cpp b/klipper/clipboardpoll.cpp
index 2f7ce4ddb..75d901446 100644
--- a/klipper/clipboardpoll.cpp
+++ b/klipper/clipboardpoll.cpp
@@ -71,7 +71,7 @@ ClipboardPoll::ClipboardPoll( TQWidget* parent )
"KLIPPER_SELECTION_TIMESTAMP",
"KLIPPER_CLIPBOARD_TIMESTAMP" };
Atom atoms[ 6 ];
- XInternAtoms( qt_xdisplay(), const_cast< char** >( names ), 6, False, atoms );
+ XInternAtoms( tqt_xdisplay(), const_cast< char** >( names ), 6, False, atoms );
selection.sentinel_atom = atoms[ 0 ];
clipboard.sentinel_atom = atoms[ 1 ];
xa_clipboard = atoms[ 2 ];
@@ -82,13 +82,13 @@ ClipboardPoll::ClipboardPoll( TQWidget* parent )
kapp->installX11EventFilter( this );
#ifdef HAVE_XFIXES
int dummy;
- if( XFixesQueryExtension( qt_xdisplay(), &xfixes_event_base, &dummy ))
+ if( XFixesQueryExtension( tqt_xdisplay(), &xfixes_event_base, &dummy ))
{
- XFixesSelectSelectionInput( qt_xdisplay(), qt_xrootwin( 0 ), XA_PRIMARY,
+ XFixesSelectSelectionInput( tqt_xdisplay(), tqt_xrootwin( 0 ), XA_PRIMARY,
XFixesSetSelectionOwnerNotifyMask |
XFixesSelectionWindowDestroyNotifyMask |
XFixesSelectionClientCloseNotifyMask );
- XFixesSelectSelectionInput( qt_xdisplay(), qt_xrootwin( 0 ), xa_clipboard,
+ XFixesSelectSelectionInput( tqt_xdisplay(), tqt_xrootwin( 0 ), xa_clipboard,
XFixesSetSelectionOwnerNotifyMask |
XFixesSelectionWindowDestroyNotifyMask |
XFixesSelectionClientCloseNotifyMask );
@@ -116,11 +116,11 @@ void ClipboardPoll::initPolling()
selection.atom = XA_PRIMARY;
clipboard.atom = xa_clipboard;
selection.last_change = clipboard.last_change = GET_QT_X_TIME(); // don't trigger right after startup
- selection.last_owner = XGetSelectionOwner( qt_xdisplay(), XA_PRIMARY );
+ selection.last_owner = XGetSelectionOwner( tqt_xdisplay(), XA_PRIMARY );
#ifdef NOISY_KLIPPER_
kdDebug() << "(1) Setting last_owner for =" << "selection" << ":" << selection.last_owner << endl;
#endif
- clipboard.last_owner = XGetSelectionOwner( qt_xdisplay(), xa_clipboard );
+ clipboard.last_owner = XGetSelectionOwner( tqt_xdisplay(), xa_clipboard );
#ifdef NOISY_KLIPPER_
kdDebug() << "(2) Setting last_owner for =" << "clipboard" << ":" << clipboard.last_owner << endl;
#endif
@@ -193,7 +193,7 @@ void ClipboardPoll::updateQtOwnership( SelectionData& data )
unsigned long nitems;
unsigned long after;
unsigned char* prop = NULL;
- if( XGetWindowProperty( qt_xdisplay(), qt_xrootwin( 0 ), data.sentinel_atom, 0, 2, False,
+ if( XGetWindowProperty( tqt_xdisplay(), tqt_xrootwin( 0 ), data.sentinel_atom, 0, 2, False,
XA_WINDOW, &type, &format, &nitems, &after, &prop ) != Success
|| type != XA_WINDOW || format != 32 || nitems != 2 || prop == NULL )
{
@@ -207,7 +207,7 @@ void ClipboardPoll::updateQtOwnership( SelectionData& data )
}
Window owner = reinterpret_cast< long* >( prop )[ 0 ]; // [0] is new owner, [1] is previous
XFree( prop );
- Window current_owner = XGetSelectionOwner( qt_xdisplay(), data.atom );
+ Window current_owner = XGetSelectionOwner( tqt_xdisplay(), data.atom );
data.owner_is_qt = ( owner == current_owner );
#ifdef REALLY_NOISY_KLIPPER_
kdDebug() << "owner=" << owner << "; current_owner=" << current_owner << endl;
@@ -235,7 +235,7 @@ void ClipboardPoll::timeout()
bool ClipboardPoll::checkTimestamp( SelectionData& data )
{
- Window current_owner = XGetSelectionOwner( qt_xdisplay(), data.atom );
+ Window current_owner = XGetSelectionOwner( tqt_xdisplay(), data.atom );
bool signal = false;
updateQtOwnership( data );
if( data.owner_is_qt )
@@ -269,8 +269,8 @@ bool ClipboardPoll::checkTimestamp( SelectionData& data )
// We're already waiting for the timestamp of the last check
return false;
}
- XDeleteProperty( qt_xdisplay(), winId(), data.timestamp_atom );
- XConvertSelection( qt_xdisplay(), data.atom, xa_timestamp, data.timestamp_atom, winId(), GET_QT_X_TIME() );
+ XDeleteProperty( tqt_xdisplay(), winId(), data.timestamp_atom );
+ XConvertSelection( tqt_xdisplay(), data.atom, xa_timestamp, data.timestamp_atom, winId(), GET_QT_X_TIME() );
data.waiting_for_timestamp = true;
data.waiting_x_time = GET_QT_X_TIME();
#ifdef REALLY_NOISY_KLIPPER_
@@ -300,7 +300,7 @@ bool ClipboardPoll::changedTimestamp( SelectionData& data, const XEvent& ev )
unsigned long nitems;
unsigned long after;
unsigned char* prop = NULL;
- if( XGetWindowProperty( qt_xdisplay(), winId(), ev.xselection.property, 0, 1, False,
+ if( XGetWindowProperty( tqt_xdisplay(), winId(), ev.xselection.property, 0, 1, False,
AnyPropertyType, &type, &format, &nitems, &after, &prop ) != Success
|| format != 32 || nitems != 1 || prop == NULL )
{
diff --git a/klipper/toplevel.cpp b/klipper/toplevel.cpp
index 3c75502af..712745a86 100644
--- a/klipper/toplevel.cpp
+++ b/klipper/toplevel.cpp
@@ -118,7 +118,7 @@ private:
KlipperWidget* klipper;
};
-extern bool qt_qclipboard_bailout_hack;
+extern bool tqt_qclipboard_bailout_hack;
#if KDE_IS_VERSION( 15, 0, 0 )
#error Check status of #80072 with Qt4.
#endif
@@ -135,7 +135,7 @@ KlipperWidget::KlipperWidget( TQWidget *parent, KConfig* config )
, m_pendingContentsCheck( false )
, session_managed( new KlipperSessionManaged( this ))
{
- qt_qclipboard_bailout_hack = true;
+ tqt_qclipboard_bailout_hack = true;
// We don't use the clipboardsynchronizer anymore, and it confuses Klipper
ensureGlobalSyncOff(m_config);
@@ -240,7 +240,7 @@ KlipperWidget::~KlipperWidget()
delete myURLGrabber;
if( m_config != kapp->config())
delete m_config;
- qt_qclipboard_bailout_hack = false;
+ tqt_qclipboard_bailout_hack = false;
}
void KlipperWidget::adjustSize()
@@ -1028,11 +1028,11 @@ bool KlipperWidget::ignoreClipboardChanges() const
return false;
}
-// TQClipboard uses qt_x_time as the timestamp for selection operations.
+// TQClipboard uses tqt_x_time as the timestamp for selection operations.
// It is updated mainly from user actions, but Klipper polls the clipboard
-// without any user action triggering it, so qt_x_time may be old,
+// without any user action triggering it, so tqt_x_time may be old,
// which could possibly lead to TQClipboard reporting empty clipboard.
-// Therefore, qt_x_time needs to be updated to current X server timestamp.
+// Therefore, tqt_x_time needs to be updated to current X server timestamp.
// Call KApplication::updateUserTime() only from functions that are
// called from outside (DCOP), or from TQTimer timeout !
@@ -1074,7 +1074,7 @@ static Bool update_x_time_predicate( Display*, XEvent* event, XPointer )
}
void KlipperWidget::updateTimestamp()
-{ // Qt3.3.0 and 3.3.1 use qt_x_user_time for clipboard operations
+{ // Qt3.3.0 and 3.3.1 use tqt_x_user_time for clipboard operations
Time time = ( strcmp( tqVersion(), "3.3.1" ) == 0
|| strcmp( tqVersion(), "3.3.0" ) == 0 )
? GET_QT_X_USER_TIME() : GET_QT_X_TIME();
@@ -1082,19 +1082,19 @@ void KlipperWidget::updateTimestamp()
if ( !w )
w = new TQWidget;
unsigned char data[ 1 ];
- XChangeProperty( qt_xdisplay(), w->winId(), XA_ATOM, XA_ATOM, 8, PropModeAppend, data, 1 );
+ XChangeProperty( tqt_xdisplay(), w->winId(), XA_ATOM, XA_ATOM, 8, PropModeAppend, data, 1 );
next_x_time = CurrentTime;
XEvent dummy;
- XCheckIfEvent( qt_xdisplay(), &dummy, update_x_time_predicate, NULL );
+ XCheckIfEvent( tqt_xdisplay(), &dummy, update_x_time_predicate, NULL );
if( next_x_time == CurrentTime )
{
- XSync( qt_xdisplay(), False );
- XCheckIfEvent( qt_xdisplay(), &dummy, update_x_time_predicate, NULL );
+ XSync( tqt_xdisplay(), False );
+ XCheckIfEvent( tqt_xdisplay(), &dummy, update_x_time_predicate, NULL );
}
Q_ASSERT( next_x_time != CurrentTime );
time = next_x_time;
XEvent ev; // remove the PropertyNotify event from the events queue
- XWindowEvent( qt_xdisplay(), w->winId(), PropertyChangeMask, &ev );
+ XWindowEvent( tqt_xdisplay(), w->winId(), PropertyChangeMask, &ev );
}
static const char * const description =
diff --git a/klipper/urlgrabber.cpp b/klipper/urlgrabber.cpp
index dfe5d80e5..7e2cc6bd4 100644
--- a/klipper/urlgrabber.cpp
+++ b/klipper/urlgrabber.cpp
@@ -334,7 +334,7 @@ void URLGrabber::writeConfiguration( KConfig *kc )
// digged a little bit in netwm.cpp
bool URLGrabber::isAvoidedWindow() const
{
- Display *d = qt_xdisplay();
+ Display *d = tqt_xdisplay();
static Atom wm_class = XInternAtom( d, "WM_CLASS", true );
static Atom active_window = XInternAtom( d, "_NET_ACTIVE_WINDOW", true );
Atom type_ret;
diff --git a/konqueror/KonquerorIface.cc b/konqueror/KonquerorIface.cc
index ce945d832..b726f759b 100644
--- a/konqueror/KonquerorIface.cc
+++ b/konqueror/KonquerorIface.cc
@@ -241,7 +241,7 @@ void KonquerorIface::comboCleared( TQCString objId )
bool KonquerorIface::processCanBeReused( int screen )
{
- if( qt_xscreen() != screen )
+ if( tqt_xscreen() != screen )
return false; // this instance run on different screen, and Qt apps can't migrate
if( KonqMainWindow::isPreloaded())
return false; // will be handled by preloading related code instead
diff --git a/konqueror/client/kfmclient.cc b/konqueror/client/kfmclient.cc
index 99a4a82a1..e2d07c0dd 100644
--- a/konqueror/client/kfmclient.cc
+++ b/konqueror/client/kfmclient.cc
@@ -232,8 +232,8 @@ static bool startNewKonqueror( TQString url, TQString mimetype, const TQString&
static int currentScreen()
{
- if( qt_xdisplay() != NULL )
- return qt_xscreen();
+ if( tqt_xdisplay() != NULL )
+ return tqt_xscreen();
// case when there's no KApplication instance
const char* env = getenv( "DISPLAY" );
if( env == NULL )
@@ -286,12 +286,12 @@ void clientApp::sendASNChange()
KStartupInfoData data;
data.addPid( 0 ); // say there's another process for this ASN with unknown PID
data.setHostname(); // ( no need to bother to get this konqy's PID )
- Display* dpy = qt_xdisplay();
+ Display* dpy = tqt_xdisplay();
if( dpy == NULL ) // we may be running without TQApplication here
dpy = XOpenDisplay( NULL );
if( dpy != NULL )
KStartupInfo::sendChangeX( dpy, id, data );
- if( dpy != NULL && dpy != qt_xdisplay())
+ if( dpy != NULL && dpy != tqt_xdisplay())
XCloseDisplay( dpy );
}
diff --git a/konqueror/konq_main.cc b/konqueror/konq_main.cc
index 3f3e47bc3..6e98bf104 100644
--- a/konqueror/konq_main.cc
+++ b/konqueror/konq_main.cc
@@ -133,7 +133,7 @@ extern "C" KDE_EXPORT int kdemain( int argc, char **argv )
{
DCOPRef ref( "kded", "konqy_preloader" );
if( !ref.callExt( "registerPreloadedKonqy", DCOPRef::NoEventLoop, 5000,
- app.dcopClient()->appId(), qt_xscreen()))
+ app.dcopClient()->appId(), tqt_xscreen()))
return 0; // too many preloaded or failed
KonqMainWindow* win = new KonqMainWindow( KURL(), false ); // prepare an empty window too
// KonqMainWindow ctor sets always the preloaded flag to false, so create the window before this
diff --git a/konqueror/konq_mainwindow.cc b/konqueror/konq_mainwindow.cc
index e0196ee06..f6f4759e9 100644
--- a/konqueror/konq_mainwindow.cc
+++ b/konqueror/konq_mainwindow.cc
@@ -1295,7 +1295,7 @@ void KonqMainWindow::slotCreateNewWindow( const KURL &url, const KParts::URLArgs
Time saved_last_input_time = GET_QT_X_USER_TIME();
if ( windowArgs.lowerWindow )
{
- NETRootInfo wm_info( qt_xdisplay(), NET::Supported );
+ NETRootInfo wm_info( tqt_xdisplay(), NET::Supported );
wm_usertime_support = wm_info.isSupported( NET::WM2UserTime );
if( wm_usertime_support )
{
@@ -5803,28 +5803,28 @@ void KonqMainWindow::resetWindow()
char data[ 1 ];
// empty append to get current X timestamp
TQWidget tmp_widget;
- XChangeProperty( qt_xdisplay(), tmp_widget.winId(), XA_WM_CLASS, XA_STRING, 8,
+ XChangeProperty( tqt_xdisplay(), tmp_widget.winId(), XA_WM_CLASS, XA_STRING, 8,
PropModeAppend, (unsigned char*) &data, 0 );
XEvent ev;
- XWindowEvent( qt_xdisplay(), tmp_widget.winId(), PropertyChangeMask, &ev );
+ XWindowEvent( tqt_xdisplay(), tmp_widget.winId(), PropertyChangeMask, &ev );
long x_time = ev.xproperty.time;
// bad hack - without updating the _KDE_NET_WM_USER_CREATION_TIME property,
// KWin will apply don't_steal_focus to this window, and will not make it active
// (shows mainly with 'konqueror --preload')
- static Atom atom = XInternAtom( qt_xdisplay(), "_KDE_NET_WM_USER_CREATION_TIME", False );
- XChangeProperty( qt_xdisplay(), winId(), atom, XA_CARDINAL, 32,
+ static Atom atom = XInternAtom( tqt_xdisplay(), "_KDE_NET_WM_USER_CREATION_TIME", False );
+ XChangeProperty( tqt_xdisplay(), winId(), atom, XA_CARDINAL, 32,
PropModeReplace, (unsigned char *) &x_time, 1);
SET_QT_X_USER_TIME(CurrentTime); // won't have _NET_WM_USER_TIME set
#if !KDE_IS_VERSION( 3, 2, 90 ) // _KDE_NET_USER_TIME is obsolete
- static Atom atom2 = XInternAtom( qt_xdisplay(), "_KDE_NET_USER_TIME", False );
+ static Atom atom2 = XInternAtom( tqt_xdisplay(), "_KDE_NET_USER_TIME", False );
timeval tv;
gettimeofday( &tv, NULL );
unsigned long now = tv.tv_sec * 10 + tv.tv_usec / 100000;
- XChangeProperty(qt_xdisplay(), winId(), atom2, XA_CARDINAL,
+ XChangeProperty(tqt_xdisplay(), winId(), atom2, XA_CARDINAL,
32, PropModeReplace, (unsigned char *)&now, 1);
#endif
- static Atom atom3 = XInternAtom( qt_xdisplay(), "_NET_WM_USER_TIME", False );
- XDeleteProperty( qt_xdisplay(), winId(), atom3 );
+ static Atom atom3 = XInternAtom( tqt_xdisplay(), "_NET_WM_USER_TIME", False );
+ XDeleteProperty( tqt_xdisplay(), winId(), atom3 );
// Qt remembers the iconic state if the window was withdrawn while on another virtual desktop
clearWState( WState_Minimized );
ignoreInitialGeometry();
@@ -5866,7 +5866,7 @@ bool KonqMainWindow::stayPreloaded()
return false;
DCOPRef ref( "kded", "konqy_preloader" );
if( !ref.callExt( "registerPreloadedKonqy", DCOPRef::NoEventLoop, 5000,
- kapp->dcopClient()->appId(), qt_xscreen()))
+ kapp->dcopClient()->appId(), tqt_xscreen()))
{
return false;
}
diff --git a/konsole/konsole/TEmuVt102.cpp b/konsole/konsole/TEmuVt102.cpp
index e8ee73b64..76772ab7f 100644
--- a/konsole/konsole/TEmuVt102.cpp
+++ b/konsole/konsole/TEmuVt102.cpp
@@ -1321,7 +1321,7 @@ static int xkb_init()
int xkb_lmaj = XkbMajorVersion;
int xkb_lmin = XkbMinorVersion;
return XkbLibraryVersion( &xkb_lmaj, &xkb_lmin )
- && XkbQueryExtension( qt_xdisplay(), &xkb_opcode, &xkb_event, &xkb_error,
+ && XkbQueryExtension( tqt_xdisplay(), &xkb_opcode, &xkb_event, &xkb_error,
&xkb_lmaj, &xkb_lmin );
}
@@ -1355,7 +1355,7 @@ static unsigned int xkb_mask_modifier( XkbDescPtr xkb, const char *name )
static unsigned int xkb_scrolllock_mask()
{
XkbDescPtr xkb;
- if(( xkb = XkbGetKeyboard( qt_xdisplay(), XkbAllComponentsMask, XkbUseCoreKbd )) != NULL )
+ if(( xkb = XkbGetKeyboard( tqt_xdisplay(), XkbAllComponentsMask, XkbUseCoreKbd )) != NULL )
{
unsigned int mask = xkb_mask_modifier( xkb, "ScrollLock" );
XkbFreeKeyboard( xkb, 0, True );
@@ -1368,8 +1368,8 @@ static unsigned int xkb_scrolllock_mask()
static unsigned int xkb_scrolllock_mask()
{
int scrolllock_mask = 0;
- XModifierKeymap* map = XGetModifierMapping( qt_xdisplay() );
- KeyCode scrolllock_keycode = XKeysymToKeycode( qt_xdisplay(), XK_Scroll_Lock );
+ XModifierKeymap* map = XGetModifierMapping( tqt_xdisplay() );
+ KeyCode scrolllock_keycode = XKeysymToKeycode( tqt_xdisplay(), XK_Scroll_Lock );
if( scrolllock_keycode == NoSymbol ) {
XFreeModifiermap(map);
return 0;
@@ -1400,7 +1400,7 @@ static int xkb_set_on()
if( scrolllock_mask == 0 )
return 0;
}
- XkbLockModifiers ( qt_xdisplay(), XkbUseCoreKbd, scrolllock_mask, scrolllock_mask);
+ XkbLockModifiers ( tqt_xdisplay(), XkbUseCoreKbd, scrolllock_mask, scrolllock_mask);
return 1;
}
@@ -1414,7 +1414,7 @@ static int xkb_set_off()
if( scrolllock_mask == 0 )
return 0;
}
- XkbLockModifiers ( qt_xdisplay(), XkbUseCoreKbd, scrolllock_mask, 0);
+ XkbLockModifiers ( tqt_xdisplay(), XkbUseCoreKbd, scrolllock_mask, 0);
return 1;
}
diff --git a/konsole/konsole/konsole.cpp b/konsole/konsole/konsole.cpp
index cb60e228e..87ad18e20 100644
--- a/konsole/konsole/konsole.cpp
+++ b/konsole/konsole/konsole.cpp
@@ -350,8 +350,8 @@ Konsole::Konsole(const char* name, int histon, bool menubaron, bool tabbaron, bo
// Signal that we want to be transparent to the desktop, not to windows behind us...
Atom kde_wm_transparent_to_desktop;
- kde_wm_transparent_to_desktop = XInternAtom(qt_xdisplay(), "_KDE_TRANSPARENT_TO_DESKTOP", False);
- XChangeProperty(qt_xdisplay(), winId(), kde_wm_transparent_to_desktop, XA_INTEGER, 32, PropModeReplace, (unsigned char *) "TRUE", 1L);
+ kde_wm_transparent_to_desktop = XInternAtom(tqt_xdisplay(), "_KDE_TRANSPARENT_TO_DESKTOP", False);
+ XChangeProperty(tqt_xdisplay(), winId(), kde_wm_transparent_to_desktop, XA_INTEGER, 32, PropModeReplace, (unsigned char *) "TRUE", 1L);
}
diff --git a/kpager/desktop.cpp b/kpager/desktop.cpp
index f155d7050..6af6d8daf 100644
--- a/kpager/desktop.cpp
+++ b/kpager/desktop.cpp
@@ -348,7 +348,7 @@ void Desktop::dropEvent(TQDropEvent *ev)
convertCoordP2S(x,y);
// kdDebug() << "moving window " << win << "d from " << origdesk << " to " << m_desk << endl;
-// NETWinInfo NETinfo( qt_xdisplay(), win, qt_xrootwin(), NET::Client | NET::WMDesktop);
+// NETWinInfo NETinfo( tqt_xdisplay(), win, tqt_xrootwin(), NET::Client | NET::WMDesktop);
if (m_desk==0)
{
diff --git a/kpager/kpager.cpp b/kpager/kpager.cpp
index 3d17ffaaf..3bce94fac 100644
--- a/kpager/kpager.cpp
+++ b/kpager/kpager.cpp
@@ -85,7 +85,7 @@ KPagerMainWindow::KPagerMainWindow(TQWidget *parent, const char *name)
move(xpos,ypos);
else
{
-// NETRootInfo ri( qt_xdisplay(), NET::WorkArea );
+// NETRootInfo ri( tqt_xdisplay(), NET::WorkArea );
// NETRect rect=ri.workArea(1);
// move(rect.pos.x+rect.size.width-m_pPager->width(),
// rect.pos.y+rect.size.height-m_pPager->height());
@@ -609,10 +609,10 @@ void KPager::clientPopupActivated( int id )
switch ( id ) {
case MaximizeOp:
if ( (m_winfo.state() & NET::Max) == 0 ) {
- NETWinInfo ni( qt_xdisplay(), m_winfo.win(), qt_xrootwin(), 0);
+ NETWinInfo ni( tqt_xdisplay(), m_winfo.win(), tqt_xrootwin(), 0);
ni.setState( NET::Max, NET::Max );
} else {
- NETWinInfo ni( qt_xdisplay(), m_winfo.win(), qt_xrootwin(), 0);
+ NETWinInfo ni( tqt_xdisplay(), m_winfo.win(), tqt_xrootwin(), 0);
ni.setState( 0, NET::Max );
}
break;
@@ -631,7 +631,7 @@ void KPager::clientPopupActivated( int id )
}
break;
case CloseOp: {
- NETRootInfo ri( qt_xdisplay(), 0 );
+ NETRootInfo ri( tqt_xdisplay(), 0 );
ri.closeWindowRequest( m_winfo.win() );
} break;
default:
diff --git a/krootbacking/krootbacking.cpp b/krootbacking/krootbacking.cpp
index 22c7bfc72..3d5872fb3 100644
--- a/krootbacking/krootbacking.cpp
+++ b/krootbacking/krootbacking.cpp
@@ -87,7 +87,7 @@ KRootBacking::~KRootBacking()
int KRootBacking::currentDesktop() const
{
#ifdef Q_WS_X11
- NETRootInfo rinfo( qt_xdisplay(), NET::CurrentDesktop );
+ NETRootInfo rinfo( tqt_xdisplay(), NET::CurrentDesktop );
rinfo.activate();
return rinfo.currentDesktop();
#endif
@@ -180,7 +180,7 @@ bool KRootBacking::isAvailable() const
TQString KRootBacking::pixmapName(int desk) {
TQString pattern = TQString("DESKTOP%1");
#ifdef Q_WS_X11
- int screen_number = DefaultScreen(qt_xdisplay());
+ int screen_number = DefaultScreen(tqt_xdisplay());
if (screen_number) {
pattern = TQString("SCREEN%1-DESKTOP").arg(screen_number) + "%1";
}
@@ -201,7 +201,7 @@ void KRootBacking::enableExports()
args << 1;
TQCString appname( "kdesktop" );
- int screen_number = DefaultScreen(qt_xdisplay());
+ int screen_number = DefaultScreen(tqt_xdisplay());
if ( screen_number )
appname.sprintf("kdesktop-screen-%d", screen_number );
diff --git a/kscreensaver/random.cpp b/kscreensaver/random.cpp
index cd984a145..d4b90b037 100644
--- a/kscreensaver/random.cpp
+++ b/kscreensaver/random.cpp
@@ -125,7 +125,7 @@ int main(int argc, char *argv[])
if (args->isSet("root"))
{
- windowId = RootWindow(qt_xdisplay(), qt_xscreen());
+ windowId = RootWindow(tqt_xdisplay(), tqt_xscreen());
}
KGlobal::dirs()->addResourceType("scrsav",
@@ -250,10 +250,10 @@ int main(int argc, char *argv[])
// If we end up here then we couldn't start a saver.
// If we have been supplied a window id or root window then blank it.
- Window win = windowId ? windowId : RootWindow(qt_xdisplay(), qt_xscreen());
- XSetWindowBackground(qt_xdisplay(), win,
- BlackPixel(qt_xdisplay(), qt_xscreen()));
- XClearWindow(qt_xdisplay(), win);
+ Window win = windowId ? windowId : RootWindow(tqt_xdisplay(), tqt_xscreen());
+ XSetWindowBackground(tqt_xdisplay(), win,
+ BlackPixel(tqt_xdisplay(), tqt_xscreen()));
+ XClearWindow(tqt_xdisplay(), win);
}
diff --git a/ksmserver/legacy.cpp b/ksmserver/legacy.cpp
index ec0ace402..ecef6423b 100644
--- a/ksmserver/legacy.cpp
+++ b/ksmserver/legacy.cpp
@@ -92,7 +92,7 @@ void KSMServer::performLegacySessionSave()
Atom atoms[ 3 ];
const char* const names[]
= { "WM_SAVE_YOURSELF", "WM_PROTOCOLS", "WM_CLIENT_LEADER" };
- XInternAtoms( qt_xdisplay(), const_cast< char** >( names ), 3,
+ XInternAtoms( tqt_xdisplay(), const_cast< char** >( names ), 3,
False, atoms );
wm_save_yourself = atoms[ 0 ];
wm_protocols = atoms[ 1 ];
@@ -105,7 +105,7 @@ void KSMServer::performLegacySessionSave()
SMType wtype = SM_WMCOMMAND;
int nprotocols = 0;
Atom *protocols = 0;
- if( XGetWMProtocols(qt_xdisplay(), leader, &protocols, &nprotocols)) {
+ if( XGetWMProtocols(tqt_xdisplay(), leader, &protocols, &nprotocols)) {
for (int i=0; i<nprotocols; i++)
if (protocols[i] == wm_save_yourself) {
wtype = SM_WMSAVEYOURSELF;
@@ -116,7 +116,7 @@ void KSMServer::performLegacySessionSave()
SMData data;
data.type = wtype;
XClassHint classHint;
- if( XGetClassHint( qt_xdisplay(), leader, &classHint ) ) {
+ if( XGetClassHint( tqt_xdisplay(), leader, &classHint ) ) {
data.wmclass1 = classHint.res_name;
data.wmclass2 = classHint.res_class;
XFree( classHint.res_name );
@@ -126,8 +126,8 @@ void KSMServer::performLegacySessionSave()
}
}
// Open fresh display for sending WM_SAVE_YOURSELF
- XSync(qt_xdisplay(), False);
- Display *newdisplay = XOpenDisplay(DisplayString(qt_xdisplay()));
+ XSync(tqt_xdisplay(), False);
+ Display *newdisplay = XOpenDisplay(DisplayString(tqt_xdisplay()));
if (!newdisplay) {
windowMapPtr = NULL;
XSetErrorHandler(oldHandler);
@@ -194,7 +194,7 @@ void KSMServer::performLegacySessionSave()
XSync(newdisplay, False);
XCloseDisplay(newdisplay);
// Restore old error handler
- XSync(qt_xdisplay(), False);
+ XSync(tqt_xdisplay(), False);
XSetErrorHandler(oldHandler);
for (WindowMap::Iterator it = legacyWindows.begin(); it != legacyWindows.end(); ++it) {
if ( (*it).type != SM_ERROR) {
@@ -288,7 +288,7 @@ static TQCString getQCStringProperty(WId w, Atom prop)
unsigned long extra = 0;
unsigned char *data = 0;
TQCString result = "";
- status = XGetWindowProperty( qt_xdisplay(), w, prop, 0, 10000,
+ status = XGetWindowProperty( tqt_xdisplay(), w, prop, 0, 10000,
FALSE, XA_STRING, &type, &format,
&nitems, &extra, &data );
if ( status == Success) {
@@ -308,7 +308,7 @@ static TQStringList getQStringListProperty(WId w, Atom prop)
unsigned char *data = 0;
TQStringList result;
- status = XGetWindowProperty( qt_xdisplay(), w, prop, 0, 10000,
+ status = XGetWindowProperty( tqt_xdisplay(), w, prop, 0, 10000,
FALSE, XA_STRING, &type, &format,
&nitems, &extra, &data );
if ( status == Success) {
@@ -374,7 +374,7 @@ WId KSMServer::windowWmClientLeader(WId w)
unsigned long extra = 0;
unsigned char *data = 0;
Window result = w;
- status = XGetWindowProperty( qt_xdisplay(), w, wm_client_leader, 0, 10000,
+ status = XGetWindowProperty( tqt_xdisplay(), w, wm_client_leader, 0, 10000,
FALSE, XA_WINDOW, &type, &format,
&nitems, &extra, &data );
if (status == Success ) {
@@ -390,11 +390,11 @@ WId KSMServer::windowWmClientLeader(WId w)
Returns sessionId for this client,
taken either from its window or from the leader window.
*/
-extern Atom qt_sm_client_id;
+extern Atom tqt_sm_client_id;
TQCString KSMServer::windowSessionId(WId w, WId leader)
{
- TQCString result = getQCStringProperty(w, qt_sm_client_id);
+ TQCString result = getQCStringProperty(w, tqt_sm_client_id);
if (result.isEmpty() && leader != (WId)None && leader != w)
- result = getQCStringProperty(leader, qt_sm_client_id);
+ result = getQCStringProperty(leader, tqt_sm_client_id);
return result;
}
diff --git a/ksmserver/main.cpp b/ksmserver/main.cpp
index b425cedc7..26b93dfd9 100644
--- a/ksmserver/main.cpp
+++ b/ksmserver/main.cpp
@@ -191,7 +191,7 @@ extern "C" KDE_EXPORT int kdemain( int argc, char* argv[] )
putenv((char*)"SESSION_MANAGER=");
KApplication a(KApplication::openX11RGBADisplay(), false); // Disable styles until we need them.
- fcntl(ConnectionNumber(qt_xdisplay()), F_SETFD, 1);
+ fcntl(ConnectionNumber(tqt_xdisplay()), F_SETFD, 1);
KCmdLineArgs *args = KCmdLineArgs::parsedArgs();
@@ -228,7 +228,7 @@ extern "C" KDE_EXPORT int kdemain( int argc, char* argv[] )
KConfig *config = KGlobal::config();
config->setGroup( "General" );
- int realScreenCount = ScreenCount( qt_xdisplay() );
+ int realScreenCount = ScreenCount( tqt_xdisplay() );
bool screenCountChanged =
( config->readNumEntry( "screenCount", realScreenCount ) != realScreenCount );
diff --git a/ksmserver/server.cpp b/ksmserver/server.cpp
index cacaabdfa..da6af4943 100644
--- a/ksmserver/server.cpp
+++ b/ksmserver/server.cpp
@@ -885,7 +885,7 @@ void KSMServer::storeSession()
config->writeEntry( "count", count );
config->setGroup("General");
- config->writeEntry( "screenCount", ScreenCount(qt_xdisplay()));
+ config->writeEntry( "screenCount", ScreenCount(tqt_xdisplay()));
storeLegacySession( config );
config->sync();
diff --git a/ksmserver/shutdowndlg.cpp b/ksmserver/shutdowndlg.cpp
index 9a7e4ef04..cf2985ade 100644
--- a/ksmserver/shutdowndlg.cpp
+++ b/ksmserver/shutdowndlg.cpp
@@ -95,7 +95,7 @@ KSMShutdownFeedback::KSMShutdownFeedback()
else {
// The hacks below aren't needed any more because Qt3 supports true transparency for the fading logout screen when composition is available
DCOPRef("kicker", "KMenu").call("hideMenu"); // Make sure the K Menu is completely removed from the screen before taking a snapshot...
- m_grayImage = TQPixmap(TQPixmap::grabWindow(qt_xrootwin(), 0, 0, TQApplication::desktop()->width(), TQApplication::desktop()->height())).convertToImage();
+ m_grayImage = TQPixmap(TQPixmap::grabWindow(tqt_xrootwin(), 0, 0, TQApplication::desktop()->width(), TQApplication::desktop()->height())).convertToImage();
}
m_unfadedImage = m_grayImage;
resize(0, 0);
@@ -500,13 +500,13 @@ void KSMShutdownFeedback::slotPaintEffect()
if ( m_currentY == 0 ) {
KPixmap pixmap;
- pixmap = TQPixmap(TQPixmap::grabWindow( qt_xrootwin(), 0, 0, width(), height() ));
+ pixmap = TQPixmap(TQPixmap::grabWindow( tqt_xrootwin(), 0, 0, width(), height() ));
bitBlt( this, 0, 0, &pixmap );
bitBlt( &m_root, 0, 0, &pixmap );
}
KPixmap pixmap;
- pixmap = TQPixmap(TQPixmap::grabWindow( qt_xrootwin(), 0, m_currentY, width(), 10 ));
+ pixmap = TQPixmap(TQPixmap::grabWindow( tqt_xrootwin(), 0, m_currentY, width(), 10 ));
TQImage image = pixmap.convertToImage();
KImageEffect::blend( Qt::black, image, 0.4 );
KImageEffect::toGray( image, true );
diff --git a/ksmserver/startup.cpp b/ksmserver/startup.cpp
index eaee5f20c..7ef0fcc5f 100644
--- a/ksmserver/startup.cpp
+++ b/ksmserver/startup.cpp
@@ -467,13 +467,13 @@ void KSMServer::upAndRunning( const TQString& msg )
DCOPRef( "ksplash" ).send( "upAndRunning", msg );
XEvent e;
e.xclient.type = ClientMessage;
- e.xclient.message_type = XInternAtom( qt_xdisplay(), "_KDE_SPLASH_PROGRESS", False );
- e.xclient.display = qt_xdisplay();
- e.xclient.window = qt_xrootwin();
+ e.xclient.message_type = XInternAtom( tqt_xdisplay(), "_KDE_SPLASH_PROGRESS", False );
+ e.xclient.display = tqt_xdisplay();
+ e.xclient.window = tqt_xrootwin();
e.xclient.format = 8;
assert( strlen( msg.latin1()) < 20 );
strcpy( e.xclient.data.b, msg.latin1());
- XSendEvent( qt_xdisplay(), qt_xrootwin(), False, SubstructureNotifyMask, &e );
+ XSendEvent( tqt_xdisplay(), tqt_xrootwin(), False, SubstructureNotifyMask, &e );
}
// these two are in the DCOP interface but I have no idea what uses them
diff --git a/ksplashml/themeengine/themeengine.cpp b/ksplashml/themeengine/themeengine.cpp
index f0e51c53c..cb3566588 100644
--- a/ksplashml/themeengine/themeengine.cpp
+++ b/ksplashml/themeengine/themeengine.cpp
@@ -48,9 +48,9 @@ ThemeEngine::ThemeEngine( TQWidget *, const char *, const TQStringList& args )
kapp->installEventFilter( this );
(void)kapp->desktop();
XWindowAttributes rootAttr;
- XGetWindowAttributes(qt_xdisplay(), RootWindow(qt_xdisplay(),
- qt_xscreen()), &rootAttr);
- XSelectInput( qt_xdisplay(), qt_xrootwin(),
+ XGetWindowAttributes(tqt_xdisplay(), RootWindow(tqt_xdisplay(),
+ tqt_xscreen()), &rootAttr);
+ XSelectInput( tqt_xdisplay(), tqt_xrootwin(),
SubstructureNotifyMask | rootAttr.your_event_mask );
if (args.isEmpty())
mTheme = new ObjKsTheme( "Default" );
@@ -98,7 +98,7 @@ void ThemeEngine::addSplashWindow( TQWidget* w )
static_cast< HackWidget* >( w )->setWFlags( WX11BypassWM );
XSetWindowAttributes attrs;
attrs.override_redirect = True;
- XChangeWindowAttributes( qt_xdisplay(), w->winId(), CWOverrideRedirect, &attrs );
+ XChangeWindowAttributes( tqt_xdisplay(), w->winId(), CWOverrideRedirect, &attrs );
}
d->mSplashWindows.prepend( w->winId());
connect( w, TQT_SIGNAL( destroyed( TQObject* )), TQT_SLOT( splashWindowDestroyed( TQObject* )));
@@ -114,9 +114,9 @@ bool ThemeEngine::x11Event( XEvent* e )
{
if( e->type != ConfigureNotify && e->type != MapNotify )
return false;
- if( e->type == ConfigureNotify && e->xconfigure.event != qt_xrootwin())
+ if( e->type == ConfigureNotify && e->xconfigure.event != tqt_xrootwin())
return false;
- if( e->type == MapNotify && e->xmap.event != qt_xrootwin())
+ if( e->type == MapNotify && e->xmap.event != tqt_xrootwin())
return false;
if( d->mSplashWindows.count() == 0 )
return false;
@@ -125,7 +125,7 @@ bool ThemeEngine::x11Event( XEvent* e )
// all restacking operations will be no-op,
// and no ConfigureNotify will be generated,
// thus avoiding possible infinite loops
- XRaiseWindow( qt_xdisplay(), d->mSplashWindows.first()); // raise topmost
+ XRaiseWindow( tqt_xdisplay(), d->mSplashWindows.first()); // raise topmost
// and stack others below it
Window* stack = new Window[ d->mSplashWindows.count() ];
int count = 0;
diff --git a/kstart/kstart.cpp b/kstart/kstart.cpp
index 411ba9a0f..16fc0bd96 100644
--- a/kstart/kstart.cpp
+++ b/kstart/kstart.cpp
@@ -48,7 +48,7 @@ static KWinModule* twinmodule;
KStart::KStart()
:TQObject()
{
- NETRootInfo i( qt_xdisplay(), NET::Supported );
+ NETRootInfo i( tqt_xdisplay(), NET::Supported );
bool useRule = !toSysTray && i.isSupported( NET::WM2KDETemporaryRules );
if( useRule )
@@ -151,7 +151,7 @@ void KStart::windowAdded(WId w){
}
if ( windowclass != 0 ) {
XClassHint hint;
- if( !XGetClassHint( qt_xdisplay(), w, &hint ))
+ if( !XGetClassHint( tqt_xdisplay(), w, &hint ))
return;
TQCString cls = windowclass.contains( ' ' )
? TQCString( hint.res_name ) + ' ' + hint.res_class : TQCString( hint.res_class );
@@ -173,14 +173,14 @@ void KStart::windowAdded(WId w){
}
-extern Atom qt_wm_state; // defined in qapplication_x11.cpp
+extern Atom tqt_wm_state; // defined in qapplication_x11.cpp
static bool wstate_withdrawn( WId winid )
{
Atom type;
int format;
unsigned long length, after;
unsigned char *data;
- int r = XGetWindowProperty( qt_xdisplay(), winid, qt_wm_state, 0, 2,
+ int r = XGetWindowProperty( tqt_xdisplay(), winid, tqt_wm_state, 0, 2,
FALSE, AnyPropertyType, &type, &format,
&length, &after, &data );
bool withdrawn = TRUE;
@@ -197,25 +197,25 @@ void KStart::applyStyle(WId w ) {
if ( toSysTray || state || iconify || windowtype != NET::Unknown || desktop >= 1 ) {
- XWithdrawWindow(qt_xdisplay(), w, qt_xscreen());
+ XWithdrawWindow(tqt_xdisplay(), w, tqt_xscreen());
TQApplication::flushX();
while ( !wstate_withdrawn(w) )
;
}
- NETWinInfo info( qt_xdisplay(), w, qt_xrootwin(), NET::WMState );
+ NETWinInfo info( tqt_xdisplay(), w, tqt_xrootwin(), NET::WMState );
if ( ( desktop > 0 && desktop <= twinmodule->numberOfDesktops() )
|| desktop == NETWinInfo::OnAllDesktops )
info.setDesktop( desktop );
if (iconify) {
- XWMHints * hints = XGetWMHints(qt_xdisplay(), w );
+ XWMHints * hints = XGetWMHints(tqt_xdisplay(), w );
if (hints ) {
hints->flags |= StateHint;
hints->initial_state = IconicState;
- XSetWMHints( qt_xdisplay(), w, hints );
+ XSetWMHints( tqt_xdisplay(), w, hints );
XFree(hints);
}
}
@@ -229,19 +229,19 @@ void KStart::applyStyle(WId w ) {
if ( toSysTray ) {
TQApplication::beep();
- KWin::setSystemTrayWindowFor( w, qt_xrootwin() );
+ KWin::setSystemTrayWindowFor( w, tqt_xrootwin() );
}
if ( fullscreen ) {
TQRect r = TQApplication::desktop()->geometry();
- XMoveResizeWindow( qt_xdisplay(), w, r.x(), r.y(), r.width(), r.height() );
+ XMoveResizeWindow( tqt_xdisplay(), w, r.x(), r.y(), r.width(), r.height() );
}
- XSync(qt_xdisplay(), False);
+ XSync(tqt_xdisplay(), False);
- XMapWindow(qt_xdisplay(), w );
- XSync(qt_xdisplay(), False);
+ XMapWindow(tqt_xdisplay(), w );
+ XSync(tqt_xdisplay(), False);
if (activate)
KWin::forceActiveWindow( w );
@@ -385,7 +385,7 @@ int main( int argc, char *argv[] )
iconify = args->isSet("iconify");
toSysTray = args->isSet("tosystray");
if ( args->isSet("fullscreen") ) {
- NETRootInfo i( qt_xdisplay(), NET::Supported );
+ NETRootInfo i( tqt_xdisplay(), NET::Supported );
if( i.isSupported( NET::FullScreen )) {
state |= NET::FullScreen;
mask |= NET::FullScreen;
@@ -395,7 +395,7 @@ int main( int argc, char *argv[] )
}
}
- fcntl(ConnectionNumber(qt_xdisplay()), F_SETFD, 1);
+ fcntl(ConnectionNumber(tqt_xdisplay()), F_SETFD, 1);
args->clear();
KStart start;
diff --git a/ksystraycmd/ksystraycmd.cpp b/ksystraycmd/ksystraycmd.cpp
index 9eb71db4f..8319ca2fd 100644
--- a/ksystraycmd/ksystraycmd.cpp
+++ b/ksystraycmd/ksystraycmd.cpp
@@ -81,9 +81,9 @@ void KSysTrayCmd::showWindow()
isVisible = true;
if ( !win )
return;
- XMapWindow( qt_xdisplay(), win );
+ XMapWindow( tqt_xdisplay(), win );
// We move the window to the memorized position
- XMoveWindow( qt_xdisplay(), win, left, top);
+ XMoveWindow( tqt_xdisplay(), win, left, top);
// Window always on top
if (onTop)
@@ -104,7 +104,7 @@ void KSysTrayCmd::hideWindow()
left = KWin::windowInfo(win).frameGeometry().left();
top=KWin::windowInfo(win).frameGeometry().top();
- XUnmapWindow( qt_xdisplay(), win );
+ XUnmapWindow( tqt_xdisplay(), win );
}
void KSysTrayCmd::setTargetWindow( WId w )
@@ -202,8 +202,8 @@ void KSysTrayCmd::quitClient()
{
if ( win ) {
// Before sending the close request we have to show the window
- XMapWindow( qt_xdisplay(), win );
- NETRootInfo ri( qt_xdisplay(), NET::CloseWindow );
+ XMapWindow( tqt_xdisplay(), win );
+ NETRootInfo ri( tqt_xdisplay(), NET::CloseWindow );
ri.closeWindowRequest( win );
win=0;
noquit = false;
@@ -251,7 +251,7 @@ void KSysTrayCmd::execContextMenu( const TQPoint &pos )
}
else if ( quitOnHide && ( hasRunningClient() ) && isVisible )
{
- NETRootInfo ri( qt_xdisplay(), NET::CloseWindow );
+ NETRootInfo ri( tqt_xdisplay(), NET::CloseWindow );
ri.closeWindowRequest( win );
isVisible=false;
}
@@ -301,7 +301,7 @@ void KSysTrayCmd::mousePressEvent( TQMouseEvent *e )
}
else if ( quitOnHide && ( hasRunningClient() ) && isVisible )
{
- NETRootInfo ri( qt_xdisplay(), NET::CloseWindow );
+ NETRootInfo ri( tqt_xdisplay(), NET::CloseWindow );
ri.closeWindowRequest( win );
isVisible=false;
}
@@ -313,12 +313,12 @@ WId KSysTrayCmd::findRealWindow( WId w, int depth )
{
if( depth > 5 )
return None;
- static Atom wm_state = XInternAtom( qt_xdisplay(), "WM_STATE", False );
+ static Atom wm_state = XInternAtom( tqt_xdisplay(), "WM_STATE", False );
Atom type;
int format;
unsigned long nitems, after;
unsigned char* prop;
- if( XGetWindowProperty( qt_xdisplay(), w, wm_state, 0, 0, False, AnyPropertyType,
+ if( XGetWindowProperty( tqt_xdisplay(), w, wm_state, 0, 0, False, AnyPropertyType,
&type, &format, &nitems, &after, &prop ) == Success ) {
if( prop != NULL )
XFree( prop );
@@ -329,7 +329,7 @@ WId KSysTrayCmd::findRealWindow( WId w, int depth )
Window* children;
unsigned int nchildren;
Window ret = None;
- if( XQueryTree( qt_xdisplay(), w, &root, &parent, &children, &nchildren ) != 0 ) {
+ if( XQueryTree( tqt_xdisplay(), w, &root, &parent, &children, &nchildren ) != 0 ) {
for( unsigned int i = 0;
i < nchildren && ret == None;
++i )
diff --git a/ksystraycmd/main.cpp b/ksystraycmd/main.cpp
index ac6b94d74..eef6c541e 100644
--- a/ksystraycmd/main.cpp
+++ b/ksystraycmd/main.cpp
@@ -135,7 +135,7 @@ int main( int argc, char *argv[] )
return 1;
}
- fcntl(ConnectionNumber(qt_xdisplay()), F_SETFD, 1);
+ fcntl(ConnectionNumber(tqt_xdisplay()), F_SETFD, 1);
args->clear();
return app.exec();
diff --git a/kxkb/extension.cpp b/kxkb/extension.cpp
index 3817a8c4c..da1282b12 100644
--- a/kxkb/extension.cpp
+++ b/kxkb/extension.cpp
@@ -38,7 +38,7 @@ TQString XKBExtension::getPrecompiledLayoutFilename(const TQString& layoutKey)
XKBExtension::XKBExtension(Display *d)
{
if ( d == NULL )
- d = qt_xdisplay();
+ d = tqt_xdisplay();
m_dpy = d;
// TQStringList dirs = KGlobal::dirs()->findDirs ( "tmp", "" );
diff --git a/kxkb/kcmmisc.cpp b/kxkb/kcmmisc.cpp
index 8850d8906..14fdb2049 100644
--- a/kxkb/kcmmisc.cpp
+++ b/kxkb/kcmmisc.cpp
@@ -274,7 +274,7 @@ DEALINGS IN THE SOFTWARE.
#if defined(HAVE_XTEST) || defined(HAVE_XKB)
-Display* dpy = qt_xdisplay();
+Display* dpy = tqt_xdisplay();
/* the XKB stuff is based on code created by Oswald Buddenhagen <ossi@kde.org> */
#ifdef HAVE_XKB
@@ -487,7 +487,7 @@ void numlockx_change_numlock_state( bool ) {} // dummy
#include <X11/extensions/xf86misc.h>
void set_repeatrate(int delay, double rate)
{
- Display* dpy = qt_xdisplay();
+ Display* dpy = tqt_xdisplay();
XF86MiscKbdSettings values;
XF86MiscGetKbdSettings(dpy, &values);
@@ -500,7 +500,7 @@ void set_repeatrate(int delay, double rate)
void set_repeatrate(int delay, double rate)
{
#if HAVE_XKB
- Display* dpy = qt_xdisplay();
+ Display* dpy = tqt_xdisplay();
int xkbmajor = XkbMajorVersion, xkbminor = XkbMinorVersion;
int xkbopcode, xkbevent, xkberror;
diff --git a/kxkb/layoutmap.cpp b/kxkb/layoutmap.cpp
index 9c13fc49b..106f70950 100644
--- a/kxkb/layoutmap.cpp
+++ b/kxkb/layoutmap.cpp
@@ -42,7 +42,7 @@ void LayoutMap::setCurrentWindow(WId winId)
{
m_currentWinId = winId;
if( m_kxkbConfig.m_switchingPolicy == SWITCH_POLICY_WIN_CLASS )
- m_currentWinClass = X11Helper::getWindowClass(winId, qt_xdisplay());
+ m_currentWinClass = X11Helper::getWindowClass(winId, tqt_xdisplay());
}
// private
@@ -54,7 +54,7 @@ TQPtrQueue<LayoutState>& LayoutMap::getCurrentLayoutQueueInternal(WId winId)
switch( m_kxkbConfig.m_switchingPolicy ) {
case SWITCH_POLICY_WIN_CLASS: {
-// TQString winClass = X11Helper::getWindowClass(winId, qt_xdisplay());
+// TQString winClass = X11Helper::getWindowClass(winId, tqt_xdisplay());
return m_appLayouts[ m_currentWinClass ];
}
case SWITCH_POLICY_WINDOW:
diff --git a/kxkb/rules.cpp b/kxkb/rules.cpp
index 685c701fd..28d8f687c 100644
--- a/kxkb/rules.cpp
+++ b/kxkb/rules.cpp
@@ -26,7 +26,7 @@ XkbRules::XkbRules(bool layoutsOnly):
return;
}
- TQString rulesFile = X11Helper::findXkbRulesFile(X11_DIR, qt_xdisplay());
+ TQString rulesFile = X11Helper::findXkbRulesFile(X11_DIR, tqt_xdisplay());
if( rulesFile.isEmpty() ) {
kdError() << "Cannot find rules file in " << X11_DIR << endl;
diff --git a/libkonq/konq_operations.cc b/libkonq/konq_operations.cc
index 9d52bddb7..63a11af44 100644
--- a/libkonq/konq_operations.cc
+++ b/libkonq/konq_operations.cc
@@ -351,7 +351,7 @@ void KonqOperations::doDrop( const KFileItem * destItem, const KURL & dest, TQDr
Window child;
int root_x, root_y, win_x, win_y;
uint keybstate;
- XQueryPointer( qt_xdisplay(), qt_xrootwin(), &root, &child,
+ XQueryPointer( tqt_xdisplay(), tqt_xrootwin(), &root, &child,
&root_x, &root_y, &win_x, &win_y, &keybstate );
TQDropEvent::Action action = ev->action();
diff --git a/nsplugins/viewer/kxt.cpp b/nsplugins/viewer/kxt.cpp
index 05b2673be..b8992b171 100644
--- a/nsplugins/viewer/kxt.cpp
+++ b/nsplugins/viewer/kxt.cpp
@@ -74,7 +74,7 @@ const int XKeyRelease = KeyRelease;
#undef KeyPress
#undef KeyRelease
-extern Atom qt_wm_state;
+extern Atom tqt_wm_state;
//#define HAVE_MOTIF
#ifdef HAVE_MOTIF
@@ -145,13 +145,13 @@ void reparentChildrenOf(TQWidget* parent)
for ( TQObjectListIt it( *parent->children() ); it.current(); ++it ) {
if ( it.current()->isWidgetType() ) {
TQWidget* widget = (TQWidget*)it.current();
- XReparentWindow( qt_xdisplay(),
+ XReparentWindow( tqt_xdisplay(),
widget->winId(),
parent->winId(),
widget->x(),
widget->y() );
if ( widget->isVisible() )
- XMapWindow( qt_xdisplay(), widget->winId() );
+ XMapWindow( tqt_xdisplay(), widget->winId() );
}
}
@@ -170,7 +170,7 @@ void qwidget_realize(
reparentChildrenOf(qxtw);
}
qxtw->show();
- XMapWindow( qt_xdisplay(), qxtw->winId() );
+ XMapWindow( tqt_xdisplay(), qxtw->winId() );
}
static
@@ -232,7 +232,7 @@ void installXtEventFilters()
// Get Xt out of our face - install filter on every event type
for (int et=2; et < LASTEvent; et++) {
qt_np_cascade_event_handler[et] = XtSetEventDispatcher(
- qt_xdisplay(), et, qt_event_handler_wrapper );
+ tqt_xdisplay(), et, qt_event_handler_wrapper );
}
filters_installed = TRUE;
}
@@ -244,7 +244,7 @@ void removeXtEventFilters()
// We aren't needed any more... slink back into the shadows.
for (int et=2; et < LASTEvent; et++) {
XtSetEventDispatcher(
- qt_xdisplay(), et, qt_np_cascade_event_handler[et] );
+ tqt_xdisplay(), et, qt_np_cascade_event_handler[et] );
}
filters_installed = FALSE;
}
@@ -321,7 +321,7 @@ KXtApplication::KXtApplication(int& argc, char** argv,
XtToolkitInitialize();
appcon = XtCreateApplicationContext();
if (resources) XtAppSetFallbackResources(appcon, (char**)resources);
- XtDisplayInitialize(appcon, qt_xdisplay(), name(), rAppName, options,
+ XtDisplayInitialize(appcon, tqt_xdisplay(), name(), rAppName, options,
num_options, &argc, argv);
init();
}
@@ -403,8 +403,8 @@ void KXtWidget::init(const char* name, WidgetClass widget_class,
Q_ASSERT(!managed);
String n, c;
- XtGetApplicationNameAndClass(qt_xdisplay(), &n, &c);
- xtw = XtAppCreateShell(n, c, widget_class, qt_xdisplay(),
+ XtGetApplicationNameAndClass(tqt_xdisplay(), &n, &c);
+ xtw = XtAppCreateShell(n, c, widget_class, tqt_xdisplay(),
args, num_args);
if ( widget_class == qWidgetClass )
((QWidgetRec*)xtw)->qwidget.qxtwidget = this;
@@ -414,8 +414,8 @@ void KXtWidget::init(const char* name, WidgetClass widget_class,
XtResizeWidget( xtw, 100, 100, 0 );
XtSetMappedWhenManaged(xtw, False);
XtRealizeWidget(xtw);
- XSync(qt_xdisplay(), False); // I want all windows to be created now
- XReparentWindow(qt_xdisplay(), XtWindow(xtw), qparent->winId(), x(), y());
+ XSync(tqt_xdisplay(), False); // I want all windows to be created now
+ XReparentWindow(tqt_xdisplay(), XtWindow(xtw), qparent->winId(), x(), y());
XtSetMappedWhenManaged(xtw, True);
need_reroot=TRUE;
}
@@ -505,7 +505,7 @@ KXtWidget::~KXtWidget()
if ( need_reroot ) {
hide();
- XReparentWindow(qt_xdisplay(), winId(), tqApp->desktop()->winId(),
+ XReparentWindow(tqt_xdisplay(), winId(), tqApp->desktop()->winId(),
x(), y());
}
@@ -546,7 +546,7 @@ void KXtWidget::setActiveWindow()
e.window = winId();
e.mode = NotifyNormal;
e.detail = NotifyInferior;
- XSendEvent( qt_xdisplay(), e.window, TRUE, NoEventMask, (XEvent*)&e );
+ XSendEvent( tqt_xdisplay(), e.window, TRUE, NoEventMask, (XEvent*)&e );
}
} else {
TQWidget::setActiveWindow();
@@ -560,7 +560,7 @@ bool KXtWidget::isActiveWindow() const
{
Window win;
int revert;
- XGetInputFocus( qt_xdisplay(), &win, &revert );
+ XGetInputFocus( tqt_xdisplay(), &win, &revert );
if ( win == None) return FALSE;
@@ -574,7 +574,7 @@ bool KXtWidget::isActiveWindow() const
Window cursor = winId();
Window *ch;
unsigned int nch;
- while ( XQueryTree(qt_xdisplay(), cursor, &root, &parent, &ch, &nch) ) {
+ while ( XQueryTree(tqt_xdisplay(), cursor, &root, &parent, &ch, &nch) ) {
if (ch) XFree( (char*)ch);
if ( parent == win ) return TRUE;
if ( parent == root ) return FALSE;
@@ -599,7 +599,7 @@ void KXtWidget::moveEvent( TQMoveEvent* )
c.width = width();
c.height = height();
c.border_width = 0;
- XSendEvent( qt_xdisplay(), c.event, TRUE, NoEventMask, (XEvent*)&c );
+ XSendEvent( tqt_xdisplay(), c.event, TRUE, NoEventMask, (XEvent*)&c );
XtMoveWidget( xtw, x(), y() );
}
@@ -620,7 +620,7 @@ void KXtWidget::resizeEvent( TQResizeEvent* )
c.width = width();
c.height = height();
c.border_width = 0;
- XSendEvent( qt_xdisplay(), c.event, TRUE, NoEventMask, (XEvent*)&c );
+ XSendEvent( tqt_xdisplay(), c.event, TRUE, NoEventMask, (XEvent*)&c );
XtResizeWidget( xtw, width(), height(), preferred.border_width );
}
diff --git a/nsplugins/viewer/nsplugin.cpp b/nsplugins/viewer/nsplugin.cpp
index 7092d1024..f8e3a37f8 100644
--- a/nsplugins/viewer/nsplugin.cpp
+++ b/nsplugins/viewer/nsplugin.cpp
@@ -164,10 +164,10 @@ NPError g_NPN_GetValue(NPP /*instance*/, NPNVariable variable, void *value)
switch (variable)
{
case NPNVxDisplay:
- *(void**)value = qt_xdisplay();
+ *(void**)value = tqt_xdisplay();
return NPERR_NO_ERROR;
case NPNVxtAppContext:
- *(void**)value = XtDisplayToApplicationContext(qt_xdisplay());
+ *(void**)value = XtDisplayToApplicationContext(tqt_xdisplay());
return NPERR_NO_ERROR;
case NPNVjavascriptEnabledBool:
*(bool*)value = true;
@@ -638,10 +638,10 @@ NSPluginInstance::NSPluginInstance(NPP privateData, NPPluginFuncs *pluginFuncs,
XtSetArg(args[nargs], XtNborderWidth, 0); nargs++;
String n, c;
- XtGetApplicationNameAndClass(qt_xdisplay(), &n, &c);
+ XtGetApplicationNameAndClass(tqt_xdisplay(), &n, &c);
_toplevel = XtAppCreateShell("drawingArea", c, applicationShellWidgetClass,
- qt_xdisplay(), args, nargs);
+ tqt_xdisplay(), args, nargs);
// What exactly does widget mapping mean? Without this call the widget isn't
// embedded correctly. With it the viewer doesn't show anything in standalone mode.
@@ -655,13 +655,13 @@ NSPluginInstance::NSPluginInstance(NPP privateData, NPPluginFuncs *pluginFuncs,
XtSetArg(args[nargs], XtNdepth, TQPaintDevice::x11AppDepth()); nargs++;
XtSetArg(args[nargs], XtNcolormap, TQPaintDevice::x11AppColormap()); nargs++;
XtSetValues(_form, args, nargs);
- XSync(qt_xdisplay(), false);
+ XSync(tqt_xdisplay(), false);
// From mozilla - not sure if it's needed yet, nor what to use for embedder
#if 0
/* this little trick seems to finish initializing the widget */
#if XlibSpecificationRelease >= 6
- XtRegisterDrawable(qt_xdisplay(), embedderid, _toplevel);
+ XtRegisterDrawable(tqt_xdisplay(), embedderid, _toplevel);
#else
_XtRegisterWindow(embedderid, _toplevel);
#endif
@@ -674,7 +674,7 @@ NSPluginInstance::NSPluginInstance(NPP privateData, NPPluginFuncs *pluginFuncs,
False, forwarder, (XtPointer)this );
XtAddEventHandler(_form, (KeyPressMask|KeyReleaseMask),
False, forwarder, (XtPointer)this );
- XSync(qt_xdisplay(), false);
+ XSync(tqt_xdisplay(), false);
}
}
@@ -942,10 +942,10 @@ int NSPluginInstance::setWindow(TQ_INT8 remove)
if( _xembed_window ) {
_win.window = (void*) _xembed_window;
_win_info.type = NP_SETWINDOW;
- _win_info.display = qt_xdisplay();
- _win_info.visual = DefaultVisualOfScreen(DefaultScreenOfDisplay(qt_xdisplay()));
- _win_info.colormap = DefaultColormapOfScreen(DefaultScreenOfDisplay(qt_xdisplay()));
- _win_info.depth = DefaultDepthOfScreen(DefaultScreenOfDisplay(qt_xdisplay()));
+ _win_info.display = tqt_xdisplay();
+ _win_info.visual = DefaultVisualOfScreen(DefaultScreenOfDisplay(tqt_xdisplay()));
+ _win_info.colormap = DefaultColormapOfScreen(DefaultScreenOfDisplay(tqt_xdisplay()));
+ _win_info.depth = DefaultDepthOfScreen(DefaultScreenOfDisplay(tqt_xdisplay()));
} else {
_win.window = (void*) XtWindow(_form);
@@ -971,9 +971,9 @@ static void resizeWidgets(Window w, int width, int height) {
Window rroot, parent, *children;
unsigned int nchildren = 0;
- if (XQueryTree(qt_xdisplay(), w, &rroot, &parent, &children, &nchildren)) {
+ if (XQueryTree(tqt_xdisplay(), w, &rroot, &parent, &children, &nchildren)) {
for (unsigned int i = 0; i < nchildren; i++) {
- XResizeWindow(qt_xdisplay(), children[i], width, height);
+ XResizeWindow(tqt_xdisplay(), children[i], width, height);
}
XFree(children);
}
@@ -991,8 +991,8 @@ void NSPluginInstance::resizePlugin(TQ_INT32 w, TQ_INT32 h)
_height = h;
if( _form != 0 ) {
- XResizeWindow(qt_xdisplay(), XtWindow(_form), w, h);
- XResizeWindow(qt_xdisplay(), XtWindow(_toplevel), w, h);
+ XResizeWindow(tqt_xdisplay(), XtWindow(_form), w, h);
+ XResizeWindow(tqt_xdisplay(), XtWindow(_toplevel), w, h);
Arg args[7];
Cardinal nargs = 0;
diff --git a/tdm/kfrontend/kfdialog.cpp b/tdm/kfrontend/kfdialog.cpp
index 98b5773c2..a2338cd67 100644
--- a/tdm/kfrontend/kfdialog.cpp
+++ b/tdm/kfrontend/kfdialog.cpp
@@ -47,8 +47,8 @@ FDialog::FDialog( TQWidget *parent, bool framed )
if (framed) {
// Signal that we do not want any window controls to be shown at all
Atom kde_wm_system_modal_notification;
- kde_wm_system_modal_notification = XInternAtom(qt_xdisplay(), "_KDE_WM_MODAL_SYS_NOTIFICATION", False);
- XChangeProperty(qt_xdisplay(), winId(), kde_wm_system_modal_notification, XA_INTEGER, 32, PropModeReplace, (unsigned char *) "TRUE", 1L);
+ kde_wm_system_modal_notification = XInternAtom(tqt_xdisplay(), "_KDE_WM_MODAL_SYS_NOTIFICATION", False);
+ XChangeProperty(tqt_xdisplay(), winId(), kde_wm_system_modal_notification, XA_INTEGER, 32, PropModeReplace, (unsigned char *) "TRUE", 1L);
}
if (framed) {
diff --git a/tdm/kfrontend/kgapp.cpp b/tdm/kfrontend/kgapp.cpp
index f6123891c..e35f16d0b 100644
--- a/tdm/kfrontend/kgapp.cpp
+++ b/tdm/kfrontend/kgapp.cpp
@@ -118,7 +118,7 @@ void
GreeterApp::timerEvent( TQTimerEvent * )
{
alarm( 0 );
- if (!PingServer( qt_xdisplay() ))
+ if (!PingServer( tqt_xdisplay() ))
::exit( EX_RESERVER_DPY );
alarm( pingInterval * 70 ); // sic! give the "proper" pinger enough time
}
@@ -259,7 +259,7 @@ kg_main( const char *argv0 )
TQString login_user;
TQString login_session_wm;
- Display *dpy = qt_xdisplay();
+ Display *dpy = tqt_xdisplay();
if (!_GUIStyle.isEmpty())
app->setStyle( _GUIStyle );
@@ -466,7 +466,7 @@ kg_main( const char *argv0 )
UnsecureDisplay( dpy );
restore_modifiers();
- XSetInputFocus( qt_xdisplay(), PointerRoot, PointerRoot, CurrentTime );
+ XSetInputFocus( tqt_xdisplay(), PointerRoot, PointerRoot, CurrentTime );
delete app;
}
diff --git a/tdm/kfrontend/kgverify.cpp b/tdm/kfrontend/kgverify.cpp
index ec0bfae6c..5b65a0b5b 100644
--- a/tdm/kfrontend/kgverify.cpp
+++ b/tdm/kfrontend/kgverify.cpp
@@ -834,7 +834,7 @@ KGVerify::updateLockStatus()
unsigned int lmask;
Window dummy1, dummy2;
int dummy3, dummy4, dummy5, dummy6;
- XQueryPointer( qt_xdisplay(), DefaultRootWindow( qt_xdisplay() ),
+ XQueryPointer( tqt_xdisplay(), DefaultRootWindow( tqt_xdisplay() ),
&dummy1, &dummy2, &dummy3, &dummy4, &dummy5, &dummy6,
&lmask );
capsLocked = lmask & LockMask;
diff --git a/tdm/kfrontend/krootimage.cpp b/tdm/kfrontend/krootimage.cpp
index b51367485..8fac7d76a 100644
--- a/tdm/kfrontend/krootimage.cpp
+++ b/tdm/kfrontend/krootimage.cpp
@@ -59,7 +59,7 @@ MyApplication::MyApplication( const char *conf )
renderer.start();
if( !properties_inited ) {
- prop_root = XInternAtom(qt_xdisplay(), "_XROOTPMAP_ID", False);
+ prop_root = XInternAtom(tqt_xdisplay(), "_XROOTPMAP_ID", False);
properties_inited = true;
}
}
@@ -77,7 +77,7 @@ MyApplication::renderDone()
// ...and export it via Esetroot-style so that composition managers can use it!
Pixmap bgPm = pm.handle(); // fetch the actual X handle to it
- XChangeProperty(qt_xdisplay(), qt_xrootwin(), prop_root, XA_PIXMAP, 32, PropModeReplace, (unsigned char *) &bgPm, 1);
+ XChangeProperty(tqt_xdisplay(), tqt_xrootwin(), prop_root, XA_PIXMAP, 32, PropModeReplace, (unsigned char *) &bgPm, 1);
renderer.saveCacheFile();
renderer.cleanup();
@@ -132,7 +132,7 @@ main( int argc, char *argv[] )
app.flushX();
// Keep color resources after termination
- XSetCloseDownMode( qt_xdisplay(), RetainTemporary );
+ XSetCloseDownMode( tqt_xdisplay(), RetainTemporary );
return 0;
}
diff --git a/tdm/kfrontend/sakdlg.cc b/tdm/kfrontend/sakdlg.cc
index c1da24d6e..255e36567 100644
--- a/tdm/kfrontend/sakdlg.cc
+++ b/tdm/kfrontend/sakdlg.cc
@@ -91,8 +91,8 @@ SAKDlg::SAKDlg(TQWidget *parent)
if (trinity_desktop_lock_use_system_modal_dialogs) {
// Signal that we do not want any window controls to be shown at all
Atom kde_wm_system_modal_notification;
- kde_wm_system_modal_notification = XInternAtom(qt_xdisplay(), "_KDE_WM_MODAL_SYS_NOTIFICATION", False);
- XChangeProperty(qt_xdisplay(), winId(), kde_wm_system_modal_notification, XA_INTEGER, 32, PropModeReplace, (unsigned char *) "TRUE", 1L);
+ kde_wm_system_modal_notification = XInternAtom(tqt_xdisplay(), "_KDE_WM_MODAL_SYS_NOTIFICATION", False);
+ XChangeProperty(tqt_xdisplay(), winId(), kde_wm_system_modal_notification, XA_INTEGER, 32, PropModeReplace, (unsigned char *) "TRUE", 1L);
}
setCaption(TDM_LOGIN_SCREEN_BASE_TITLE);
diff --git a/tqt3integration/libqtkde/qtkde.cpp b/tqt3integration/libqtkde/qtkde.cpp
index a3c95cb67..a2f93b48f 100644
--- a/tqt3integration/libqtkde/qtkde.cpp
+++ b/tqt3integration/libqtkde/qtkde.cpp
@@ -31,7 +31,7 @@
#include <X11/Xlib.h>
-extern Time qt_x_time;
+extern Time tqt_x_time;
static TQString convertFileFilter( const TQString& filter )
{
@@ -98,7 +98,7 @@ static DCOPClient* dcopClient()
// defined in qapplication_x11.cpp
typedef int (*QX11EventFilter) (XEvent*);
-extern QX11EventFilter qt_set_x11_event_filter (QX11EventFilter filter);
+extern QX11EventFilter tqt_set_x11_event_filter (QX11EventFilter filter);
static QX11EventFilter old_filter;
@@ -125,9 +125,9 @@ static int input_filter( XEvent* e )
void qtkde_EventLoop::block( bool b )
{
if( b )
- old_filter = qt_set_x11_event_filter( input_filter );
+ old_filter = tqt_set_x11_event_filter( input_filter );
else
- qt_set_x11_event_filter( old_filter );
+ tqt_set_x11_event_filter( old_filter );
}
// duped in kded module
diff --git a/tqt3integration/module/module.cpp b/tqt3integration/module/module.cpp
index fd1f8c8bd..fffa62124 100644
--- a/tqt3integration/module/module.cpp
+++ b/tqt3integration/module/module.cpp
@@ -52,7 +52,7 @@ static void prepareDialog( TQWidget* w, long parent, const TQCString& wmclass1,
XClassHint hints;
hints.res_name = ( char* ) ( const char* ) wmclass1;
hints.res_class = ( char* ) ( const char* ) wmclass2;
- XSetClassHint( qt_xdisplay(), w->winId(), &hints );
+ XSetClassHint( tqt_xdisplay(), w->winId(), &hints );
KWin::setMainWindow( w, parent );
KWin::setState( w->winId(), NET::Modal );
KWin::WindowInfo info = KWin::windowInfo( parent, (unsigned long)NET::WMGeometry );
diff --git a/tqt3integration/utils/gen.cpp b/tqt3integration/utils/gen.cpp
index 5406cb1aa..85507573e 100644
--- a/tqt3integration/utils/gen.cpp
+++ b/tqt3integration/utils/gen.cpp
@@ -500,8 +500,8 @@ void generateTQtKde()
stream << "\n";
stream <<
" {\n"
-" if( qt_xdisplay() != NULL )\n"
-" XSync( qt_xdisplay(), False );\n";
+" if( tqt_xdisplay() != NULL )\n"
+" XSync( tqt_xdisplay(), False );\n";
TQString parent_arg;
for( TQValueList< Arg >::ConstIterator it2 = function.args.begin();
it2 != function.args.end();
@@ -519,7 +519,7 @@ void generateTQtKde()
if( !parent_arg.isEmpty())
{
stream << " if( " << parent_arg << " == 0 )\n";
- stream << " DCOPRef( \"kded\", \"MainApplication-Interface\" ).call( \"updateUserTimestamp\", qt_x_time );\n";
+ stream << " DCOPRef( \"kded\", \"MainApplication-Interface\" ).call( \"updateUserTimestamp\", tqt_x_time );\n";
}
stream <<
" TQByteArray data, replyData;\n"
diff --git a/twin/activation.cpp b/twin/activation.cpp
index d0212def2..f54b37232 100644
--- a/twin/activation.cpp
+++ b/twin/activation.cpp
@@ -687,7 +687,7 @@ Time Client::readUserCreationTime() const
unsigned long extra = 0;
unsigned char *data = 0;
KXErrorHandler handler; // ignore errors?
- status = XGetWindowProperty( qt_xdisplay(), window(),
+ status = XGetWindowProperty( tqt_xdisplay(), window(),
atoms->kde_net_wm_user_creation_time, 0, 10000, FALSE, XA_CARDINAL,
&type, &format, &nitems, &extra, &data );
if (status == Success )
diff --git a/twin/atoms.cpp b/twin/atoms.cpp
index aa6e82ea2..0d4ee6195 100644
--- a/twin/atoms.cpp
+++ b/twin/atoms.cpp
@@ -103,7 +103,7 @@ Atoms::Atoms()
assert( n <= max );
- XInternAtoms( qt_xdisplay(), names, n, FALSE, atoms_return );
+ XInternAtoms( tqt_xdisplay(), names, n, FALSE, atoms_return );
for (int i = 0; i < n; i++ )
*atoms[i] = atoms_return[i];
}
diff --git a/twin/client.cpp b/twin/client.cpp
index 8a8745664..749942643 100644
--- a/twin/client.cpp
+++ b/twin/client.cpp
@@ -38,9 +38,9 @@ License. See the file "COPYING" for the exact licensing terms.
// put all externs before the namespace statement to allow the linker
// to resolve them properly
-extern Atom qt_wm_state;
-extern Atom qt_window_role;
-extern Atom qt_sm_client_id;
+extern Atom tqt_wm_state;
+extern Atom tqt_window_role;
+extern Atom tqt_sm_client_id;
// wait 200 ms before drawing shadow after move/resize
static const int SHADOW_DELAY = 200;
@@ -227,7 +227,7 @@ void Client::releaseWindow( bool on_shutdown )
hidden = true; // so that it's not considered visible anymore (can't use hideClient(), it would set flags)
if( !on_shutdown )
workspace()->clientHidden( this );
- XUnmapWindow( qt_xdisplay(), frameId()); // destroying decoration would cause ugly visual effect
+ XUnmapWindow( tqt_xdisplay(), frameId()); // destroying decoration would cause ugly visual effect
destroyDecoration();
cleanGrouping();
if( !on_shutdown )
@@ -239,27 +239,27 @@ void Client::releaseWindow( bool on_shutdown )
desk = 0;
info->setState( 0, info->state()); // reset all state flags
}
- XDeleteProperty( qt_xdisplay(), client, atoms->kde_net_wm_user_creation_time);
- XDeleteProperty( qt_xdisplay(), client, atoms->net_frame_extents );
- XDeleteProperty( qt_xdisplay(), client, atoms->kde_net_wm_frame_strut );
- XReparentWindow( qt_xdisplay(), client, workspace()->rootWin(), x(), y());
- XRemoveFromSaveSet( qt_xdisplay(), client );
- XSelectInput( qt_xdisplay(), client, NoEventMask );
+ XDeleteProperty( tqt_xdisplay(), client, atoms->kde_net_wm_user_creation_time);
+ XDeleteProperty( tqt_xdisplay(), client, atoms->net_frame_extents );
+ XDeleteProperty( tqt_xdisplay(), client, atoms->kde_net_wm_frame_strut );
+ XReparentWindow( tqt_xdisplay(), client, workspace()->rootWin(), x(), y());
+ XRemoveFromSaveSet( tqt_xdisplay(), client );
+ XSelectInput( tqt_xdisplay(), client, NoEventMask );
if( on_shutdown )
{ // map the window, so it can be found after another WM is started
- XMapWindow( qt_xdisplay(), client );
+ XMapWindow( tqt_xdisplay(), client );
// TODO preserve minimized, shaded etc. state?
}
else
{
// Make sure it's not mapped if the app unmapped it (#65279). The app
// may do map+unmap before we initially map the window by calling rawShow() from manage().
- XUnmapWindow( qt_xdisplay(), client );
+ XUnmapWindow( tqt_xdisplay(), client );
}
client = None;
- XDestroyWindow( qt_xdisplay(), wrapper );
+ XDestroyWindow( tqt_xdisplay(), wrapper );
wrapper = None;
- XDestroyWindow( qt_xdisplay(), frame );
+ XDestroyWindow( tqt_xdisplay(), frame );
frame = None;
--postpone_geometry_updates; // don't use GeometryUpdatesBlocker, it would now set the geometry
checkNonExistentClients();
@@ -288,9 +288,9 @@ void Client::destroyClient()
cleanGrouping();
workspace()->removeClient( this, Allowed );
client = None; // invalidate
- XDestroyWindow( qt_xdisplay(), wrapper );
+ XDestroyWindow( tqt_xdisplay(), wrapper );
wrapper = None;
- XDestroyWindow( qt_xdisplay(), frame );
+ XDestroyWindow( tqt_xdisplay(), frame );
frame = None;
--postpone_geometry_updates; // don't use GeometryUpdatesBlocker, it would now set the geometry
checkNonExistentClients();
@@ -313,7 +313,7 @@ void Client::updateDecoration( bool check_workspace_pos, bool force )
// TODO check decoration's minimum size?
decoration->init();
decoration->widget()->installEventFilter( this );
- XReparentWindow( qt_xdisplay(), decoration->widget()->winId(), frameId(), 0, 0 );
+ XReparentWindow( tqt_xdisplay(), decoration->widget()->winId(), frameId(), 0, 0 );
decoration->widget()->lower();
decoration->borders( border_left, border_right, border_top, border_bottom );
options->onlyDecoTranslucent ?
@@ -507,7 +507,7 @@ bool Client::isModalSystemNotification() const
Atom actual;
int format, result;
unsigned long n, left;
- result = XGetWindowProperty(qt_xdisplay(), window(), atoms->net_wm_system_modal_notification, 0L, 1L, False, XA_CARDINAL, &actual, &format, &n, &left, /*(unsigned char **)*/ &data);
+ result = XGetWindowProperty(tqt_xdisplay(), window(), atoms->net_wm_system_modal_notification, 0L, 1L, False, XA_CARDINAL, &actual, &format, &n, &left, /*(unsigned char **)*/ &data);
if (result == Success && data != None && format == 32 )
{
return TRUE;
@@ -526,7 +526,7 @@ void Client::updateShape()
updateOpacityCache();
if ( shape() )
{
- XShapeCombineShape(qt_xdisplay(), frameId(), ShapeBounding,
+ XShapeCombineShape(tqt_xdisplay(), frameId(), ShapeBounding,
clientPos().x(), clientPos().y(),
window(), ShapeBounding, ShapeSet);
setShapable(TRUE);
@@ -546,18 +546,18 @@ void Client::updateShape()
// the window lose focus (which is a problem with mouse focus policies)
static Window helper_window = None;
if( helper_window == None )
- helper_window = XCreateSimpleWindow( qt_xdisplay(), qt_xrootwin(),
+ helper_window = XCreateSimpleWindow( tqt_xdisplay(), tqt_xrootwin(),
0, 0, 1, 1, 0, 0, 0 );
- XResizeWindow( qt_xdisplay(), helper_window, width(), height());
- XShapeCombineShape( qt_xdisplay(), helper_window, ShapeInput, 0, 0,
+ XResizeWindow( tqt_xdisplay(), helper_window, width(), height());
+ XShapeCombineShape( tqt_xdisplay(), helper_window, ShapeInput, 0, 0,
frameId(), ShapeBounding, ShapeSet );
- XShapeCombineShape( qt_xdisplay(), helper_window, ShapeInput,
+ XShapeCombineShape( tqt_xdisplay(), helper_window, ShapeInput,
clientPos().x(), clientPos().y(),
window(), ShapeBounding, ShapeSubtract );
- XShapeCombineShape( qt_xdisplay(), helper_window, ShapeInput,
+ XShapeCombineShape( tqt_xdisplay(), helper_window, ShapeInput,
clientPos().x(), clientPos().y(),
window(), ShapeInput, ShapeUnion );
- XShapeCombineShape( qt_xdisplay(), frameId(), ShapeInput, 0, 0,
+ XShapeCombineShape( tqt_xdisplay(), frameId(), ShapeInput, 0, 0,
helper_window, ShapeInput, ShapeSet );
}
}
@@ -566,10 +566,10 @@ void Client::setMask( const TQRegion& reg, int mode )
{
_mask = reg;
if( reg.isNull())
- XShapeCombineMask( qt_xdisplay(), frameId(), ShapeBounding, 0, 0,
+ XShapeCombineMask( tqt_xdisplay(), frameId(), ShapeBounding, 0, 0,
None, ShapeSet );
else if( mode == X::Unsorted )
- XShapeCombineRegion( qt_xdisplay(), frameId(), ShapeBounding, 0, 0,
+ XShapeCombineRegion( tqt_xdisplay(), frameId(), ShapeBounding, 0, 0,
reg.handle(), ShapeSet );
else
{
@@ -584,7 +584,7 @@ void Client::setMask( const TQRegion& reg, int mode )
xrects[ i ].width = rects[ i ].width();
xrects[ i ].height = rects[ i ].height();
}
- XShapeCombineRectangles( qt_xdisplay(), frameId(), ShapeBounding, 0, 0,
+ XShapeCombineRectangles( tqt_xdisplay(), frameId(), ShapeBounding, 0, 0,
xrects, rects.count(), ShapeSet, mode );
delete[] xrects;
}
@@ -601,7 +601,7 @@ TQRegion Client::mask() const
void Client::setShapable(bool b)
{
long tmp = b?1:0;
- XChangeProperty(qt_xdisplay(), frameId(), atoms->net_wm_window_shapable, XA_CARDINAL, 32, PropModeReplace, (unsigned char *) &tmp, 1L);
+ XChangeProperty(tqt_xdisplay(), frameId(), atoms->net_wm_window_shapable, XA_CARDINAL, 32, PropModeReplace, (unsigned char *) &tmp, 1L);
}
void Client::hideClient( bool hide )
@@ -767,7 +767,7 @@ void Client::animateMinimizeOrUnminimize( bool minimize )
if (area2 != area)
{
pm = animationPixmap( area.width() );
- pm2 = TQPixmap::grabWindow( qt_xrootwin(), area.x(), area.y(), area.width(), area.height() );
+ pm2 = TQPixmap::grabWindow( tqt_xrootwin(), area.x(), area.y(), area.width(), area.height() );
p.drawPixmap( area.x(), area.y(), pm );
if ( need_to_clear )
{
@@ -776,8 +776,8 @@ void Client::animateMinimizeOrUnminimize( bool minimize )
}
area2 = area;
}
- XFlush(qt_xdisplay());
- XSync( qt_xdisplay(), FALSE );
+ XFlush(tqt_xdisplay());
+ XSync( tqt_xdisplay(), FALSE );
diff = t.elapsed();
if (diff > step)
diff = step;
@@ -867,16 +867,16 @@ void Client::setShade( ShadeMode mode )
{ // shade_mode == ShadeNormal
// we're about to shade, texx xcompmgr to prepare
long _shade = 1;
- XChangeProperty(qt_xdisplay(), frameId(), atoms->net_wm_window_shade, XA_CARDINAL, 32, PropModeReplace, (unsigned char *) &_shade, 1L);
+ XChangeProperty(tqt_xdisplay(), frameId(), atoms->net_wm_window_shade, XA_CARDINAL, 32, PropModeReplace, (unsigned char *) &_shade, 1L);
// shade
int h = height();
shade_geometry_change = true;
TQSize s( sizeForClientSize( TQSize( clientSize())));
s.setHeight( border_top + border_bottom );
- XSelectInput( qt_xdisplay(), wrapper, ClientWinMask ); // avoid getting UnmapNotify
- XUnmapWindow( qt_xdisplay(), wrapper );
- XUnmapWindow( qt_xdisplay(), client );
- XSelectInput( qt_xdisplay(), wrapper, ClientWinMask | SubstructureNotifyMask );
+ XSelectInput( tqt_xdisplay(), wrapper, ClientWinMask ); // avoid getting UnmapNotify
+ XUnmapWindow( tqt_xdisplay(), wrapper );
+ XUnmapWindow( tqt_xdisplay(), client );
+ XSelectInput( tqt_xdisplay(), wrapper, ClientWinMask | SubstructureNotifyMask );
//as we hid the unmap event, xcompmgr didn't recognize the client wid has vanished, so we'll extra inform it
//done xcompmgr workaround
// FRAME repaint( FALSE );
@@ -886,7 +886,7 @@ void Client::setShade( ShadeMode mode )
do
{
h -= step;
- XResizeWindow( qt_xdisplay(), frameId(), s.width(), h );
+ XResizeWindow( tqt_xdisplay(), frameId(), s.width(), h );
resizeDecoration( TQSize( s.width(), h ));
TQApplication::syncX();
} while ( h > s.height() + step );
@@ -903,7 +903,7 @@ void Client::setShade( ShadeMode mode )
}
// tell xcompmgr shade's done
_shade = 2;
- XChangeProperty(qt_xdisplay(), frameId(), atoms->net_wm_window_shade, XA_CARDINAL, 32, PropModeReplace, (unsigned char *) &_shade, 1L);
+ XChangeProperty(tqt_xdisplay(), frameId(), atoms->net_wm_window_shade, XA_CARDINAL, 32, PropModeReplace, (unsigned char *) &_shade, 1L);
}
else
{
@@ -916,7 +916,7 @@ void Client::setShade( ShadeMode mode )
do
{
h += step;
- XResizeWindow( qt_xdisplay(), frameId(), s.width(), h );
+ XResizeWindow( tqt_xdisplay(), frameId(), s.width(), h );
resizeDecoration( TQSize( s.width(), h ));
// assume a border
// we do not have time to wait for X to send us paint events
@@ -929,9 +929,9 @@ void Client::setShade( ShadeMode mode )
plainResize( s );
if( shade_mode == ShadeHover || shade_mode == ShadeActivated )
setActive( TRUE );
- XMapWindow( qt_xdisplay(), wrapperId());
- XMapWindow( qt_xdisplay(), window());
- XDeleteProperty (qt_xdisplay(), client, atoms->net_wm_window_shade);
+ XMapWindow( tqt_xdisplay(), wrapperId());
+ XMapWindow( tqt_xdisplay(), window());
+ XDeleteProperty (tqt_xdisplay(), client, atoms->net_wm_window_shade);
if (options->shadowEnabled(false))
{
for (ClientList::ConstIterator it = transients().begin();
@@ -1211,7 +1211,7 @@ void Client::drawShadow()
* this type of window. Otherwise, drawIntersectingShadows() won't update
* properly when this window is moved/resized/hidden/closed.
*/
- shapes = XShapeGetRectangles(qt_xdisplay(), frameId(), ShapeBounding,
+ shapes = XShapeGetRectangles(tqt_xdisplay(), frameId(), ShapeBounding,
&count, &ordering);
if (!shapes)
// XShape extension not supported
@@ -1265,7 +1265,7 @@ void Client::drawShadow()
// Create a fake drop-down shadow effect via blended Xwindows
shadowWidget = new TQWidget(0, 0, (WFlags)(WStyle_Customize | WX11BypassWM));
shadowWidget->setGeometry(shadow);
- XSelectInput(qt_xdisplay(), shadowWidget->winId(),
+ XSelectInput(tqt_xdisplay(), shadowWidget->winId(),
ButtonPressMask | ButtonReleaseMask | StructureNotifyMask);
shadowWidget->installEventFilter(this);
@@ -1309,7 +1309,7 @@ void Client::drawShadow()
shadowShapes[i].height = (*it).height();
i++;
}
- XShapeCombineRectangles(qt_xdisplay(), shadowWidget->winId(),
+ XShapeCombineRectangles(tqt_xdisplay(), shadowWidget->winId(),
ShapeBounding, -x() + thickness - xOffset,
-y() + thickness - yOffset, shadowShapes, i, ShapeSet,
Unsorted);
@@ -1347,11 +1347,11 @@ void Client::drawShadow()
shadows[1] = shadowWidget->winId();
}
- XRestackWindows(qt_xdisplay(), shadows, 2);
+ XRestackWindows(tqt_xdisplay(), shadows, 2);
// Don't use TQWidget::show() so we don't confuse QEffects, thus causing
// broken focus.
- XMapWindow(qt_xdisplay(), shadowWidget->winId());
+ XMapWindow(tqt_xdisplay(), shadowWidget->winId());
// Tell whatever Clients are listening that this Client's shadow has been drawn.
emit shadowDrawn();
@@ -1431,7 +1431,7 @@ void Client::imposeCachedShadow(TQPixmap &pixmap, TQRegion exposed)
int thickness, windowX, windowY, xOffset, yOffset;
rectangles = exposed.rects();
- rootWindow = qt_xrootwin();
+ rootWindow = tqt_xrootwin();
thickness = options->shadowThickness(isActive());
windowX = this->x();
windowY = this->y();
@@ -1491,7 +1491,7 @@ void Client::imposeRegionShadow(TQPixmap &pixmap, TQRegion occluded,
int windowX, windowY, xOffset, yOffset;
rectangles = exposed.rects();
- rootWindow = qt_xrootwin();
+ rootWindow = tqt_xrootwin();
windowX = this->x();
windowY = this->y();
xOffset = options->shadowXOffset(isActive());
@@ -1623,7 +1623,7 @@ void Client::setMappingState(int s)
mapping_state = s;
if( mapping_state == WithdrawnState )
{
- XDeleteProperty( qt_xdisplay(), window(), qt_wm_state );
+ XDeleteProperty( tqt_xdisplay(), window(), tqt_wm_state );
return;
}
assert( s == NormalState || s == IconicState );
@@ -1631,7 +1631,7 @@ void Client::setMappingState(int s)
unsigned long data[2];
data[0] = (unsigned long) s;
data[1] = (unsigned long) None;
- XChangeProperty(qt_xdisplay(), window(), qt_wm_state, qt_wm_state, 32,
+ XChangeProperty(tqt_xdisplay(), window(), tqt_wm_state, tqt_wm_state, 32,
PropModeReplace, (unsigned char *)data, 2);
if( was_unmanaged ) // manage() did postpone_geometry_updates = 1, now it's ok to finally set the geometry
@@ -1646,11 +1646,11 @@ void Client::rawShow()
{
if( decoration != NULL )
decoration->widget()->show(); // not really necessary, but let it know the state
- XMapWindow( qt_xdisplay(), frame );
+ XMapWindow( tqt_xdisplay(), frame );
if( !isShade())
{
- XMapWindow( qt_xdisplay(), wrapper );
- XMapWindow( qt_xdisplay(), client );
+ XMapWindow( tqt_xdisplay(), wrapper );
+ XMapWindow( tqt_xdisplay(), client );
}
if (options->shadowEnabled(isActive()))
drawDelayedShadow();
@@ -1671,11 +1671,11 @@ void Client::rawHide()
// here.
removeShadow();
drawIntersectingShadows();
- XSelectInput( qt_xdisplay(), wrapper, ClientWinMask ); // avoid getting UnmapNotify
- XUnmapWindow( qt_xdisplay(), frame );
- XUnmapWindow( qt_xdisplay(), wrapper );
- XUnmapWindow( qt_xdisplay(), client );
- XSelectInput( qt_xdisplay(), wrapper, ClientWinMask | SubstructureNotifyMask );
+ XSelectInput( tqt_xdisplay(), wrapper, ClientWinMask ); // avoid getting UnmapNotify
+ XUnmapWindow( tqt_xdisplay(), frame );
+ XUnmapWindow( tqt_xdisplay(), wrapper );
+ XUnmapWindow( tqt_xdisplay(), client );
+ XSelectInput( tqt_xdisplay(), wrapper, ClientWinMask | SubstructureNotifyMask );
if( decoration != NULL )
decoration->widget()->hide(); // not really necessary, but let it know the state
workspace()->clientHidden( this );
@@ -1697,9 +1697,9 @@ void Client::sendClientMessage(Window w, Atom a, Atom protocol, long data1, long
ev.xclient.data.l[3] = data2;
ev.xclient.data.l[4] = data3;
mask = 0L;
- if (w == qt_xrootwin())
+ if (w == tqt_xrootwin())
mask = SubstructureRedirectMask; /* magic! */
- XSendEvent(qt_xdisplay(), w, False, mask, &ev);
+ XSendEvent(tqt_xdisplay(), w, False, mask, &ev);
}
/*
@@ -1753,7 +1753,7 @@ void Client::killWindow()
Notify::raise( Notify::Delete );
killProcess( false );
// always kill this client at the server
- XKillClient(qt_xdisplay(), window() );
+ XKillClient(tqt_xdisplay(), window() );
destroyClient();
}
@@ -2206,7 +2206,7 @@ void Client::takeFocus( allowed_t )
#endif
if ( rules()->checkAcceptFocus( input ))
{
- XSetInputFocus( qt_xdisplay(), window(), RevertToPointerRoot, GET_QT_X_TIME() );
+ XSetInputFocus( tqt_xdisplay(), window(), RevertToPointerRoot, GET_QT_X_TIME() );
}
if ( Ptakefocus )
sendClientMessage(window(), atoms->wm_protocols, atoms->wm_take_focus);
@@ -2340,7 +2340,7 @@ TQString Client::caption( bool full ) const
void Client::getWMHints()
{
- XWMHints *hints = XGetWMHints(qt_xdisplay(), window() );
+ XWMHints *hints = XGetWMHints(tqt_xdisplay(), window() );
input = true;
window_group = None;
urgency = false;
@@ -2431,7 +2431,7 @@ void Client::getWindowProtocols()
Pcontexthelp = 0;
Pping = 0;
- if (XGetWMProtocols(qt_xdisplay(), window(), &p, &n))
+ if (XGetWMProtocols(tqt_xdisplay(), window(), &p, &n))
{
for (i = 0; i < n; i++)
if (p[i] == atoms->wm_delete_window)
@@ -2459,7 +2459,7 @@ static int nullErrorHandler(Display *, XErrorEvent *)
*/
TQCString Client::staticWindowRole(WId w)
{
- return getStringProperty(w, qt_window_role).lower();
+ return getStringProperty(w, tqt_window_role).lower();
}
/*!
@@ -2467,7 +2467,7 @@ TQCString Client::staticWindowRole(WId w)
*/
TQCString Client::staticSessionId(WId w)
{
- return getStringProperty(w, qt_sm_client_id);
+ return getStringProperty(w, tqt_sm_client_id);
}
/*!
@@ -2490,7 +2490,7 @@ Window Client::staticWmClientLeader(WId w)
unsigned char *data = 0;
Window result = w;
XErrorHandler oldHandler = XSetErrorHandler(nullErrorHandler);
- status = XGetWindowProperty( qt_xdisplay(), w, atoms->wm_client_leader, 0, 10000,
+ status = XGetWindowProperty( tqt_xdisplay(), w, atoms->wm_client_leader, 0, 10000,
FALSE, XA_WINDOW, &type, &format,
&nitems, &extra, &data );
XSetErrorHandler(oldHandler);
@@ -2708,7 +2708,7 @@ void Client::setCursor( const TQCursor& c )
cursor = c;
if( decoration != NULL )
decoration->widget()->setCursor( cursor );
- XDefineCursor( qt_xdisplay(), frameId(), cursor.handle());
+ XDefineCursor( tqt_xdisplay(), frameId(), cursor.handle());
}
Client::Position Client::mousePosition( const TQPoint& p ) const
@@ -2763,21 +2763,21 @@ void Client::setOpacity(bool translucent, uint opacity)
{
if (isDesktop())
return; // xcompmgr does not like non solid desktops and the user could set it accidently by mouse scrolling
-// tqWarning("setting opacity for %d",qt_xdisplay());
+// tqWarning("setting opacity for %d",tqt_xdisplay());
//rule out activated translulcency with 100% opacity
if (!translucent || opacity == 0xFFFFFFFF)
{
opacity_ = 0xFFFFFFFF;
- XDeleteProperty (qt_xdisplay(), frameId(), atoms->net_wm_window_opacity);
- XDeleteProperty (qt_xdisplay(), window(), atoms->net_wm_window_opacity); // ??? frameId() is necessary for visible changes, window() is the winId() that would be set by apps - we set both to be sure the app knows what's currently displayd
+ XDeleteProperty (tqt_xdisplay(), frameId(), atoms->net_wm_window_opacity);
+ XDeleteProperty (tqt_xdisplay(), window(), atoms->net_wm_window_opacity); // ??? frameId() is necessary for visible changes, window() is the winId() that would be set by apps - we set both to be sure the app knows what's currently displayd
}
else{
if(opacity == opacity_)
return;
opacity_ = opacity;
long data = opacity; // 32bit XChangeProperty needs long
- XChangeProperty(qt_xdisplay(), frameId(), atoms->net_wm_window_opacity, XA_CARDINAL, 32, PropModeReplace, (unsigned char *) &data, 1L);
- XChangeProperty(qt_xdisplay(), window(), atoms->net_wm_window_opacity, XA_CARDINAL, 32, PropModeReplace, (unsigned char *) &data, 1L);
+ XChangeProperty(tqt_xdisplay(), frameId(), atoms->net_wm_window_opacity, XA_CARDINAL, 32, PropModeReplace, (unsigned char *) &data, 1L);
+ XChangeProperty(tqt_xdisplay(), window(), atoms->net_wm_window_opacity, XA_CARDINAL, 32, PropModeReplace, (unsigned char *) &data, 1L);
}
}
@@ -2786,7 +2786,7 @@ void Client::setShadowSize(uint shadowSize)
// ignoring all individual settings - if we control a window, we control it's shadow
// TODO somehow handle individual settings for docks (besides custom sizes)
long data = shadowSize;
- XChangeProperty(qt_xdisplay(), frameId(), atoms->net_wm_window_shadow, XA_CARDINAL, 32, PropModeReplace, (unsigned char *) &data, 1L);
+ XChangeProperty(tqt_xdisplay(), frameId(), atoms->net_wm_window_shadow, XA_CARDINAL, 32, PropModeReplace, (unsigned char *) &data, 1L);
}
void Client::updateOpacity()
@@ -2974,7 +2974,7 @@ bool Client::getWindowOpacity() //query translucency settings from X, returns tr
Atom actual;
int format, result;
unsigned long n, left;
- result = XGetWindowProperty(qt_xdisplay(), window(), atoms->net_wm_window_opacity, 0L, 1L, False, XA_CARDINAL, &actual, &format, &n, &left, /*(unsigned char **)*/ &data);
+ result = XGetWindowProperty(tqt_xdisplay(), window(), atoms->net_wm_window_opacity, 0L, 1L, False, XA_CARDINAL, &actual, &format, &n, &left, /*(unsigned char **)*/ &data);
if (result == Success && data != None && format == 32 )
{
opacity_ = *reinterpret_cast< long* >( data );
@@ -3021,12 +3021,12 @@ void Client::setDecoHashProperty(uint topHeight, uint rightWidth, uint bottomHei
(rightWidth < 255 ? rightWidth : 255) << 16 |
(bottomHeight < 255 ? bottomHeight : 255) << 8 |
(leftWidth < 255 ? leftWidth : 255);
- XChangeProperty(qt_xdisplay(), frameId(), atoms->net_wm_window_decohash, XA_CARDINAL, 32, PropModeReplace, (unsigned char *) &data, 1L);
+ XChangeProperty(tqt_xdisplay(), frameId(), atoms->net_wm_window_decohash, XA_CARDINAL, 32, PropModeReplace, (unsigned char *) &data, 1L);
}
void Client::unsetDecoHashProperty()
{
- XDeleteProperty( qt_xdisplay(), frameId(), atoms->net_wm_window_decohash);
+ XDeleteProperty( tqt_xdisplay(), frameId(), atoms->net_wm_window_decohash);
}
#ifndef NDEBUG
diff --git a/twin/clients/b2/b2client.cpp b/twin/clients/b2/b2client.cpp
index 8e62360a6..027987b9c 100644
--- a/twin/clients/b2/b2client.cpp
+++ b/twin/clients/b2/b2client.cpp
@@ -440,8 +440,8 @@ bool B2Client::isModalSystemNotification()
int format, result;
unsigned long n, left;
Atom kde_wm_system_modal_notification;
- kde_wm_system_modal_notification = XInternAtom(qt_xdisplay(), "_KDE_WM_MODAL_SYS_NOTIFICATION", False);
- result = XGetWindowProperty(qt_xdisplay(), windowId(), kde_wm_system_modal_notification, 0L, 1L, False, XA_CARDINAL, &actual, &format, &n, &left, /*(unsigned char **)*/ &data);
+ kde_wm_system_modal_notification = XInternAtom(tqt_xdisplay(), "_KDE_WM_MODAL_SYS_NOTIFICATION", False);
+ result = XGetWindowProperty(tqt_xdisplay(), windowId(), kde_wm_system_modal_notification, 0L, 1L, False, XA_CARDINAL, &actual, &format, &n, &left, /*(unsigned char **)*/ &data);
if (result == Success && data != None && format == 32 )
{
return TRUE;
@@ -1324,7 +1324,7 @@ bool B2Titlebar::x11Event(XEvent *e)
{
if (!set_x11mask) {
set_x11mask = true;
- XSelectInput(qt_xdisplay(), winId(),
+ XSelectInput(tqt_xdisplay(), winId(),
KeyPressMask | KeyReleaseMask |
ButtonPressMask | ButtonReleaseMask |
KeymapStateMask |
diff --git a/twin/clients/keramik/keramik.cpp b/twin/clients/keramik/keramik.cpp
index 121861865..2ffbbdfee 100644
--- a/twin/clients/keramik/keramik.cpp
+++ b/twin/clients/keramik/keramik.cpp
@@ -1031,8 +1031,8 @@ bool KeramikClient::isModalSystemNotification()
int format, result;
unsigned long n, left;
Atom kde_wm_system_modal_notification;
- kde_wm_system_modal_notification = XInternAtom(qt_xdisplay(), "_KDE_WM_MODAL_SYS_NOTIFICATION", False);
- result = XGetWindowProperty(qt_xdisplay(), windowId(), kde_wm_system_modal_notification, 0L, 1L, False, XA_CARDINAL, &actual, &format, &n, &left, /*(unsigned char **)*/ &data);
+ kde_wm_system_modal_notification = XInternAtom(tqt_xdisplay(), "_KDE_WM_MODAL_SYS_NOTIFICATION", False);
+ result = XGetWindowProperty(tqt_xdisplay(), windowId(), kde_wm_system_modal_notification, 0L, 1L, False, XA_CARDINAL, &actual, &format, &n, &left, /*(unsigned char **)*/ &data);
if (result == Success && data != None && format == 32 )
{
return TRUE;
diff --git a/twin/events.cpp b/twin/events.cpp
index 72047bffc..c7472cdaf 100644
--- a/twin/events.cpp
+++ b/twin/events.cpp
@@ -30,7 +30,7 @@ License. See the file "COPYING" for the exact licensing terms.
#include <X11/Xatom.h>
#include <stdlib.h>
-extern Atom qt_window_role;
+extern Atom tqt_window_role;
namespace KWinInternal
{
@@ -197,7 +197,7 @@ bool Workspace::workspaceEvent( XEvent * e )
if ( mouse_emulation && (e->type == ButtonPress || e->type == ButtonRelease ) )
{
mouse_emulation = FALSE;
- XUngrabKeyboard( qt_xdisplay(), GET_QT_X_TIME() );
+ XUngrabKeyboard( tqt_xdisplay(), GET_QT_X_TIME() );
}
if( e->type == PropertyNotify || e->type == ClientMessage )
@@ -293,7 +293,7 @@ bool Workspace::workspaceEvent( XEvent * e )
{
// see comments for allowClientActivation()
Time my_qtx_time = GET_QT_X_TIME();
- XChangeProperty(qt_xdisplay(), e->xcreatewindow.window,
+ XChangeProperty(tqt_xdisplay(), e->xcreatewindow.window,
atoms->kde_net_wm_user_creation_time, XA_CARDINAL,
32, PropModeReplace, (unsigned char *)&my_qtx_time, 1);
SET_QT_X_TIME(my_qtx_time);
@@ -314,12 +314,12 @@ bool Workspace::workspaceEvent( XEvent * e )
// window.
XEvent ev;
WId w = e->xunmap.window;
- if ( XCheckTypedWindowEvent (qt_xdisplay(), w,
+ if ( XCheckTypedWindowEvent (tqt_xdisplay(), w,
ReparentNotify, &ev) )
{
if ( ev.xreparent.parent != root )
{
- XReparentWindow( qt_xdisplay(), w, root, 0, 0 );
+ XReparentWindow( tqt_xdisplay(), w, root, 0, 0 );
addSystemTrayWin( w );
}
}
@@ -364,13 +364,13 @@ bool Workspace::workspaceEvent( XEvent * e )
if ( addSystemTrayWin( e->xmaprequest.window ) )
return TRUE;
c = createClient( e->xmaprequest.window, false );
- if ( c != NULL && root != qt_xrootwin() )
+ if ( c != NULL && root != tqt_xrootwin() )
{ // TODO what is this?
// TODO may use TQWidget::create
- XReparentWindow( qt_xdisplay(), c->frameId(), root, 0, 0 );
+ XReparentWindow( tqt_xdisplay(), c->frameId(), root, 0, 0 );
}
if( c == NULL ) // refused to manage, simply map it (most probably override redirect)
- XMapRaised( qt_xdisplay(), e->xmaprequest.window );
+ XMapRaised( tqt_xdisplay(), e->xmaprequest.window );
return true;
}
if( c )
@@ -417,7 +417,7 @@ bool Workspace::workspaceEvent( XEvent * e )
wc.stack_mode = Above;
unsigned int value_mask = e->xconfigurerequest.value_mask
& ( CWX | CWY | CWWidth | CWHeight | CWBorderWidth );
- XConfigureWindow( qt_xdisplay(), e->xconfigurerequest.window, value_mask, &wc );
+ XConfigureWindow( tqt_xdisplay(), e->xconfigurerequest.window, value_mask, &wc );
return true;
}
break;
@@ -434,10 +434,10 @@ bool Workspace::workspaceEvent( XEvent * e )
if( e->xfocus.window == rootWin() && TQCString( getenv("TDE_MULTIHEAD")).lower() != "true"
&& ( e->xfocus.detail == NotifyDetailNone || e->xfocus.detail == NotifyPointerRoot ))
{
- updateXTime(); // focusToNull() uses qt_x_time, which is old now (FocusIn has no timestamp)
+ updateXTime(); // focusToNull() uses tqt_x_time, which is old now (FocusIn has no timestamp)
Window focus;
int revert;
- XGetInputFocus( qt_xdisplay(), &focus, &revert );
+ XGetInputFocus( tqt_xdisplay(), &focus, &revert );
if( focus == None || focus == PointerRoot )
{
//kdWarning( 1212 ) << "X focus set to None/PointerRoot, reseting focus" << endl;
@@ -712,7 +712,7 @@ void Client::unmapNotifyEvent( XUnmapEvent* e )
case NormalState:
// maybe we will be destroyed soon. Check this first.
XEvent ev;
- if( XCheckTypedWindowEvent (qt_xdisplay(), window(),
+ if( XCheckTypedWindowEvent (tqt_xdisplay(), window(),
DestroyNotify, &ev) ) // TODO I don't like this much
{
destroyClient(); // deletes this
@@ -808,7 +808,7 @@ void Client::configureRequestEvent( XConfigureRequestEvent* e )
wc.border_width = 0;
value_mask = CWBorderWidth;
- XConfigureWindow( qt_xdisplay(), window(), value_mask, & wc );
+ XConfigureWindow( tqt_xdisplay(), window(), value_mask, & wc );
}
if( e->value_mask & ( CWX | CWY | CWHeight | CWWidth ))
@@ -859,7 +859,7 @@ void Client::propertyNotifyEvent( XPropertyEvent* e )
getWindowProtocols();
else if (e->atom == atoms->wm_client_leader )
getWmClientLeader();
- else if( e->atom == qt_window_role )
+ else if( e->atom == tqt_window_role )
window_role = staticWindowRole( window());
else if( e->atom == atoms->motif_wm_hints )
getMotifHints();
@@ -939,7 +939,7 @@ void Client::leaveNotifyEvent( XCrossingEvent* e )
int d1, d2, d3, d4;
unsigned int d5;
Window w, child;
- if( XQueryPointer( qt_xdisplay(), frameId(), &w, &child, &d1, &d2, &d3, &d4, &d5 ) == False
+ if( XQueryPointer( tqt_xdisplay(), frameId(), &w, &child, &d1, &d2, &d3, &d4, &d5 ) == False
|| child == None )
lostMouse = true; // really lost the mouse
}
@@ -972,7 +972,7 @@ void Client::grabButton( int modifier )
for( int i = 0;
i < 8;
++i )
- XGrabButton( qt_xdisplay(), AnyButton,
+ XGrabButton( tqt_xdisplay(), AnyButton,
modifier | mods[ i ],
wrapperId(), FALSE, ButtonPressMask,
GrabModeSync, GrabModeAsync, None, None );
@@ -989,7 +989,7 @@ void Client::ungrabButton( int modifier )
for( int i = 0;
i < 8;
++i )
- XUngrabButton( qt_xdisplay(), AnyButton,
+ XUngrabButton( tqt_xdisplay(), AnyButton,
modifier | mods[ i ], wrapperId());
}
#undef XCapL
@@ -1006,7 +1006,7 @@ void Client::updateMouseGrab()
{
if( workspace()->globalShortcutsDisabled())
{
- XUngrabButton( qt_xdisplay(), AnyButton, AnyModifier, wrapperId());
+ XUngrabButton( tqt_xdisplay(), AnyButton, AnyModifier, wrapperId());
// keep grab for the simple click without modifiers if needed (see below)
bool not_obscured = workspace()->topClientOnDesktop( workspace()->currentDesktop(), true, false ) == this;
if( !( !options->clickRaise || not_obscured ))
@@ -1016,7 +1016,7 @@ void Client::updateMouseGrab()
if( isActive() && !workspace()->forcedGlobalMouseGrab()) // see Workspace::establishTabBoxGrab()
{
// first grab all modifier combinations
- XGrabButton(qt_xdisplay(), AnyButton, AnyModifier, wrapperId(), FALSE,
+ XGrabButton(tqt_xdisplay(), AnyButton, AnyModifier, wrapperId(), FALSE,
ButtonPressMask,
GrabModeSync, GrabModeAsync,
None, None );
@@ -1035,9 +1035,9 @@ void Client::updateMouseGrab()
}
else
{
- XUngrabButton( qt_xdisplay(), AnyButton, AnyModifier, wrapperId());
+ XUngrabButton( tqt_xdisplay(), AnyButton, AnyModifier, wrapperId());
// simply grab all modifier combinations
- XGrabButton(qt_xdisplay(), AnyButton, AnyModifier, wrapperId(), FALSE,
+ XGrabButton(tqt_xdisplay(), AnyButton, AnyModifier, wrapperId(), FALSE,
ButtonPressMask,
GrabModeSync, GrabModeAsync,
None, None );
@@ -1108,8 +1108,8 @@ bool Client::eventFilter( TQObject* o, TQEvent* e )
// find the window under the cursor that should receive the
// simulated events
- root_window = qt_xrootwin();
- XQueryPointer(qt_xdisplay(), root_window, &root_window,
+ root_window = tqt_xrootwin();
+ XQueryPointer(tqt_xdisplay(), root_window, &root_window,
&pointer_window, &x_root, &y_root, &x, &y, &mask);
if (pointer_window != None)
@@ -1119,7 +1119,7 @@ bool Client::eventFilter( TQObject* o, TQEvent* e )
// the immediate descendant of a window's window decoration,
// which causes KWin to refocus windows properly
parent_window = pointer_window;
- XQueryPointer(qt_xdisplay(), parent_window, &root_window,
+ XQueryPointer(tqt_xdisplay(), parent_window, &root_window,
&pointer_window, &x_root, &y_root, &x, &y, &mask);
inner_window = pointer_window;
@@ -1130,7 +1130,7 @@ bool Client::eventFilter( TQObject* o, TQEvent* e )
// the subsequent query. When no child window is left, we've
// found the child that will receive the simulated event
parent_window = pointer_window;
- XQueryPointer(qt_xdisplay(), parent_window, &root_window,
+ XQueryPointer(tqt_xdisplay(), parent_window, &root_window,
&pointer_window, &x_root, &y_root, &x, &y, &mask);
}
pointer_window = parent_window;
@@ -1140,8 +1140,8 @@ bool Client::eventFilter( TQObject* o, TQEvent* e )
// simulate a mouse button press
xe.type = ButtonPress;
- xe.display = qt_xdisplay();
- xe.root = qt_xrootwin();
+ xe.display = tqt_xdisplay();
+ xe.root = tqt_xrootwin();
xe.subwindow = None;
xe.time = CurrentTime;
xe.x = x;
@@ -1154,17 +1154,17 @@ bool Client::eventFilter( TQObject* o, TQEvent* e )
if (inner_window != None && inner_window != pointer_window)
{
xe.window = inner_window;
- XSendEvent(qt_xdisplay(), inner_window, True, ButtonPressMask,
+ XSendEvent(tqt_xdisplay(), inner_window, True, ButtonPressMask,
(XEvent *)&xe);
}
xe.window = pointer_window;
- XSendEvent(qt_xdisplay(), pointer_window, True, ButtonPressMask,
+ XSendEvent(tqt_xdisplay(), pointer_window, True, ButtonPressMask,
(XEvent *)&xe);
// simulate a mouse button release
xe.type = ButtonRelease;
- xe.display = qt_xdisplay();
- xe.root = qt_xrootwin();
+ xe.display = tqt_xdisplay();
+ xe.root = tqt_xrootwin();
xe.subwindow = None;
xe.time = CurrentTime;
xe.x = x;
@@ -1177,11 +1177,11 @@ bool Client::eventFilter( TQObject* o, TQEvent* e )
if (inner_window != None && inner_window != pointer_window)
{
xe.window = inner_window;
- XSendEvent(qt_xdisplay(), inner_window, True, ButtonReleaseMask,
+ XSendEvent(tqt_xdisplay(), inner_window, True, ButtonReleaseMask,
(XEvent *)&xe);
}
xe.window = pointer_window;
- XSendEvent(qt_xdisplay(), pointer_window, True, ButtonReleaseMask,
+ XSendEvent(tqt_xdisplay(), pointer_window, True, ButtonReleaseMask,
(XEvent *)&xe);
drawDelayedShadow();
@@ -1206,8 +1206,8 @@ bool Client::eventFilter( TQObject* o, TQEvent* e )
// find the window under the cursor that should receive the
// simulated events
- root_window = qt_xrootwin();
- XQueryPointer(qt_xdisplay(), root_window, &root_window,
+ root_window = tqt_xrootwin();
+ XQueryPointer(tqt_xdisplay(), root_window, &root_window,
&pointer_window, &x_root, &y_root, &x, &y, &mask);
if (pointer_window != None)
@@ -1217,7 +1217,7 @@ bool Client::eventFilter( TQObject* o, TQEvent* e )
// the immediate descendant of a window's window decoration,
// which causes KWin to refocus windows properly
parent_window = pointer_window;
- XQueryPointer(qt_xdisplay(), parent_window, &root_window,
+ XQueryPointer(tqt_xdisplay(), parent_window, &root_window,
&pointer_window, &x_root, &y_root, &x, &y, &mask);
inner_window = pointer_window;
@@ -1228,7 +1228,7 @@ bool Client::eventFilter( TQObject* o, TQEvent* e )
// the subsequent query. When no child window is left, we've
// found the child that will receive the simulated event
parent_window = pointer_window;
- XQueryPointer(qt_xdisplay(), parent_window, &root_window,
+ XQueryPointer(tqt_xdisplay(), parent_window, &root_window,
&pointer_window, &x_root, &y_root, &x, &y, &mask);
}
pointer_window = parent_window;
@@ -1238,8 +1238,8 @@ bool Client::eventFilter( TQObject* o, TQEvent* e )
// simulate a mouse button press
xe.type = ButtonPress;
- xe.display = qt_xdisplay();
- xe.root = qt_xrootwin();
+ xe.display = tqt_xdisplay();
+ xe.root = tqt_xrootwin();
xe.subwindow = None;
xe.time = CurrentTime;
xe.x = x;
@@ -1252,18 +1252,18 @@ bool Client::eventFilter( TQObject* o, TQEvent* e )
{
xe.button = buttonPressed;
xe.window = inner_window;
- XSendEvent(qt_xdisplay(), inner_window, True, ButtonPressMask,
+ XSendEvent(tqt_xdisplay(), inner_window, True, ButtonPressMask,
(XEvent *)&xe);
}
xe.button = buttonPressed;
xe.window = pointer_window;
- XSendEvent(qt_xdisplay(), pointer_window, True, ButtonPressMask,
+ XSendEvent(tqt_xdisplay(), pointer_window, True, ButtonPressMask,
(XEvent *)&xe);
// simulate a mouse button release
xe.type = ButtonRelease;
- xe.display = qt_xdisplay();
- xe.root = qt_xrootwin();
+ xe.display = tqt_xdisplay();
+ xe.root = tqt_xrootwin();
xe.subwindow = None;
xe.time = CurrentTime;
xe.x = x;
@@ -1276,13 +1276,13 @@ bool Client::eventFilter( TQObject* o, TQEvent* e )
xe.window = inner_window;
xe.state = buttonMask;
xe.button = buttonPressed;
- XSendEvent(qt_xdisplay(), inner_window, True, ButtonReleaseMask,
+ XSendEvent(tqt_xdisplay(), inner_window, True, ButtonReleaseMask,
(XEvent *)&xe);
}
xe.state = buttonMask;
xe.button = buttonPressed;
xe.window = pointer_window;
- XSendEvent(qt_xdisplay(), pointer_window, True, ButtonReleaseMask,
+ XSendEvent(tqt_xdisplay(), pointer_window, True, ButtonReleaseMask,
(XEvent *)&xe);
drawDelayedShadow();
@@ -1339,7 +1339,7 @@ bool Client::buttonPressEvent( Window w, int button, int state, int x, int y, in
if (buttonDown)
{
if( w == wrapperId())
- XAllowEvents(qt_xdisplay(), SyncPointer, CurrentTime ); //qt_x_time);
+ XAllowEvents(tqt_xdisplay(), SyncPointer, CurrentTime ); //tqt_x_time);
return true;
}
@@ -1358,7 +1358,7 @@ bool Client::buttonPressEvent( Window w, int button, int state, int x, int y, in
{ // hide splashwindow if the user clicks on it
hideClient( true );
if( w == wrapperId())
- XAllowEvents(qt_xdisplay(), SyncPointer, CurrentTime ); //qt_x_time);
+ XAllowEvents(tqt_xdisplay(), SyncPointer, CurrentTime ); //tqt_x_time);
return true;
}
@@ -1423,14 +1423,14 @@ bool Client::buttonPressEvent( Window w, int button, int state, int x, int y, in
replay = TRUE;
if( w == wrapperId()) // these can come only from a grab
- XAllowEvents(qt_xdisplay(), replay? ReplayPointer : SyncPointer, CurrentTime ); //qt_x_time);
+ XAllowEvents(tqt_xdisplay(), replay? ReplayPointer : SyncPointer, CurrentTime ); //tqt_x_time);
return true;
}
}
if( w == wrapperId()) // these can come only from a grab
{
- XAllowEvents(qt_xdisplay(), ReplayPointer, CurrentTime ); //qt_x_time);
+ XAllowEvents(tqt_xdisplay(), ReplayPointer, CurrentTime ); //tqt_x_time);
return true;
}
if( w == decorationId())
@@ -1503,7 +1503,7 @@ bool Client::buttonReleaseEvent( Window w, int /*button*/, int state, int x, int
return false;
if( w == wrapperId())
{
- XAllowEvents(qt_xdisplay(), SyncPointer, CurrentTime ); //qt_x_time);
+ XAllowEvents(tqt_xdisplay(), SyncPointer, CurrentTime ); //tqt_x_time);
return true;
}
if( w != frameId() && w != decorationId() && w != moveResizeGrabWindow())
@@ -1553,9 +1553,9 @@ static bool waitingMotionEvent()
&& timestampCompare( GET_QT_X_TIME(), next_motion_time ) < 0 )
return true;
was_motion = false;
- XSync( qt_xdisplay(), False ); // this helps to discard more MotionNotify events
+ XSync( tqt_xdisplay(), False ); // this helps to discard more MotionNotify events
XEvent dummy;
- XCheckIfEvent( qt_xdisplay(), &dummy, motion_predicate, NULL );
+ XCheckIfEvent( tqt_xdisplay(), &dummy, motion_predicate, NULL );
return was_motion;
}
@@ -1648,7 +1648,7 @@ static bool check_follows_focusin( Client* c )
// XCheckIfEvent() is used to make the search non-blocking, the predicate
// always returns False, so nothing is removed from the events queue.
// XPeekIfEvent() would block.
- XCheckIfEvent( qt_xdisplay(), &dummy, predicate_follows_focusin, (XPointer)c );
+ XCheckIfEvent( tqt_xdisplay(), &dummy, predicate_follows_focusin, (XPointer)c );
return follows_focusin;
}
diff --git a/twin/geometry.cpp b/twin/geometry.cpp
index ab7311556..4215ec38f 100644
--- a/twin/geometry.cpp
+++ b/twin/geometry.cpp
@@ -680,10 +680,10 @@ void Workspace::updateTopMenuGeometry( Client* c )
if( c != NULL )
{
XEvent ev;
- ev.xclient.display = qt_xdisplay();
+ ev.xclient.display = tqt_xdisplay();
ev.xclient.type = ClientMessage;
ev.xclient.window = c->window();
- static Atom msg_type_atom = XInternAtom( qt_xdisplay(), "_KDE_TOPMENU_MINSIZE", False );
+ static Atom msg_type_atom = XInternAtom( tqt_xdisplay(), "_KDE_TOPMENU_MINSIZE", False );
ev.xclient.message_type = msg_type_atom;
ev.xclient.format = 32;
ev.xclient.data.l[0] = GET_QT_X_TIME();
@@ -691,7 +691,7 @@ void Workspace::updateTopMenuGeometry( Client* c )
ev.xclient.data.l[2] = topmenu_space->height();
ev.xclient.data.l[3] = 0;
ev.xclient.data.l[4] = 0;
- XSendEvent( qt_xdisplay(), c->window(), False, NoEventMask, &ev );
+ XSendEvent( tqt_xdisplay(), c->window(), False, NoEventMask, &ev );
KWin::setStrut( c->window(), 0, 0, topmenu_height, 0 ); // so that kicker etc. know
c->checkWorkspacePosition();
return;
@@ -859,25 +859,25 @@ NETExtendedStrut Client::strut() const
{
ext.left_width = str.left;
ext.left_start = 0;
- ext.left_end = XDisplayHeight( qt_xdisplay(), DefaultScreen( qt_xdisplay()));
+ ext.left_end = XDisplayHeight( tqt_xdisplay(), DefaultScreen( tqt_xdisplay()));
}
if( str.right != 0 )
{
ext.right_width = str.right;
ext.right_start = 0;
- ext.right_end = XDisplayHeight( qt_xdisplay(), DefaultScreen( qt_xdisplay()));
+ ext.right_end = XDisplayHeight( tqt_xdisplay(), DefaultScreen( tqt_xdisplay()));
}
if( str.top != 0 )
{
ext.top_width = str.top;
ext.top_start = 0;
- ext.top_end = XDisplayWidth( qt_xdisplay(), DefaultScreen( qt_xdisplay()));
+ ext.top_end = XDisplayWidth( tqt_xdisplay(), DefaultScreen( tqt_xdisplay()));
}
if( str.bottom != 0 )
{
ext.bottom_width = str.bottom;
ext.bottom_start = 0;
- ext.bottom_end = XDisplayWidth( qt_xdisplay(), DefaultScreen( qt_xdisplay()));
+ ext.bottom_end = XDisplayWidth( tqt_xdisplay(), DefaultScreen( tqt_xdisplay()));
}
}
return ext;
@@ -1284,7 +1284,7 @@ TQSize Client::sizeForClientSize( const TQSize& wsize, Sizemode mode, bool nofra
void Client::getWmNormalHints()
{
long msize;
- if (XGetWMNormalHints(qt_xdisplay(), window(), &xSizeHint, &msize) == 0 )
+ if (XGetWMNormalHints(tqt_xdisplay(), window(), &xSizeHint, &msize) == 0 )
xSizeHint.flags = 0;
// set defined values for the fields, even if they're not in flags
@@ -1386,7 +1386,7 @@ void Client::sendSyntheticConfigureNotify()
c.border_width = 0;
c.above = None;
c.override_redirect = 0;
- XSendEvent( qt_xdisplay(), c.event, TRUE, StructureNotifyMask, (XEvent*)&c );
+ XSendEvent( tqt_xdisplay(), c.event, TRUE, StructureNotifyMask, (XEvent*)&c );
}
const TQPoint Client::calculateGravitation( bool invert, int gravity ) const
@@ -1758,14 +1758,14 @@ void Client::setGeometry( int x, int y, int w, int h, ForceGeometry_t force )
return;
}
resizeDecoration( TQSize( w, h ));
- XMoveResizeWindow( qt_xdisplay(), frameId(), x, y, w, h );
+ XMoveResizeWindow( tqt_xdisplay(), frameId(), x, y, w, h );
// resizeDecoration( TQSize( w, h ));
if( !isShade())
{
TQSize cs = clientSize();
- XMoveResizeWindow( qt_xdisplay(), wrapperId(), clientPos().x(), clientPos().y(),
+ XMoveResizeWindow( tqt_xdisplay(), wrapperId(), clientPos().x(), clientPos().y(),
cs.width(), cs.height());
- XMoveResizeWindow( qt_xdisplay(), window(), 0, 0, cs.width(), cs.height());
+ XMoveResizeWindow( tqt_xdisplay(), window(), 0, 0, cs.width(), cs.height());
}
updateShape();
// SELI TODO won't this be too expensive?
@@ -1813,14 +1813,14 @@ void Client::plainResize( int w, int h, ForceGeometry_t force )
return;
}
resizeDecoration( TQSize( w, h ));
- XResizeWindow( qt_xdisplay(), frameId(), w, h );
+ XResizeWindow( tqt_xdisplay(), frameId(), w, h );
// resizeDecoration( TQSize( w, h ));
if( !isShade())
{
TQSize cs = clientSize();
- XMoveResizeWindow( qt_xdisplay(), wrapperId(), clientPos().x(), clientPos().y(),
+ XMoveResizeWindow( tqt_xdisplay(), wrapperId(), clientPos().x(), clientPos().y(),
cs.width(), cs.height());
- XMoveResizeWindow( qt_xdisplay(), window(), 0, 0, cs.width(), cs.height());
+ XMoveResizeWindow( tqt_xdisplay(), window(), 0, 0, cs.width(), cs.height());
}
updateShape();
updateWorkareaDiffs();
@@ -1844,7 +1844,7 @@ void Client::move( int x, int y, ForceGeometry_t force )
pending_geometry_update = true;
return;
}
- XMoveWindow( qt_xdisplay(), frameId(), x, y );
+ XMoveWindow( tqt_xdisplay(), frameId(), x, y );
sendSyntheticConfigureNotify();
updateWindowRules();
checkMaximizeGeometry();
@@ -2314,18 +2314,18 @@ bool Client::startMoveResize()
// (http://lists.kde.org/?t=107302193400001&r=1&w=2)
XSetWindowAttributes attrs;
TQRect r = workspace()->clientArea( FullArea, this );
- move_resize_grab_window = XCreateWindow( qt_xdisplay(), workspace()->rootWin(), r.x(), r.y(),
+ move_resize_grab_window = XCreateWindow( tqt_xdisplay(), workspace()->rootWin(), r.x(), r.y(),
r.width(), r.height(), 0, CopyFromParent, InputOnly, CopyFromParent, 0, &attrs );
- XMapRaised( qt_xdisplay(), move_resize_grab_window );
- if( XGrabPointer( qt_xdisplay(), move_resize_grab_window, False,
+ XMapRaised( tqt_xdisplay(), move_resize_grab_window );
+ if( XGrabPointer( tqt_xdisplay(), move_resize_grab_window, False,
ButtonPressMask | ButtonReleaseMask | PointerMotionMask | EnterWindowMask | LeaveWindowMask,
GrabModeAsync, GrabModeAsync, move_resize_grab_window, cursor.handle(), GET_QT_X_TIME() ) == Success )
has_grab = true;
- if( XGrabKeyboard( qt_xdisplay(), frameId(), False, GrabModeAsync, GrabModeAsync, GET_QT_X_TIME() ) == Success )
+ if( XGrabKeyboard( tqt_xdisplay(), frameId(), False, GrabModeAsync, GrabModeAsync, GET_QT_X_TIME() ) == Success )
has_grab = true;
if( !has_grab ) // at least one grab is necessary in order to be able to finish move/resize
{
- XDestroyWindow( qt_xdisplay(), move_resize_grab_window );
+ XDestroyWindow( tqt_xdisplay(), move_resize_grab_window );
move_resize_grab_window = None;
return false;
}
@@ -2389,9 +2389,9 @@ void Client::leaveMoveResize()
if ( ( isMove() && rules()->checkMoveResizeMode( options->moveMode ) != Options::Opaque )
|| ( isResize() && rules()->checkMoveResizeMode( options->resizeMode ) != Options::Opaque ) )
ungrabXServer();
- XUngrabKeyboard( qt_xdisplay(), GET_QT_X_TIME() );
- XUngrabPointer( qt_xdisplay(), GET_QT_X_TIME() );
- XDestroyWindow( qt_xdisplay(), move_resize_grab_window );
+ XUngrabKeyboard( tqt_xdisplay(), GET_QT_X_TIME() );
+ XUngrabPointer( tqt_xdisplay(), GET_QT_X_TIME() );
+ XDestroyWindow( tqt_xdisplay(), move_resize_grab_window );
move_resize_grab_window = None;
workspace()->setClientIsMoving(0);
if( move_faked_activity )
diff --git a/twin/geometrytip.cpp b/twin/geometrytip.cpp
index e196135ab..046f1d594 100644
--- a/twin/geometrytip.cpp
+++ b/twin/geometrytip.cpp
@@ -26,7 +26,7 @@ GeometryTip::GeometryTip( const XSizeHints* xSizeHints, bool save_under ):
{
XSetWindowAttributes attr;
attr.save_under = True; // use saveunder if possible to avoid weird effects in transparent mode
- XChangeWindowAttributes( qt_xdisplay(), winId(), CWSaveUnder, &attr );
+ XChangeWindowAttributes( tqt_xdisplay(), winId(), CWSaveUnder, &attr );
}
}
diff --git a/twin/group.cpp b/twin/group.cpp
index 8d5bd7246..50fce46f0 100644
--- a/twin/group.cpp
+++ b/twin/group.cpp
@@ -209,7 +209,7 @@ Group::Group( Window leader_P, Workspace* workspace_P )
{
leader_client = workspace_P->findClient( WindowMatchPredicate( leader_P ));
unsigned long properties[ 2 ] = { 0, NET::WM2StartupId };
- leader_info = new NETWinInfo( qt_xdisplay(), leader_P, workspace()->rootWin(),
+ leader_info = new NETWinInfo( tqt_xdisplay(), leader_P, workspace()->rootWin(),
properties, 2 );
}
workspace()->addGroup( this, Allowed );
@@ -580,7 +580,7 @@ void Client::readTransient()
{
TRANSIENCY_CHECK( this );
Window new_transient_for_id;
- if( XGetTransientForHint( qt_xdisplay(), window(), &new_transient_for_id ))
+ if( XGetTransientForHint( tqt_xdisplay(), window(), &new_transient_for_id ))
{
original_transient_for_id = new_transient_for_id;
new_transient_for_id = verifyTransientFor( new_transient_for_id, true );
@@ -787,7 +787,7 @@ Window Client::verifyTransientFor( Window new_transient_for, bool defined )
Window root_return, parent_return;
Window* wins = NULL;
unsigned int nwins;
- int r = XQueryTree(qt_xdisplay(), new_transient_for, &root_return, &parent_return, &wins, &nwins);
+ int r = XQueryTree(tqt_xdisplay(), new_transient_for, &root_return, &parent_return, &wins, &nwins);
if ( wins )
XFree((void *) wins);
if ( r == 0)
@@ -828,7 +828,7 @@ Window Client::verifyTransientFor( Window new_transient_for, bool defined )
new_transient_for = workspace()->rootWin();
}
if( new_property_value != original_transient_for_id )
- XSetTransientForHint( qt_xdisplay(), window(), new_property_value );
+ XSetTransientForHint( tqt_xdisplay(), window(), new_property_value );
return new_transient_for;
}
diff --git a/twin/kcmtwin/twindecoration/preview.cpp b/twin/kcmtwin/twindecoration/preview.cpp
index 573971f27..29d93a7f3 100644
--- a/twin/kcmtwin/twindecoration/preview.cpp
+++ b/twin/kcmtwin/twindecoration/preview.cpp
@@ -145,7 +145,7 @@ void KDecorationPreview::setPreviewMask( const TQRegion& reg, int mode, bool act
// FRAME duped from client.cpp
if( mode == Unsorted )
{
- XShapeCombineRegion( qt_xdisplay(), widget->winId(), ShapeBounding, 0, 0,
+ XShapeCombineRegion( tqt_xdisplay(), widget->winId(), ShapeBounding, 0, 0,
reg.handle(), ShapeSet );
}
else
@@ -161,7 +161,7 @@ void KDecorationPreview::setPreviewMask( const TQRegion& reg, int mode, bool act
xrects[ i ].width = rects[ i ].width();
xrects[ i ].height = rects[ i ].height();
}
- XShapeCombineRectangles( qt_xdisplay(), widget->winId(), ShapeBounding, 0, 0,
+ XShapeCombineRectangles( tqt_xdisplay(), widget->winId(), ShapeBounding, 0, 0,
xrects, rects.count(), ShapeSet, mode );
delete[] xrects;
}
diff --git a/twin/kcmtwin/twinrules/detectwidget.cpp b/twin/kcmtwin/twinrules/detectwidget.cpp
index d82836868..3eb6cf0aa 100644
--- a/twin/kcmtwin/twinrules/detectwidget.cpp
+++ b/twin/kcmtwin/twinrules/detectwidget.cpp
@@ -191,13 +191,13 @@ WId DetectDialog::findWindow()
Window child;
uint mask;
int rootX, rootY, x, y;
- Window parent = qt_xrootwin();
- Atom wm_state = XInternAtom( qt_xdisplay(), "WM_STATE", False );
+ Window parent = tqt_xrootwin();
+ Atom wm_state = XInternAtom( tqt_xdisplay(), "WM_STATE", False );
for( int i = 0;
i < 10;
++i )
{
- XQueryPointer( qt_xdisplay(), parent, &root, &child,
+ XQueryPointer( tqt_xdisplay(), parent, &root, &child,
&rootX, &rootY, &x, &y, &mask );
if( child == None )
return 0;
@@ -205,7 +205,7 @@ WId DetectDialog::findWindow()
int format;
unsigned long nitems, after;
unsigned char* prop;
- if( XGetWindowProperty( qt_xdisplay(), child, wm_state, 0, 0, False, AnyPropertyType,
+ if( XGetWindowProperty( tqt_xdisplay(), child, wm_state, 0, 0, False, AnyPropertyType,
&type, &format, &nitems, &after, &prop ) == Success )
{
if( prop != NULL )
diff --git a/twin/killer/killer.cpp b/twin/killer/killer.cpp
index ebd4fea90..43336d654 100644
--- a/twin/killer/killer.cpp
+++ b/twin/killer/killer.cpp
@@ -83,6 +83,6 @@ int main( int argc, char* argv[] )
}
else
::kill( pid, SIGKILL );
- XKillClient( qt_xdisplay(), id );
+ XKillClient( tqt_xdisplay(), id );
}
}
diff --git a/twin/killwindow.cpp b/twin/killwindow.cpp
index 7dc6504f9..fb5486546 100644
--- a/twin/killwindow.cpp
+++ b/twin/killwindow.cpp
@@ -35,16 +35,16 @@ void KillWindow::start()
{
static Cursor kill_cursor = 0;
if (!kill_cursor)
- kill_cursor = XCreateFontCursor(qt_xdisplay(), XC_pirate);
+ kill_cursor = XCreateFontCursor(tqt_xdisplay(), XC_pirate);
- if (XGrabPointer(qt_xdisplay(), qt_xrootwin(), False,
+ if (XGrabPointer(tqt_xdisplay(), tqt_xrootwin(), False,
ButtonPressMask | ButtonReleaseMask |
PointerMotionMask |
EnterWindowMask | LeaveWindowMask,
GrabModeAsync, GrabModeAsync, None,
kill_cursor, CurrentTime) == GrabSuccess)
{
- XGrabKeyboard(qt_xdisplay(), qt_xrootwin(), False,
+ XGrabKeyboard(tqt_xdisplay(), tqt_xrootwin(), False,
GrabModeAsync, GrabModeAsync, CurrentTime);
XEvent ev;
@@ -56,12 +56,12 @@ void KillWindow::start()
while (!return_pressed && !escape_pressed && !button_released)
{
- XMaskEvent(qt_xdisplay(), KeyPressMask | ButtonPressMask |
+ XMaskEvent(tqt_xdisplay(), KeyPressMask | ButtonPressMask |
ButtonReleaseMask | PointerMotionMask, &ev);
if (ev.type == KeyPress)
{
- int kc = XKeycodeToKeysym(qt_xdisplay(), ev.xkey.keycode, 0);
+ int kc = XKeycodeToKeysym(tqt_xdisplay(), ev.xkey.keycode, 0);
int mx = 0;
int my = 0;
return_pressed = (kc == XK_Return) || (kc == XK_space);
@@ -96,7 +96,7 @@ void KillWindow::start()
Window root, child;
int dummy1, dummy2, dummy3, dummy4;
unsigned int dummy5;
- if( XQueryPointer( qt_xdisplay(), qt_xrootwin(), &root, &child,
+ if( XQueryPointer( tqt_xdisplay(), tqt_xrootwin(), &root, &child,
&dummy1, &dummy2, &dummy3, &dummy4, &dummy5 ) == true
&& child != None )
workspace->killWindowId( child );
@@ -104,8 +104,8 @@ void KillWindow::start()
ungrabXServer();
- XUngrabKeyboard(qt_xdisplay(), CurrentTime);
- XUngrabPointer(qt_xdisplay(), CurrentTime);
+ XUngrabKeyboard(tqt_xdisplay(), CurrentTime);
+ XUngrabPointer(tqt_xdisplay(), CurrentTime);
}
}
diff --git a/twin/layers.cpp b/twin/layers.cpp
index 794d06636..143d826d5 100644
--- a/twin/layers.cpp
+++ b/twin/layers.cpp
@@ -211,10 +211,10 @@ void Workspace::propagateClients( bool propagate_new_clients )
assert( new_stack[ 0 ] = supportWindow->winId());
#endif
#if 0
- XRestackWindows(qt_xdisplay(), new_stack, pos);
+ XRestackWindows(tqt_xdisplay(), new_stack, pos);
delete [] new_stack;
#endif
- XRestackWindows(qt_xdisplay(), window_stack, pos);
+ XRestackWindows(tqt_xdisplay(), window_stack, pos);
delete [] dock_shadow_stack;
delete [] window_stack;
diff --git a/twin/lib/kcommondecoration.cpp b/twin/lib/kcommondecoration.cpp
index bd33e979f..95e297bc2 100644
--- a/twin/lib/kcommondecoration.cpp
+++ b/twin/lib/kcommondecoration.cpp
@@ -328,8 +328,8 @@ bool KCommonDecoration::isModalSystemNotification()
int format, result;
unsigned long n, left;
Atom kde_wm_system_modal_notification;
- kde_wm_system_modal_notification = XInternAtom(qt_xdisplay(), "_KDE_WM_MODAL_SYS_NOTIFICATION", False);
- result = XGetWindowProperty(qt_xdisplay(), windowId(), kde_wm_system_modal_notification, 0L, 1L, False, XA_CARDINAL, &actual, &format, &n, &left, /*(unsigned char **)*/ &data);
+ kde_wm_system_modal_notification = XInternAtom(tqt_xdisplay(), "_KDE_WM_MODAL_SYS_NOTIFICATION", False);
+ result = XGetWindowProperty(tqt_xdisplay(), windowId(), kde_wm_system_modal_notification, 0L, 1L, False, XA_CARDINAL, &actual, &format, &n, &left, /*(unsigned char **)*/ &data);
if (result == Success && data != None && format == 32 )
{
return TRUE;
diff --git a/twin/main.cpp b/twin/main.cpp
index 5bb1be654..1e1ec114c 100644
--- a/twin/main.cpp
+++ b/twin/main.cpp
@@ -96,11 +96,11 @@ Application::Application( )
}
if (screen_number == -1)
- screen_number = DefaultScreen(qt_xdisplay());
+ screen_number = DefaultScreen(tqt_xdisplay());
if( !owner.claim( args->isSet( "replace" ), true ))
{
- Display* dpy = qt_xdisplay();
+ Display* dpy = tqt_xdisplay();
Window w;
Atom a;
static char net_wm_sm[] = "WM_Sxx";
@@ -156,7 +156,7 @@ Application::Application( )
XSetErrorHandler( x11ErrorHandler );
// check whether another windowmanager is running
- XSelectInput(qt_xdisplay(), qt_xrootwin(), SubstructureRedirectMask );
+ XSelectInput(tqt_xdisplay(), tqt_xrootwin(), SubstructureRedirectMask );
syncX(); // trigger error now
options = new Options;
@@ -164,8 +164,8 @@ Application::Application( )
// Signal that we are The KWin!
Atom kde_wm_system_modal_notification;
- kde_wm_system_modal_notification = XInternAtom(qt_xdisplay(), "_KDE_WM_IS_KWIN", False);
- XChangeProperty(qt_xdisplay(), owner.ownerWindow(), kde_wm_system_modal_notification, XA_INTEGER, 32, PropModeReplace, (unsigned char *) "TRUE", 1L);
+ kde_wm_system_modal_notification = XInternAtom(tqt_xdisplay(), "_KDE_WM_IS_KWIN", False);
+ XChangeProperty(tqt_xdisplay(), owner.ownerWindow(), kde_wm_system_modal_notification, XA_INTEGER, 32, PropModeReplace, (unsigned char *) "TRUE", 1L);
// create workspace.
(void) new Workspace( isSessionRestored() );
@@ -180,12 +180,12 @@ Application::Application( )
dcopClient()->send( "ksplash", "", "upAndRunning(TQString)", TQString("wm started"));
XEvent e;
e.xclient.type = ClientMessage;
- e.xclient.message_type = XInternAtom( qt_xdisplay(), "_KDE_SPLASH_PROGRESS", False );
- e.xclient.display = qt_xdisplay();
- e.xclient.window = qt_xrootwin();
+ e.xclient.message_type = XInternAtom( tqt_xdisplay(), "_KDE_SPLASH_PROGRESS", False );
+ e.xclient.display = tqt_xdisplay();
+ e.xclient.window = tqt_xrootwin();
e.xclient.format = 8;
strcpy( e.xclient.data.b, "wm started" );
- XSendEvent( qt_xdisplay(), qt_xrootwin(), False, SubstructureNotifyMask, &e );
+ XSendEvent( tqt_xdisplay(), tqt_xrootwin(), False, SubstructureNotifyMask, &e );
}
Application::~Application()
@@ -193,7 +193,7 @@ Application::~Application()
delete Workspace::self();
if( owner.ownerWindow() != None ) // if there was no --replace (no new WM)
{
- XSetInputFocus( qt_xdisplay(), PointerRoot, RevertToPointerRoot, GET_QT_X_TIME() );
+ XSetInputFocus( tqt_xdisplay(), PointerRoot, RevertToPointerRoot, GET_QT_X_TIME() );
DCOPRef ref( "kded", "kded" );
if( !ref.send( "loadModule", TQCString( "kdetrayproxy" )))
kdWarning( 176 ) << "Loading of kdetrayproxy failed." << endl;
@@ -205,7 +205,7 @@ void Application::lostSelection()
{
delete Workspace::self();
// remove windowmanager privileges
- XSelectInput(qt_xdisplay(), qt_xrootwin(), PropertyChangeMask );
+ XSelectInput(tqt_xdisplay(), tqt_xrootwin(), PropertyChangeMask );
DCOPRef ref( "kded", "kded" );
if( !ref.send( "loadModule", TQCString( "kdetrayproxy" )))
kdWarning( 176 ) << "Loading of kdetrayproxy failed." << endl;
@@ -332,7 +332,7 @@ KDE_EXPORT int kdemain( int argc, char * argv[] )
KWinInternal::SessionManaged weAreIndeed;
KWinInternal::SessionSaveDoneHelper helper;
- fcntl(ConnectionNumber(qt_xdisplay()), F_SETFD, 1);
+ fcntl(ConnectionNumber(tqt_xdisplay()), F_SETFD, 1);
TQCString appname;
if (KWinInternal::screen_number == 0)
diff --git a/twin/manage.cpp b/twin/manage.cpp
index acf1ce598..d6127e4e0 100644
--- a/twin/manage.cpp
+++ b/twin/manage.cpp
@@ -36,7 +36,7 @@ namespace KWinInternal
bool Client::manage( Window w, bool isMapped )
{
XWindowAttributes attr;
- if( !XGetWindowAttributes(qt_xdisplay(), w, &attr))
+ if( !XGetWindowAttributes(tqt_xdisplay(), w, &attr))
return false;
grabXServer();
@@ -50,7 +50,7 @@ bool Client::manage( Window w, bool isMapped )
// SELI order all these things in some sane manner
bool init_minimize = false;
- XWMHints * hints = XGetWMHints(qt_xdisplay(), w );
+ XWMHints * hints = XGetWMHints(tqt_xdisplay(), w );
if (hints && (hints->flags & StateHint) && hints->initial_state == IconicState)
init_minimize = true;
if (hints)
@@ -76,12 +76,12 @@ bool Client::manage( Window w, bool isMapped )
NET::WM2ExtendedStrut |
0;
- info = new WinInfo( this, qt_xdisplay(), client, qt_xrootwin(), properties, 2 );
+ info = new WinInfo( this, tqt_xdisplay(), client, tqt_xrootwin(), properties, 2 );
cmap = attr.colormap;
XClassHint classHint;
- if ( XGetClassHint( qt_xdisplay(), client, &classHint ) )
+ if ( XGetClassHint( tqt_xdisplay(), client, &classHint ) )
{
// Qt3.2 and older had this all lowercase, Qt3.3 capitalized resource class
// force lowercase, so that workarounds listing resource classes still work
@@ -318,7 +318,7 @@ bool Client::manage( Window w, bool isMapped )
if(( !isSpecialWindow() || isToolbar()) && isMovable())
keepInArea( area, partial_keep_in_area );
- XShapeSelectInput( qt_xdisplay(), window(), ShapeNotifyMask );
+ XShapeSelectInput( tqt_xdisplay(), window(), ShapeNotifyMask );
is_shape = Shape::hasShape( window());
updateShape();
@@ -444,7 +444,7 @@ bool Client::manage( Window w, bool isMapped )
// TODO this should avoid flicker, because real restacking is done
// only after manage() finishes, but the window is shown sooner
// - keep it?
- XLowerWindow( qt_xdisplay(), frameId());
+ XLowerWindow( tqt_xdisplay(), frameId());
// set initial user time directly
user_time = readUserTimeMapTimestamp( asn_valid ? &asn_id : NULL, asn_valid ? &asn_data : NULL, session );
@@ -558,30 +558,30 @@ void Client::embedClient( Window w, const XWindowAttributes &attr )
assert( wrapper == None );
client = w;
// we don't want the window to be destroyed when we are destroyed
- XAddToSaveSet( qt_xdisplay(), client );
- XSelectInput( qt_xdisplay(), client, NoEventMask );
- XUnmapWindow( qt_xdisplay(), client );
+ XAddToSaveSet( tqt_xdisplay(), client );
+ XSelectInput( tqt_xdisplay(), client, NoEventMask );
+ XUnmapWindow( tqt_xdisplay(), client );
XWindowChanges wc; // set the border width to 0
wc.border_width = 0; // TODO possibly save this, and also use it for initial configuring of the window
- XConfigureWindow( qt_xdisplay(), client, CWBorderWidth, &wc );
+ XConfigureWindow( tqt_xdisplay(), client, CWBorderWidth, &wc );
XSetWindowAttributes swa;
swa.colormap = attr.colormap;
swa.background_pixmap = None;
swa.border_pixel = 0;
- frame = XCreateWindow( qt_xdisplay(), qt_xrootwin(), 0, 0, 1, 1, 0,
+ frame = XCreateWindow( tqt_xdisplay(), tqt_xrootwin(), 0, 0, 1, 1, 0,
attr.depth, InputOutput, attr.visual,
CWColormap | CWBackPixmap | CWBorderPixel, &swa );
- wrapper = XCreateWindow( qt_xdisplay(), frame, 0, 0, 1, 1, 0,
+ wrapper = XCreateWindow( tqt_xdisplay(), frame, 0, 0, 1, 1, 0,
attr.depth, InputOutput, attr.visual,
CWColormap | CWBackPixmap | CWBorderPixel, &swa );
- XDefineCursor( qt_xdisplay(), frame, tqarrowCursor.handle());
+ XDefineCursor( tqt_xdisplay(), frame, tqarrowCursor.handle());
// some apps are stupid and don't define their own cursor - set the arrow one for them
- XDefineCursor( qt_xdisplay(), wrapper, tqarrowCursor.handle());
- XReparentWindow( qt_xdisplay(), client, wrapper, 0, 0 );
- XSelectInput( qt_xdisplay(), frame,
+ XDefineCursor( tqt_xdisplay(), wrapper, tqarrowCursor.handle());
+ XReparentWindow( tqt_xdisplay(), client, wrapper, 0, 0 );
+ XSelectInput( tqt_xdisplay(), frame,
KeyPressMask | KeyReleaseMask |
ButtonPressMask | ButtonReleaseMask |
KeymapStateMask |
@@ -592,8 +592,8 @@ void Client::embedClient( Window w, const XWindowAttributes &attr )
ExposureMask |
PropertyChangeMask |
StructureNotifyMask | SubstructureRedirectMask );
- XSelectInput( qt_xdisplay(), wrapper, ClientWinMask | SubstructureNotifyMask );
- XSelectInput( qt_xdisplay(), client,
+ XSelectInput( tqt_xdisplay(), wrapper, ClientWinMask | SubstructureNotifyMask );
+ XSelectInput( tqt_xdisplay(), client,
FocusChangeMask |
PropertyChangeMask |
ColormapChangeMask |
diff --git a/twin/popupinfo.cpp b/twin/popupinfo.cpp
index a2760d336..5f75adfbc 100644
--- a/twin/popupinfo.cpp
+++ b/twin/popupinfo.cpp
@@ -109,7 +109,7 @@ void PopupInfo::hide()
TQWidget::hide();
TQApplication::syncX();
XEvent otherEvent;
- while (XCheckTypedEvent (qt_xdisplay(), EnterNotify, &otherEvent ) )
+ while (XCheckTypedEvent (tqt_xdisplay(), EnterNotify, &otherEvent ) )
;
m_shown = false;
}
diff --git a/twin/tabbox.cpp b/twin/tabbox.cpp
index 943ba6dc6..284a920bc 100644
--- a/twin/tabbox.cpp
+++ b/twin/tabbox.cpp
@@ -57,22 +57,22 @@ TabBox::TabBox( Workspace *ws, const char *name )
XSetWindowAttributes attr;
attr.override_redirect = 1;
- outline_left = XCreateWindow( qt_xdisplay(), qt_xrootwin(), 0, 0, 1, 1, 0,
+ outline_left = XCreateWindow( tqt_xdisplay(), tqt_xrootwin(), 0, 0, 1, 1, 0,
CopyFromParent, CopyFromParent, CopyFromParent, CWOverrideRedirect, &attr );
- outline_right = XCreateWindow( qt_xdisplay(), qt_xrootwin(), 0, 0, 1, 1, 0,
+ outline_right = XCreateWindow( tqt_xdisplay(), tqt_xrootwin(), 0, 0, 1, 1, 0,
CopyFromParent, CopyFromParent, CopyFromParent, CWOverrideRedirect, &attr );
- outline_top = XCreateWindow( qt_xdisplay(), qt_xrootwin(), 0, 0, 1, 1, 0,
+ outline_top = XCreateWindow( tqt_xdisplay(), tqt_xrootwin(), 0, 0, 1, 1, 0,
CopyFromParent, CopyFromParent, CopyFromParent, CWOverrideRedirect, &attr );
- outline_bottom = XCreateWindow( qt_xdisplay(), qt_xrootwin(), 0, 0, 1, 1, 0,
+ outline_bottom = XCreateWindow( tqt_xdisplay(), tqt_xrootwin(), 0, 0, 1, 1, 0,
CopyFromParent, CopyFromParent, CopyFromParent, CWOverrideRedirect, &attr );
}
TabBox::~TabBox()
{
- XDestroyWindow( qt_xdisplay(), outline_left );
- XDestroyWindow( qt_xdisplay(), outline_right );
- XDestroyWindow( qt_xdisplay(), outline_top );
- XDestroyWindow( qt_xdisplay(), outline_bottom );
+ XDestroyWindow( tqt_xdisplay(), outline_left );
+ XDestroyWindow( tqt_xdisplay(), outline_right );
+ XDestroyWindow( tqt_xdisplay(), outline_top );
+ XDestroyWindow( tqt_xdisplay(), outline_bottom );
}
@@ -344,10 +344,10 @@ int TabBox::currentDesktop()
void TabBox::showEvent( TQShowEvent* )
{
updateOutline();
- XRaiseWindow( qt_xdisplay(), outline_left );
- XRaiseWindow( qt_xdisplay(), outline_right );
- XRaiseWindow( qt_xdisplay(), outline_top );
- XRaiseWindow( qt_xdisplay(), outline_bottom );
+ XRaiseWindow( tqt_xdisplay(), outline_left );
+ XRaiseWindow( tqt_xdisplay(), outline_right );
+ XRaiseWindow( tqt_xdisplay(), outline_top );
+ XRaiseWindow( tqt_xdisplay(), outline_bottom );
raise();
}
@@ -357,10 +357,10 @@ void TabBox::showEvent( TQShowEvent* )
*/
void TabBox::hideEvent( TQHideEvent* )
{
- XUnmapWindow( qt_xdisplay(), outline_left );
- XUnmapWindow( qt_xdisplay(), outline_right );
- XUnmapWindow( qt_xdisplay(), outline_top );
- XUnmapWindow( qt_xdisplay(), outline_bottom );
+ XUnmapWindow( tqt_xdisplay(), outline_left );
+ XUnmapWindow( tqt_xdisplay(), outline_right );
+ XUnmapWindow( tqt_xdisplay(), outline_top );
+ XUnmapWindow( tqt_xdisplay(), outline_bottom );
}
/*!
@@ -557,17 +557,17 @@ void TabBox::updateOutline()
Client* c = currentClient();
if( !options->tabboxOutline || c == NULL || this->isHidden() || !c->isShown( true ) || !c->isOnCurrentDesktop())
{
- XUnmapWindow( qt_xdisplay(), outline_left );
- XUnmapWindow( qt_xdisplay(), outline_right );
- XUnmapWindow( qt_xdisplay(), outline_top );
- XUnmapWindow( qt_xdisplay(), outline_bottom );
+ XUnmapWindow( tqt_xdisplay(), outline_left );
+ XUnmapWindow( tqt_xdisplay(), outline_right );
+ XUnmapWindow( tqt_xdisplay(), outline_top );
+ XUnmapWindow( tqt_xdisplay(), outline_bottom );
return;
}
// left/right parts are between top/bottom, they don't reach as far as the corners
- XMoveResizeWindow( qt_xdisplay(), outline_left, c->x(), c->y() + 5, 5, c->height() - 10 );
- XMoveResizeWindow( qt_xdisplay(), outline_right, c->x() + c->width() - 5, c->y() + 5, 5, c->height() - 10 );
- XMoveResizeWindow( qt_xdisplay(), outline_top, c->x(), c->y(), c->width(), 5 );
- XMoveResizeWindow( qt_xdisplay(), outline_bottom, c->x(), c->y() + c->height() - 5, c->width(), 5 );
+ XMoveResizeWindow( tqt_xdisplay(), outline_left, c->x(), c->y() + 5, 5, c->height() - 10 );
+ XMoveResizeWindow( tqt_xdisplay(), outline_right, c->x() + c->width() - 5, c->y() + 5, 5, c->height() - 10 );
+ XMoveResizeWindow( tqt_xdisplay(), outline_top, c->x(), c->y(), c->width(), 5 );
+ XMoveResizeWindow( tqt_xdisplay(), outline_bottom, c->x(), c->y() + c->height() - 5, c->width(), 5 );
{
TQPixmap pix( 5, c->height() - 10 );
TQPainter p( &pix );
@@ -580,8 +580,8 @@ void TabBox::updateOutline()
p.setPen( black );
p.drawLine( 2, 0, 2, pix.height() - 1 );
p.end();
- XSetWindowBackgroundPixmap( qt_xdisplay(), outline_left, pix.handle());
- XSetWindowBackgroundPixmap( qt_xdisplay(), outline_right, pix.handle());
+ XSetWindowBackgroundPixmap( tqt_xdisplay(), outline_left, pix.handle());
+ XSetWindowBackgroundPixmap( tqt_xdisplay(), outline_right, pix.handle());
}
{
TQPixmap pix( c->width(), 5 );
@@ -603,7 +603,7 @@ void TabBox::updateOutline()
p.drawLine( 2, 2, 2, 4 );
p.drawLine( pix.width() - 1 - 2, 2, pix.width() - 1 - 2, 4 );
p.end();
- XSetWindowBackgroundPixmap( qt_xdisplay(), outline_top, pix.handle());
+ XSetWindowBackgroundPixmap( tqt_xdisplay(), outline_top, pix.handle());
}
{
TQPixmap pix( c->width(), 5 );
@@ -625,16 +625,16 @@ void TabBox::updateOutline()
p.drawLine( 2, 0, 2, 2 );
p.drawLine( pix.width() - 1 - 2, 0, pix.width() - 1 - 2, 2 );
p.end();
- XSetWindowBackgroundPixmap( qt_xdisplay(), outline_bottom, pix.handle());
+ XSetWindowBackgroundPixmap( tqt_xdisplay(), outline_bottom, pix.handle());
}
- XClearWindow( qt_xdisplay(), outline_left );
- XClearWindow( qt_xdisplay(), outline_right );
- XClearWindow( qt_xdisplay(), outline_top );
- XClearWindow( qt_xdisplay(), outline_bottom );
- XMapWindow( qt_xdisplay(), outline_left );
- XMapWindow( qt_xdisplay(), outline_right );
- XMapWindow( qt_xdisplay(), outline_top );
- XMapWindow( qt_xdisplay(), outline_bottom );
+ XClearWindow( tqt_xdisplay(), outline_left );
+ XClearWindow( tqt_xdisplay(), outline_right );
+ XClearWindow( tqt_xdisplay(), outline_top );
+ XClearWindow( tqt_xdisplay(), outline_bottom );
+ XMapWindow( tqt_xdisplay(), outline_left );
+ XMapWindow( tqt_xdisplay(), outline_right );
+ XMapWindow( tqt_xdisplay(), outline_top );
+ XMapWindow( tqt_xdisplay(), outline_bottom );
}
void TabBox::hide()
@@ -643,7 +643,7 @@ void TabBox::hide()
TQWidget::hide();
TQApplication::syncX();
XEvent otherEvent;
- while (XCheckTypedEvent (qt_xdisplay(), EnterNotify, &otherEvent ) )
+ while (XCheckTypedEvent (tqt_xdisplay(), EnterNotify, &otherEvent ) )
;
}
@@ -692,7 +692,7 @@ void TabBox::delayedShow()
void TabBox::handleMouseEvent( XEvent* e )
{
- XAllowEvents( qt_xdisplay(), AsyncPointer, GET_QT_X_TIME() );
+ XAllowEvents( tqt_xdisplay(), AsyncPointer, GET_QT_X_TIME() );
if( e->type != ButtonPress )
return;
TQPoint pos( e->xbutton.x_root, e->xbutton.y_root );
@@ -757,12 +757,12 @@ bool areKeySymXsDepressed( bool bAll, const uint keySyms[], int nKeySyms )
kdDebug(125) << "areKeySymXsDepressed: " << (bAll ? "all of " : "any of ") << nKeySyms << endl;
- XQueryKeymap( qt_xdisplay(), keymap );
+ XQueryKeymap( tqt_xdisplay(), keymap );
for( int iKeySym = 0; iKeySym < nKeySyms; iKeySym++ )
{
uint keySymX = keySyms[ iKeySym ];
- uchar keyCodeX = XKeysymToKeycode( qt_xdisplay(), keySymX );
+ uchar keyCodeX = XKeysymToKeycode( tqt_xdisplay(), keySymX );
int i = keyCodeX / 8;
char mask = 1 << (keyCodeX - (i * 8));
@@ -844,13 +844,13 @@ static bool areModKeysDepressed( const KShortcut& cut )
void Workspace::slotWalkThroughWindows()
{
- if ( root != qt_xrootwin() )
+ if ( root != tqt_xrootwin() )
return;
if ( tab_grab || control_grab )
return;
if ( options->altTabStyle == Options::CDE || !options->focusPolicyIsReasonable())
{
- //XUngrabKeyboard(qt_xdisplay(), GET_QT_X_TIME()); // need that because of accelerator raw mode
+ //XUngrabKeyboard(tqt_xdisplay(), GET_QT_X_TIME()); // need that because of accelerator raw mode
// CDE style raise / lower
CDEWalkThroughWindows( true );
}
@@ -870,7 +870,7 @@ void Workspace::slotWalkThroughWindows()
void Workspace::slotWalkBackThroughWindows()
{
- if ( root != qt_xrootwin() )
+ if ( root != tqt_xrootwin() )
return;
if( tab_grab || control_grab )
return;
@@ -895,7 +895,7 @@ void Workspace::slotWalkBackThroughWindows()
void Workspace::slotWalkThroughDesktops()
{
- if ( root != qt_xrootwin() )
+ if ( root != tqt_xrootwin() )
return;
if( tab_grab || control_grab )
return;
@@ -912,7 +912,7 @@ void Workspace::slotWalkThroughDesktops()
void Workspace::slotWalkBackThroughDesktops()
{
- if ( root != qt_xrootwin() )
+ if ( root != tqt_xrootwin() )
return;
if( tab_grab || control_grab )
return;
@@ -929,7 +929,7 @@ void Workspace::slotWalkBackThroughDesktops()
void Workspace::slotWalkThroughDesktopList()
{
- if ( root != qt_xrootwin() )
+ if ( root != tqt_xrootwin() )
return;
if( tab_grab || control_grab )
return;
@@ -946,7 +946,7 @@ void Workspace::slotWalkThroughDesktopList()
void Workspace::slotWalkBackThroughDesktopList()
{
- if ( root != qt_xrootwin() )
+ if ( root != tqt_xrootwin() )
return;
if( tab_grab || control_grab )
return;
@@ -1185,7 +1185,7 @@ void Workspace::tabBoxKeyRelease( const XKeyEvent& ev )
release = true;
else
{
- XModifierKeymap* xmk = XGetModifierMapping(qt_xdisplay());
+ XModifierKeymap* xmk = XGetModifierMapping(tqt_xdisplay());
for (int i=0; i<xmk->max_keypermod; i++)
if (xmk->modifiermap[xmk->max_keypermod * mod_index + i]
== ev.keycode)
@@ -1316,7 +1316,7 @@ Client* Workspace::previousStaticClient( Client* c ) const
bool Workspace::establishTabBoxGrab()
{
- if( XGrabKeyboard( qt_xdisplay(), root, FALSE,
+ if( XGrabKeyboard( tqt_xdisplay(), root, FALSE,
GrabModeAsync, GrabModeAsync, GET_QT_X_TIME()) != GrabSuccess )
return false;
// Don't try to establish a global mouse grab using XGrabPointer, as that would prevent
@@ -1333,7 +1333,7 @@ bool Workspace::establishTabBoxGrab()
void Workspace::removeTabBoxGrab()
{
- XUngrabKeyboard(qt_xdisplay(), GET_QT_X_TIME());
+ XUngrabKeyboard(tqt_xdisplay(), GET_QT_X_TIME());
assert( forced_global_mouse_grab );
forced_global_mouse_grab = false;
if( active_client != NULL )
diff --git a/twin/tools/decobenchmark/preview.cpp b/twin/tools/decobenchmark/preview.cpp
index 8154612ec..2accb7644 100644
--- a/twin/tools/decobenchmark/preview.cpp
+++ b/twin/tools/decobenchmark/preview.cpp
@@ -140,7 +140,7 @@ void KDecorationPreview::setPreviewMask( const TQRegion& reg, int mode )
// FRAME duped from client.cpp
if( mode == Unsorted )
{
- XShapeCombineRegion( qt_xdisplay(), widget->winId(), ShapeBounding, 0, 0,
+ XShapeCombineRegion( tqt_xdisplay(), widget->winId(), ShapeBounding, 0, 0,
reg.handle(), ShapeSet );
}
else
@@ -156,7 +156,7 @@ void KDecorationPreview::setPreviewMask( const TQRegion& reg, int mode )
xrects[ i ].width = rects[ i ].width();
xrects[ i ].height = rects[ i ].height();
}
- XShapeCombineRectangles( qt_xdisplay(), widget->winId(), ShapeBounding, 0, 0,
+ XShapeCombineRectangles( tqt_xdisplay(), widget->winId(), ShapeBounding, 0, 0,
xrects, rects.count(), ShapeSet, mode );
delete[] xrects;
}
diff --git a/twin/utils.cpp b/twin/utils.cpp
index d476c8932..93d14080e 100644
--- a/twin/utils.cpp
+++ b/twin/utils.cpp
@@ -58,7 +58,7 @@ bool Shape::hasShape( WId w)
int boundingShaped = 0, clipShaped = 0;
if (!available())
return FALSE;
- XShapeQueryExtents(qt_xdisplay(), w,
+ XShapeQueryExtents(tqt_xdisplay(), w,
&boundingShaped, &xws, &yws, &wws, &hws,
&clipShaped, &xbs, &ybs, &wbs, &hbs);
return boundingShaped != 0;
@@ -73,10 +73,10 @@ void Shape::init()
{
twin_shape_version = 0;
int dummy;
- if( !XShapeQueryExtension(qt_xdisplay(), &twin_shape_event, &dummy))
+ if( !XShapeQueryExtension(tqt_xdisplay(), &twin_shape_event, &dummy))
return;
int major, minor;
- if( !XShapeQueryVersion( qt_xdisplay(), &major, &minor ))
+ if( !XShapeQueryVersion( tqt_xdisplay(), &major, &minor ))
return;
twin_shape_version = major * 0x10 + minor;
}
@@ -89,7 +89,7 @@ void Motif::readFlags( WId w, bool& noborder, bool& resize, bool& move,
unsigned long length, after;
unsigned char* data;
MwmHints* hints = 0;
- if ( XGetWindowProperty( qt_xdisplay(), w, atoms->motif_wm_hints, 0, 5,
+ if ( XGetWindowProperty( tqt_xdisplay(), w, atoms->motif_wm_hints, 0, 5,
FALSE, atoms->motif_wm_hints, &type, &format,
&length, &after, &data ) == Success )
{
@@ -142,10 +142,10 @@ KWinSelectionOwner::KWinSelectionOwner( int screen_P )
Atom KWinSelectionOwner::make_selection_atom( int screen_P )
{
if( screen_P < 0 )
- screen_P = DefaultScreen( qt_xdisplay());
+ screen_P = DefaultScreen( tqt_xdisplay());
char tmp[ 30 ];
sprintf( tmp, "WM_S%d", screen_P );
- return XInternAtom( qt_xdisplay(), tmp, False );
+ return XInternAtom( tqt_xdisplay(), tmp, False );
}
void KWinSelectionOwner::getAtoms()
@@ -156,7 +156,7 @@ void KWinSelectionOwner::getAtoms()
Atom atoms[ 1 ];
const char* const names[] =
{ "VERSION" };
- XInternAtoms( qt_xdisplay(), const_cast< char** >( names ), 1, False, atoms );
+ XInternAtoms( tqt_xdisplay(), const_cast< char** >( names ), 1, False, atoms );
xa_version = atoms[ 0 ];
}
}
@@ -166,7 +166,7 @@ void KWinSelectionOwner::replyTargets( Atom property_P, Window requestor_P )
KSelectionOwner::replyTargets( property_P, requestor_P );
Atom atoms[ 1 ] = { xa_version };
// PropModeAppend !
- XChangeProperty( qt_xdisplay(), requestor_P, property_P, XA_ATOM, 32, PropModeAppend,
+ XChangeProperty( tqt_xdisplay(), requestor_P, property_P, XA_ATOM, 32, PropModeAppend,
reinterpret_cast< unsigned char* >( atoms ), 1 );
}
@@ -175,7 +175,7 @@ bool KWinSelectionOwner::genericReply( Atom target_P, Atom property_P, Window re
if( target_P == xa_version )
{
long version[] = { 2, 0 };
- XChangeProperty( qt_xdisplay(), requestor_P, property_P, XA_INTEGER, 32,
+ XChangeProperty( tqt_xdisplay(), requestor_P, property_P, XA_INTEGER, 32,
PropModeReplace, reinterpret_cast< unsigned char* >( &version ), 2 );
}
else
@@ -195,7 +195,7 @@ TQCString getStringProperty(WId w, Atom prop, char separator)
unsigned char *data = 0;
TQCString result = "";
KXErrorHandler handler; // ignore errors
- status = XGetWindowProperty( qt_xdisplay(), w, prop, 0, 10000,
+ status = XGetWindowProperty( tqt_xdisplay(), w, prop, 0, 10000,
FALSE, XA_STRING, &type, &format,
&nitems, &extra, &data );
if ( status == Success)
@@ -250,8 +250,8 @@ static Bool update_x_time_predicate( Display*, XEvent* event, XPointer )
}
/*
- Updates qt_x_time. This used to simply fetch current timestamp from the server,
- but that can cause qt_x_time to be newer than timestamp of events that are
+ Updates tqt_x_time. This used to simply fetch current timestamp from the server,
+ but that can cause tqt_x_time to be newer than timestamp of events that are
still in our events queue, thus e.g. making XSetInputFocus() caused by such
event to be ignored. Therefore events queue is searched for first
event with timestamp, and extra PropertyNotify is generated in order to make
@@ -263,20 +263,20 @@ void updateXTime()
if ( !w )
w = new TQWidget;
long data = 1;
- XChangeProperty(qt_xdisplay(), w->winId(), atoms->twin_running, atoms->twin_running, 32,
+ XChangeProperty(tqt_xdisplay(), w->winId(), atoms->twin_running, atoms->twin_running, 32,
PropModeAppend, (unsigned char*) &data, 1);
next_x_time = CurrentTime;
XEvent dummy;
- XCheckIfEvent( qt_xdisplay(), &dummy, update_x_time_predicate, NULL );
+ XCheckIfEvent( tqt_xdisplay(), &dummy, update_x_time_predicate, NULL );
if( next_x_time == CurrentTime )
{
- XSync( qt_xdisplay(), False );
- XCheckIfEvent( qt_xdisplay(), &dummy, update_x_time_predicate, NULL );
+ XSync( tqt_xdisplay(), False );
+ XCheckIfEvent( tqt_xdisplay(), &dummy, update_x_time_predicate, NULL );
}
assert( next_x_time != CurrentTime );
SET_QT_X_TIME(next_x_time);
XEvent ev; // remove the PropertyNotify event from the events queue
- XWindowEvent( qt_xdisplay(), w->winId(), PropertyChangeMask, &ev );
+ XWindowEvent( tqt_xdisplay(), w->winId(), PropertyChangeMask, &ev );
}
static int server_grab_count = 0;
@@ -284,7 +284,7 @@ static int server_grab_count = 0;
void grabXServer()
{
if( ++server_grab_count == 1 )
- XGrabServer( qt_xdisplay());
+ XGrabServer( tqt_xdisplay());
}
void ungrabXServer()
@@ -292,8 +292,8 @@ void ungrabXServer()
assert( server_grab_count > 0 );
if( --server_grab_count == 0 )
{
- XUngrabServer( qt_xdisplay());
- XFlush( qt_xdisplay());
+ XUngrabServer( tqt_xdisplay());
+ XFlush( tqt_xdisplay());
Notify::sendPendingEvents();
}
}
@@ -334,7 +334,7 @@ ShortcutDialog::ShortcutDialog( const KShortcut& cut )
// make it a popup, so that it has the grab
XSetWindowAttributes attrs;
attrs.override_redirect = True;
- XChangeWindowAttributes( qt_xdisplay(), winId(), CWOverrideRedirect, &attrs );
+ XChangeWindowAttributes( tqt_xdisplay(), winId(), CWOverrideRedirect, &attrs );
setWFlags( WType_Popup );
}
diff --git a/twin/workspace.cpp b/twin/workspace.cpp
index b46697d99..fb59002f8 100644
--- a/twin/workspace.cpp
+++ b/twin/workspace.cpp
@@ -63,9 +63,9 @@ bool supportsCompMgr()
{
int i;
- bool damageExt = XQueryExtension(qt_xdisplay(), "DAMAGE", &i, &i, &i);
- bool compositeExt = XQueryExtension(qt_xdisplay(), "Composite", &i, &i, &i);
- bool xfixesExt = XQueryExtension(qt_xdisplay(), "XFIXES", &i, &i, &i);
+ bool damageExt = XQueryExtension(tqt_xdisplay(), "DAMAGE", &i, &i, &i);
+ bool compositeExt = XQueryExtension(tqt_xdisplay(), "Composite", &i, &i, &i);
+ bool xfixesExt = XQueryExtension(tqt_xdisplay(), "XFIXES", &i, &i, &i);
return damageExt && compositeExt && xfixesExt;
}
@@ -140,8 +140,8 @@ Workspace::Workspace( bool restore )
{
_self = this;
mgr = new PluginMgr;
- root = qt_xrootwin();
- default_colormap = DefaultColormap(qt_xdisplay(), qt_xscreen() );
+ root = tqt_xrootwin();
+ default_colormap = DefaultColormap(tqt_xdisplay(), tqt_xscreen() );
installed_colormap = default_colormap;
session.setAutoDelete( TRUE );
@@ -176,7 +176,7 @@ Workspace::Workspace( bool restore )
KStartupInfo::DisableKWinModule | KStartupInfo::AnnounceSilenceChanges, this );
// select windowmanager privileges
- XSelectInput(qt_xdisplay(), root,
+ XSelectInput(tqt_xdisplay(), root,
KeyPressMask |
PropertyChangeMask |
ColormapChangeMask |
@@ -191,8 +191,8 @@ Workspace::Workspace( bool restore )
long data = 1;
XChangeProperty(
- qt_xdisplay(),
- qt_xrootwin(),
+ tqt_xdisplay(),
+ tqt_xrootwin(),
atoms->twin_running,
atoms->twin_running,
32,
@@ -286,13 +286,13 @@ void Workspace::init()
// maximizedWindowCounter = 0;
supportWindow = new TQWidget;
- XLowerWindow( qt_xdisplay(), supportWindow->winId()); // see usage in layers.cpp
+ XLowerWindow( tqt_xdisplay(), supportWindow->winId()); // see usage in layers.cpp
XSetWindowAttributes attr;
attr.override_redirect = 1;
- null_focus_window = XCreateWindow( qt_xdisplay(), qt_xrootwin(), -1,-1, 1, 1, 0, CopyFromParent,
+ null_focus_window = XCreateWindow( tqt_xdisplay(), tqt_xrootwin(), -1,-1, 1, 1, 0, CopyFromParent,
InputOnly, CopyFromParent, CWOverrideRedirect, &attr );
- XMapWindow(qt_xdisplay(), null_focus_window);
+ XMapWindow(tqt_xdisplay(), null_focus_window);
unsigned long protocols[ 5 ] =
{
@@ -375,13 +375,13 @@ void Workspace::init()
,
};
- rootInfo = new RootInfo( this, qt_xdisplay(), supportWindow->winId(), "KWin",
- protocols, 5, qt_xscreen() );
+ rootInfo = new RootInfo( this, tqt_xdisplay(), supportWindow->winId(), "KWin",
+ protocols, 5, tqt_xscreen() );
loadDesktopSettings();
updateDesktopLayout();
// extra NETRootInfo instance in Client mode is needed to get the values of the properties
- NETRootInfo client_info( qt_xdisplay(), NET::ActiveWindow | NET::CurrentDesktop );
+ NETRootInfo client_info( tqt_xdisplay(), NET::ActiveWindow | NET::CurrentDesktop );
int initial_desktop;
if( !kapp->isSessionRestored())
initial_desktop = client_info.currentDesktop();
@@ -413,8 +413,8 @@ void Workspace::init()
++block_focus; // because it will be set below
char nm[ 100 ];
- sprintf( nm, "_KDE_TOPMENU_OWNER_S%d", DefaultScreen( qt_xdisplay()));
- Atom topmenu_atom = XInternAtom( qt_xdisplay(), nm, False );
+ sprintf( nm, "_KDE_TOPMENU_OWNER_S%d", DefaultScreen( tqt_xdisplay()));
+ Atom topmenu_atom = XInternAtom( tqt_xdisplay(), nm, False );
topmenu_selection = new KSelectionOwner( topmenu_atom );
topmenu_watcher = new KSelectionWatcher( topmenu_atom );
// TODO grabXServer(); - where exactly put this? topmenu selection claiming down belong must be before
@@ -429,11 +429,11 @@ void Workspace::init()
unsigned int i, nwins;
Window root_return, parent_return, *wins;
- XQueryTree(qt_xdisplay(), root, &root_return, &parent_return, &wins, &nwins);
+ XQueryTree(tqt_xdisplay(), root, &root_return, &parent_return, &wins, &nwins);
for (i = 0; i < nwins; i++)
{
XWindowAttributes attr;
- XGetWindowAttributes(qt_xdisplay(), wins[i], &attr);
+ XGetWindowAttributes(tqt_xdisplay(), wins[i], &attr);
if (attr.override_redirect )
continue;
if( topmenu_space && topmenu_space->winId() == wins[ i ] )
@@ -443,10 +443,10 @@ void Workspace::init()
if ( addSystemTrayWin( wins[i] ) )
continue;
Client* c = createClient( wins[i], true );
- if ( c != NULL && root != qt_xrootwin() )
+ if ( c != NULL && root != tqt_xrootwin() )
{ // TODO what is this?
// TODO may use TQWidget:.create
- XReparentWindow( qt_xdisplay(), c->frameId(), root, 0, 0 );
+ XReparentWindow( tqt_xdisplay(), c->frameId(), root, 0, 0 );
c->move(0,0);
}
}
@@ -518,8 +518,8 @@ Workspace::~Workspace()
delete tab_box;
delete popupinfo;
delete popup;
- if ( root == qt_xrootwin() )
- XDeleteProperty(qt_xdisplay(), qt_xrootwin(), atoms->twin_running);
+ if ( root == tqt_xrootwin() )
+ XDeleteProperty(tqt_xdisplay(), tqt_xrootwin(), atoms->twin_running);
writeWindowRules();
KGlobal::config()->sync();
@@ -540,7 +540,7 @@ Workspace::~Workspace()
delete rules.front();
rules.pop_front();
}
- XDestroyWindow( qt_xdisplay(), null_focus_window );
+ XDestroyWindow( tqt_xdisplay(), null_focus_window );
// TODO ungrabXServer();
_self = 0;
}
@@ -984,7 +984,7 @@ void Workspace::updateColormap()
cmap = activeClient()->colormap();
if ( cmap != installed_colormap )
{
- XInstallColormap(qt_xdisplay(), cmap );
+ XInstallColormap(tqt_xdisplay(), cmap );
installed_colormap = cmap;
}
}
@@ -1301,14 +1301,14 @@ void ObscuringWindows::create( Client* c )
XSetWindowAttributes a;
a.background_pixmap = None;
a.override_redirect = True;
- obs_win = XCreateWindow( qt_xdisplay(), qt_xrootwin(), c->x(), c->y(),
+ obs_win = XCreateWindow( tqt_xdisplay(), tqt_xrootwin(), c->x(), c->y(),
c->width(), c->height(), 0, CopyFromParent, InputOutput,
CopyFromParent, CWBackPixmap | CWOverrideRedirect, &a );
}
chngs.sibling = c->frameId();
chngs.stack_mode = Below;
- XConfigureWindow( qt_xdisplay(), obs_win, mask, &chngs );
- XMapWindow( qt_xdisplay(), obs_win );
+ XConfigureWindow( tqt_xdisplay(), obs_win, mask, &chngs );
+ XMapWindow( tqt_xdisplay(), obs_win );
obscuring_windows.append( obs_win );
}
@@ -1319,11 +1319,11 @@ ObscuringWindows::~ObscuringWindows()
it != obscuring_windows.end();
++it )
{
- XUnmapWindow( qt_xdisplay(), *it );
+ XUnmapWindow( tqt_xdisplay(), *it );
if( cached->count() < max_cache_size )
cached->prepend( *it );
else
- XDestroyWindow( qt_xdisplay(), *it );
+ XDestroyWindow( tqt_xdisplay(), *it );
}
}
@@ -1386,7 +1386,7 @@ bool Workspace::setCurrentDesktop( int new_desktop )
if (desktopHasCompositing) {
// If composition is in use then we cannot hide the old windows before showing the new ones,
// unless you happen to like the "flicker annoyingly to desktop" effect... :-P
- XSync( qt_xdisplay(), false); // Make absolutely certain all new windows are shown before hiding the old ones
+ XSync( tqt_xdisplay(), false); // Make absolutely certain all new windows are shown before hiding the old ones
for ( ClientList::ConstIterator it = stacking_order.begin(); it != stacking_order.end(); ++it) {
if ( !(*it)->isOnDesktop( new_desktop ) && (*it) != movingClient )
{
@@ -1812,15 +1812,15 @@ bool Workspace::addSystemTrayWin( WId w )
if ( systemTrayWins.contains( w ) )
return TRUE;
- NETWinInfo ni( qt_xdisplay(), w, root, NET::WMKDESystemTrayWinFor );
+ NETWinInfo ni( tqt_xdisplay(), w, root, NET::WMKDESystemTrayWinFor );
WId trayWinFor = ni.kdeSystemTrayWinFor();
if ( !trayWinFor )
return FALSE;
systemTrayWins.append( SystemTrayWindow( w, trayWinFor ) );
- XSelectInput( qt_xdisplay(), w,
+ XSelectInput( tqt_xdisplay(), w,
StructureNotifyMask
);
- XAddToSaveSet( qt_xdisplay(), w );
+ XAddToSaveSet( tqt_xdisplay(), w );
propagateSystemTrayWins();
return TRUE;
}
@@ -1843,7 +1843,7 @@ bool Workspace::removeSystemTrayWin( WId w, bool check )
// embedding it, allowing KWin to figure out. Kicker just mustn't
// crash before removing it again ... *shrug* .
int num_props;
- Atom* props = XListProperties( qt_xdisplay(), w, &num_props );
+ Atom* props = XListProperties( tqt_xdisplay(), w, &num_props );
if( props != NULL )
{
for( int i = 0;
@@ -1858,7 +1858,7 @@ bool Workspace::removeSystemTrayWin( WId w, bool check )
}
}
systemTrayWins.remove( w );
- XRemoveFromSaveSet (qt_xdisplay (), w);
+ XRemoveFromSaveSet (tqt_xdisplay (), w);
propagateSystemTrayWins();
return TRUE;
}
@@ -1896,7 +1896,7 @@ void Workspace::killWindowId( Window window_to_kill )
Window parent, root;
Window* children;
unsigned int children_count;
- XQueryTree( qt_xdisplay(), window, &root, &parent, &children, &children_count );
+ XQueryTree( tqt_xdisplay(), window, &root, &parent, &children, &children_count );
if( children != NULL )
XFree( children );
if( window == root ) // we didn't find the client, probably an override-redirect window
@@ -1906,7 +1906,7 @@ void Workspace::killWindowId( Window window_to_kill )
if( client != NULL )
client->killWindow();
else
- XKillClient( qt_xdisplay(), window_to_kill );
+ XKillClient( tqt_xdisplay(), window_to_kill );
}
void Workspace::suspendWindowId( Window window_to_suspend )
@@ -1923,7 +1923,7 @@ void Workspace::suspendWindowId( Window window_to_suspend )
Window parent, root;
Window* children;
unsigned int children_count;
- XQueryTree( qt_xdisplay(), window, &root, &parent, &children, &children_count );
+ XQueryTree( tqt_xdisplay(), window, &root, &parent, &children, &children_count );
if( children != NULL )
XFree( children );
if( window == root ) // we didn't find the client, probably an override-redirect window
@@ -1950,7 +1950,7 @@ void Workspace::resumeWindowId( Window window_to_resume )
Window parent, root;
Window* children;
unsigned int children_count;
- XQueryTree( qt_xdisplay(), window, &root, &parent, &children, &children_count );
+ XQueryTree( tqt_xdisplay(), window, &root, &parent, &children, &children_count );
if( children != NULL )
XFree( children );
if( window == root ) // we didn't find the client, probably an override-redirect window
@@ -1990,7 +1990,7 @@ void Workspace::slotGrabWindow()
{
//As the first step, get the mask from XShape.
int count, order;
- XRectangle* rects = XShapeGetRectangles( qt_xdisplay(), active_client->frameId(),
+ XRectangle* rects = XShapeGetRectangles( tqt_xdisplay(), active_client->frameId(),
ShapeBounding, &count, &order);
//The ShapeBounding region is the outermost shape of the window;
//ShapeBounding - ShapeClipping is defined to be the border.
@@ -2035,7 +2035,7 @@ void Workspace::slotGrabWindow()
*/
void Workspace::slotGrabDesktop()
{
- TQPixmap p = TQPixmap::grabWindow( qt_xrootwin() );
+ TQPixmap p = TQPixmap::grabWindow( tqt_xrootwin() );
TQClipboard *cb = TQApplication::clipboard();
cb->setPixmap( p );
}
@@ -2049,12 +2049,12 @@ void Workspace::slotMouseEmulation()
if ( mouse_emulation )
{
- XUngrabKeyboard(qt_xdisplay(), GET_QT_X_TIME());
+ XUngrabKeyboard(tqt_xdisplay(), GET_QT_X_TIME());
mouse_emulation = FALSE;
return;
}
- if ( XGrabKeyboard(qt_xdisplay(),
+ if ( XGrabKeyboard(tqt_xdisplay(),
root, FALSE,
GrabModeAsync, GrabModeAsync,
GET_QT_X_TIME()) == GrabSuccess )
@@ -2074,7 +2074,7 @@ void Workspace::slotMouseEmulation()
WId Workspace::getMouseEmulationWindow()
{
Window root;
- Window child = qt_xrootwin();
+ Window child = tqt_xrootwin();
int root_x, root_y, lx, ly;
uint state;
Window w;
@@ -2084,7 +2084,7 @@ WId Workspace::getMouseEmulationWindow()
w = child;
if (!c)
c = findClient( FrameIdMatchPredicate( w ));
- XQueryPointer( qt_xdisplay(), w, &root, &child,
+ XQueryPointer( tqt_xdisplay(), w, &root, &child,
&root_x, &root_y, &lx, &ly, &state );
} while ( child != None && child != w );
@@ -2105,13 +2105,13 @@ unsigned int Workspace::sendFakedMouseEvent( TQPoint pos, WId w, MouseEmulation
{
int x, y;
Window xw;
- XTranslateCoordinates( qt_xdisplay(), qt_xrootwin(), w, pos.x(), pos.y(), &x, &y, &xw );
+ XTranslateCoordinates( tqt_xdisplay(), tqt_xrootwin(), w, pos.x(), pos.y(), &x, &y, &xw );
if ( type == EmuMove )
{ // motion notify events
XEvent e;
e.type = MotionNotify;
e.xmotion.window = w;
- e.xmotion.root = qt_xrootwin();
+ e.xmotion.root = tqt_xrootwin();
e.xmotion.subwindow = w;
e.xmotion.time = GET_QT_X_TIME();
e.xmotion.x = x;
@@ -2120,14 +2120,14 @@ unsigned int Workspace::sendFakedMouseEvent( TQPoint pos, WId w, MouseEmulation
e.xmotion.y_root = pos.y();
e.xmotion.state = state;
e.xmotion.is_hint = NotifyNormal;
- XSendEvent( qt_xdisplay(), w, TRUE, ButtonMotionMask, &e );
+ XSendEvent( tqt_xdisplay(), w, TRUE, ButtonMotionMask, &e );
}
else
{
XEvent e;
e.type = type == EmuRelease ? ButtonRelease : ButtonPress;
e.xbutton.window = w;
- e.xbutton.root = qt_xrootwin();
+ e.xbutton.root = tqt_xrootwin();
e.xbutton.subwindow = w;
e.xbutton.time = GET_QT_X_TIME();
e.xbutton.x = x;
@@ -2136,7 +2136,7 @@ unsigned int Workspace::sendFakedMouseEvent( TQPoint pos, WId w, MouseEmulation
e.xbutton.y_root = pos.y();
e.xbutton.state = state;
e.xbutton.button = button;
- XSendEvent( qt_xdisplay(), w, TRUE, ButtonPressMask, &e );
+ XSendEvent( tqt_xdisplay(), w, TRUE, ButtonPressMask, &e );
if ( type == EmuPress )
{
@@ -2178,9 +2178,9 @@ unsigned int Workspace::sendFakedMouseEvent( TQPoint pos, WId w, MouseEmulation
*/
bool Workspace::keyPressMouseEmulation( XKeyEvent& ev )
{
- if ( root != qt_xrootwin() )
+ if ( root != tqt_xrootwin() )
return FALSE;
- int kc = XKeycodeToKeysym(qt_xdisplay(), ev.keycode, 0);
+ int kc = XKeycodeToKeysym(tqt_xdisplay(), ev.keycode, 0);
int km = ev.state & (ControlMask | Mod1Mask | ShiftMask);
bool is_control = km & ControlMask;
@@ -2255,7 +2255,7 @@ bool Workspace::keyPressMouseEmulation( XKeyEvent& ev )
}
// fall through
case XK_Escape:
- XUngrabKeyboard(qt_xdisplay(), GET_QT_X_TIME());
+ XUngrabKeyboard(tqt_xdisplay(), GET_QT_X_TIME());
mouse_emulation = FALSE;
return TRUE;
default:
@@ -2340,58 +2340,58 @@ void Workspace::createBorderWindows()
attributes.override_redirect = True;
attributes.event_mask = ( EnterWindowMask | LeaveWindowMask );
valuemask= (CWOverrideRedirect | CWEventMask | CWCursor );
- attributes.cursor = XCreateFontCursor(qt_xdisplay(),
+ attributes.cursor = XCreateFontCursor(tqt_xdisplay(),
XC_sb_up_arrow);
- electric_top_border = XCreateWindow (qt_xdisplay(), qt_xrootwin(),
+ electric_top_border = XCreateWindow (tqt_xdisplay(), tqt_xrootwin(),
0,0,
r.width(),1,
0,
CopyFromParent, InputOnly,
CopyFromParent,
valuemask, &attributes);
- XMapWindow(qt_xdisplay(), electric_top_border);
+ XMapWindow(tqt_xdisplay(), electric_top_border);
- attributes.cursor = XCreateFontCursor(qt_xdisplay(),
+ attributes.cursor = XCreateFontCursor(tqt_xdisplay(),
XC_sb_down_arrow);
- electric_bottom_border = XCreateWindow (qt_xdisplay(), qt_xrootwin(),
+ electric_bottom_border = XCreateWindow (tqt_xdisplay(), tqt_xrootwin(),
0,r.height()-1,
r.width(),1,
0,
CopyFromParent, InputOnly,
CopyFromParent,
valuemask, &attributes);
- XMapWindow(qt_xdisplay(), electric_bottom_border);
+ XMapWindow(tqt_xdisplay(), electric_bottom_border);
- attributes.cursor = XCreateFontCursor(qt_xdisplay(),
+ attributes.cursor = XCreateFontCursor(tqt_xdisplay(),
XC_sb_left_arrow);
- electric_left_border = XCreateWindow (qt_xdisplay(), qt_xrootwin(),
+ electric_left_border = XCreateWindow (tqt_xdisplay(), tqt_xrootwin(),
0,0,
1,r.height(),
0,
CopyFromParent, InputOnly,
CopyFromParent,
valuemask, &attributes);
- XMapWindow(qt_xdisplay(), electric_left_border);
+ XMapWindow(tqt_xdisplay(), electric_left_border);
- attributes.cursor = XCreateFontCursor(qt_xdisplay(),
+ attributes.cursor = XCreateFontCursor(tqt_xdisplay(),
XC_sb_right_arrow);
- electric_right_border = XCreateWindow (qt_xdisplay(), qt_xrootwin(),
+ electric_right_border = XCreateWindow (tqt_xdisplay(), tqt_xrootwin(),
r.width()-1,0,
1,r.height(),
0,
CopyFromParent, InputOnly,
CopyFromParent,
valuemask, &attributes);
- XMapWindow(qt_xdisplay(), electric_right_border);
+ XMapWindow(tqt_xdisplay(), electric_right_border);
// Set XdndAware on the windows, so that DND enter events are received (#86998)
Atom version = 4; // XDND version
- XChangeProperty( qt_xdisplay(), electric_top_border, atoms->xdnd_aware, XA_ATOM,
+ XChangeProperty( tqt_xdisplay(), electric_top_border, atoms->xdnd_aware, XA_ATOM,
32, PropModeReplace, ( unsigned char* )&version, 1 );
- XChangeProperty( qt_xdisplay(), electric_bottom_border, atoms->xdnd_aware, XA_ATOM,
+ XChangeProperty( tqt_xdisplay(), electric_bottom_border, atoms->xdnd_aware, XA_ATOM,
32, PropModeReplace, ( unsigned char* )&version, 1 );
- XChangeProperty( qt_xdisplay(), electric_left_border, atoms->xdnd_aware, XA_ATOM,
+ XChangeProperty( tqt_xdisplay(), electric_left_border, atoms->xdnd_aware, XA_ATOM,
32, PropModeReplace, ( unsigned char* )&version, 1 );
- XChangeProperty( qt_xdisplay(), electric_right_border, atoms->xdnd_aware, XA_ATOM,
+ XChangeProperty( tqt_xdisplay(), electric_right_border, atoms->xdnd_aware, XA_ATOM,
32, PropModeReplace, ( unsigned char* )&version, 1 );
}
@@ -2409,13 +2409,13 @@ void Workspace::destroyBorderWindows()
electric_have_borders = false;
if(electric_top_border)
- XDestroyWindow(qt_xdisplay(),electric_top_border);
+ XDestroyWindow(tqt_xdisplay(),electric_top_border);
if(electric_bottom_border)
- XDestroyWindow(qt_xdisplay(),electric_bottom_border);
+ XDestroyWindow(tqt_xdisplay(),electric_bottom_border);
if(electric_left_border)
- XDestroyWindow(qt_xdisplay(),electric_left_border);
+ XDestroyWindow(tqt_xdisplay(),electric_left_border);
if(electric_right_border)
- XDestroyWindow(qt_xdisplay(),electric_right_border);
+ XDestroyWindow(tqt_xdisplay(),electric_right_border);
electric_top_border = None;
electric_bottom_border = None;
@@ -2565,10 +2565,10 @@ void Workspace::raiseElectricBorders()
if(electric_have_borders)
{
- XRaiseWindow(qt_xdisplay(), electric_top_border);
- XRaiseWindow(qt_xdisplay(), electric_left_border);
- XRaiseWindow(qt_xdisplay(), electric_bottom_border);
- XRaiseWindow(qt_xdisplay(), electric_right_border);
+ XRaiseWindow(tqt_xdisplay(), electric_top_border);
+ XRaiseWindow(tqt_xdisplay(), electric_left_border);
+ XRaiseWindow(tqt_xdisplay(), electric_bottom_border);
+ XRaiseWindow(tqt_xdisplay(), electric_right_border);
}
}
@@ -2647,7 +2647,7 @@ void Workspace::setupTopMenuHandling()
Window stack[ 2 ];
stack[ 0 ] = supportWindow->winId();
stack[ 1 ] = topmenu_space->winId();
- XRestackWindows(qt_xdisplay(), stack, 2);
+ XRestackWindows(tqt_xdisplay(), stack, 2);
updateTopMenuGeometry();
topmenu_space->show();
updateClientArea();
@@ -2686,7 +2686,7 @@ bool Workspace::checkStartupNotification( Window w, KStartupInfoId& id, KStartup
*/
void Workspace::focusToNull()
{
- XSetInputFocus(qt_xdisplay(), null_focus_window, RevertToPointerRoot, GET_QT_X_TIME() );
+ XSetInputFocus(tqt_xdisplay(), null_focus_window, RevertToPointerRoot, GET_QT_X_TIME() );
}
void Workspace::helperDialog( const TQString& message, const Client* c )
@@ -2746,8 +2746,8 @@ void Workspace::startKompmgr()
unsigned long length, after;
unsigned char* data_root;
Atom prop_root;
- prop_root = XInternAtom(qt_xdisplay(), "_XROOTPMAP_ID", False);
- if( XGetWindowProperty( qt_xdisplay(), qt_xrootwin(), prop_root, 0L, 1L, False, AnyPropertyType, &type, &format, &length, &after, &data_root) == Success && data_root != NULL ) {
+ prop_root = XInternAtom(tqt_xdisplay(), "_XROOTPMAP_ID", False);
+ if( XGetWindowProperty( tqt_xdisplay(), tqt_xrootwin(), prop_root, 0L, 1L, False, AnyPropertyType, &type, &format, &length, &after, &data_root) == Success && data_root != NULL ) {
// Root pixmap is available; OK to load...
}
else {
@@ -2770,7 +2770,7 @@ void Workspace::startKompmgr()
{
delete kompmgr_selection;
char selection_name[ 100 ];
- sprintf( selection_name, "_NET_WM_CM_S%d", DefaultScreen( qt_xdisplay()));
+ sprintf( selection_name, "_NET_WM_CM_S%d", DefaultScreen( tqt_xdisplay()));
kompmgr_selection = new KSelectionOwner( selection_name );
connect( kompmgr_selection, TQT_SIGNAL( lostOwnership()), TQT_SLOT( stopKompmgr()));
kompmgr_selection->claim( true );