130 } |
130 } |
131 |
131 |
132 // get publisher uid from widget registry |
132 // get publisher uid from widget registry |
133 FetchPublisherUidL( aHsContentInfo->PublisherId(), |
133 FetchPublisherUidL( aHsContentInfo->PublisherId(), |
134 aRegistryClientSession ); |
134 aRegistryClientSession ); |
135 |
135 |
|
136 // delete the old list box item |
|
137 delete iMdcaPoint; |
|
138 iMdcaPoint = NULL; |
|
139 |
136 // create iMdcaPoint for listbox |
140 // create iMdcaPoint for listbox |
137 _LIT( KFormatStr, "0\t%S"); |
141 _LIT( KFormatStr, "0\t%S"); |
138 iMdcaPoint = HBufC::NewL( |
142 iMdcaPoint = HBufC::NewL( |
139 aHsContentInfo->Name().Length() + KFormatStr().Length() ); |
143 aHsContentInfo->Name().Length() + KFormatStr().Length() ); |
140 iMdcaPoint->Des().Format( KFormatStr(), &aHsContentInfo->Name() ); |
144 iMdcaPoint->Des().Format( KFormatStr(), &aHsContentInfo->Name() ); |
141 |
145 |
|
146 // delete the old content info |
|
147 delete iHsContentInfo; |
|
148 iHsContentInfo = NULL; |
|
149 |
142 // take ownership of the content info |
150 // take ownership of the content info |
143 iHsContentInfo = aHsContentInfo; |
151 iHsContentInfo = aHsContentInfo; |
144 } |
152 } |
145 |
153 |
146 // --------------------------------------------------------- |
154 // --------------------------------------------------------- |
421 iHsContentInfo->Description() == aHsContentInfo->Description() && |
429 iHsContentInfo->Description() == aHsContentInfo->Description() && |
422 iHsContentInfo->CanBeAdded() == aHsContentInfo->CanBeAdded() ); |
430 iHsContentInfo->CanBeAdded() == aHsContentInfo->CanBeAdded() ); |
423 TBool sameLogo = ( |
431 TBool sameLogo = ( |
424 iHsContentInfo->IconPath() == aHsContentInfo->IconPath() ); |
432 iHsContentInfo->IconPath() == aHsContentInfo->IconPath() ); |
425 |
433 |
426 // delete the old content info |
|
427 delete iHsContentInfo; |
|
428 iHsContentInfo = NULL; |
|
429 |
|
430 // re-init the object, take care about leave. |
434 // re-init the object, take care about leave. |
431 TRAPD( err, InitL( aHsContentInfo, NULL ); ); |
435 TRAPD( err, InitL( aHsContentInfo, NULL ); ); |
432 if ( KErrNone != err ) |
436 if ( KErrNone != err ) |
433 { |
437 { |
434 delete aHsContentInfo; |
438 delete aHsContentInfo; |