|
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: VideoThumbnailData class implementation |
|
15 * |
|
16 */ |
|
17 |
|
18 // INCLUDE FILES |
|
19 #include "videothumbnaildata.h" |
|
20 #include "videothumbnailtestdata.h" |
|
21 |
|
22 int VideoThumbnailTestData::mInstanceCallCount = 0; |
|
23 int VideoThumbnailTestData::mFreeThumbnailDataCallCount = 0; |
|
24 int VideoThumbnailTestData::mBackgroundThumbnailFetchingEnabled = 0; |
|
25 int VideoThumbnailTestData::mStartBackgroundFetchingCallCount = 0; |
|
26 |
|
27 VideoThumbnailData &VideoThumbnailData::instance() |
|
28 { |
|
29 VideoThumbnailTestData::mInstanceCallCount++; |
|
30 static VideoThumbnailData _thumbnailData; |
|
31 return _thumbnailData; |
|
32 } |
|
33 |
|
34 VideoThumbnailData::VideoThumbnailData() |
|
35 { |
|
36 // not stubbed |
|
37 } |
|
38 |
|
39 VideoThumbnailData::~VideoThumbnailData() |
|
40 { |
|
41 // not stubbed |
|
42 } |
|
43 |
|
44 bool VideoThumbnailData::removeThumbnail(TMPXItemId mediaId) |
|
45 { |
|
46 Q_UNUSED(mediaId); |
|
47 |
|
48 // not stubbed |
|
49 |
|
50 return true; |
|
51 } |
|
52 |
|
53 const QIcon* VideoThumbnailData::getThumbnail(TMPXItemId mediaId) |
|
54 { |
|
55 Q_UNUSED(mediaId); |
|
56 |
|
57 // not stubbed |
|
58 |
|
59 return 0; |
|
60 } |
|
61 |
|
62 void VideoThumbnailData::startBackgroundFetching(VideoSortFilterProxyModel *model, int fetchIndex) |
|
63 { |
|
64 Q_UNUSED(model); |
|
65 Q_UNUSED(fetchIndex); |
|
66 |
|
67 VideoThumbnailTestData::mStartBackgroundFetchingCallCount++; |
|
68 } |
|
69 |
|
70 void VideoThumbnailData::enableBackgroundFetching(bool enable) |
|
71 { |
|
72 VideoThumbnailTestData::mBackgroundThumbnailFetchingEnabled = enable; |
|
73 } |
|
74 |
|
75 void VideoThumbnailData::enableThumbnailCreation(bool enable) |
|
76 { |
|
77 Q_UNUSED(enable); |
|
78 // not stubbed |
|
79 } |
|
80 |
|
81 void VideoThumbnailData::freeThumbnailData() |
|
82 { |
|
83 VideoThumbnailTestData::mFreeThumbnailDataCallCount++; |
|
84 } |