|
1 /* |
|
2 * Copyright (c) 2006 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: Base class for concrete thumbnailloaders. |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 #ifndef CPHCNTTHUMBNAILLOADERBASE_H |
|
20 #define CPHCNTTHUMBNAILLOADERBASE_H |
|
21 |
|
22 |
|
23 #include <e32base.h> |
|
24 #include "mphcntthumbnailloader.h" |
|
25 |
|
26 /** |
|
27 * Base class for thumbnail loaders. |
|
28 * |
|
29 * Holds the loading observer and offers interface |
|
30 * for notifying the observer. |
|
31 * |
|
32 * @lib PhoneCntFinder |
|
33 * @since S60 v3.1 |
|
34 */ |
|
35 NONSHARABLE_CLASS( CPhCntThumbnailLoaderBase ) : |
|
36 public CBase, |
|
37 public MPhCntThumbnailLoader |
|
38 { |
|
39 public: |
|
40 |
|
41 // from base class MPhCntThumbnailLoader |
|
42 |
|
43 /** |
|
44 * From MPhCntThumbnailLoader. |
|
45 * |
|
46 * @since S60 v3.1 |
|
47 * @see MPhCntThumbnailLoader |
|
48 */ |
|
49 void LoadL( |
|
50 const CPhCntContactId& aContactId, |
|
51 MPhCntLoaderObserver& aLoadingObserver ); |
|
52 |
|
53 protected: |
|
54 |
|
55 virtual ~CPhCntThumbnailLoaderBase(); |
|
56 |
|
57 CPhCntThumbnailLoaderBase(); |
|
58 |
|
59 /** |
|
60 * Notifies the observer. |
|
61 */ |
|
62 void NotifyObserver( CFbsBitmap* aBitmap, TInt aError ); |
|
63 |
|
64 private: |
|
65 |
|
66 /** |
|
67 * Template method, for doing the actual loading in base class. |
|
68 */ |
|
69 virtual void DoLoadL( const CPhCntContactId& aContactId ) = 0; |
|
70 |
|
71 private: // Data |
|
72 |
|
73 /** |
|
74 * Observer of loading thumbnail. |
|
75 * Not own. |
|
76 */ |
|
77 MPhCntLoaderObserver* iLoadingObserver; |
|
78 |
|
79 }; |
|
80 |
|
81 #endif // CPHCNTTHUMBNAILLOADERBASE_H |