summaryrefslogtreecommitdiffstats
path: root/libkcal/qtopiaformat.cpp
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-04-13 00:46:47 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-04-13 00:46:47 +0000
commit67e29a054cfcb1b0d2fe6b0a316cf6b3eec087b7 (patch)
tree5f52a9eada2e9f3654fc327d7c14dfef570a6ecb /libkcal/qtopiaformat.cpp
parent2ee4bf4fd5eff93b2fbef0ff8e8063edffc5da5c (diff)
downloadtdepim-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 'libkcal/qtopiaformat.cpp')
-rw-r--r--libkcal/qtopiaformat.cpp38
1 files changed, 19 insertions, 19 deletions
diff --git a/libkcal/qtopiaformat.cpp b/libkcal/qtopiaformat.cpp
index 372c52308..964e48c52 100644
--- a/libkcal/qtopiaformat.cpp
+++ b/libkcal/qtopiaformat.cpp
@@ -38,17 +38,17 @@
using namespace KCal;
-class QtopiaParser : public QXmlDefaultHandler
+class TQtopiaParser : public TQXmlDefaultHandler
{
public:
- QtopiaParser( Calendar *calendar ) : mCalendar( calendar ) {}
+ TQtopiaParser( Calendar *calendar ) : mCalendar( calendar ) {}
bool startElement( const TQString &, const TQString &, const TQString & qName,
const TQXmlAttributes &attributes )
{
if ( qName == "event" ) {
Event *event = new Event;
- TQString uid = "Qtopia" + attributes.value( "uid" );
+ TQString uid = "TQtopia" + attributes.value( "uid" );
event->setUid( uid );
event->setSummary( attributes.value( "description" ) );
@@ -136,11 +136,11 @@ class QtopiaParser : public QXmlDefaultHandler
} else if ( qName == "Task" ) {
Todo *todo = new Todo;
- TQString uid = "Qtopia" + attributes.value( "Uid" );
+ TQString uid = "TQtopia" + attributes.value( "Uid" );
todo->setUid( uid );
TQString description = attributes.value( "Description" );
- int pos = description.find( '\n' );
+ int pos = description.tqfind( '\n' );
if ( pos > 0 ) {
TQString summary = description.left( pos );
todo->setSummary( summary );
@@ -205,7 +205,7 @@ class QtopiaParser : public QXmlDefaultHandler
TQString errorString ()
{
- return "QtopiaParser: Error!";
+ return "TQtopiaParser: Error!";
}
protected:
@@ -242,7 +242,7 @@ class QtopiaParser : public QXmlDefaultHandler
static TQString category( const TQString &id )
{
- TQMap<TQString,TQString>::ConstIterator it = mCategoriesMap.find( id );
+ TQMap<TQString,TQString>::ConstIterator it = mCategoriesMap.tqfind( id );
if ( it == mCategoriesMap.end() ) return id;
else return *it;
}
@@ -255,23 +255,23 @@ class QtopiaParser : public QXmlDefaultHandler
static TQMap<TQString,TQString> mCategoriesMap;
};
-TQMap<TQString,TQString> QtopiaParser::mCategoriesMap;
+TQMap<TQString,TQString> TQtopiaParser::mCategoriesMap;
-QtopiaFormat::QtopiaFormat()
+TQtopiaFormat::TQtopiaFormat()
{
}
-QtopiaFormat::~QtopiaFormat()
+TQtopiaFormat::~TQtopiaFormat()
{
}
-bool QtopiaFormat::load( Calendar *calendar, const TQString &fileName)
+bool TQtopiaFormat::load( Calendar *calendar, const TQString &fileName)
{
- kdDebug(5800) << "QtopiaFormat::load() " << fileName << endl;
+ kdDebug(5800) << "TQtopiaFormat::load() " << fileName << endl;
clearException();
- QtopiaParser handler( calendar );
+ TQtopiaParser handler( calendar );
TQFile xmlFile( fileName );
TQXmlInputSource source( xmlFile );
TQXmlSimpleReader reader;
@@ -279,9 +279,9 @@ bool QtopiaFormat::load( Calendar *calendar, const TQString &fileName)
return reader.parse( source );
}
-bool QtopiaFormat::save( Calendar *calendar, const TQString &fileName )
+bool TQtopiaFormat::save( Calendar *calendar, const TQString &fileName )
{
- kdDebug(5800) << "QtopiaFormat::save(): " << fileName << endl;
+ kdDebug(5800) << "TQtopiaFormat::save(): " << fileName << endl;
clearException();
@@ -304,13 +304,13 @@ bool QtopiaFormat::save( Calendar *calendar, const TQString &fileName )
return true;
}
-bool QtopiaFormat::fromString( Calendar *, const TQString & )
+bool TQtopiaFormat::fromString( Calendar *, const TQString & )
{
- kdDebug(5800) << "QtopiaFormat::fromString() not yet implemented." << endl;
+ kdDebug(5800) << "TQtopiaFormat::fromString() not yet implemented." << endl;
return false;
}
-TQString QtopiaFormat::toString( Calendar * )
+TQString TQtopiaFormat::toString( Calendar * )
{
- return TQString::null;
+ return TQString();
}