15 * |
15 * |
16 */ |
16 */ |
17 |
17 |
18 |
18 |
19 |
19 |
20 #include "BasePlugin.h" |
20 #include "baseplugin.h" |
21 #include "baseplugincommonutils.h" |
21 #include "baseplugincommonutils.h" |
22 #include "CFSMailCommon.h" |
22 #include "cfsmailcommon.h" |
23 |
23 |
24 |
24 |
25 static void TranslateMsgStoreAttendeeL( |
25 static void TranslateMsgStoreAttendeeL( |
26 CMsgStorePropertyContainer& aSrc, |
26 CMsgStorePropertyContainer& aSrc, |
27 TUint aIdx, |
27 TUint aIdx, |
91 |
91 |
92 |
92 |
93 /** |
93 /** |
94 * |
94 * |
95 */ |
95 */ |
96 void CBasePlugin::TranslateMsgStorePropsL( |
96 EXPORT_C void CBasePlugin::TranslateMsgStorePropsL( |
97 const TFSMailMsgId& aMailBoxId, |
97 const TFSMailMsgId& aMailBoxId, |
98 CMsgStorePropertyContainer& aMessage, |
98 CMsgStorePropertyContainer& aMessage, |
99 CFSMailMessagePart& aFsMsg, |
99 CFSMailMessagePart& aFsMsg, |
100 const TFSMailDetails aDetails ) |
100 const TFSMailDetails aDetails ) |
101 |
101 |
316 * Common msgstore meeting request fields translation to Freestyle. |
316 * Common msgstore meeting request fields translation to Freestyle. |
317 * |
317 * |
318 * @param aMessage |
318 * @param aMessage |
319 * @param aFsMsg |
319 * @param aFsMsg |
320 */ |
320 */ |
321 void CBasePlugin::TranslateMsgStoreMrL( |
321 EXPORT_C void CBasePlugin::TranslateMsgStoreMrL( |
322 const TFSMailMsgId& aMailBoxId, |
322 const TFSMailMsgId& aMailBoxId, |
323 CMsgStorePropertyContainer& aMessage, |
323 CMsgStorePropertyContainer& aMessage, |
324 CMsgStorePropertyContainer& aCalendar, |
324 CMsgStorePropertyContainer& aCalendar, |
325 CFSMailMessagePart& aFsMsg ) |
325 CFSMailMessagePart& aFsMsg ) |
326 |
326 |
611 CleanupClosePushL( days ); |
611 CleanupClosePushL( days ); |
612 |
612 |
613 if ( aCalendar.FindProperty( KMsgStorePropertyMrMonthDay, idx ) ) |
613 if ( aCalendar.FindProperty( KMsgStorePropertyMrMonthDay, idx ) ) |
614 { |
614 { |
615 TUint32 monthDayNo = aCalendar.PropertyValueUint32L( idx ); |
615 TUint32 monthDayNo = aCalendar.PropertyValueUint32L( idx ); |
616 days.AppendL(monthDayNo); |
616 days.Append(monthDayNo); |
617 /**@ double check that when testing starts.*/ |
617 /**@ double check that when testing starts.*/ |
618 } |
618 } |
619 |
619 |
620 recurrenceRule->SetRecurrentMonthDaysL( days ); |
620 recurrenceRule->SetRecurrentMonthDaysL( days ); |
621 |
621 |
774 aDst.AddOrUpdatePropertyL( KMsgStorePropertyReceivedAt, sentTime ); |
774 aDst.AddOrUpdatePropertyL( KMsgStorePropertyReceivedAt, sentTime ); |
775 aSrc.SetDate( sentTime ); |
775 aSrc.SetDate( sentTime ); |
776 } |
776 } |
777 |
777 |
778 //to recipients. |
778 //to recipients. |
779 //<qmail> Return by val (as in earlier Cmail version) |
779 RPointerArray<CFSMailAddress>& toRecipients = aSrc.GetToRecipients(); |
780 RPointerArray<CFSMailAddress> toRecipients = aSrc.GetToRecipients(); |
|
781 TranslateEmailFwRecipientsL( aDst, KMsgStorePropertyTo, toRecipients ); |
780 TranslateEmailFwRecipientsL( aDst, KMsgStorePropertyTo, toRecipients ); |
782 |
781 |
783 //cc recipients. |
782 //cc recipients. |
784 RPointerArray<CFSMailAddress> ccRecipients = aSrc.GetCCRecipients(); |
783 RPointerArray<CFSMailAddress>& ccRecipients = aSrc.GetCCRecipients(); |
785 TranslateEmailFwRecipientsL( aDst, KMsgStorePropertyCc, ccRecipients ); |
784 TranslateEmailFwRecipientsL( aDst, KMsgStorePropertyCc, ccRecipients ); |
786 |
785 |
787 //bcc recipients. |
786 //bcc recipients. |
788 RPointerArray<CFSMailAddress> bccRecipients = aSrc.GetBCCRecipients(); |
787 RPointerArray<CFSMailAddress>& bccRecipients = aSrc.GetBCCRecipients(); |
789 TranslateEmailFwRecipientsL( aDst, KMsgStorePropertyBcc, bccRecipients ); |
788 TranslateEmailFwRecipientsL( aDst, KMsgStorePropertyBcc, bccRecipients ); |
790 //</qmail> |
|
791 |
789 |
792 //flags. |
790 //flags. |
793 //the cast is important otherwise the TBool overload gets called. |
791 //the cast is important otherwise the TBool overload gets called. |
794 TUint32 flag = static_cast<TUint32>( aSrc.GetFlags() ); |
792 TUint32 flag = static_cast<TUint32>( aSrc.GetFlags() ); |
795 aDst.AddOrUpdatePropertyL( |
793 aDst.AddOrUpdatePropertyL( |
1116 * step is supplied via the day of week ftor. See CDayOfWeekFtor for further |
1114 * step is supplied via the day of week ftor. See CDayOfWeekFtor for further |
1117 * information. Although not strictly necessary this avoids duplicating all the if's |
1115 * information. Although not strictly necessary this avoids duplicating all the if's |
1118 * when dealing with rule translation. |
1116 * when dealing with rule translation. |
1119 * |
1117 * |
1120 * @param aDayOfWeekMask day of week mask in the MsgStore format, see |
1118 * @param aDayOfWeekMask day of week mask in the MsgStore format, see |
1121 * MsgStorePropertyKeys.h for information. |
1119 * msgstorepropertykeys.h for information. |
1122 * @param aFtor translation ftor. |
1120 * @param aFtor translation ftor. |
1123 */ |
1121 */ |
1124 void CBasePlugin::TranslateMsgStoreDayOfWeek( |
1122 void CBasePlugin::TranslateMsgStoreDayOfWeek( |
1125 TUint32 aDayOfWeekMask, |
1123 TUint32 aDayOfWeekMask, |
1126 TDayOfWeekFtor& aFtor ) |
1124 TDayOfWeekFtor& aFtor ) |