summaryrefslogtreecommitdiff
path: root/noncore/apps/opie-reader/cbkmkselector.h
Unidiff
Diffstat (limited to 'noncore/apps/opie-reader/cbkmkselector.h') (more/less context) (show whitespace changes)
-rw-r--r--noncore/apps/opie-reader/cbkmkselector.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/noncore/apps/opie-reader/cbkmkselector.h b/noncore/apps/opie-reader/cbkmkselector.h
index 1a49c5a..1a70048 100644
--- a/noncore/apps/opie-reader/cbkmkselector.h
+++ b/noncore/apps/opie-reader/cbkmkselector.h
@@ -6,12 +6,13 @@
6class CBkmkSelector : public QWidget 6class CBkmkSelector : public QWidget
7{ 7{
8 8
9 Q_OBJECT 9 Q_OBJECT
10 10
11 QListBox* bkmkselector; 11 QListBox* bkmkselector;
12 QPushButton* exitButton;
12 13
13signals: 14signals:
14 void selected(int i); 15 void selected(int i);
15 void cancelled(); 16 void cancelled();
16private slots: 17private slots:
17 void slotSelected(QListBoxItem* t) { emit selected(bkmkselector->index(t)); } 18 void slotSelected(QListBoxItem* t) { emit selected(bkmkselector->index(t)); }
@@ -24,18 +25,19 @@ public:
24 25
25// QFont f("unifont", 16); 26// QFont f("unifont", 16);
26// setFont( f ); 27// setFont( f );
27 28
28 QVBoxLayout* grid = new QVBoxLayout(this); 29 QVBoxLayout* grid = new QVBoxLayout(this);
29 bkmkselector = new QListBox(this, "Bookmarks"); 30 bkmkselector = new QListBox(this, "Bookmarks");
30 QPushButton* exitButton = new QPushButton("Cancel", this); 31 exitButton = new QPushButton("Cancel", this);
31 connect(bkmkselector, SIGNAL( selected(int) ), this, SLOT( slotSelected(int) ) ); 32 connect(bkmkselector, SIGNAL( selected(int) ), this, SLOT( slotSelected(int) ) );
32 connect(bkmkselector, SIGNAL( clicked(QListBoxItem*) ), this, SLOT( slotSelected(QListBoxItem*) ) ); 33 connect(bkmkselector, SIGNAL( clicked(QListBoxItem*) ), this, SLOT( slotSelected(QListBoxItem*) ) );
33 connect(exitButton, SIGNAL( released() ), this, SLOT( slotCancel() ) ); 34 connect(exitButton, SIGNAL( released() ), this, SLOT( slotCancel() ) );
34 grid->addWidget(bkmkselector,1); 35 grid->addWidget(bkmkselector,1);
35 grid->addWidget(exitButton); 36 grid->addWidget(exitButton);
36 } 37 }
37 void clear() { bkmkselector->clear(); } 38 void clear() { bkmkselector->clear(); }
38 void insertItem(const QString& item) { bkmkselector->insertItem(item); } 39 void insertItem(const QString& item) { bkmkselector->insertItem(item); }
39 QString text(int index) const { return bkmkselector->text(index); } 40 QString text(int index) const { return bkmkselector->text(index); }
41 void setText(const QString& _l) { exitButton->setText(_l); }
40}; 42};
41 43