11 * |
11 * |
12 * Contributors: |
12 * Contributors: |
13 * |
13 * |
14 * Description: |
14 * Description: |
15 * |
15 * |
16 * Version : %version: 5 % |
16 * Version : %version: 7 % |
17 */ |
17 */ |
18 #include <QList> |
18 #include <QList> |
19 #include "hglogger.h" |
19 #include "hglogger.h" |
20 #include <hbicon.h> |
20 #include <HbIcon> |
21 #include "mydataprovider.h" |
21 #include "mydataprovider.h" |
22 |
|
23 //#include "x:\sf\mw\qt\src\openvg\qpixmapdata_vg_p.h" |
|
24 //typedef VGImage (*pfnVgCreateEGLImageTargetKHR)(VGeglImageKHR); |
|
25 |
22 |
26 const int KItemIdRole = Qt::UserRole+1; |
23 const int KItemIdRole = Qt::UserRole+1; |
27 |
24 |
28 const int KThumbnailsPriority = EPriorityLess; //standard priority |
25 const int KThumbnailsPriority = EPriorityLess; //standard priority |
29 |
26 |
30 |
27 |
31 MyDataProvider::MyDataProvider(QObject *parent) : |
28 MyDataProvider::MyDataProvider(QObject *parent) : |
32 HgDataProviderModel(parent), |
29 HgDataProviderModel(parent), |
33 mDefaultIcon(new HbIcon(QIcon(QPixmap(":/icons/default.png")))), |
30 mDefaultIcon(QIcon(QPixmap(":/icons/default.png"))), |
34 mScheduler(new CActiveSchedulerWait()), |
31 mScheduler(new CActiveSchedulerWait()), |
35 mWrapper( new ThumbnailManager() ), |
32 mWrapper( new ThumbnailManager() ), |
36 mThumbnailRequestPending(false), |
33 mThumbnailRequestPending(false), |
37 mThumbnailRequestIndex(-1), |
34 mThumbnailRequestIndex(-1), |
38 mThumbnailRequestID(-1), |
35 mThumbnailRequestID(-1), |
40 mMDSLoadInProgress(false), |
37 mMDSLoadInProgress(false), |
41 mMode(0) |
38 mMode(0) |
42 { |
39 { |
43 // TX_ENTRY |
40 // TX_ENTRY |
44 Q_UNUSED(parent); |
41 Q_UNUSED(parent); |
|
42 |
45 mWrapper->setThumbnailSize( mThumbnailsize ); |
43 mWrapper->setThumbnailSize( mThumbnailsize ); |
46 mWrapper->setQualityPreference( ThumbnailManager::OptimizeForPerformance ); |
44 mWrapper->setQualityPreference( ThumbnailManager::OptimizeForPerformance ); |
47 |
45 |
48 QObject::connect( mWrapper, SIGNAL(thumbnailReady( QPixmap , void* , int, int ) ), |
46 QObject::connect( mWrapper, SIGNAL(thumbnailReady( QPixmap , void* , int, int ) ), |
49 this, SLOT( thumbnailReady( QPixmap , void* , int , int ))); |
47 this, SLOT( thumbnailReady( QPixmap , void* , int , int ))); |