Fix crash if key bindings specified in profile cannot be found. Improve
[personal-kdebase.git] / apps / kfind / kfwin.h
blob958ee778a46c885609abea39d4d16ae442a61ade
1 /***********************************************************************
3 * Kfwin.h
5 ***********************************************************************/
7 #ifndef KFWIN_H
8 #define KFWIN_H
10 #include <k3listview.h>
11 #include <kfileitem.h>
12 #include <kurl.h>
14 class QFileInfo;
15 class KMenu;
16 class KfindWindow;
18 class KfFileLVI : public Q3ListViewItem
20 public:
21 KfFileLVI(KfindWindow* lv, const KFileItem &item,const QString& matchingLine);
22 ~KfFileLVI();
24 QString key(int column, bool) const;
26 QFileInfo *fileInfo;
27 KFileItem fileitem;
30 class KfindWindow: public K3ListView
32 Q_OBJECT
33 public:
34 KfindWindow( QWidget * parent = 0 );
36 void beginSearch(const KUrl& baseUrl);
37 void endSearch();
39 void insertItem(const KFileItem &item, const QString& matchingLine);
41 QString reducedDir(const QString& fullDir);
43 public Q_SLOTS:
44 void copySelection();
45 void slotContextMenu(K3ListView *,Q3ListViewItem *item,const QPoint&p);
47 private Q_SLOTS:
48 void deleteFiles();
49 void fileProperties();
50 void openFolder();
51 void saveResults();
52 void openBinding();
53 void selectionHasChanged();
54 void slotExecute(Q3ListViewItem*);
55 void slotOpenWith();
57 protected:
58 virtual void resizeEvent(QResizeEvent *e);
60 virtual Q3DragObject *dragObject();
62 Q_SIGNALS:
63 void resultSelected(bool);
65 private:
66 QString m_baseDir;
67 KMenu *m_menu;
68 bool haveSelection;
69 bool m_pressed;
70 void resetColumns(bool init);
73 #endif