From 67e29a054cfcb1b0d2fe6b0a316cf6b3eec087b7 Mon Sep 17 00:00:00 2001 From: tpearson Date: Wed, 13 Apr 2011 00:46:47 +0000 Subject: 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 --- kresources/blogging/API_Blog.cpp | 12 ++++++------ kresources/blogging/API_Blog.h | 7 ++++--- kresources/blogging/API_Blogger.cpp | 18 +++++++++--------- kresources/blogging/API_Blogger.h | 2 +- kresources/blogging/bloggingcalendaradaptor.h | 1 + kresources/blogging/bloggingglobals.cpp | 2 +- kresources/blogging/bloggingglobals.h | 2 +- kresources/blogging/kcal_resourceblogging.h | 1 + .../blogging/kcal_resourcebloggingconfig.cpp | 2 +- kresources/blogging/kcal_resourcebloggingconfig.h | 3 ++- kresources/blogging/resourcebloggingsettings.ui | 22 +++++++++++----------- kresources/blogging/xmlrpcjob.cpp | 10 +++++----- kresources/blogging/xmlrpcjob.h | 1 + 13 files changed, 44 insertions(+), 39 deletions(-) (limited to 'kresources/blogging') diff --git a/kresources/blogging/API_Blog.cpp b/kresources/blogging/API_Blog.cpp index b6ac3752b..2ad11c1dc 100644 --- a/kresources/blogging/API_Blog.cpp +++ b/kresources/blogging/API_Blog.cpp @@ -12,9 +12,9 @@ using namespace KBlog; -APIBlog::APIBlog( const KURL &url, TQObject *parent, const char *name ) : - TQObject( parent, name ), - mServerURL( url ), mAppID( TQString::null ), mDownloadCount( 20 ) +APIBlog::APIBlog( const KURL &url, TQObject *tqparent, const char *name ) : + TQObject( tqparent, name ), + mServerURL( url ), mAppID( TQString() ), mDownloadCount( 20 ) {} APIBlog::~APIBlog() @@ -70,9 +70,9 @@ KCal::Journal *APIBlog::journalFromPosting( KBlog::BlogPosting *blog ) TQDateTime dt = blog->dateTime(); TQDateTime creationDt = blog->creationDateTime(); TQDateTime modificationDt = blog->modificationDateTime(); -kdDebug() << "dt ="<setCreationDateTime( dt ); - TQString fp = dt.toString( Qt::ISODate ); + TQString fp = dt.toString( TQt::ISODate ); } dt = postInfo[ "postDate" ].toDateTime(); if ( dt.isValid() && !dt.isNull() ) { post->setDateTime( dt ); - fp = dt.toString( Qt::ISODate ); + fp = dt.toString( TQt::ISODate ); } dt = postInfo[ "lastModified" ].toDateTime(); if ( dt.isValid() && !dt.isNull() ) { post->setModificationDateTime( dt ); - fp = dt.toString( Qt::ISODate ); + fp = dt.toString( TQt::ISODate ); } post->setFingerprint( fp ); @@ -299,8 +299,8 @@ bool APIBlogger::readPostingFromMap( BlogPosting *post, const TQMap catStart ) { category = contents.mid( catStart, catEnd - catStart ); @@ -308,8 +308,8 @@ kdDebug() << " catTagOpen = " << catTagOpen << ", catTagClose = " << catTagClos contents = contents.remove( catStart - catTagOpen.length(), catEnd - catStart + catTagClose.length() + catTagOpen.length() ); } - int titleStart = contents.find( titleTagOpen, 0, false ) + titleTagOpen.length(); - int titleEnd = contents.find( titleTagClose, 0, false ); + int titleStart = contents.tqfind( titleTagOpen, 0, false ) + titleTagOpen.length(); + int titleEnd = contents.tqfind( titleTagClose, 0, false ); kdDebug() << " titleTagOpen = " << titleTagOpen << ", titleTagClose = " << titleTagClose << ", start - end : " << titleStart <<" - " << titleEnd << endl; kdDebug() << "Title start and end: " << titleStart << ", " << titleEnd << endl; if ( titleEnd > titleStart ) { diff --git a/kresources/blogging/API_Blogger.h b/kresources/blogging/API_Blogger.h index 32610bf60..5255e19fc 100644 --- a/kresources/blogging/API_Blogger.h +++ b/kresources/blogging/API_Blogger.h @@ -32,7 +32,7 @@ namespace KBlog { class APIBlogger : public APIBlog { public: - APIBlogger( const KURL &server, TQObject *parent = 0L, const char *name = 0L ) : APIBlog( server, parent, name ) {} + APIBlogger( const KURL &server, TQObject *tqparent = 0L, const char *name = 0L ) : APIBlog( server, tqparent, name ) {} TQString getFunctionName( blogFunctions type ); TQString interfaceName() const { return "Blogger API 1.0"; } diff --git a/kresources/blogging/bloggingcalendaradaptor.h b/kresources/blogging/bloggingcalendaradaptor.h index 2b7a4899b..9baedfdae 100644 --- a/kresources/blogging/bloggingcalendaradaptor.h +++ b/kresources/blogging/bloggingcalendaradaptor.h @@ -51,6 +51,7 @@ class BloggingUploadItem : public KPIM::GroupwareUploadItem class BloggingCalendarAdaptor : public CalendarAdaptor { Q_OBJECT + TQ_OBJECT public: BloggingCalendarAdaptor(); TQValueList supportedTypes() diff --git a/kresources/blogging/bloggingglobals.cpp b/kresources/blogging/bloggingglobals.cpp index 247ed9014..b6b4c4228 100644 --- a/kresources/blogging/bloggingglobals.cpp +++ b/kresources/blogging/bloggingglobals.cpp @@ -35,7 +35,7 @@ TQString BloggingGlobals::getFunctionName( blogFunctions type ) case bloggerGetPost: return "blogger.getPost"; case bloggerGetTemplate: return "blogger.getTemplate"; case bloggerSetTemplate: return "blogger.setTemplate"; - default: return TQString::null; + default: return TQString(); } } diff --git a/kresources/blogging/bloggingglobals.h b/kresources/blogging/bloggingglobals.h index b55029f1a..004ed4d9a 100644 --- a/kresources/blogging/bloggingglobals.h +++ b/kresources/blogging/bloggingglobals.h @@ -43,7 +43,7 @@ class BloggingGlobals }; static TQString getFunctionName( blogFunctions type ); - static TQValueList defaultArgs( const TQString &user, const TQString &pw, const TQString &id = TQString::null ); + static TQValueList defaultArgs( const TQString &user, const TQString &pw, const TQString &id = TQString() ); static TQString mAppID; }; diff --git a/kresources/blogging/kcal_resourceblogging.h b/kresources/blogging/kcal_resourceblogging.h index 2563b66ed..ac3820abb 100644 --- a/kresources/blogging/kcal_resourceblogging.h +++ b/kresources/blogging/kcal_resourceblogging.h @@ -36,6 +36,7 @@ namespace KCal { class KDE_EXPORT ResourceBlogging : public ResourceGroupwareBase { Q_OBJECT + TQ_OBJECT public: ResourceBlogging(); ResourceBlogging( const KConfig * ); diff --git a/kresources/blogging/kcal_resourcebloggingconfig.cpp b/kresources/blogging/kcal_resourcebloggingconfig.cpp index d68584a2b..04f62cf91 100644 --- a/kresources/blogging/kcal_resourcebloggingconfig.cpp +++ b/kresources/blogging/kcal_resourcebloggingconfig.cpp @@ -25,7 +25,7 @@ using namespace KCal; -ResourceBloggingConfig::ResourceBloggingConfig( TQWidget *parent, const char *name ) : ResourceGroupwareBaseConfig( parent, name ) +ResourceBloggingConfig::ResourceBloggingConfig( TQWidget *tqparent, const char *name ) : ResourceGroupwareBaseConfig( tqparent, name ) { } diff --git a/kresources/blogging/kcal_resourcebloggingconfig.h b/kresources/blogging/kcal_resourcebloggingconfig.h index 8495595b6..d15c89757 100644 --- a/kresources/blogging/kcal_resourcebloggingconfig.h +++ b/kresources/blogging/kcal_resourcebloggingconfig.h @@ -28,8 +28,9 @@ namespace KCal { class KDE_EXPORT ResourceBloggingConfig : public ResourceGroupwareBaseConfig { Q_OBJECT + TQ_OBJECT public: - ResourceBloggingConfig( TQWidget *parent = 0, const char *name = 0 ); + ResourceBloggingConfig( TQWidget *tqparent = 0, const char *name = 0 ); public slots: virtual void saveSettings( KRES::Resource *resource ); diff --git a/kresources/blogging/resourcebloggingsettings.ui b/kresources/blogging/resourcebloggingsettings.ui index 15f2ab9b0..e896ae4e0 100644 --- a/kresources/blogging/resourcebloggingsettings.ui +++ b/kresources/blogging/resourcebloggingsettings.ui @@ -1,7 +1,7 @@ ResourceBloggingSettings Ian Reinhart Geiser <geiseri@kde.org> - + ResourceBloggingSettings @@ -17,7 +17,7 @@ unnamed - + tqlayout12 @@ -25,7 +25,7 @@ unnamed - + textLabel1_4 @@ -64,7 +64,7 @@ - + groupBox2 @@ -75,7 +75,7 @@ unnamed - + textLabel1 @@ -91,7 +91,7 @@ URL: - + textLabel9 @@ -104,7 +104,7 @@ mUser - + textLabel10 @@ -131,7 +131,7 @@ Password - + textLabel4_2 @@ -177,7 +177,7 @@ - + groupBox3 @@ -204,7 +204,7 @@ </TITLE> - + textLabel7_2 @@ -247,7 +247,7 @@ <CATEGORY> - + textLabel8_2 diff --git a/kresources/blogging/xmlrpcjob.cpp b/kresources/blogging/xmlrpcjob.cpp index d99e8add8..e2a3adc32 100644 --- a/kresources/blogging/xmlrpcjob.cpp +++ b/kresources/blogging/xmlrpcjob.cpp @@ -72,7 +72,7 @@ XmlrpcJob::XmlrpcJob( const KURL& url, const TQString& method, showProgressInfo ) { d = new XmlrpcJobPrivate; - // We couldn't set the args when calling the parent constructor, + // We couldn't set the args when calling the tqparent constructor, // so do it now. TQDataStream stream( m_packedArgs, IO_WriteOnly ); stream << (int)1 << url; @@ -262,7 +262,7 @@ TQString XmlrpcJob::marshal( const TQVariant &arg ) "\r\n"; case TQVariant::DateTime: return "" + - arg.toDateTime().toString( Qt::ISODate ) + + arg.toDateTime().toString( TQt::ISODate ) + "\r\n"; case TQVariant::List: { @@ -295,7 +295,7 @@ TQString XmlrpcJob::marshal( const TQVariant &arg ) kdWarning() << "Failed to marshal unknown variant type: " << arg.type() << endl; }; - return TQString::null; + return TQString(); } TQVariant XmlrpcJob::demarshal( const TQDomElement &elem ) @@ -337,13 +337,13 @@ kdDebug()<<"Demarshalling element \"" << elem.text() <<"\"" << endl; else if ( typeName == "datetime" || typeName == "datetime.iso8601" ) { TQString text( typeElement.text() ); - if ( text.find( TQRegExp("^[0-9]{8,8}T") ) >= 0 ) { + if ( text.tqfind( TQRegExp("^[0-9]{8,8}T") ) >= 0 ) { // It's in the format 20041120T...., so adjust it to correct // ISO 8601 Format 2004-11-20T..., else TQDateTime::fromString won't work: text = text.insert( 6, '-' ); text = text.insert( 4, '-' ); } - return TQVariant( TQDateTime::fromString( text, Qt::ISODate ) ); + return TQVariant( TQDateTime::fromString( text, TQt::ISODate ) ); } else if ( typeName == "array" ) { diff --git a/kresources/blogging/xmlrpcjob.h b/kresources/blogging/xmlrpcjob.h index 7bb18b159..349d7617a 100644 --- a/kresources/blogging/xmlrpcjob.h +++ b/kresources/blogging/xmlrpcjob.h @@ -46,6 +46,7 @@ namespace KIO { */ class XmlrpcJob : public TransferJob { Q_OBJECT + TQ_OBJECT public: /** Indicates the response type of the call -- cgit v1.2.1