2
This file is part of Choqok, the KDE micro-blogging client
4
Copyright (C) 2008-2009 Mehrdad Momeny <mehrdad.momeny@gmail.com>
6
This program is free software; you can redistribute it and/or
7
modify it under the terms of the GNU General Public License as
8
published by the Free Software Foundation; either version 2 of
9
the License or (at your option) version 3 or any later version
10
accepted by the membership of KDE e.V. (or its successor approved
11
by the membership of KDE e.V.), which shall act as a proxy
12
defined in Section 14 of version 3 of the license.
15
This program is distributed in the hope that it will be useful,
16
but WITHOUT ANY WARRANTY; without even the implied warranty of
17
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18
GNU General Public License for more details.
20
You should have received a copy of the GNU General Public License
21
along with this program; if not, see http://www.gnu.org/licenses/
25
#ifndef SEARCHWINDOW_H
26
#define SEARCHWINDOW_H
30
#include <QIntValidator>
32
#include "ui_searchwidget_base.h"
41
For any microblogging service compatible with the Twitter Search API
43
@author Stephen Henderson \<hendersonsk@gmail.com\>
44
@author Mehrdad Momeny \<mehrdad.momeny@gmail.com\>
46
class SearchWindow : public QWidget
50
explicit SearchWindow(const Account &account, QWidget* parent = 0 );
53
void clearSearchResults();
54
void updateStatusList();
55
void setAccount(const Account &account);
56
void init(int type = 0, const QString & query = QString());
59
virtual void keyPressEvent( QKeyEvent *e );
62
void updateSearchResults();
63
void autoUpdateSearchResults();
64
void updateNumPages();
68
void searchResultsReceived( QList<Status> &stautsList );
69
void error( QString message );
72
void forwardReply( const QString &username, qulonglong statusId, bool dMsg );
73
void forwardFavorited( qulonglong statusId, bool isFavorite );
74
void forwardReTweet( const QString &text );
75
// void updateTimeLines();
78
void addNewStatusesToUi( QList<Status> &statusList );
79
void resetSearchArea(int type = 0, const QString & query = QString());
80
void markStatusesAsRead();
83
void updateSearchArea(int type = 0, const QString & query = QString());
88
void showNavigation( bool showNav );
89
void slotSearchTypeChanged(int);
92
QList<StatusWidget*> listResults;
97
Ui::searchwidget_base ui;
99
qulonglong lastValidPage;
100
QString lastSearchQuery;
102
QIntValidator* intValidator;