equal
deleted
inserted
replaced
123 // @since 3.1 |
123 // @since 3.1 |
124 // ============================================================================ |
124 // ============================================================================ |
125 // |
125 // |
126 CWidgetEntry::CWidgetEntry() |
126 CWidgetEntry::CWidgetEntry() |
127 : iPropertyValues( EWidgetPropertyIdCount ), |
127 : iPropertyValues( EWidgetPropertyIdCount ), |
128 iBlanketPermGranted ( EFalse), |
128 iMiniView ( EFalse), |
129 iFullView ( EFalse), |
129 iFullView ( EFalse), |
130 iMiniView ( EFalse) |
130 iBlanketPermGranted ( EFalse) |
131 { |
131 { |
132 } |
132 } |
133 |
133 |
134 // ============================================================================ |
134 // ============================================================================ |
135 // CWidgetEntry::~CWidgetEntry() |
135 // CWidgetEntry::~CWidgetEntry() |
434 |
434 |
435 void CWidgetEntry::ExternalizeXmlL( RWriteStream& aWriteStream, |
435 void CWidgetEntry::ExternalizeXmlL( RWriteStream& aWriteStream, |
436 CWidgetRegistryXml* aXmlProcessor, |
436 CWidgetRegistryXml* aXmlProcessor, |
437 RFs& aFileSession ) |
437 RFs& aFileSession ) |
438 { |
438 { |
439 xmlDocPtr doc = NULL; // not really used |
|
440 TInt i = 0; |
439 TInt i = 0; |
441 // For each property, write an XML entry |
440 // For each property, write an XML entry |
442 for ( ; i < EWidgetPropertyIdCount; ++i ) |
441 for ( ; i < EWidgetPropertyIdCount; ++i ) |
443 { |
442 { |
444 // skip props without values |
443 // skip props without values |
690 // and they will be undefined when serialized/deserialized) |
689 // and they will be undefined when serialized/deserialized) |
691 currentVersion = KWidgetPropertyListVersion71; |
690 currentVersion = KWidgetPropertyListVersion71; |
692 break; |
691 break; |
693 case KWidgetPropertyListVersion71: |
692 case KWidgetPropertyListVersion71: |
694 // Go from PropertlyListVersion71 to PropertyListVersion71CWRT |
693 // Go from PropertlyListVersion71 to PropertyListVersion71CWRT |
695 // 1) add ProcessUid for WRT (wgz) widgets |
694 // 1) add ProcessUid for WRT (wgz) widgets |
|
695 { |
696 (*this)[EProcessUid] = KUidWidgetUi.iUid; |
696 (*this)[EProcessUid] = KUidWidgetUi.iUid; |
697 |
697 |
698 // 2) add MIMEType |
698 // 2) add MIMEType |
699 HBufC* heapBuf = HBufC::NewLC(KWidgetMime().Length()); |
699 HBufC* heapBuf = HBufC::NewLC(KWidgetMime().Length()); |
700 TPtr ptr(heapBuf->Des()); |
700 TPtr ptr(heapBuf->Des()); |
701 ptr.Copy(KWidgetMime); // 8-bit to 16-bit copy |
701 ptr.Copy(KWidgetMime); // 8-bit to 16-bit copy |
702 (*this)[EMimeType] = *heapBuf; |
702 (*this)[EMimeType] = *heapBuf; |
703 CleanupStack::PopAndDestroy(); |
703 CleanupStack::PopAndDestroy(); |
704 |
704 |
705 currentVersion = KWidgetPropertyListVersion71CWRT; |
705 currentVersion = KWidgetPropertyListVersion71CWRT; |
|
706 } |
706 break; |
707 break; |
707 default: |
708 default: |
708 // Trouble |
709 // Trouble |
709 return; |
710 return; |
710 } |
711 } |