connectionmonitoring/connmon/connectionmonitor/src/cellulardatausagekeyupdater.cpp
equal
deleted
inserted
replaced
26 #include <datamobilitycommsdattypes.h> |
26 #include <datamobilitycommsdattypes.h> |
27 #include <cmpluginbaseeng.h> |
27 #include <cmpluginbaseeng.h> |
28 |
28 |
29 #include "cellulardatausagekeyupdater.h" |
29 #include "cellulardatausagekeyupdater.h" |
30 #include "ConnMonServ.h" |
30 #include "ConnMonServ.h" |
|
31 #include "ConnMonAvailabilityManager.h" |
31 #include "ConnMonIap.h" |
32 #include "ConnMonIap.h" |
32 #include "ConnMonDef.h" |
33 #include "ConnMonDef.h" |
33 #include "log.h" |
34 #include "log.h" |
34 |
35 |
35 // Repository for CommsDat |
36 // Repository for CommsDat |
97 TRAPD( err, cmRepository = CRepository::NewL( KCRUidCmManager ) ) |
98 TRAPD( err, cmRepository = CRepository::NewL( KCRUidCmManager ) ) |
98 |
99 |
99 if ( err == KErrNone ) |
100 if ( err == KErrNone ) |
100 { |
101 { |
101 TInt previous( 0 ); |
102 TInt previous( 0 ); |
102 TInt err = cmRepository->Get( KCurrentCellularDataUsage, previous ); |
103 err = cmRepository->Get( KCurrentCellularDataUsage, previous ); |
103 |
104 |
104 if ( err == KErrNone && ( value != previous ) ) |
105 if ( err == KErrNone && ( value != previous ) ) |
105 { |
106 { |
106 cmRepository->Set( KCurrentCellularDataUsage, value ); |
107 cmRepository->Set( KCurrentCellularDataUsage, value ); |
107 LOGIT1("KCurrentCellularDataUsage set to <%d>", value) |
108 LOGIT1("KCurrentCellularDataUsage set to %d", value) |
|
109 |
|
110 LOGIT("CCellularDataUsageKeyUpdater triggered HandleAvailabilityChange()") |
|
111 iServer->AvailabilityManager()->HandleAvailabilityChange(); |
108 } |
112 } |
109 delete cmRepository; |
113 delete cmRepository; |
110 } |
114 } |
111 else |
115 else |
112 { |
116 { |