diff options
author | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-04-14 20:16:30 +0000 |
---|---|---|
committer | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-04-14 20:16:30 +0000 |
commit | 1c93fca14d9ce37499bcfdf994c660186a0b6f17 (patch) | |
tree | f2defe163a805a9e34a2142dfde4cdb5e49241e7 /kontact/src | |
parent | 67e29a054cfcb1b0d2fe6b0a316cf6b3eec087b7 (diff) | |
download | tdepim-1c93fca14d9ce37499bcfdf994c660186a0b6f17.tar.gz tdepim-1c93fca14d9ce37499bcfdf994c660186a0b6f17.zip |
Enable kdepim compilation under Qt4
This will likely break Qt3 compilation temporarily, which is an unintended side effect.
A third and final kdepim commit will repair Qt3 compilation shortly.
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdepim@1227946 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kontact/src')
-rw-r--r-- | kontact/src/aboutdialog.cpp | 6 | ||||
-rw-r--r-- | kontact/src/iconsidepane.cpp | 8 | ||||
-rw-r--r-- | kontact/src/kcmkontact.cpp | 2 | ||||
-rw-r--r-- | kontact/src/main.cpp | 2 | ||||
-rw-r--r-- | kontact/src/mainwindow.cpp | 100 | ||||
-rw-r--r-- | kontact/src/profiledialog.cpp | 8 | ||||
-rw-r--r-- | kontact/src/profilemanager.cpp | 2 |
7 files changed, 64 insertions, 64 deletions
diff --git a/kontact/src/aboutdialog.cpp b/kontact/src/aboutdialog.cpp index e7fef654a..02e48e771 100644 --- a/kontact/src/aboutdialog.cpp +++ b/kontact/src/aboutdialog.cpp @@ -81,7 +81,7 @@ void AboutDialog::addAboutData( const TQString &title, const TQString &icon, text += "<p><b>" + about->programName() + "</b><br>"; - text += i18n( "Version %1</p>" ).arg( about->version() ); + text += i18n( "Version %1</p>" ).tqarg( about->version() ); if ( !about->shortDescription().isEmpty() ) { text += "<p>" + about->shortDescription() + "<br>" + @@ -163,13 +163,13 @@ void AboutDialog::addLicenseText( const KAboutData *about ) TQPixmap pixmap = KGlobal::iconLoader()->loadIcon( "signature", KIcon::Desktop, 48 ); - TQString title = i18n( "%1 License" ).arg( about->programName() ); + TQString title = i18n( "%1 License" ).tqarg( about->programName() ); TQFrame *topFrame = addPage( title, TQString(), pixmap ); TQBoxLayout *topLayout = new TQVBoxLayout( topFrame ); KTextBrowser *textBrowser = new KTextBrowser( topFrame ); - textBrowser->setText( TQString( "<pre>%1</pre>" ).arg( about->license() ) ); + textBrowser->setText( TQString( "<pre>%1</pre>" ).tqarg( about->license() ) ); topLayout->addWidget( textBrowser ); } diff --git a/kontact/src/iconsidepane.cpp b/kontact/src/iconsidepane.cpp index 7e4d027ed..fa19c1f7c 100644 --- a/kontact/src/iconsidepane.cpp +++ b/kontact/src/iconsidepane.cpp @@ -175,7 +175,7 @@ void EntryItem::paint( TQPainter *p ) if ( isCurrent() || isSelected() || mPaintActive ) brush = box->tqcolorGroup().brush( TQColorGroup::Highlight ); else - brush = box->tqcolorGroup().highlight().light( 115 ); + brush = TQBrush(box->tqcolorGroup().highlight().light( 115 )); p->fillRect( 1, 0, w - 2, h - 1, brush ); TQPen pen = p->pen(); TQPen oldPen = pen; @@ -223,7 +223,7 @@ void EntryItem::paint( TQPainter *p ) } if ( plugin()->disabled() ) { - p->setPen( box->palette().disabled().text( ) ); + p->setPen( box->tqpalette().disabled().text( ) ); } else if ( isCurrent() || isSelected() || mHasHover ) { p->setPen( box->tqcolorGroup().highlight().dark(115) ); p->drawText( x + ( TQApplication::reverseLayout() ? -1 : 1), @@ -265,7 +265,7 @@ Navigator::Navigator( IconSidePane *tqparent, const char *name ) setHScrollBarMode( TQScrollView::AlwaysOff ); setAcceptDrops( true ); - setFocusPolicy( NoFocus ); + setFocusPolicy( Qt::NoFocus ); connect( this, TQT_SIGNAL( selectionChanged( TQListBoxItem* ) ), TQT_SLOT( slotExecuted( TQListBoxItem* ) ) ); @@ -275,7 +275,7 @@ Navigator::Navigator( IconSidePane *tqparent, const char *name ) TQT_SLOT( slotMouseOn( TQListBoxItem * ) ) ); connect( this, TQT_SIGNAL( onViewport() ), TQT_SLOT( slotMouseOff() ) ); - mMapper = new TQSignalMapper( this ); + mMapper = new TQSignalMapper( TQT_TQOBJECT(this) ); connect( mMapper, TQT_SIGNAL( mapped( int ) ), TQT_SLOT( shortCutSelected( int ) ) ); TQToolTip::remove( this ); diff --git a/kontact/src/kcmkontact.cpp b/kontact/src/kcmkontact.cpp index 2e7c61f83..fbdd4a045 100644 --- a/kontact/src/kcmkontact.cpp +++ b/kontact/src/kcmkontact.cpp @@ -115,7 +115,7 @@ void PluginSelection::readConfig() { const KTrader::OfferList offers = KTrader::self()->query( TQString::tqfromLatin1( "Kontact/Plugin" ), - TQString( "[X-KDE-KontactPluginVersion] == %1" ).arg( KONTACT_PLUGIN_VERSION ) ); + TQString( "[X-KDE-KontactPluginVersion] == %1" ).tqarg( KONTACT_PLUGIN_VERSION ) ); int activeComponent = 0; mPluginCombo->clear(); diff --git a/kontact/src/main.cpp b/kontact/src/main.cpp index 760ea846e..8d2f3623f 100644 --- a/kontact/src/main.cpp +++ b/kontact/src/main.cpp @@ -77,7 +77,7 @@ static void listPlugins() KInstance instance( "kontact" ); // Can't use KontactApp since it's too late for adding cmdline options KTrader::OfferList offers = KTrader::self()->query( TQString::tqfromLatin1( "Kontact/Plugin" ), - TQString( "[X-KDE-KontactPluginVersion] == %1" ).arg( KONTACT_PLUGIN_VERSION ) ); + TQString( "[X-KDE-KontactPluginVersion] == %1" ).tqarg( KONTACT_PLUGIN_VERSION ) ); for ( KService::List::Iterator it = offers.begin(); it != offers.end(); ++it ) { KService::Ptr service = (*it); // skip summary only plugins diff --git a/kontact/src/mainwindow.cpp b/kontact/src/mainwindow.cpp index 0e56f918a..df9631405 100644 --- a/kontact/src/mainwindow.cpp +++ b/kontact/src/mainwindow.cpp @@ -96,7 +96,7 @@ class SettingsDialogWrapper : public KSettings::Dialog void fixButtonLabel( TQWidget *widget ) { TQObject *object = widget->child( "KJanusWidget::buttonBelowList" ); - TQPushButton *button = static_cast<TQPushButton*>( object ); + TQPushButton *button = static_cast<TQPushButton*>( TQT_TQWIDGET(object) ); if ( button ) button->setText( i18n( "Select Components ..." ) ); } @@ -125,7 +125,7 @@ void MainWindow::initGUI() KTrader::OfferList offers = KTrader::self()->query( TQString::tqfromLatin1( "Kontact/Plugin" ), - TQString( "[X-KDE-KontactPluginVersion] == %1" ).arg( KONTACT_PLUGIN_VERSION ) ); + TQString( "[X-KDE-KontactPluginVersion] == %1" ).tqarg( KONTACT_PLUGIN_VERSION ) ); mPluginInfos = KPluginInfo::fromServices( offers, Prefs::self()->config(), "Plugins" ); KPluginInfo::List::Iterator it; @@ -133,10 +133,10 @@ void MainWindow::initGUI() (*it)->load(); KAction *action = new KAction( (*it)->name(), (*it)->icon(), KShortcut(), - this, TQT_SLOT(slotActionTriggered()), + TQT_TQOBJECT(this), TQT_SLOT(slotActionTriggered()), actionCollection(), (*it)->pluginName().latin1() ); action->setName( (*it)->pluginName().latin1() ); - action->setWhatsThis( i18n( "Switch to plugin %1" ).arg( (*it)->name() ) ); + action->setWhatsThis( i18n( "Switch to plugin %1" ).tqarg( (*it)->name() ) ); TQVariant hasPartProp = (*it)->property( "X-KDE-KontactPluginHasPart" ); if ( !hasPartProp.isValid() || hasPartProp.toBool() ) { @@ -144,8 +144,8 @@ void MainWindow::initGUI() } } - KStdAction::keyBindings( this, TQT_SLOT( configureShortcuts() ), actionCollection() ); - KStdAction::configureToolbars( this, TQT_SLOT( configureToolbars() ), actionCollection() ); + KStdAction::keyBindings( TQT_TQOBJECT(this), TQT_SLOT( configureShortcuts() ), actionCollection() ); + KStdAction::configureToolbars( TQT_TQOBJECT(this), TQT_SLOT( configureToolbars() ), actionCollection() ); setXMLFile( "kontactui.rc" ); setStandardToolBarMenuEnabled( true ); @@ -175,7 +175,7 @@ void MainWindow::initObject() mSidePane->updatePlugins(); } - KSettings::Dispatcher::self()->registerInstance( instance(), this, + KSettings::Dispatcher::self()->registerInstance( instance(), TQT_TQOBJECT(this), TQT_SLOT( updateConfig() ) ); loadSettings(); @@ -267,7 +267,7 @@ void MainWindow::initWidgets() initAboutScreen(); TQString loading = i18n( "<h2 style='text-align:center; margin-top: 0px; margin-bottom: 0px'>%1</h2>" ) - .arg( i18n("Loading Kontact...") ); + .tqarg( i18n("Loading Kontact...") ); paintAboutScreen( loading ); @@ -290,11 +290,11 @@ void MainWindow::paintAboutScreen( const TQString& msg ) { TQString location = locate( "data", "kontact/about/main.html" ); TQString content = KPIM::kFileToString( location ); - content = content.arg( locate( "data", "libkdepim/about/kde_infopage.css" ) ); + content = content.tqarg( locate( "data", "libkdepim/about/kde_infopage.css" ) ); if ( kapp->reverseLayout() ) - content = content.arg( "@import \"%1\";" ).arg( locate( "data", "libkdepim/about/kde_infopage_rtl.css" ) ); + content = content.tqarg( "@import \"%1\";" ).tqarg( locate( "data", "libkdepim/about/kde_infopage_rtl.css" ) ); else - content = content.arg( "" ); + content = content.tqarg( "" ); mIntroPart->begin( KURL( location ) ); @@ -302,8 +302,8 @@ void MainWindow::paintAboutScreen( const TQString& msg ) TQString catchPhrase( i18n( "Get Organized!" ) ); TQString quickDescription( i18n( "The KDE Personal Information Management Suite" ) ); - mIntroPart->write( content.arg( TQFont().pointSize() + 2 ).arg( appName ) - .arg( catchPhrase ).arg( quickDescription ).arg( msg ) ); + mIntroPart->write( content.tqarg( TQFont().pointSize() + 2 ).tqarg( appName ) + .tqarg( catchPhrase ).tqarg( quickDescription ).tqarg( msg ) ); mIntroPart->end(); } @@ -313,7 +313,7 @@ void MainWindow::initAboutScreen() mPartsStack->addWidget( introbox ); mPartsStack->raiseWidget( introbox ); mIntroPart = new KHTMLPart( introbox ); - mIntroPart->widget()->setFocusPolicy( WheelFocus ); + mIntroPart->widget()->setFocusPolicy( Qt::WheelFocus ); // Let's better be paranoid and disable plugins (it defaults to enabled): mIntroPart->setPluginsEnabled( false ); mIntroPart->setJScriptEnabled( false ); // just make this explicit @@ -333,9 +333,9 @@ void MainWindow::initAboutScreen() void MainWindow::setupActions() { - KStdAction::quit( this, TQT_SLOT( slotQuit() ), actionCollection() ); + KStdAction::quit( TQT_TQOBJECT(this), TQT_SLOT( slotQuit() ), actionCollection() ); mNewActions = new KToolBarPopupAction( KGuiItem( i18n( "New" ), "" ), - KStdAccel::shortcut(KStdAccel::New), this, TQT_SLOT( slotNewClicked() ), + KStdAccel::shortcut(KStdAccel::New), TQT_TQOBJECT(this), TQT_SLOT( slotNewClicked() ), actionCollection(), "action_new" ); KConfig* const cfg = Prefs::self()->config(); @@ -344,18 +344,18 @@ void MainWindow::setupActions() if ( mSyncActionsEnabled ) { mSyncActions = new KToolBarPopupAction( KGuiItem( i18n( "Synchronize" ), "kitchensync" ), - KStdAccel::shortcut(KStdAccel::Reload), this, TQT_SLOT( slotSyncClicked() ), + KStdAccel::shortcut(KStdAccel::Reload), TQT_TQOBJECT(this), TQT_SLOT( slotSyncClicked() ), actionCollection(), "action_sync" ); } - new KAction( i18n( "Configure Kontact..." ), "configure", 0, this, TQT_SLOT( slotPreferences() ), + new KAction( i18n( "Configure Kontact..." ), "configure", 0, TQT_TQOBJECT(this), TQT_SLOT( slotPreferences() ), actionCollection(), "settings_configure_kontact" ); - new KAction( i18n( "Configure &Profiles..." ), 0, this, TQT_SLOT( slotConfigureProfiles() ), + new KAction( i18n( "Configure &Profiles..." ), 0, TQT_TQOBJECT(this), TQT_SLOT( slotConfigureProfiles() ), actionCollection(), "settings_configure_kontact_profiles" ); - new KAction( i18n( "&Kontact Introduction" ), 0, this, TQT_SLOT( slotShowIntroduction() ), + new KAction( i18n( "&Kontact Introduction" ), 0, TQT_TQOBJECT(this), TQT_SLOT( slotShowIntroduction() ), actionCollection(), "help_introduction" ); - new KAction( i18n( "&Tip of the Day" ), 0, this, TQT_SLOT( slotShowTip() ), + new KAction( i18n( "&Tip of the Day" ), 0, TQT_TQOBJECT(this), TQT_SLOT( slotShowTip() ), actionCollection(), "help_tipofday" ); KWidgetAction* spacerAction = new KWidgetAction( new TQWidget( this ), "SpacerAction", "", 0, 0, actionCollection(), "navigator_spacer_item" ); @@ -543,7 +543,7 @@ void MainWindow::loadPlugins() kdDebug(5600) << "Loading Plugin: " << (*it)->name() << endl; Kontact::Plugin *plugin = KParts::ComponentFactory::createInstanceFromService<Kontact::Plugin>( - (*it)->service(), this ); + (*it)->service(), TQT_TQOBJECT(this) ); if ( !plugin ) continue; @@ -629,7 +629,7 @@ void MainWindow::updateShortcuts() ++it; if ( isPluginLoadedByAction( action ) ) { loadedActions.append( action ); - TQString shortcut = TQString( "CTRL+%1" ).arg( i ); + TQString shortcut = TQString( "CTRL+%1" ).tqarg( i ); action->setShortcut( KShortcut( shortcut ) ); i++; } else { @@ -763,7 +763,7 @@ void MainWindow::slotSyncClicked() KToolBar* Kontact::MainWindow::findToolBar(const char* name) { // like KMainWindow::toolBar, but which doesn't create the toolbar if not found - return static_cast<KToolBar *>(child(name, "KToolBar")); + return static_cast<KToolBar *>(TQT_TQWIDGET(child(name, "KToolBar"))); } void MainWindow::slotActionTriggered() @@ -794,7 +794,7 @@ void MainWindow::selectPlugin( Kontact::Plugin *plugin ) if ( !part ) { KApplication::restoreOverrideCursor(); KMessageBox::error( this, i18n( "Cannot load part for %1." ) - .arg( plugin->title() ) + .tqarg( plugin->title() ) + "\n" + lastErrorMessage() ); plugin->setDisabled( true ); mSidePane->updatePlugins(); @@ -848,7 +848,7 @@ void MainWindow::selectPlugin( Kontact::Plugin *plugin ) topDock()->moveDockWindow( navigatorToolBar, -1 ); } - setCaption( i18n( "Plugin dependent window title" ,"%1 - Kontact" ).arg( plugin->title() ) ); + setCaption( i18n( "Plugin dependent window title" ,"%1 - Kontact" ).tqarg( plugin->title() ) ); if ( newAction ) { mNewActions->setIcon( newAction->icon() ); @@ -1178,30 +1178,30 @@ TQString MainWindow::introductionString() "<td><a href=\"%1\">%1</a><br><span id=\"subtext\"><nobr>%1</td></tr>" "</table>" "<p style=\"margin-bottom: 0px\"> <a href=\"%1\">Skip this introduction</a></p>" ) - .arg( kapp->aboutData()->version() ) - .arg( i18n( "Kontact handles your e-mail, addressbook, calendar, to-do list and more." ) ) - .arg( "exec:/help?kontact" ) - .arg( iconSize ) - .arg( iconSize ) - .arg( handbook_icon_path ) - .arg( "exec:/help?kontact" ) - .arg( i18n( "Read Manual" ) ) - .arg( i18n( "Learn more about Kontact and its components" ) ) - .arg( "http://kontact.org" ) - .arg( iconSize ) - .arg( iconSize ) - .arg( html_icon_path ) - .arg( "http://kontact.org" ) - .arg( i18n( "Visit Kontact Website" ) ) - .arg( i18n( "Access online resources and tutorials" ) ) - .arg( "exec:/gwwizard" ) - .arg( iconSize ) - .arg( iconSize ) - .arg( wizard_icon_path ) - .arg( "exec:/gwwizard" ) - .arg( i18n( "Configure Kontact as Groupware Client" ) ) - .arg( i18n( "Prepare Kontact for use in corporate networks" ) ) - .arg( "exec:/switch" ); + .tqarg( kapp->aboutData()->version() ) + .tqarg( i18n( "Kontact handles your e-mail, addressbook, calendar, to-do list and more." ) ) + .tqarg( "exec:/help?kontact" ) + .tqarg( iconSize ) + .tqarg( iconSize ) + .tqarg( handbook_icon_path ) + .tqarg( "exec:/help?kontact" ) + .tqarg( i18n( "Read Manual" ) ) + .tqarg( i18n( "Learn more about Kontact and its components" ) ) + .tqarg( "http://kontact.org" ) + .tqarg( iconSize ) + .tqarg( iconSize ) + .tqarg( html_icon_path ) + .tqarg( "http://kontact.org" ) + .tqarg( i18n( "Visit Kontact Website" ) ) + .tqarg( i18n( "Access online resources and tutorials" ) ) + .tqarg( "exec:/gwwizard" ) + .tqarg( iconSize ) + .tqarg( iconSize ) + .tqarg( wizard_icon_path ) + .tqarg( "exec:/gwwizard" ) + .tqarg( i18n( "Configure Kontact as Groupware Client" ) ) + .tqarg( i18n( "Prepare Kontact for use in corporate networks" ) ) + .tqarg( "exec:/switch" ); return info; } diff --git a/kontact/src/profiledialog.cpp b/kontact/src/profiledialog.cpp index cb28d1194..bc3bff990 100644 --- a/kontact/src/profiledialog.cpp +++ b/kontact/src/profiledialog.cpp @@ -140,7 +140,7 @@ void Kontact::ProfileDialog::profileLoaded( const TQString& id ) const Kontact::Profile profile = Kontact::ProfileManager::self()->profileById( id ); if ( profile.isNull() ) return; - KMessageBox::information( this, i18n("The profile \"%1\" was successfully loaded. Some profile settings require a restart to get activated.").arg( profile.name() ), i18n("Profile Loaded") ); + KMessageBox::information( this, i18n("The profile \"%1\" was successfully loaded. Some profile settings require a restart to get activated.").tqarg( profile.name() ), i18n("Profile Loaded") ); } void Kontact::ProfileDialog::saveToSelectedProfile() @@ -148,7 +148,7 @@ void Kontact::ProfileDialog::saveToSelectedProfile() const Kontact::Profile profile = Kontact::ProfileManager::self()->profileById( selectedProfile() ); if ( profile.isNull() ) return; - if ( KMessageBox::Yes != KMessageBox::warningYesNo( this, i18n("The profile \"%1\" will be overwritten with the current settings. Are you sure?").arg( profile.name() ), i18n("Save to Profile"), KStdGuiItem::overwrite(), KStdGuiItem::cancel() ) ) + if ( KMessageBox::Yes != KMessageBox::warningYesNo( this, i18n("The profile \"%1\" will be overwritten with the current settings. Are you sure?").tqarg( profile.name() ), i18n("Save to Profile"), KStdGuiItem::overwrite(), KStdGuiItem::cancel() ) ) return; Kontact::ProfileManager::self()->saveToProfile( profile.id() ); } @@ -158,7 +158,7 @@ void Kontact::ProfileDialog::deleteSelectedProfile() const Kontact::Profile profile = Kontact::ProfileManager::self()->profileById( selectedProfile() ); if ( profile.isNull() ) return; - if ( KMessageBox::Yes != KMessageBox::warningYesNo( this, i18n("Do you really want to delete the profile \"%1\"? All profile settings will be lost!").arg( profile.name() ), i18n("Delete Profile"), KStdGuiItem::del(), KStdGuiItem::cancel() ) ) + if ( KMessageBox::Yes != KMessageBox::warningYesNo( this, i18n("Do you really want to delete the profile \"%1\"? All profile settings will be lost!").tqarg( profile.name() ), i18n("Delete Profile"), KStdGuiItem::del(), KStdGuiItem::cancel() ) ) return; Kontact::ProfileManager::self()->removeProfile( profile ); } @@ -175,7 +175,7 @@ void Kontact::ProfileDialog::exportSelectedProfile() const Kontact::ProfileManager::ExportError error = Kontact::ProfileManager::self()->exportProfileToDirectory( id, path ); if ( error == Kontact::ProfileManager::SuccessfulExport ) { - KMessageBox::information( this, i18n("The profile \"%1\" was successfully exported.").arg( profile.name() ), i18n("Profile Exported") ); + KMessageBox::information( this, i18n("The profile \"%1\" was successfully exported.").tqarg( profile.name() ), i18n("Profile Exported") ); } else { diff --git a/kontact/src/profilemanager.cpp b/kontact/src/profilemanager.cpp index deed6f37a..005779414 100644 --- a/kontact/src/profilemanager.cpp +++ b/kontact/src/profilemanager.cpp @@ -152,7 +152,7 @@ void Kontact::ProfileManager::writeConfig() const Kontact::Profile Kontact::ProfileManager::readFromConfiguration( const TQString& configFile, bool isLocal ) { KConfig profileCfg( configFile, true /*read-only*/, false /*no KDE global*/ ); - const TQString configDir = configFile.left( configFile.findRev( TQDir::separator(), -1 ) ); + const TQString configDir = configFile.left( configFile.tqfindRev( TQDir::separator(), -1 ) ); profileCfg.setGroup( "Kontact Profile" ); const TQString id = profileCfg.readEntry( "Identifier" ); Kontact::Profile profile( id ); |