--- a/mmshplugins/mmshsettingsuiplugin/src/mussettingscontainer.cpp Thu Jan 07 12:45:29 2010 +0200
+++ b/mmshplugins/mmshsettingsuiplugin/src/mussettingscontainer.cpp Tue Feb 02 00:09:07 2010 +0200
@@ -12,7 +12,7 @@
* Contributors:
*
* Description: Container for MUSSettingsPlugin.
-* Version : %version: 15.2.4.1.7 % << Don't touch! Updated by Synergy at check-out.
+* Version : %version: 20 % << Don't touch! Updated by Synergy at check-out.
*
*/
@@ -65,7 +65,7 @@
{
MUS_LOG( "[MUSSET] -> CMusSettingsContainer::ConstructL()" )
- iOperatorVariant = iModel.VSSettingsOperatorVariantL();
+ iOperatorVariant = MultimediaSharingSettings::OperatorVariantSettingL();
iListBox = new( ELeave ) CAknSettingStyleListBox;
@@ -93,9 +93,9 @@
}
-// ---------------------------------------------------------------------------
+// -----------------------------------------------------------------------------
// Constructs a listbox from a specified resource id.
-// ---------------------------------------------------------------------------
+// -----------------------------------------------------------------------------
//
void CMusSettingsContainer::ConstructListBoxL( TInt aResLbxId )
{
@@ -135,9 +135,9 @@
}
-// ---------------------------------------------------------------------------
+// -----------------------------------------------------------------------------
// Populates listbox items.
-// ---------------------------------------------------------------------------
+// -----------------------------------------------------------------------------
//
void CMusSettingsContainer::CreateListBoxItemsL()
{
@@ -158,9 +158,9 @@
}
-// ---------------------------------------------------------------------------
+// -----------------------------------------------------------------------------
// Updates a specified feature (item in listbox).
-// ---------------------------------------------------------------------------
+// -----------------------------------------------------------------------------
//
void CMusSettingsContainer::UpdateListBoxL( TInt aFeatureId )
{
@@ -199,9 +199,9 @@
}
-// ---------------------------------------------------------------------------
+// -----------------------------------------------------------------------------
// Generic method to add an item to listbox and make it visible.
-// ---------------------------------------------------------------------------
+// -----------------------------------------------------------------------------
//
void CMusSettingsContainer::AddItemL( TInt aId, const TPtrC aText )
{
@@ -213,24 +213,33 @@
}
-// ---------------------------------------------------------------------------
+// -----------------------------------------------------------------------------
// Adds activation setting item to listbox.
-// ---------------------------------------------------------------------------
+// -----------------------------------------------------------------------------
//
void CMusSettingsContainer::MakeActivationItemL()
{
MUS_LOG( "[MUSSET] -> CMusSettingsContainer::MakeActivationItemL()" )
- iVSActication = iModel.VSSettingsActivationL();
- AddItemL( KGSSettIdVSActivation, ( *iActivationItems )[ iVSActication ] );
+ MusSettingsKeys::TActivation activation =
+ MultimediaSharingSettings::ActivationSettingL();
+
+ if ( activation != MusSettingsKeys::EAlwaysActive )
+ {
+ // We make sure that if someone has written to CenRep value bigger
+ // than 1 (which after OCC changes means 'Off') we treat it as 'Off'.
+ activation = MusSettingsKeys::EActiveInHomeNetworks;
+ }
+
+ AddItemL( KGSSettIdVSActivation, ( *iActivationItems )[ activation ] );
MUS_LOG( "[MUSSET] <- CMusSettingsContainer::MakeActivationItemL()" )
}
-// ---------------------------------------------------------------------------
+// -----------------------------------------------------------------------------
// Adds operator specific activation setting item to listbox.
-// ---------------------------------------------------------------------------
+// -----------------------------------------------------------------------------
//
void CMusSettingsContainer::MakeOperatorActivationItemL()
{
@@ -243,17 +252,17 @@
}
-// ---------------------------------------------------------------------------
+// -----------------------------------------------------------------------------
// Adds SIP profile setting item to settings listbox. Item will contain
// indication of [no SIP profile selected], [using default SIP profile] or
// [name of SIP profile specified to be used]
-// ---------------------------------------------------------------------------
+// -----------------------------------------------------------------------------
//
void CMusSettingsContainer::MakeSIPProfileItemL()
{
MUS_LOG( "[MUSSET] -> CMusSettingsContainer::MakeSIPProfileItemL()" )
- TInt profile = iModel.VSSettingsProfileL();
+ TInt profile = MultimediaSharingSettings::SipProfileSettingL();
if ( profile != KDefaultSipProfile && profile != KNoSipProfileSelected )
{
@@ -289,14 +298,14 @@
}
-// ---------------------------------------------------------------------------
+// -----------------------------------------------------------------------------
// Adds autorecord item to listbox.
-// ---------------------------------------------------------------------------
+// -----------------------------------------------------------------------------
//
void CMusSettingsContainer::MakeAutoRecordItemL()
{
MUS_LOG( "[MUSSET] -> CMusSettingsContainer::MakeAutoRecordItemL()" )
- TInt autoRecordMode = iModel.VSSettingsAutoRecordL();
+ TInt autoRecordMode = MultimediaSharingSettings::AutoRecordSettingL();
MUS_LOG1( "[MUSSET] autoRecordMode: %d", autoRecordMode )
MUS_LOG1( "[MUSSET] iAutoRecordItems.Count: %d", iAutoRecordItems->Count() )
@@ -314,9 +323,9 @@
}
-// ---------------------------------------------------------------------------
+// -----------------------------------------------------------------------------
// Adds recorded video saving item to listbox.
-// ---------------------------------------------------------------------------
+// -----------------------------------------------------------------------------
//
void CMusSettingsContainer::MakeRecordedVideoSavingItemL()
{
@@ -332,12 +341,12 @@
if ( index == KErrNotFound )
{
- MUS_LOG( "[MUSSET] -> preferred drive doesn't exist anymore \
-(e.g. remote drive deleted), taking system drive..." )
+ MUS_LOG( "[MUSSET] Preferred drive doesn't exist anymore, " )
+ MUS_LOG( "[MUSSET] e.g. remote drive deleted, using system drive" )
driveNumber = RFs::GetSystemDrive();
index = dlg->FindIndexByDrive( driveNumber );
- iModel.SetVSSettingsRecordedVideoSavingL( driveNumber );
+ MultimediaSharingSettings::SetVideoLocationSettingL( driveNumber );
}
TFileName item( KNullDesC );
@@ -353,40 +362,38 @@
}
-// ---------------------------------------------------------------------------
+// -----------------------------------------------------------------------------
// Adds note item to listbox. (Alerts setting). Present only with operator
// variant set.
-// ---------------------------------------------------------------------------
+// -----------------------------------------------------------------------------
//
void CMusSettingsContainer::MakeNoteItemL()
{
- MUS_LOG(
- "[MUSSET] -> CMusSettingsContainer::MakeNoteItemL()" )
+ MUS_LOG( "[MUSSET] -> CMusSettingsContainer::MakeNoteItemL()" )
- TInt savingMode = iModel.VSSettingsNoteL();
+ MusSettingsKeys::TAuditoryNotification auditoryNotification =
+ MultimediaSharingSettings::AuditoryNotificationSettingL();
- MUS_LOG1( "[MUSSET] -> CMusSettingsContainer::Mode:%d()", savingMode );
+ MUS_LOG1( "[MUSSET] -> CMusSettingsContainer::Mode:%d()",
+ auditoryNotification )
// If unset, use and set default value
- if ( savingMode < 0 || savingMode > 1 )
+ if ( auditoryNotification < 0 || auditoryNotification > 1 )
{
- MUS_LOG( "[MUSSET] -> SetVSSettingsNoteL" );
- savingMode = 0;
- iModel.SetVSSettingsNoteL(
- MusSettingsKeys::EAuditoryNotificationOff );
- MUS_LOG( "[MUSSET] <- SetVSSettingsNoteL" );
+ auditoryNotification = MusSettingsKeys::EAuditoryNotificationOff;
+ MultimediaSharingSettings::SetAuditoryNotificationSettingL(
+ MusSettingsKeys::EAuditoryNotificationOff );
}
- MUS_LOG( "[MUSSET] -> AddItemL" );
- AddItemL( KGSSettIdNote, ( *iActivationItems )[ savingMode ] );
- MUS_LOG( "[MUSSET] <- SetVSSettingsNoteL" );
- MUS_LOG(
- "[MUSSET] <- CMusSettingsContainer::MakeNoteItemL()" )
+
+ AddItemL( KGSSettIdNote, ( *iActivationItems )[ auditoryNotification ] );
+
+ MUS_LOG( "[MUSSET] <- CMusSettingsContainer::MakeNoteItemL()" )
}
-// ---------------------------------------------------------------------------
+// -----------------------------------------------------------------------------
// Gets help context.
-// ---------------------------------------------------------------------------
+// -----------------------------------------------------------------------------
//
void CMusSettingsContainer::GetHelpContext( TCoeHelpContext& aContext ) const
{
@@ -397,9 +404,9 @@
}
-// ---------------------------------------------------------------------------
+// -----------------------------------------------------------------------------
// Returns currently selected feature (listbox item).
-// ---------------------------------------------------------------------------
+// -----------------------------------------------------------------------------
//
TInt CMusSettingsContainer::CurrentFeatureId() const
{
@@ -408,10 +415,10 @@
}
-// ----------------------------------------------------------------------------
+// -----------------------------------------------------------------------------
// If call is on, informs user with note that new profile is going to be active
// after current call.
-// ----------------------------------------------------------------------------
+// -----------------------------------------------------------------------------
//
void CMusSettingsContainer::ShowNewProfileActiveAfterCallL()
{
@@ -438,10 +445,10 @@
}
}
-// ----------------------------------------------------------------------------
+// -----------------------------------------------------------------------------
// void CMusSettingsContainer::HideItemsL(TInt aItemIndex)
// Some items are unwanted by operators.Hide those items from listbox item
-// ----------------------------------------------------------------------------
+// -----------------------------------------------------------------------------
//
void CMusSettingsContainer::HideItemsL(TInt aItemIndex)
{