--- a/javauis/lcdui_akn/lcdui/src/CMIDChoiceGroupModel.cpp Wed Sep 15 12:05:25 2010 +0300
+++ b/javauis/lcdui_akn/lcdui/src/CMIDChoiceGroupModel.cpp Wed Oct 13 14:23:59 2010 +0300
@@ -71,10 +71,6 @@
// Delete icons
delete iIconSelected;
delete iIconNotSelected;
-#ifdef RD_JAVA_S60_RELEASE_9_2
- delete iIconSelectedHighlighted;
- delete iIconNotSelectedHighlighted;
-#endif // RD_JAVA_S60_RELEASE_9_2
delete iIconDummy;
}
@@ -132,8 +128,6 @@
TSize iconSize(layoutRect.Rect().Width(), layoutRect.Rect().Height());
- // create icons for non-highlighted mode
-
AknsUtils::CreateColorIconLC(skin, notSelectedSkinId, KAknsIIDQsnIconColors,
EAknsCIQsnIconColorsCG14, bitmap, mask, avkonbmpFilename, notSelectedIconId,
notSelectedMaskId, KRgbBlue, iconSize, EAspectRatioPreservedAndUnusedSpaceRemoved);
@@ -153,29 +147,6 @@
delete iIconSelected;
iIconSelected = iconSelected;
-
- // create icons for highlighted mode
-#ifdef RD_JAVA_S60_RELEASE_9_2
- AknsUtils::CreateColorIconLC(skin, notSelectedSkinId, KAknsIIDQsnIconColors,
- EAknsCIQsnIconColorsCG15, bitmap, mask, avkonbmpFilename, notSelectedIconId,
- notSelectedMaskId, KRgbBlue, iconSize, EAspectRatioPreservedAndUnusedSpaceRemoved);
-
- CGulIcon* iconNotSelectedHighlighted = CGulIcon::NewL(bitmap, mask);
- CleanupStack::Pop(2); //bitmap, mask
-
- delete iIconNotSelectedHighlighted;
- iIconNotSelectedHighlighted = iconNotSelectedHighlighted;
-
- AknsUtils::CreateColorIconLC(skin, selectedSkinId, KAknsIIDQsnIconColors,
- EAknsCIQsnIconColorsCG15, bitmap, mask, avkonbmpFilename, selectedIconId,
- selectedMaskId, KRgbBlue, iconSize, EAspectRatioPreservedAndUnusedSpaceRemoved);
-
- CGulIcon* iconSelectedHighlighted = CGulIcon::NewL(bitmap, mask);
- CleanupStack::Pop(2); //bitmap, mask
-
- delete iIconSelectedHighlighted;
- iIconSelectedHighlighted = iconSelectedHighlighted;
-#endif // RD_JAVA_S60_RELEASE_9_2
}
// Base class overrides
@@ -241,14 +212,7 @@
if (!iUpdating)
{
// Refresh icon array
-#ifdef RD_JAVA_S60_RELEASE_9_2
- if (iObserver)
- {
- UpdateIconArrayL(iObserver->IsControlOnFormHighlighted());
- }
-#else
UpdateIconArrayL();
-#endif // RD_JAVA_S60_RELEASE_9_2
// Report event
ReportEventL(MMIDChoiceGroupModelObserver::EElementAdded);
@@ -276,14 +240,7 @@
if (!iUpdating)
{
// Refresh icon array
-#ifdef RD_JAVA_S60_RELEASE_9_2
- if (iObserver)
- {
- UpdateIconArrayL(iObserver->IsControlOnFormHighlighted());
- }
-#else
UpdateIconArrayL();
-#endif // RD_JAVA_S60_RELEASE_9_2
// Report element addition
ReportEventL(MMIDChoiceGroupModelObserver::EElementAdded);
@@ -335,14 +292,7 @@
if (!iUpdating)
{
// Refresh icon array.
-#ifdef RD_JAVA_S60_RELEASE_9_2
- if (iObserver)
- {
- UpdateIconArrayL(iObserver->IsControlOnFormHighlighted());
- }
-#else
UpdateIconArrayL();
-#endif // RD_JAVA_S60_RELEASE_9_2
// Update the looks of the control
ReportEventL(MMIDChoiceGroupModelObserver::EElementDeleted);
@@ -366,14 +316,7 @@
if (!iUpdating)
{
// Recreate icon array
-#ifdef RD_JAVA_S60_RELEASE_9_2
- if (iObserver)
- {
- UpdateIconArrayL(iObserver->IsControlOnFormHighlighted());
- }
-#else
UpdateIconArrayL();
-#endif // RD_JAVA_S60_RELEASE_9_2
// Report event
ReportEventL(MMIDChoiceGroupModelObserver::EElementDeleted);
@@ -408,14 +351,7 @@
if (!iUpdating)
{
// Icon may have changed, recreate array.
-#ifdef RD_JAVA_S60_RELEASE_9_2
- if (iObserver)
- {
- UpdateIconArrayL(iObserver->IsControlOnFormHighlighted());
- }
-#else
UpdateIconArrayL();
-#endif // RD_JAVA_S60_RELEASE_9_2
// Report event
ReportEventL(MMIDChoiceGroupModelObserver::EElementModified);
@@ -454,15 +390,7 @@
if (aReCreate)
{
// Recreate, trap & ignore leaves
-#ifdef RD_JAVA_S60_RELEASE_9_2
- if (iObserver)
- {
- TRAP_IGNORE(
- UpdateIconArrayL(iObserver->IsControlOnFormHighlighted()));
- }
-#else
TRAP_IGNORE(UpdateIconArrayL());
-#endif // RD_JAVA_S60_RELEASE_9_2
}
return iIconArray;
@@ -527,17 +455,10 @@
iUpdating = EFalse;
// Create array, refresh control
-#ifdef RD_JAVA_S60_RELEASE_9_2
- if (iObserver)
- {
- TRAP_IGNORE(UpdateIconArrayL(iObserver->IsControlOnFormHighlighted()));
- }
-#else
- TRAP_IGNORE(UpdateIconArrayL());
-#endif // RD_JAVA_S60_RELEASE_9_2
+ TRAPD(ignore, UpdateIconArrayL());
// Report update end (observer should redraw)
- TRAP_IGNORE(ReportEventL(MMIDChoiceGroupModelObserver::EUpdateEnded));
+ TRAP(ignore, ReportEventL(MMIDChoiceGroupModelObserver::EUpdateEnded));
}
@@ -610,11 +531,7 @@
// NOTE that the indices in the array and the item strings should
// be synchronised. The selection icon is always at index
// 0 (selected) and 1 (not selected)
-#ifdef RD_JAVA_S60_RELEASE_9_2
-void CMIDChoiceGroupModel::UpdateIconArrayL(TBool aHighlighted)
-#else
void CMIDChoiceGroupModel::UpdateIconArrayL()
-#endif // RD_JAVA_S60_RELEASE_9_2
{
ASSERT(iElements);
ASSERT(iIconArray);
@@ -630,21 +547,8 @@
}
// First add the selection icons
-#ifdef RD_JAVA_S60_RELEASE_9_2
- if (aHighlighted)
- {
- iIconArray->AppendL(iIconSelectedHighlighted);
- iIconArray->AppendL(iIconNotSelectedHighlighted);
- }
- else
- {
- iIconArray->AppendL(iIconSelected);
- iIconArray->AppendL(iIconNotSelected);
- }
-#else
iIconArray->AppendL(iIconSelected);
iIconArray->AppendL(iIconNotSelected);
-#endif // RD_JAVA_S60_RELEASE_9_2
// Then loop through the elements and add their icons
for (TInt i = 0; i < nCount; i++)