diff options
author | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2010-07-31 19:33:34 +0000 |
---|---|---|
committer | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2010-07-31 19:33:34 +0000 |
commit | c663b6440964f6ac48027143ac9e63298991f9d0 (patch) | |
tree | 6d8b0c5a5f9db1ee16acf98b1397cea9126b281d /kwin/kcmkwin/kwinrules/main.cpp | |
parent | a061f7191beebb0e4a3b0c0a7c534ec5f22f2dc7 (diff) | |
download | tdebase-c663b6440964f6ac48027143ac9e63298991f9d0.tar.gz tdebase-c663b6440964f6ac48027143ac9e63298991f9d0.zip |
Trinity Qt initial conversion
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdebase@1157639 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kwin/kcmkwin/kwinrules/main.cpp')
-rw-r--r-- | kwin/kcmkwin/kwinrules/main.cpp | 34 |
1 files changed, 17 insertions, 17 deletions
diff --git a/kwin/kcmkwin/kwinrules/main.cpp b/kwin/kcmkwin/kwinrules/main.cpp index 9657e3649..b58c96239 100644 --- a/kwin/kcmkwin/kwinrules/main.cpp +++ b/kwin/kcmkwin/kwinrules/main.cpp @@ -32,7 +32,7 @@ namespace KWinInternal { -static void loadRules( QValueList< Rules* >& rules ) +static void loadRules( TQValueList< Rules* >& rules ) { KConfig cfg( "kwinrulesrc", true ); cfg.setGroup( "General" ); @@ -41,52 +41,52 @@ static void loadRules( QValueList< Rules* >& rules ) i <= count; ++i ) { - cfg.setGroup( QString::number( i )); + cfg.setGroup( TQString::number( i )); Rules* rule = new Rules( cfg ); rules.append( rule ); } } -static void saveRules( const QValueList< Rules* >& rules ) +static void saveRules( const TQValueList< Rules* >& rules ) { KConfig cfg( "kwinrulesrc" ); - QStringList groups = cfg.groupList(); - for( QStringList::ConstIterator it = groups.begin(); + TQStringList groups = cfg.groupList(); + for( TQStringList::ConstIterator it = groups.begin(); it != groups.end(); ++it ) cfg.deleteGroup( *it ); cfg.setGroup( "General" ); cfg.writeEntry( "count", rules.count()); int i = 1; - for( QValueList< Rules* >::ConstIterator it = rules.begin(); + for( TQValueList< Rules* >::ConstIterator it = rules.begin(); it != rules.end(); ++it ) { - cfg.setGroup( QString::number( i )); + cfg.setGroup( TQString::number( i )); (*it)->write( cfg ); ++i; } } -static Rules* findRule( const QValueList< Rules* >& rules, Window wid, bool whole_app ) +static Rules* findRule( const TQValueList< Rules* >& rules, Window wid, bool whole_app ) { KWin::WindowInfo info = KWin::windowInfo( wid, NET::WMName | NET::WMWindowType, NET::WM2WindowClass | NET::WM2WindowRole | NET::WM2ClientMachine ); if( !info.valid()) // shouldn't really happen return NULL; - QCString wmclass_class = info.windowClassClass().lower(); - QCString wmclass_name = info.windowClassName().lower(); - QCString role = info.windowRole().lower(); + TQCString wmclass_class = info.windowClassClass().lower(); + TQCString wmclass_name = info.windowClassName().lower(); + TQCString role = info.windowRole().lower(); NET::WindowType type = info.windowType( NET::NormalMask | NET::DesktopMask | NET::DockMask | NET::ToolbarMask | NET::MenuMask | NET::DialogMask | NET::OverrideMask | NET::TopMenuMask | NET::UtilityMask | NET::SplashMask ); - QString title = info.name(); -// QCString extrarole = ""; // TODO - QCString machine = info.clientMachine().lower(); + TQString title = info.name(); +// TQCString extrarole = ""; // TODO + TQCString machine = info.clientMachine().lower(); Rules* best_match = NULL; int match_quality = 0; - for( QValueList< Rules* >::ConstIterator it = rules.begin(); + for( TQValueList< Rules* >::ConstIterator it = rules.begin(); it != rules.end(); ++it ) { @@ -233,7 +233,7 @@ static Rules* findRule( const QValueList< Rules* >& rules, Window wid, bool whol static int edit( Window wid, bool whole_app ) { - QValueList< Rules* > rules; + TQValueList< Rules* > rules; loadRules( rules ); Rules* orig_rule = findRule( rules, wid, whole_app ); RulesDialog dlg; @@ -248,7 +248,7 @@ static int edit( Window wid, bool whole_app ) } else if( edited_rule != orig_rule ) { - QValueList< Rules* >::Iterator pos = rules.find( orig_rule ); + TQValueList< Rules* >::Iterator pos = rules.find( orig_rule ); if( pos != rules.end()) *pos = edited_rule; else |