|
1 /* |
|
2 * Copyright (c) 2008-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: Definition of CGlxtnDeleteThumbnailsTask |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 |
|
20 |
|
21 /** |
|
22 * @internal reviewed 30/07/2007 by Simon Brooks |
|
23 */ |
|
24 |
|
25 #ifndef C_GLXTNDELETETHUMBNAILSTASK_H |
|
26 #define C_GLXTNDELETETHUMBNAILSTASK_H |
|
27 |
|
28 // INCLUDES |
|
29 |
|
30 #include "glxtntask.h" |
|
31 |
|
32 // CONSTANTS |
|
33 |
|
34 // MACROS |
|
35 |
|
36 // DATA TYPES |
|
37 |
|
38 // FUNCTION PROTOTYPES |
|
39 |
|
40 // FORWARD DECLARATIONS |
|
41 |
|
42 class CGlxtnFileInfo; |
|
43 |
|
44 // CLASS DECLARATION |
|
45 |
|
46 /** |
|
47 * Task to delete all stored thumbnails for a media item. |
|
48 * |
|
49 * @author Dan Rhodes |
|
50 * @ingroup glx_thumbnail_creator |
|
51 */ |
|
52 NONSHARABLE_CLASS(CGlxtnDeleteThumbnailsTask) : public CGlxtnClientTask |
|
53 { |
|
54 public: // Constructors and destructor |
|
55 |
|
56 /** |
|
57 * Two-phased constructor. |
|
58 * @param iItemId Media ID of item whose thumbnails should be deleted. |
|
59 * @param aClient Client initiating the request. |
|
60 */ |
|
61 static CGlxtnDeleteThumbnailsTask* NewL(const TGlxMediaId& aItemId, |
|
62 MGlxtnThumbnailCreatorClient& aClient); |
|
63 |
|
64 /** |
|
65 * Destructor. |
|
66 */ |
|
67 virtual ~CGlxtnDeleteThumbnailsTask(); |
|
68 |
|
69 protected: // From CGlxtnTask |
|
70 |
|
71 TBool DoStartL(TRequestStatus& aStatus); |
|
72 void DoCancel(); |
|
73 TBool DoRunL(TRequestStatus& aStatus); |
|
74 TBool DoRunError(TInt aError); |
|
75 |
|
76 private: |
|
77 |
|
78 /** |
|
79 * C++ default constructor. |
|
80 * @param iItemId Media ID of item whose thumbnails should be deleted. |
|
81 * @param aClient Client initiating the request. |
|
82 */ |
|
83 CGlxtnDeleteThumbnailsTask(const TGlxMediaId& aItemId, |
|
84 MGlxtnThumbnailCreatorClient& aClient); |
|
85 |
|
86 /** |
|
87 * By default Symbian 2nd phase constructor is private. |
|
88 */ |
|
89 void ConstructL(); |
|
90 |
|
91 private: // Data |
|
92 /** File information for item whose thumbnails are to be deleted */ |
|
93 CGlxtnFileInfo* iInfo; |
|
94 /** Whether delete operation has been started */ |
|
95 TBool iDeleting; |
|
96 }; |
|
97 |
|
98 #endif // C_GLXTNDELETETHUMBNAILSTASK_H |
|
99 |
|
100 // End of File |