klistviewsearchline_pimcopy.h
00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019 #ifndef KLISTVIEWSEARCHLINE_H
00020 #define KLISTVIEWSEARCHLINE_H
00021
00022 #include <klineedit.h>
00023
00024 class KListView;
00025 class QListViewItem;
00026
00027 namespace KPIM {
00028
00037 class KListViewSearchLine : public KLineEdit
00038 {
00039 Q_OBJECT
00040
00041 public:
00042
00050 KListViewSearchLine(QWidget *parent = 0, KListView *listView = 0, const char *name = 0);
00051
00055 virtual ~KListViewSearchLine();
00056
00062 bool caseSensitive() const;
00063
00070 QValueList<int> searchColumns() const;
00071
00078 bool keepParentsVisible() const;
00079
00085 KListView *listView() const;
00086
00087 public slots:
00092 virtual void updateSearch(const QString &s = QString::null);
00093
00099 void setCaseSensitive(bool cs);
00100
00111 void setKeepParentsVisible(bool v);
00112
00119 void setSearchColumns(const QValueList<int> &columns);
00120
00127 void setListView(KListView *lv);
00128
00129 protected:
00130
00136 virtual bool itemMatches(const QListViewItem *item, const QString &s) const;
00137
00143 virtual QPopupMenu *createPopupMenu();
00144
00145 protected slots:
00146 void queueSearch(const QString &search);
00147 void activateSearch();
00148
00149 private:
00150
00155 void checkItemParentsNotVisible();
00156
00162 bool checkItemParentsVisible(QListViewItem *item);
00163
00164 private slots:
00165 void itemAdded(QListViewItem *item) const;
00166 void listViewDeleted();
00167 void searchColumnsMenuActivated(int);
00168
00169 private:
00170 class KListViewSearchLinePrivate;
00171 KListViewSearchLinePrivate *d;
00172 };
00173 }
00174
00175 #endif
This file is part of the documentation for libkdepim Library Version 3.3.2.