diff options
author | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-04-13 00:46:47 +0000 |
---|---|---|
committer | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-04-13 00:46:47 +0000 |
commit | 67e29a054cfcb1b0d2fe6b0a316cf6b3eec087b7 (patch) | |
tree | 5f52a9eada2e9f3654fc327d7c14dfef570a6ecb /korganizer/kocore.cpp | |
parent | 2ee4bf4fd5eff93b2fbef0ff8e8063edffc5da5c (diff) | |
download | tdepim-67e29a054cfcb1b0d2fe6b0a316cf6b3eec087b7.tar.gz tdepim-67e29a054cfcb1b0d2fe6b0a316cf6b3eec087b7.zip |
Initial conversion of kdepim to TQt
This will probably require some tweaking before it will build under Qt4,
however Qt3 builds are OK. Any alterations this commit makes to kdepim
behaviour under Qt3 are unintentional and should be fixed.
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdepim@1227832 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'korganizer/kocore.cpp')
-rw-r--r-- | korganizer/kocore.cpp | 46 |
1 files changed, 23 insertions, 23 deletions
diff --git a/korganizer/kocore.cpp b/korganizer/kocore.cpp index d4829559a..6313dd2fa 100644 --- a/korganizer/kocore.cpp +++ b/korganizer/kocore.cpp @@ -19,8 +19,8 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. As a special exception, permission is given to link this program - with any edition of Qt, and distribute the resulting executable, - without including the source code for Qt in the source distribution. + with any edition of TQt, and distribute the resulting executable, + without including the source code for TQt in the source distribution. */ #include "kocore.h" @@ -170,7 +170,7 @@ KOrg::CalendarDecoration *KOCore::loadCalendarDecoration( const TQString &name ) return 0; } -KOrg::Part *KOCore::loadPart( KService::Ptr service, KOrg::MainWindow *parent ) +KOrg::Part *KOCore::loadPart( KService::Ptr service, KOrg::MainWindow *tqparent ) { kdDebug(5850) << "loadPart: library: " << service->library() << endl; @@ -194,7 +194,7 @@ KOrg::Part *KOCore::loadPart( KService::Ptr service, KOrg::MainWindow *parent ) return 0; } - return pluginFactory->create( parent ); + return pluginFactory->create( tqparent ); } KOrg::PrintPlugin *KOCore::loadPrintPlugin( KService::Ptr service ) @@ -237,20 +237,20 @@ void KOCore::removeXMLGUIClient( TQWidget *wdg ) KXMLGUIClient* KOCore::xmlguiClient( TQWidget *wdg ) const { TQWidget *topLevel = wdg->tqtopLevelWidget(); - TQMap<TQWidget*, KXMLGUIClient*>::ConstIterator it = mXMLGUIClients.find( topLevel ); + TQMap<TQWidget*, KXMLGUIClient*>::ConstIterator it = mXMLGUIClients.tqfind( topLevel ); if ( it != mXMLGUIClients.end() ) return it.data(); return 0; } -KOrg::Part *KOCore::loadPart( const TQString &name, KOrg::MainWindow *parent ) +KOrg::Part *KOCore::loadPart( const TQString &name, KOrg::MainWindow *tqparent ) { KTrader::OfferList list = availableParts(); KTrader::OfferList::ConstIterator it; for( it = list.begin(); it != list.end(); ++it ) { if ( (*it)->desktopEntryName() == name ) { - return loadPart( *it, parent ); + return loadPart( *it, tqparent ); } } return 0; @@ -279,7 +279,7 @@ KOrg::CalendarDecoration::List KOCore::calendarDecorations() for( it = plugins.begin(); it != plugins.end(); ++it ) { if ( (*it)->hasServiceType("Calendar/Decoration") ) { TQString name = (*it)->desktopEntryName(); - if ( selectedPlugins.find( name ) != selectedPlugins.end() ) { + if ( selectedPlugins.tqfind( name ) != selectedPlugins.end() ) { KOrg::CalendarDecoration *d = loadCalendarDecoration(*it); mCalendarDecorations.append( d ); } @@ -291,7 +291,7 @@ KOrg::CalendarDecoration::List KOCore::calendarDecorations() return mCalendarDecorations; } -KOrg::Part::List KOCore::loadParts( KOrg::MainWindow *parent ) +KOrg::Part::List KOCore::loadParts( KOrg::MainWindow *tqparent ) { KOrg::Part::List parts; @@ -300,15 +300,15 @@ KOrg::Part::List KOCore::loadParts( KOrg::MainWindow *parent ) KTrader::OfferList plugins = availableParts(); KTrader::OfferList::ConstIterator it; for( it = plugins.begin(); it != plugins.end(); ++it ) { - if ( selectedPlugins.find( (*it)->desktopEntryName() ) != + if ( selectedPlugins.tqfind( (*it)->desktopEntryName() ) != selectedPlugins.end() ) { - KOrg::Part *part = loadPart( *it, parent ); + KOrg::Part *part = loadPart( *it, tqparent ); if ( part ) { - if ( !parent->mainGuiClient() ) { - kdError() << "KOCore::loadParts(): parent has no mainGuiClient." + if ( !tqparent->mainGuiClient() ) { + kdError() << "KOCore::loadParts(): tqparent has no mainGuiClient." << endl; } else { - parent->mainGuiClient()->insertChildClient( part ); + tqparent->mainGuiClient()->insertChildClient( part ); parts.append( part ); } } @@ -326,7 +326,7 @@ KOrg::PrintPlugin::List KOCore::loadPrintPlugins() KTrader::OfferList plugins = availablePrintPlugins(); KTrader::OfferList::ConstIterator it; for( it = plugins.begin(); it != plugins.end(); ++it ) { - if ( selectedPlugins.find( (*it)->desktopEntryName() ) != + if ( selectedPlugins.tqfind( (*it)->desktopEntryName() ) != selectedPlugins.end() ) { KOrg::PrintPlugin *part = loadPrintPlugin( *it ); if ( part ) loadedPlugins.append( part ); @@ -346,26 +346,26 @@ void KOCore::unloadPlugins() mCalendarDecorationsLoaded = false; } -void KOCore::unloadParts( KOrg::MainWindow *parent, KOrg::Part::List &parts ) +void KOCore::unloadParts( KOrg::MainWindow *tqparent, KOrg::Part::List &parts ) { KOrg::Part *part; for( part = parts.first(); part; part = parts.next() ) { - parent->mainGuiClient()->removeChildClient( part ); + tqparent->mainGuiClient()->removeChildClient( part ); delete part; } parts.clear(); } -KOrg::Part::List KOCore::reloadParts( KOrg::MainWindow *parent, +KOrg::Part::List KOCore::reloadParts( KOrg::MainWindow *tqparent, KOrg::Part::List &parts ) { - KXMLGUIFactory *factory = parent->mainGuiClient()->factory(); - factory->removeClient( parent->mainGuiClient() ); + KXMLGUIFactory *factory = tqparent->mainGuiClient()->factory(); + factory->removeClient( tqparent->mainGuiClient() ); - unloadParts( parent, parts ); - KOrg::Part::List list = loadParts( parent ); + unloadParts( tqparent, parts ); + KOrg::Part::List list = loadParts( tqparent ); - factory->addClient( parent->mainGuiClient() ); + factory->addClient( tqparent->mainGuiClient() ); return list; } |