equal
deleted
inserted
replaced
|
1 /* |
|
2 * Copyright (c) 2010 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 #include <QtCore> |
|
19 #include <QCoreApplication> |
|
20 #include <QDebug> |
|
21 #include <QTest> |
|
22 |
|
23 class QCPixSearcher; |
|
24 class QCPixDocument; |
|
25 |
|
26 class CSearchHandler: public QObject |
|
27 { |
|
28 Q_OBJECT |
|
29 public: |
|
30 CSearchHandler(); |
|
31 |
|
32 signals: |
|
33 void handleSearchResult(int, int); |
|
34 void handleAsyncSearchResult(int, int); |
|
35 void handleDocument(int aError, QCPixDocument* aDoc); |
|
36 |
|
37 private slots: |
|
38 void __handleSearchResult(int aError, int estimatedResultCount); |
|
39 void __getDocumentAsync(int aError, QCPixDocument* aDocument ); |
|
40 |
|
41 public: |
|
42 ~CSearchHandler(); |
|
43 QCPixDocument* getDocumentAtIndex(int aIndex); |
|
44 void getDocumentAsyncAtIndex(int aIndex); |
|
45 void search(QString aSearchString); |
|
46 void searchAsync(QString aSearchString); |
|
47 void cancelLastSearch(); |
|
48 int getSearchResultCount(); |
|
49 |
|
50 private: |
|
51 QCPixSearcher *iSearchInterface; |
|
52 QList<QVariantMap> searchResults; |
|
53 int iSearchresultCount; |
|
54 }; |