|
1 /* |
|
2 * Copyright (c) 2009 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: |
|
15 * |
|
16 */ |
|
17 |
|
18 #ifndef MCSCHILDRENHANDLER_H_ |
|
19 #define MCSCHILDRENHANDLER_H_ |
|
20 |
|
21 #include "mcschildrenscanner.h" |
|
22 |
|
23 class CMenuSrvEng; |
|
24 class CMcsCacheHandler; |
|
25 |
|
26 /** |
|
27 * FolderChildrenCount Handler. |
|
28 * @lib mcsmenu.lib |
|
29 * @since S60 v5.0 |
|
30 */ |
|
31 NONSHARABLE_CLASS( CMcsChildrenHandler ): |
|
32 public CBase, |
|
33 public MMcsChildrenScanner |
|
34 { |
|
35 public: |
|
36 /** |
|
37 * Two-phased constructor. Leaves on failure. |
|
38 * @return The constructed object. |
|
39 */ |
|
40 |
|
41 static CMcsChildrenHandler* NewL( |
|
42 CMenuSrvEng& aSrvEng, |
|
43 CMcsCacheHandler& aCacheHandler ); |
|
44 |
|
45 /** |
|
46 * Destructor. |
|
47 * @since S60 v5.0 |
|
48 * @capability None. |
|
49 * @throws None. |
|
50 * @panic None. |
|
51 */ |
|
52 virtual ~CMcsChildrenHandler(); |
|
53 |
|
54 |
|
55 void EngineEvents( TInt aFolder, TInt aEvents ); |
|
56 void HandleChildrenEvent(TInt aId, TUint aOldCount, TUint aNewCount); |
|
57 |
|
58 private: |
|
59 |
|
60 /** |
|
61 * Constructor. |
|
62 */ |
|
63 CMcsChildrenHandler( |
|
64 CMenuSrvEng& aSrvEng, |
|
65 CMcsCacheHandler& aCacheHandler ); |
|
66 |
|
67 /** |
|
68 * 2nd phase constructor. |
|
69 */ |
|
70 void ConstructL(); |
|
71 void ScanL(TInt aFolder); |
|
72 |
|
73 |
|
74 private: // data |
|
75 |
|
76 |
|
77 CMenuSrvEng& iSrvEng; |
|
78 |
|
79 CMcsCacheHandler& iCacheHandler; |
|
80 |
|
81 CMcsChildrenScanner* iScanner; /// < Own |
|
82 |
|
83 }; |
|
84 |
|
85 #endif /*MCSCHILDRENHANDLER_H_*/ |