author | llornkcor <llornkcor> | 2002-07-01 23:24:08 (UTC) |
---|---|---|
committer | llornkcor <llornkcor> | 2002-07-01 23:24:08 (UTC) |
commit | 59222a752fa4c8a1e8c2a00ee2f9e22855f12bb2 (patch) (unidiff) | |
tree | f148d4858859dac3b413e675c760acfdab24b8e6 /noncore/apps/opie-reader/infowin.h | |
parent | c08be8ae22dcc1bfb83cfdec807149b161d770f5 (diff) | |
download | opie-59222a752fa4c8a1e8c2a00ee2f9e22855f12bb2.zip opie-59222a752fa4c8a1e8c2a00ee2f9e22855f12bb2.tar.gz opie-59222a752fa4c8a1e8c2a00ee2f9e22855f12bb2.tar.bz2 |
initial
Diffstat (limited to 'noncore/apps/opie-reader/infowin.h') (more/less context) (show whitespace changes)
-rw-r--r-- | noncore/apps/opie-reader/infowin.h | 52 |
1 files changed, 52 insertions, 0 deletions
diff --git a/noncore/apps/opie-reader/infowin.h b/noncore/apps/opie-reader/infowin.h new file mode 100644 index 0000000..9ddce36 --- a/dev/null +++ b/noncore/apps/opie-reader/infowin.h | |||
@@ -0,0 +1,52 @@ | |||
1 | #ifndef __INFOWIN_H | ||
2 | #define __INFOWIN_H | ||
3 | |||
4 | #include <qlayout.h> | ||
5 | #include <qpushbutton.h> | ||
6 | #include <qgrid.h> | ||
7 | #include <qlabel.h> | ||
8 | |||
9 | class infowin : public QWidget | ||
10 | { | ||
11 | Q_OBJECT | ||
12 | QLabel* fileSize; | ||
13 | QLabel* textSize; | ||
14 | QLabel* ratio; | ||
15 | QLabel* location; | ||
16 | QLabel* read; | ||
17 | QGridLayout* grid; | ||
18 | public: | ||
19 | infowin::infowin( QWidget *parent=0, const char *name=0, WFlags f = 0); | ||
20 | /* | ||
21 | void addcancel(QPushButton* exitbutton) | ||
22 | { | ||
23 | grid->addWidget(exitbutton, 5, 1); | ||
24 | } | ||
25 | */ | ||
26 | void setFileSize(int sz) { fileSize->setNum(sz); } | ||
27 | void setTextSize(int sz) { textSize->setNum(sz); } | ||
28 | void setRatio(int sz) { ratio->setText(QString().setNum(sz)+"%"); } | ||
29 | void setLocation(int sz) { location->setNum(sz); } | ||
30 | void setRead(int sz) { read->setText(QString().setNum(sz)+"%"); } | ||
31 | /* | ||
32 | virtual void keyPressEvent(QKeyEvent* e) | ||
33 | { | ||
34 | printf("Received:%d\n", e->key()); | ||
35 | switch (e->key()) | ||
36 | { | ||
37 | case Key_Escape: | ||
38 | e->accept(); | ||
39 | emit Close(); | ||
40 | break; | ||
41 | default: | ||
42 | e->ignore(); | ||
43 | } | ||
44 | } | ||
45 | */ | ||
46 | private slots: | ||
47 | void infoClose() { emit Close(); } | ||
48 | signals: | ||
49 | void Close(); | ||
50 | }; | ||
51 | |||
52 | #endif | ||