summaryrefslogtreecommitdiff
path: root/noncore/tools/remote/topgroupconf.cpp
Unidiff
Diffstat (limited to 'noncore/tools/remote/topgroupconf.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r--noncore/tools/remote/topgroupconf.cpp70
1 files changed, 70 insertions, 0 deletions
diff --git a/noncore/tools/remote/topgroupconf.cpp b/noncore/tools/remote/topgroupconf.cpp
new file mode 100644
index 0000000..eb071fb
--- a/dev/null
+++ b/noncore/tools/remote/topgroupconf.cpp
@@ -0,0 +1,70 @@
1/*
2Opie-Remote. emulates remote controlls on an iPaq (and maybe a Zaurus) in Opie.
3Copyright (C) 2002 Thomas Stephens
4
5This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public
6License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later
7version.
8
9This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the
10implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General
11Public License for more details.
12
13You should have received a copy of the GNU General Public License along with this program; if not, write to the Free
14Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
15*/
16
17#include "topgroupconf.h"
18
19TopGroupConf::TopGroupConf(QWidget *parent=0, const char *name=0):QWidget(parent,name)
20{
21 QHBoxLayout *layout = new QHBoxLayout(this);
22
23 QPushButton *power = new QPushButton("Power",this,"power");
24 layout->addWidget(power);
25 connect(power, SIGNAL(pressed()), this->parentWidget(), SLOT(buttonPressed()) );
26 //power->setGeometry(5, 5,40, 20);
27
28 layout->addSpacing(5);
29
30 QPushButton *source = new QPushButton("Source",this,"source");
31 layout->addWidget(source);
32 connect(source, SIGNAL(pressed()), this->parentWidget(), SLOT(buttonPressed()) );
33 //source->setGeometry(50,5,40,20);
34
35 remotes = new QComboBox(true, this, "remotes");
36 remotes->insertItem(QString("Remotes"));
37 layout->addWidget(remotes);
38 layout->setStretchFactor(remotes, 1);
39 connect(remotes, SIGNAL(activated(const QString &)), this->parentWidget(), SLOT(remoteSelected(const QString &)) );
40
41
42 QPushButton *newrem = new QPushButton("New", this, "new");
43 layout->addWidget(newrem);
44 connect(newrem, SIGNAL(pressed()), this->parentWidget(), SLOT(newPressed()) );
45
46
47 /*remotes = new QComboBox(false, this, "remotes");
48 connect(remotes, SIGNAL(activated(const QString &)), this->parentWidget(), SLOT(remoteSelected(const QString &)) );
49 remotes->insertItem("Select Remote");
50 //remotes->setGeometry(135,5,95,20);
51
52 QLabel *remoteLabel = new QLabel(remotes, "Remote: ",this,"remoteLabel");
53 //remoteLabel->setGeometry(90,5,40,20);
54 remoteLabel->setAlignment(AlignRight | AlignVCenter);
55
56 layout->addWidget(remoteLabel);
57 layout->addWidget(remotes);
58*/
59}
60
61void TopGroupConf::updateRemotes(QStringList list)
62{
63 remotes->insertStringList(list);
64}
65
66QString TopGroupConf::getRemotesText()
67{
68 return remotes->currentText();
69}
70