1 /* |
1 /* |
2 * Copyright (c) 2004-2009 Nokia Corporation and/or its subsidiary(-ies). |
2 * Copyright (c) 2004-2010 Nokia Corporation and/or its subsidiary(-ies). |
3 * All rights reserved. |
3 * All rights reserved. |
4 * This component and the accompanying materials are made available |
4 * This component and the accompanying materials are made available |
5 * under the terms of "Eclipse Public License v1.0" |
5 * under the terms of "Eclipse Public License v1.0" |
6 * which accompanies this distribution, and is available |
6 * which accompanies this distribution, and is available |
7 * at the URL "http://www.eclipse.org/legal/epl-v10.html". |
7 * at the URL "http://www.eclipse.org/legal/epl-v10.html". |
26 // INCLUDES |
26 // INCLUDES |
27 #include <e32base.h> |
27 #include <e32base.h> |
28 #include <commdbconnpref.h> // for TCommDbConnPref |
28 #include <commdbconnpref.h> // for TCommDbConnPref |
29 #include <connpref.h> // for TConnPref |
29 #include <connpref.h> // for TConnPref |
30 #include <rconnmon.h> // for TConnMonIapInfo |
30 #include <rconnmon.h> // for TConnMonIapInfo |
31 #include <ConnectionUiUtilities.h> //TMsgQueryLinkedResults |
31 #include <ConnectionUiUtilities.h> |
32 #include "rmpm.h" |
32 #include "rmpm.h" |
33 #include "mpmserver.h" |
33 #include "mpmserver.h" |
34 |
34 |
35 // CONSTANTS |
35 // CONSTANTS |
36 const TUint32 KLowestPriority = 2147483647; // 0x7FFFFFFF |
36 const TUint32 KLowestPriority = 2147483647; // 0x7FFFFFFF |
51 const TUint KMPMNrWlansTwo = 2; |
51 const TUint KMPMNrWlansTwo = 2; |
52 const TInt KMaxGetIntSettingLength = KCommsDbSvrMaxColumnNameLength * 2; |
52 const TInt KMaxGetIntSettingLength = KCommsDbSvrMaxColumnNameLength * 2; |
53 _LIT( KIapProxyServiceSetting, "IAP\\IAPService" ); |
53 _LIT( KIapProxyServiceSetting, "IAP\\IAPService" ); |
54 |
54 |
55 // FORWARD DECLARATIONS |
55 // FORWARD DECLARATIONS |
56 class CMPMDisconnectDlg; |
|
57 class CMPMConfirmDlgRoaming; |
56 class CMPMConfirmDlgRoaming; |
58 class CMPMCommsDatAccess; |
57 class CMPMCommsDatAccess; |
59 class CMPMIapSelection; |
58 class CMPMIapSelection; |
60 |
59 |
61 // CLASS DECLARATION |
60 // CLASS DECLARATION |
319 * contain the sorted iaps |
318 * contain the sorted iaps |
320 */ |
319 */ |
321 void SortSnapL( const TUint32 aSnapId, |
320 void SortSnapL( const TUint32 aSnapId, |
322 TMpmSnapBuffer& aSortedIaps ); |
321 TMpmSnapBuffer& aSortedIaps ); |
323 |
322 |
324 /** |
|
325 * If session is displaying connection selection dialog |
|
326 * updated contents for it are written to publish& subscribe API. |
|
327 * |
|
328 * @since 3.2 |
|
329 */ |
|
330 void UpdateConnectionDialogL(); |
|
331 |
323 |
332 /** |
324 /** |
333 * Returns a reference to iStoredIapInfo. |
325 * Returns a reference to iStoredIapInfo. |
334 * |
326 * |
335 * @since 3.2 |
327 * @since 3.2 |
419 * @since 5.1 |
411 * @since 5.1 |
420 */ |
412 */ |
421 TBool UseUserConnPref(); |
413 TBool UseUserConnPref(); |
422 |
414 |
423 /** |
415 /** |
|
416 * Returns VPN user connection usage status. |
|
417 * @return ETrue if VPN user connection is used in this session. |
|
418 */ |
|
419 inline TBool VpnUserConnectionUsed() const; |
|
420 |
|
421 /** |
|
422 * Sets VPN user connection usage status. |
|
423 * @param aEnabled Informs if VPN user connection is used. |
|
424 */ |
|
425 void SetVpnUserConnectionUsed( const TBool aEnabled ); |
|
426 |
|
427 /** |
424 * Returns id of the client. |
428 * Returns id of the client. |
425 * |
429 * |
426 * @since 5.0 |
430 * @since 5.0 |
427 * @return Id of the client |
431 * @return Id of the client |
428 */ |
432 */ |
597 * Handling of error processing. |
601 * Handling of error processing. |
598 * @since 3.1 |
602 * @since 3.1 |
599 * @param aMessage message from client |
603 * @param aMessage message from client |
600 */ |
604 */ |
601 void HandleServerProcessErrorL(const RMessage2& aMessage); |
605 void HandleServerProcessErrorL(const RMessage2& aMessage); |
602 |
606 |
603 /** |
607 /** |
604 * Handling of prefered IAP notification registration. |
608 * Handling of prefered IAP notification registration. |
605 * @since 3.1 |
609 * @since 3.1 |
606 * @param aMessage message from client |
610 * @param aMessage message from client |
607 */ |
611 */ |
827 * to a background application. |
831 * to a background application. |
828 * @since 3.2 |
832 * @since 3.2 |
829 * @param aUid Application Uid |
833 * @param aUid Application Uid |
830 */ |
834 */ |
831 TBool IsBackgroundApplication( TUint32 aUid ) const; |
835 TBool IsBackgroundApplication( TUint32 aUid ) const; |
832 |
836 |
833 /** |
837 /** |
834 * Checks if disconnect dialog should be displayed for this error |
838 * Checks if disconnect dialog should be displayed for this error |
835 * @since 3.2 |
839 * @since 3.2 |
836 * @param aError Error code |
840 * @param aError Error code |
837 */ |
841 */ |
878 |
882 |
879 private: // Data |
883 private: // Data |
880 |
884 |
881 // Server class reference |
885 // Server class reference |
882 CMPMServer& iMyServer; |
886 CMPMServer& iMyServer; |
883 |
|
884 // Pointer to the disconnect dialog active object |
|
885 CMPMDisconnectDlg* iDisconnectDlg; |
|
886 |
887 |
887 // Pointer to the roaming confirmation dialog active object |
888 // Pointer to the roaming confirmation dialog active object |
888 CMPMConfirmDlgRoaming* iConfirmDlgRoaming; |
889 CMPMConfirmDlgRoaming* iConfirmDlgRoaming; |
889 |
890 |
890 // Connection Id |
891 // Connection Id |
935 |
936 |
936 // Iap selection object |
937 // Iap selection object |
937 // |
938 // |
938 CMPMIapSelection* iIapSelection; |
939 CMPMIapSelection* iIapSelection; |
939 |
940 |
940 // Stored state of migrating to carrier |
941 // Stored state of migrating to carrier |
941 // |
942 // |
942 TMigrateToCarrierState iMigrateState; |
943 TMigrateToCarrierState iMigrateState; |
943 |
944 |
944 // Last Iap notified using PreferredIap-notification |
945 // Last Iap notified using PreferredIap-notification |
945 // |
946 // |
946 TUint32 iLastNotifiedIap; |
947 TUint32 iLastNotifiedIap; |
947 |
948 |
948 // Iap to which connection is migrating |
949 // Iap to which connection is migrating |
949 // |
950 // |
950 TUint32 iMigrateIap; |
951 TUint32 iMigrateIap; |
951 |
952 |
952 // Set when this session is user connection |
953 // Set when this session is user connection |
953 // |
954 // |
954 TBool iUserConnection; |
955 TBool iUserConnection; |
955 |
956 |
956 // Set when disconnect dialog is shown to avoid |
957 // Set when this session uses VPN user connection |
957 // showing duplicate cellulara data usage dialog |
|
958 // |
958 // |
959 TBool iDisconnectDialogShown; |
959 TBool iVpnUserConnectionUsed; |
960 |
960 |
961 // Set when error discreet popup shown for IAP so it is |
961 // Set when error discreet popup shown for IAP so it is |
962 // not shown again if the SNAP is empty |
962 // not shown again if the SNAP is empty |
963 TBool iErrorDiscreetPopupShown; |
963 TBool iErrorDiscreetPopupShown; |
964 }; |
964 }; |
965 |
965 |