|
1 /* |
|
2 * Copyright (c) 2008 Nokia Corporation and/or its subsidiary(-ies). |
|
3 * All rights reserved. |
|
4 * This component and the accompanying materials are made available |
|
5 * under the terms of "Eclipse Public License v1.0" |
|
6 * which accompanies this distribution, and is available |
|
7 * at the URL "http://www.eclipse.org/legal/epl-v10.html". |
|
8 * |
|
9 * Initial Contributors: |
|
10 * Nokia Corporation - initial contribution. |
|
11 * |
|
12 * Contributors: |
|
13 * |
|
14 * Description: Setting item class for 3D settings. |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 |
|
20 // INCLUDES |
|
21 #include "CProfile3dSettingItem.h" |
|
22 #include "CProfile3dSettingPage.h" |
|
23 |
|
24 // ============================ MEMBER FUNCTIONS =============================== |
|
25 |
|
26 // ----------------------------------------------------------------------------- |
|
27 // CProfile3dSettingItem::CProfile3dSettingItem |
|
28 // C++ constructor can NOT contain any code, that might leave. |
|
29 // ----------------------------------------------------------------------------- |
|
30 // |
|
31 CProfile3dSettingItem::CProfile3dSettingItem( |
|
32 TInt aIdentifier, |
|
33 TInt& aValue, |
|
34 const TDesC& aRingingTone, |
|
35 const TInt& aRingingType, |
|
36 const TBool& aVibratingAlert, |
|
37 const TInt& aVolume, |
|
38 const TInt& a3DEffectOrEcho ) |
|
39 : CAknEnumeratedTextPopupSettingItem( aIdentifier, aValue ), |
|
40 iRingingTone( aRingingTone ), |
|
41 iRingingType( aRingingType ), |
|
42 iVibratingAlert( aVibratingAlert ), |
|
43 iVolume( aVolume ), |
|
44 i3DEffectOrEcho( a3DEffectOrEcho ) |
|
45 { |
|
46 iIdentifier = aIdentifier; |
|
47 } |
|
48 |
|
49 // ----------------------------------------------------------------------------- |
|
50 // CProfile3dSettingItem::CompleteConstructionL |
|
51 // ----------------------------------------------------------------------------- |
|
52 // |
|
53 void CProfile3dSettingItem::CompleteConstructionL() |
|
54 { |
|
55 CAknEnumeratedTextPopupSettingItem::CompleteConstructionL(); |
|
56 CArrayPtr<CAknEnumeratedText>* array = EnumeratedTextArray(); |
|
57 TInt count( array->Count() ); |
|
58 HBufC* text = NULL; |
|
59 while( count-- ) |
|
60 { |
|
61 text = array->At( count )->Value(); |
|
62 TPtr modifiable( text->Des() ); |
|
63 AknTextUtils::LanguageSpecificNumberConversion( modifiable ); |
|
64 } |
|
65 } |
|
66 |
|
67 // ----------------------------------------------------------------------------- |
|
68 // CProfile3dSettingItem::CreateSettingPageL |
|
69 // ----------------------------------------------------------------------------- |
|
70 // |
|
71 CAknSettingPage* CProfile3dSettingItem::CreateSettingPageL() |
|
72 { |
|
73 return new( ELeave ) CProfile3dSettingPage( |
|
74 SettingPageResourceId(), |
|
75 *QueryValue(), |
|
76 iRingingTone, |
|
77 iRingingType, |
|
78 iVibratingAlert, |
|
79 iVolume, |
|
80 i3DEffectOrEcho, |
|
81 iIdentifier ); |
|
82 } |
|
83 |
|
84 // End of File |