author | paule <paule> | 2007-01-28 04:04:14 (UTC) |
---|---|---|
committer | paule <paule> | 2007-01-28 04:04:14 (UTC) |
commit | ec2309cb69365847762db542c41951629cd06cbe (patch) (unidiff) | |
tree | 2f0101c1f0d6268207dbd15eb21f40c812a4fff5 /noncore/tools/remote/mainview.cpp | |
parent | 3cd37427b5c5f26f62cff583fbde914467ddafe3 (diff) | |
download | opie-ec2309cb69365847762db542c41951629cd06cbe.zip opie-ec2309cb69365847762db542c41951629cd06cbe.tar.gz opie-ec2309cb69365847762db542c41951629cd06cbe.tar.bz2 |
Refactored out all communication with LIRC into new LircHandler class
Diffstat (limited to 'noncore/tools/remote/mainview.cpp') (more/less context) (show whitespace changes)
-rw-r--r-- | noncore/tools/remote/mainview.cpp | 13 |
1 files changed, 0 insertions, 13 deletions
diff --git a/noncore/tools/remote/mainview.cpp b/noncore/tools/remote/mainview.cpp index 724eba9..8c87785 100644 --- a/noncore/tools/remote/mainview.cpp +++ b/noncore/tools/remote/mainview.cpp | |||
@@ -13,55 +13,42 @@ Public License for more details. | |||
13 | You should have received a copy of the GNU General Public License along with this program; if not, write to the Free | 13 | You should have received a copy of the GNU General Public License along with this program; if not, write to the Free |
14 | Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | 14 | Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
15 | */ | 15 | */ |
16 | 16 | ||
17 | #include "mainview.h" | 17 | #include "mainview.h" |
18 | 18 | ||
19 | #include <opie2/oresource.h> | 19 | #include <opie2/oresource.h> |
20 | 20 | ||
21 | MainView::MainView(QWidget *parent, const char *name) : QWidget(parent, name) | 21 | MainView::MainView(QWidget *parent, const char *name) : QWidget(parent, name) |
22 | { | 22 | { |
23 | setIcon( Opie::Core::OResource::loadPixmap( "remote", Opie::Core::OResource::SmallIcon ) ); | 23 | setIcon( Opie::Core::OResource::loadPixmap( "remote", Opie::Core::OResource::SmallIcon ) ); |
24 | setCaption(tr("Remote") ); | 24 | setCaption(tr("Remote") ); |
25 | 25 | ||
26 | QVBoxLayout *layout = new QVBoxLayout(this); | 26 | QVBoxLayout *layout = new QVBoxLayout(this); |
27 | QTabWidget *tabs = new QTabWidget(this); | 27 | QTabWidget *tabs = new QTabWidget(this); |
28 | 28 | ||
29 | layout->addWidget(tabs); | 29 | layout->addWidget(tabs); |
30 | 30 | ||
31 | remote = new RemoteTab(tabs); | 31 | remote = new RemoteTab(tabs); |
32 | learn = new LearnTab(tabs); | 32 | learn = new LearnTab(tabs); |
33 | config = new ConfigTab(tabs); | 33 | config = new ConfigTab(tabs); |
34 | help = new HelpTab(tabs); | 34 | help = new HelpTab(tabs); |
35 | connect(config, SIGNAL(remotesChanged()), this, SLOT(updateRemotesList()) ); | 35 | connect(config, SIGNAL(remotesChanged()), this, SLOT(updateRemotesList()) ); |
36 | 36 | ||
37 | remote->setIRSocket(fd); | ||
38 | |||
39 | tabs->addTab(remote, tr("Remote") ); | 37 | tabs->addTab(remote, tr("Remote") ); |
40 | tabs->addTab(learn,tr("Learn") ); | 38 | tabs->addTab(learn,tr("Learn") ); |
41 | tabs->addTab(config,tr("Config") ); | 39 | tabs->addTab(config,tr("Config") ); |
42 | tabs->addTab(help, tr("Help") ); | 40 | tabs->addTab(help, tr("Help") ); |
43 | 41 | ||
44 | printf("1\n"); | 42 | printf("1\n"); |
45 | cfg = new Config("Remote"); | 43 | cfg = new Config("Remote"); |
46 | printf("2\n"); | 44 | printf("2\n"); |
47 | 45 | ||
48 | remote->setConfig(cfg); | 46 | remote->setConfig(cfg); |
49 | config->setConfig(cfg); | 47 | config->setConfig(cfg); |
50 | } | 48 | } |
51 | 49 | ||
52 | int MainView::getIRSocket() | ||
53 | { | ||
54 | return fd; | ||
55 | } | ||
56 | |||
57 | void MainView::setIRSocket(int newfd) | ||
58 | { | ||
59 | fd = newfd; | ||
60 | remote->setIRSocket(fd); | ||
61 | } | ||
62 | |||
63 | void MainView::updateRemotesList() | 50 | void MainView::updateRemotesList() |
64 | { | 51 | { |
65 | remote->updateRemotesList(); | 52 | remote->updateRemotesList(); |
66 | printf("MainView: got remotes changed signal\n"); | 53 | printf("MainView: got remotes changed signal\n"); |
67 | } | 54 | } |