summaryrefslogtreecommitdiffstats
path: root/kstart
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-01-19 01:42:14 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-01-19 01:42:14 +0000
commit8155225c9be993acc0512956416d195edfef4eb9 (patch)
treede4f3cd17614fc67e47eefabcdbe2fbe170c9be7 /kstart
parent364641b8e0279758d236af39abd138d379328a19 (diff)
downloadtdebase-8155225c9be993acc0512956416d195edfef4eb9.tar.gz
tdebase-8155225c9be993acc0512956416d195edfef4eb9.zip
Enable compilation with TQt for Qt4 3.4.0 TP2
This should not break compatibility with TQt for Qt3; if it does please fix it ASAP! git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdebase@1215552 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kstart')
-rw-r--r--kstart/kstart.cpp24
1 files changed, 12 insertions, 12 deletions
diff --git a/kstart/kstart.cpp b/kstart/kstart.cpp
index f3be8e607..d9b8b5e0b 100644
--- a/kstart/kstart.cpp
+++ b/kstart/kstart.cpp
@@ -56,7 +56,7 @@ KStart::KStart()
else {
// connect to window add to get the NEW windows
connect(kwinmodule, TQT_SIGNAL(windowAdded(WId)), TQT_SLOT(windowAdded(WId)));
- if (windowtitle)
+ if (windowtitle != 0)
kwinmodule->doNotManage( windowtitle );
}
// propagate the app startup notification info to the started app
@@ -70,7 +70,7 @@ KStart::KStart()
data.addPid( proc.pid() );
TQCString bin = proc.args().first();
data.setName( bin );
- data.setBin( bin.mid( bin.findRev( '/' ) + 1 ));
+ data.setBin( bin.mid( bin.tqfindRev( '/' ) + 1 ));
KStartupInfo::sendChange( id, data );
}
else
@@ -82,14 +82,14 @@ KStart::KStart()
void KStart::sendRule() {
KXMessages msg;
TQCString message;
- if( windowtitle )
+ if( windowtitle != 0 )
message += "title=" + windowtitle + "\ntitlematch=3\n"; // 3 = regexp match
- if( windowclass )
+ if( windowclass != 0 )
message += "wmclass=" + windowclass + "\nwmclassmatch=1\n" // 1 = exact match
+ "wmclasscomplete="
// if windowclass contains a space (i.e. 2 words, use whole WM_CLASS)
- + ( windowclass.contains( ' ' ) ? "true" : "false" ) + "\n";
- if( windowtitle || windowclass ) {
+ + ( windowclass.tqcontains( ' ' ) ? "true" : "false" ) + "\n";
+ if( (windowtitle != 0) || (windowclass != 0) ) {
// always ignore these window types
message += "types=" + TQCString().setNum( -1U &
~( NET::TopMenuMask | NET::ToolbarMask | NET::DesktopMask | NET::SplashMask | NET::MenuMask )) + "\n";
@@ -143,17 +143,17 @@ void KStart::windowAdded(WId w){
|| info.windowType( SUPPORTED_WINDOW_TYPES_MASK ) == NET::Desktop )
return;
- if ( windowtitle ) {
+ if ( windowtitle != 0 ) {
TQString title = info.name().lower();
TQRegExp r( windowtitle.lower());
if (r.match(title) == -1)
return; // no match
}
- if ( windowclass ) {
+ if ( windowclass != 0 ) {
XClassHint hint;
if( !XGetClassHint( qt_xdisplay(), w, &hint ))
return;
- TQCString cls = windowclass.contains( ' ' )
+ TQCString cls = windowclass.tqcontains( ' ' )
? TQCString( hint.res_name ) + ' ' + hint.res_class : TQCString( hint.res_class );
cls = cls.lower();
XFree( hint.res_name );
@@ -161,7 +161,7 @@ void KStart::windowAdded(WId w){
if( cls != windowclass )
return;
}
- if( !windowtitle && !windowclass ) {
+ if( (windowtitle == 0) && (windowclass == 0) ) {
// accept only "normal" windows
if( info.windowType( SUPPORTED_WINDOW_TYPES_MASK ) != NET::Unknown
&& info.windowType( SUPPORTED_WINDOW_TYPES_MASK ) != NET::Normal
@@ -185,7 +185,7 @@ static bool wstate_withdrawn( WId winid )
&length, &after, &data );
bool withdrawn = TRUE;
if ( r == Success && data && format == 32 ) {
- Q_UINT32 *wstate = (Q_UINT32*)data;
+ TQ_UINT32 *wstate = (TQ_UINT32*)data;
withdrawn = (*wstate == WithdrawnState );
XFree( (char *)data );
}
@@ -322,7 +322,7 @@ int main( int argc, char *argv[] )
windowtitle = args->getOption( "window" );
windowclass = args->getOption( "windowclass" );
- if( windowclass )
+ if( windowclass != 0 )
windowclass = windowclass.lower();
if( windowtitle.isEmpty() && windowclass.isEmpty())