summaryrefslogtreecommitdiffstats
path: root/krusader/Panel/panelpopup.h
blob: dddd125cd616d64940e2941e093e19460908da96 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
#ifndef _PANELPOPUP_H
#define _PANELPOPUP_H

#include <tqwidget.h>
#include <tqwidgetstack.h>
#include <tqpixmap.h>
#include <tqvaluelist.h>
#include <kfileitem.h>
#include <tqguardedptr.h>
#include <kio/previewjob.h>
#include <kurl.h>

class TQButtonGroup;
class TQLabel;
class TQListViewItem;
class TQSplitter;
class KFileTreeView;
class TQToolButton;
class KrSqueezedTextLabel;
class KLineEdit;
class KComboBox;
class KrusaderImageFilePreview;
class PanelViewer;
class DiskUsageViewer;

class PanelPopup: public TQWidget {
   Q_OBJECT
  
   enum Parts { Tree, Preview, QuickPanel, View, DskUsage, Last=0xFF };
public:
   PanelPopup( TQSplitter *splitter, bool left );
   ~PanelPopup();
	inline int currentPage() const { return stack->id(stack->visibleWidget()); }

	void saveSizes();

public slots:
   void update(KURL url);
	void show();
	void hide();
	
signals:
	void selection(const KURL &url);
	void hideMe();
   
protected slots:	
	virtual void setFocus();
	void tabSelected(int id);
	void treeSelection(TQListViewItem*);
	void slotDroppedOnTree(TQWidget *widget, TQDropEvent *e, KURL::List &lst, KURL &);
	void handleOpenURLRequest(const KURL &url);
	void quickSelect();
	void quickSelect(const TQString &);
        void quickSelectStore();

protected:
	bool _left;
	bool _hidden;
	TQWidgetStack *stack;
	KrusaderImageFilePreview *viewer;
	KrSqueezedTextLabel *dataLine;
	TQGuardedPtr<TDEIO::PreviewJob> pjob;
	KFileTreeView *tree;
	TQToolButton *treeBtn, *previewBtn, *quickBtn, *viewerBtn, *duBtn;
	TQButtonGroup *btns;
	KLineEdit *quickFilter;
	KComboBox *quickSelectCombo;
	PanelViewer *panelviewer;
	DiskUsageViewer *diskusage;
	TQValueList<int> splitterSizes;
	TQSplitter *splitter;
};

#endif // _PANELPOPUP_H