diff options
Diffstat (limited to 'libkcal/incidenceformatter.cpp')
-rw-r--r-- | libkcal/incidenceformatter.cpp | 90 |
1 files changed, 45 insertions, 45 deletions
diff --git a/libkcal/incidenceformatter.cpp b/libkcal/incidenceformatter.cpp index cebdd0b16..ebfb68eab 100644 --- a/libkcal/incidenceformatter.cpp +++ b/libkcal/incidenceformatter.cpp @@ -74,7 +74,7 @@ static TQString htmlAddLink( const TQString &ref, const TQString &text, static TQString htmlAddTag( const TQString & tag, const TQString & text ) { - int numLineBreaks = text.contains( "\n" ); + int numLineBreaks = text.tqcontains( "\n" ); TQString str = "<" + tag + ">"; TQString tmpText = text; TQString tmpStr = str; @@ -184,7 +184,7 @@ static TQString displayViewLinkPerson( const TQString& email, TQString name, TQS // and either name or uid is missing if ( !email.isEmpty() && ( name.isEmpty() || uid.isEmpty() ) ) { KABC::AddressBook *add_book = KABC::StdAddressBook::self( true ); - KABC::Addressee::List addressList = add_book->findByEmail( email ); + KABC::Addressee::List addressList = add_book->tqfindByEmail( email ); if ( !addressList.isEmpty() ) { KABC::Addressee o = addressList.first(); if ( !o.isEmpty() && addressList.size() < 2 ) { @@ -1135,7 +1135,7 @@ static TQString invitationPerson( const TQString& email, TQString name, TQString // and either name or uid is missing if ( !email.isEmpty() && ( name.isEmpty() || uid.isEmpty() ) ) { KABC::AddressBook *add_book = KABC::StdAddressBook::self( true ); - KABC::Addressee::List addressList = add_book->findByEmail( email ); + KABC::Addressee::List addressList = add_book->tqfindByEmail( email ); if ( !addressList.isEmpty() ) { KABC::Addressee o = addressList.first(); if ( !o.isEmpty() && addressList.size() < 2 ) { @@ -2278,7 +2278,7 @@ static bool incidenceOwnedByMe( Calendar *calendar, Incidence *incidence ) return true; } const TQString subRes = res->subresourceIdentifier( incidence ); - if ( !subRes.contains( "/.INBOX.directory/" ) ) { + if ( !subRes.tqcontains( "/.INBOX.directory/" ) ) { return false; } return true; @@ -2426,9 +2426,9 @@ TQString IncidenceFormatter::formatICalInvitationHelper( TQString invitation, // First make the text of the message TQString html; - TQString tableStyle = TQString::fromLatin1( + TQString tableStyle = TQString::tqfromLatin1( "style=\"border: solid 1px; margin: 0em;\"" ); - TQString tableHead = TQString::fromLatin1( + TQString tableHead = TQString::tqfromLatin1( "<div align=\"center\">" "<table width=\"80%\" cellpadding=\"1\" cellspacing=\"0\" %1>" "<tr><td>").arg(tableStyle); @@ -2701,7 +2701,7 @@ TQString IncidenceFormatter::formatICalInvitationNoHtml( TQString invitation, //----------------------------------------------------------------------------- -static TQString stringProp( KTNEFMessage* tnefMsg, const Q_UINT32& key, +static TQString stringProp( KTNEFMessage* tnefMsg, const TQ_UINT32& key, const TQString& fallback = TQString::null) { return tnefMsg->findProp( key < 0x10000 ? key & 0xFFFF : key >> 16, @@ -2831,7 +2831,7 @@ TQString IncidenceFormatter::msTNEFToVPart( const TQByteArray& tnef ) KTNEFParser parser; TQBuffer buf( tnef ); - CalendarLocal cal ( TQString::fromLatin1( "UTC" ) ); + CalendarLocal cal ( TQString::tqfromLatin1( "UTC" ) ); KABC::Addressee addressee; KABC::VCardConverter cardConv; ICalFormat calFormat; @@ -2926,13 +2926,13 @@ TQString IncidenceFormatter::msTNEFToVPart( const TQByteArray& tnef ) Attendee *attendee = new Attendee( s, s, true ); if( bIsReply ) { if( bCompatMethodAccepted ) - attendee->setStatus( Attendee::Accepted ); + attendee->seStatus( Attendee::Accepted ); if( bCompatMethodDeclined ) - attendee->setStatus( Attendee::Declined ); + attendee->seStatus( Attendee::Declined ); if( bCompatMethodAcceptedCond ) - attendee->setStatus(Attendee::Tentative); + attendee->seStatus(Attendee::Tentative); } else { - attendee->setStatus( Attendee::NeedsAction ); + attendee->seStatus( Attendee::NeedsAction ); attendee->setRole( Attendee::ReqParticipant ); } event->addAttendee(attendee); @@ -2947,13 +2947,13 @@ TQString IncidenceFormatter::msTNEFToVPart( const TQByteArray& tnef ) true ); if( bIsReply ) { if( bCompatMethodAccepted ) - attendee->setStatus( Attendee::Accepted ); + attendee->seStatus( Attendee::Accepted ); if( bCompatMethodAcceptedCond ) - attendee->setStatus( Attendee::Declined ); + attendee->seStatus( Attendee::Declined ); if( bCompatMethodDeclined ) - attendee->setStatus( Attendee::Tentative ); + attendee->seStatus( Attendee::Tentative ); } else { - attendee->setStatus(Attendee::NeedsAction); + attendee->seStatus(Attendee::NeedsAction); attendee->setRole(Attendee::ReqParticipant); } event->addAttendee(attendee); @@ -2966,12 +2966,12 @@ TQString IncidenceFormatter::msTNEFToVPart( const TQByteArray& tnef ) if( !s.isEmpty() ) event->setOrganizer( s ); - s = tnefMsg->findProp( 0x8516 ).replace( TQChar( '-' ), TQString::null ) - .replace( TQChar( ':' ), TQString::null ); + s = tnefMsg->findProp( 0x8516 ).tqreplace( TQChar( '-' ), TQString::null ) + .tqreplace( TQChar( ':' ), TQString::null ); event->setDtStart( TQDateTime::fromString( s ) ); // ## Format?? - s = tnefMsg->findProp( 0x8517 ).replace( TQChar( '-' ), TQString::null ) - .replace( TQChar( ':' ), TQString::null ); + s = tnefMsg->findProp( 0x8517 ).tqreplace( TQChar( '-' ), TQString::null ) + .tqreplace( TQChar( ':' ), TQString::null ); event->setDtEnd( TQDateTime::fromString( s ) ); s = tnefMsg->findProp( 0x8208 ); @@ -2988,9 +2988,9 @@ TQString IncidenceFormatter::msTNEFToVPart( const TQByteArray& tnef ) // PENDING(khz): is this value in local timezone? Must it be // adjusted? Most likely this is a bug in the server or in // Outlook - we ignore it for now. - s = tnefMsg->findProp( 0x8202 ).replace( TQChar( '-' ), TQString::null ) - .replace( TQChar( ':' ), TQString::null ); - // ### libkcal always uses currentDateTime() + s = tnefMsg->findProp( 0x8202 ).tqreplace( TQChar( '-' ), TQString::null ) + .tqreplace( TQChar( ':' ), TQString::null ); + // ### libkcal always uses tqcurrentDateTime() // event->setDtStamp(TQDateTime::fromString(s)); s = tnefMsg->findNamedProp( "Keywords" ); @@ -3010,12 +3010,12 @@ TQString IncidenceFormatter::msTNEFToVPart( const TQByteArray& tnef ) Alarm *alarm = new Alarm(event); TQDateTime highNoonTime = pureISOToLocalQDateTime( tnefMsg->findProp( 0x8502 ) - .replace( TQChar( '-' ), "" ) - .replace( TQChar( ':' ), "" ) ); + .tqreplace( TQChar( '-' ), "" ) + .tqreplace( TQChar( ':' ), "" ) ); TQDateTime wakeMeUpTime = pureISOToLocalQDateTime( tnefMsg->findProp( 0x8560, "" ) - .replace( TQChar( '-' ), "" ) - .replace( TQChar( ':' ), "" ) ); + .tqreplace( TQChar( '-' ), "" ) + .tqreplace( TQChar( ':' ), "" ) ); alarm->setTime(wakeMeUpTime); if( highNoonTime.isValid() && wakeMeUpTime.isValid() ) @@ -3047,8 +3047,8 @@ TQString IncidenceFormatter::msTNEFToVPart( const TQByteArray& tnef ) addressee.insertCustom( "KADDRESSBOOK", "X-Profession", stringProp( tnefMsg, MAPI_TAG_PR_PROFESSION ) ); TQString s = tnefMsg->findProp( MAPI_TAG_PR_WEDDING_ANNIVERSARY ) - .replace( TQChar( '-' ), TQString::null ) - .replace( TQChar( ':' ), TQString::null ); + .tqreplace( TQChar( '-' ), TQString::null ) + .tqreplace( TQChar( ':' ), TQString::null ); if( !s.isEmpty() ) addressee.insertCustom( "KADDRESSBOOK", "X-Anniversary", s ); @@ -3114,8 +3114,8 @@ TQString IncidenceFormatter::msTNEFToVPart( const TQByteArray& tnef ) addressee.insertPhoneNumber( KABC::PhoneNumber( nr, KABC::PhoneNumber::Fax | KABC::PhoneNumber::Work ) ); s = tnefMsg->findProp( MAPI_TAG_PR_BIRTHDAY ) - .replace( TQChar( '-' ), TQString::null ) - .replace( TQChar( ':' ), TQString::null ); + .tqreplace( TQChar( '-' ), TQString::null ) + .tqreplace( TQChar( ':' ), TQString::null ); if( !s.isEmpty() ) addressee.setBirthday( TQDateTime::fromString( s ) ); @@ -3218,25 +3218,25 @@ TQString IncidenceFormatter::ToolTipVisitor::dateRangeText( Event *event, const tmp = "<br>" + i18n("Event start", "<i>From:</i> %1"); if (event->doesFloat()) - ret += tmp.arg( IncidenceFormatter::dateToString( startDt, false ).replace(" ", " ") ); + ret += tmp.arg( IncidenceFormatter::dateToString( startDt, false ).tqreplace(" ", " ") ); else - ret += tmp.arg( IncidenceFormatter::dateToString( startDt ).replace(" ", " ") ); + ret += tmp.arg( IncidenceFormatter::dateToString( startDt ).tqreplace(" ", " ") ); tmp = "<br>" + i18n("Event end","<i>To:</i> %1"); if (event->doesFloat()) - ret += tmp.arg( IncidenceFormatter::dateToString( endDt, false ).replace(" ", " ") ); + ret += tmp.arg( IncidenceFormatter::dateToString( endDt, false ).tqreplace(" ", " ") ); else - ret += tmp.arg( IncidenceFormatter::dateToString( endDt ).replace(" ", " ") ); + ret += tmp.arg( IncidenceFormatter::dateToString( endDt ).tqreplace(" ", " ") ); } else { ret += "<br>"+i18n("<i>Date:</i> %1"). - arg( IncidenceFormatter::dateToString( startDt, false ).replace(" ", " ") ); + arg( IncidenceFormatter::dateToString( startDt, false ).tqreplace(" ", " ") ); if ( !event->doesFloat() ) { const TQString dtStartTime = - IncidenceFormatter::timeToString( startDt, true ).replace( " ", " " ); + IncidenceFormatter::timeToString( startDt, true ).tqreplace( " ", " " ); const TQString dtEndTime = - IncidenceFormatter::timeToString( endDt, true ).replace( " ", " " ); + IncidenceFormatter::timeToString( endDt, true ).tqreplace( " ", " " ); if ( dtStartTime == dtEndTime ) { // to prevent 'Time: 17:00 - 17:00' tmp = "<br>" + i18n("time for event, to prevent ugly line breaks", "<i>Time:</i> %1"). @@ -3268,7 +3268,7 @@ TQString IncidenceFormatter::ToolTipVisitor::dateRangeText( Todo *todo, const TQ ret += "<br>" + i18n("<i>Start:</i> %1"). arg( IncidenceFormatter::dateTimeToString( startDt, floats, false ). - replace( " ", " " ) ); + tqreplace( " ", " " ) ); } if ( todo->hasDueDate() && todo->dtDue().isValid() ) { @@ -3283,7 +3283,7 @@ TQString IncidenceFormatter::ToolTipVisitor::dateRangeText( Todo *todo, const TQ ret += "<br>" + i18n("<i>Due:</i> %1"). arg( IncidenceFormatter::dateTimeToString( dueDt, floats, false ). - replace( " ", " " ) ); + tqreplace( " ", " " ) ); } // Print priority and completed info here, for lack of a better place @@ -3297,7 +3297,7 @@ TQString IncidenceFormatter::ToolTipVisitor::dateRangeText( Todo *todo, const TQ ret += "<br>"; if ( todo->isCompleted() ) { ret += "<i>" + i18n( "Completed:" ) + "</i>" + " "; - ret += todo->completedStr().replace( " ", " " ); + ret += todo->completedStr().tqreplace( " ", " " ); } else { ret += "<i>" + i18n( "Percent Done:" ) + "</i>" + " "; ret += i18n( "%1%" ).arg( todo->percentComplete() ); @@ -3361,7 +3361,7 @@ static TQString tooltipPerson( const TQString& email, TQString name ) // and name is missing if ( name.isEmpty() && !email.isEmpty() ) { KABC::AddressBook *add_book = KABC::StdAddressBook::self( true ); - KABC::Addressee::List addressList = add_book->findByEmail( email ); + KABC::Addressee::List addressList = add_book->tqfindByEmail( email ); if ( !addressList.isEmpty() ) { KABC::Addressee o = addressList.first(); if ( !o.isEmpty() && addressList.size() < 2 ) { @@ -3475,7 +3475,7 @@ TQString IncidenceFormatter::ToolTipVisitor::generateToolTip( Incidence* inciden TQString tmp = "<qt>"; // header - tmp += "<b>" + incidence->summary().replace( "\n", "<br>" ) + "</b>"; + tmp += "<b>" + incidence->summary().tqreplace( "\n", "<br>" ) + "</b>"; //NOTE: using <hr> seems to confuse TQt3 tooltips in some cases so use "-----" tmp += "<br>----------<br>"; @@ -3492,7 +3492,7 @@ TQString IncidenceFormatter::ToolTipVisitor::generateToolTip( Incidence* inciden if ( !incidence->location().isEmpty() ) { tmp += "<br>"; tmp += "<i>" + i18n( "Location:" ) + "</i>" + " "; - tmp += incidence->location().replace( "\n", "<br>" ); + tmp += incidence->location().tqreplace( "\n", "<br>" ); } TQString durStr = IncidenceFormatter::durationString( incidence ); @@ -3515,7 +3515,7 @@ TQString IncidenceFormatter::ToolTipVisitor::generateToolTip( Incidence* inciden } tmp += "<br>----------<br>"; tmp += "<i>" + i18n( "Description:" ) + "</i>" + "<br>"; - tmp += desc.replace( "\n", "<br>" ); + tmp += desc.tqreplace( "\n", "<br>" ); tmp += "<br>----------"; } |