16 */ |
16 */ |
17 #include "tstaskmonitorglobals.h" |
17 #include "tstaskmonitorglobals.h" |
18 #include "hsrunningappserver.h" |
18 #include "hsrunningappserver.h" |
19 #include "hsrunningappsession.h" |
19 #include "hsrunningappsession.h" |
20 #include "tsrunningappstorage.h" |
20 #include "tsrunningappstorage.h" |
|
21 #include "tsscreenshotprovider.h" |
|
22 #include "tsbackstepping.h" |
21 |
23 |
22 _LIT(KErrObserverExists, "Observer already exists"); |
24 _LIT(KErrObserverExists, "Observer already exists"); |
23 // ----------------------------------------------------------------------------- |
25 // ----------------------------------------------------------------------------- |
24 // |
26 // |
25 // ----------------------------------------------------------------------------- |
27 // ----------------------------------------------------------------------------- |
35 // |
37 // |
36 // ----------------------------------------------------------------------------- |
38 // ----------------------------------------------------------------------------- |
37 // |
39 // |
38 CRunningAppServer::~CRunningAppServer() |
40 CRunningAppServer::~CRunningAppServer() |
39 { |
41 { |
|
42 delete mBacksteppingEngine; |
|
43 delete mScreenshotProviderStarter; |
40 delete mStorage; |
44 delete mStorage; |
41 mObservers.ResetAndDestroy(); |
45 mObservers.ResetAndDestroy(); |
42 } |
46 } |
43 |
47 |
44 // ----------------------------------------------------------------------------- |
48 // ----------------------------------------------------------------------------- |
58 // ----------------------------------------------------------------------------- |
62 // ----------------------------------------------------------------------------- |
59 // |
63 // |
60 void CRunningAppServer::ConstructL() |
64 void CRunningAppServer::ConstructL() |
61 { |
65 { |
62 StartL(KRunningAppServerName); |
66 StartL(KRunningAppServerName); |
|
67 User::LeaveIfError(mWsSession.Connect()); |
63 mStorage = CRunningAppStorage::NewL(*this); |
68 mStorage = CRunningAppStorage::NewL(*this); |
|
69 TRAP_IGNORE(mScreenshotProviderStarter = CTsScreenshotProvider::NewL(*mStorage); |
|
70 mBacksteppingEngine = CTsBackstepping::NewL(mWsSession);) |
64 } |
71 } |
65 |
72 |
66 // ----------------------------------------------------------------------------- |
73 // ----------------------------------------------------------------------------- |
67 // |
74 // |
68 // ----------------------------------------------------------------------------- |
75 // ----------------------------------------------------------------------------- |
69 // |
76 // |
70 CSession2* CRunningAppServer::NewSessionL(const TVersion &, const RMessage2&) const |
77 CSession2* CRunningAppServer::NewSessionL(const TVersion &, const RMessage2&) const |
71 { |
78 { |
72 return CRunningAppSession::NewL(*const_cast<CRunningAppServer *>(this), |
79 return CRunningAppSession::NewL(*const_cast<CRunningAppServer *>(this), |
|
80 *const_cast<CRunningAppServer *>(this)->mStorage, |
73 *const_cast<CRunningAppServer *>(this)->mStorage); |
81 *const_cast<CRunningAppServer *>(this)->mStorage); |
74 } |
82 } |
75 |
83 |
76 // ----------------------------------------------------------------------------- |
84 // ----------------------------------------------------------------------------- |
77 // |
85 // |