summaryrefslogtreecommitdiff
path: root/noncore
Unidiff
Diffstat (limited to 'noncore') (more/less context) (ignore whitespace changes)
-rw-r--r--noncore/apps/opie-console/MyPty.cpp27
-rw-r--r--noncore/apps/opie-console/MyPty.h6
-rw-r--r--noncore/apps/opie-console/PLANS2
-rw-r--r--noncore/apps/opie-console/consoleconfigwidget.cpp95
-rw-r--r--noncore/apps/opie-console/consoleconfigwidget.h34
-rw-r--r--noncore/apps/opie-console/default.cpp9
-rw-r--r--noncore/apps/opie-console/opie-console.pro6
7 files changed, 162 insertions, 17 deletions
diff --git a/noncore/apps/opie-console/MyPty.cpp b/noncore/apps/opie-console/MyPty.cpp
index 534f79a..b0f0275 100644
--- a/noncore/apps/opie-console/MyPty.cpp
+++ b/noncore/apps/opie-console/MyPty.cpp
@@ -133,32 +133,26 @@ const char* MyPty::deviceName()
133{ 133{
134 return m_ttynam; 134 return m_ttynam;
135} 135}
136 136
137 137
138void MyPty::error() 138void MyPty::error()
139{ 139{
140 // This is code from the Qt DumbTerminal example 140 // This is code from the Qt DumbTerminal example
141 donePty(); 141 donePty();
142} 142}
143 143
144void MyPty::start() { 144void MyPty::start() {
145 char* cmd = "/bin/sh";
146
147 if ( QFile::exists( "/bin/bash" ) ) {
148 cmd = "/bin/bash";
149 }
150
151 QStrList lis; 145 QStrList lis;
152 int r =run(cmd, lis, 0, 0); 146 int r =run(m_cmd.latin1(), lis, 0, 0);
153 r = r; 147 r = r;
154} 148}
155/*! 149/*!
156 start the client program. 150 start the client program.
157*/ 151*/
158int MyPty::run(const char* cmd, QStrList &, const char*, int) 152int MyPty::run(const char* cmd, QStrList &, const char*, int)
159{ 153{
160 // This is code from the Qt DumbTerminal example 154 // This is code from the Qt DumbTerminal example
161 m_cpid = fork(); 155 m_cpid = fork();
162 156
163 if ( !m_cpid ) { 157 if ( !m_cpid ) {
164 // child - exec shell on tty 158 // child - exec shell on tty
@@ -173,25 +167,28 @@ int MyPty::run(const char* cmd, QStrList &, const char*, int)
173 if ( setsid() < 0 ) 167 if ( setsid() < 0 )
174 perror( "failed to set process group" ); 168 perror( "failed to set process group" );
175#if defined (TIOCSCTTY) 169#if defined (TIOCSCTTY)
176 // grabbed from APUE by Stevens 170 // grabbed from APUE by Stevens
177 ioctl(STDIN_FILENO, TIOCSCTTY, 0); 171 ioctl(STDIN_FILENO, TIOCSCTTY, 0);
178#endif 172#endif
179 tcgetattr( STDIN_FILENO, &ttmode ); 173 tcgetattr( STDIN_FILENO, &ttmode );
180 ttmode.c_cc[VINTR] = 3; 174 ttmode.c_cc[VINTR] = 3;
181 ttmode.c_cc[VERASE] = 8; 175 ttmode.c_cc[VERASE] = 8;
182 tcsetattr( STDIN_FILENO, TCSANOW, &ttmode ); 176 tcsetattr( STDIN_FILENO, TCSANOW, &ttmode );
183 setenv("TERM",m_term,1); 177 setenv("TERM",m_term,1);
184 setenv("COLORTERM","0",1); 178 setenv("COLORTERM","0",1);
185 179 EnvironmentMap::Iterator it;
180 for (it = m_env.begin(); it != m_env.end(); it++) {
181 setenv(it.key().latin1(), it.data().latin1(), 1);
182 }
186 if (getuid() == 0) { 183 if (getuid() == 0) {
187 char msg[] = "WARNING: You are running this shell as root!\n"; 184 char msg[] = "WARNING: You are running this shell as root!\n";
188 write(ttyfd, msg, sizeof(msg)); 185 write(ttyfd, msg, sizeof(msg));
189 } 186 }
190 execl(cmd, cmd, 0); 187 execl(cmd, cmd, 0);
191 188
192 donePty(); 189 donePty();
193 exit(-1); 190 exit(-1);
194 } 191 }
195 192
196 // parent - continue as a widget 193 // parent - continue as a widget
197 delete m_sn_r; 194 delete m_sn_r;
@@ -254,24 +251,25 @@ MyPty::MyPty(const Profile& prof) : m_cpid(0)
254 case Profile::Linux: 251 case Profile::Linux:
255 m_term = "linux"; 252 m_term = "linux";
256 break; 253 break;
257 case Profile::XTerm: 254 case Profile::XTerm:
258 m_term = "xterm"; 255 m_term = "xterm";
259 break; 256 break;
260 } 257 }
261 m_sn_e = 0l; 258 m_sn_e = 0l;
262 m_sn_r = 0l; 259 m_sn_r = 0l;
263 m_fd = openPty(); 260 m_fd = openPty();
264 ProcCtl* ctl = ProcCtl::self(); 261 ProcCtl* ctl = ProcCtl::self();
265 Q_UNUSED(ctl); 262 Q_UNUSED(ctl);
263 reload(prof);
266} 264}
267 265
268/*! 266/*!
269 Destructor. 267 Destructor.
270 Note that the related client program is not killed 268 Note that the related client program is not killed
271 (yet) when a instance is deleted. 269 (yet) when a instance is deleted.
272*/ 270*/
273MyPty::~MyPty() 271MyPty::~MyPty()
274{ 272{
275 donePty(); 273 donePty();
276} 274}
277QString MyPty::identifier()const { 275QString MyPty::identifier()const {
@@ -282,26 +280,35 @@ QString MyPty::name()const{
282} 280}
283bool MyPty::open() { 281bool MyPty::open() {
284 if (m_fd < 0) 282 if (m_fd < 0)
285 m_fd = openPty(); 283 m_fd = openPty();
286 284
287 start(); 285 start();
288 return true; 286 return true;
289} 287}
290void MyPty::close() { 288void MyPty::close() {
291 donePty(); 289 donePty();
292 m_fd = openPty(); 290 m_fd = openPty();
293} 291}
294void MyPty::reload( const Profile& ) { 292void MyPty::reload( const Profile& prof) {
295 293 m_env.clear();
294 m_cmd = prof.readEntry("Command", "/bin/bash");
295 int envcount = prof.readNumEntry("EnvVars", 0);
296 for (int i=0; i<envcount; i++) {
297 QString name = prof.readEntry("Env_Name_" + QString::number(i), "");
298 QString value = prof.readEntry("Env_Value_" + QString::number(i), "");
299 if (!(name.isEmpty() || value.isEmpty())) {
300 m_env.insert(name, value);
301 }
302 }
296} 303}
297/*! sends len bytes through the line */ 304/*! sends len bytes through the line */
298void MyPty::send(const QByteArray& ar) 305void MyPty::send(const QByteArray& ar)
299{ 306{
300#ifdef VERBOSE_DEBUG 307#ifdef VERBOSE_DEBUG
301 // verbose debug 308 // verbose debug
302 printf("sending bytes:\n"); 309 printf("sending bytes:\n");
303 for (uint i = 0; i < ar.count(); i++) 310 for (uint i = 0; i < ar.count(); i++)
304 printf("%c", ar[i]); 311 printf("%c", ar[i]);
305 printf("\n"); 312 printf("\n");
306#endif 313#endif
307 314
diff --git a/noncore/apps/opie-console/MyPty.h b/noncore/apps/opie-console/MyPty.h
index 7561ca3..b292ce4 100644
--- a/noncore/apps/opie-console/MyPty.h
+++ b/noncore/apps/opie-console/MyPty.h
@@ -14,28 +14,31 @@
14 /* */ 14 /* */
15/* Copyright (C) 2000 by John Ryland <jryland@trolltech.com> */ 15/* Copyright (C) 2000 by John Ryland <jryland@trolltech.com> */
16 /* */ 16 /* */
17/* -------------------------------------------------------------------------- */ 17/* -------------------------------------------------------------------------- */
18 18
19/*! \file 19/*! \file
20*/ 20*/
21 21
22#ifndef MY_PTY_H 22#ifndef MY_PTY_H
23#define MY_PTY_H 23#define MY_PTY_H
24 24
25#include <qobject.h> 25#include <qobject.h>
26#include <qlist.h>
26#include <qstrlist.h> 27#include <qstrlist.h>
27 28
28#include "io_layer.h" 29#include "io_layer.h"
29 30
31typedef QMap<QString, QString> EnvironmentMap;
32
30class Profile; 33class Profile;
31class QSocketNotifier; 34class QSocketNotifier;
32class MyPty : public IOLayer 35class MyPty : public IOLayer
33{ 36{
34 Q_OBJECT 37 Q_OBJECT
35public: 38public:
36 39
37 MyPty(const Profile&); 40 MyPty(const Profile&);
38 ~MyPty(); 41 ~MyPty();
39 42
40 43
41 44
@@ -86,15 +89,18 @@ protected slots:
86private: 89private:
87 int openPty(); 90 int openPty();
88 91
89private: 92private:
90 93
91 char m_ptynam[16]; // "/dev/ptyxx" | "/dev/ptmx" 94 char m_ptynam[16]; // "/dev/ptyxx" | "/dev/ptmx"
92 char m_ttynam[16]; // "/dev/ttyxx" | "/dev/pts/########..." 95 char m_ttynam[16]; // "/dev/ttyxx" | "/dev/pts/########..."
93 int m_fd; 96 int m_fd;
94 int m_cpid; 97 int m_cpid;
95 QSocketNotifier* m_sn_e; 98 QSocketNotifier* m_sn_e;
96 QSocketNotifier* m_sn_r; 99 QSocketNotifier* m_sn_r;
97 char* m_term; 100 char* m_term;
101
102 QString m_cmd;
103 EnvironmentMap m_env;
98}; 104};
99 105
100#endif 106#endif
diff --git a/noncore/apps/opie-console/PLANS b/noncore/apps/opie-console/PLANS
index 8e0bee4..a7c7578 100644
--- a/noncore/apps/opie-console/PLANS
+++ b/noncore/apps/opie-console/PLANS
@@ -18,28 +18,28 @@ keyboard?
18 18
19(Almost) DONE: 19(Almost) DONE:
20 Framework 20 Framework
21 Serial IOLayer 21 Serial IOLayer
22 Saving and Restoring Profiles 22 Saving and Restoring Profiles
23 ConfigDialog Framework 23 ConfigDialog Framework
24 IOLayer 24 IOLayer
25 Profile->Session and MainWidget 25 Profile->Session and MainWidget
26 FilesendingLayer ( Z/Y Modem tested X does not work at all ) 26 FilesendingLayer ( Z/Y Modem tested X does not work at all )
27 Fullscreen 27 Fullscreen
28 Modem - Josef 28 Modem - Josef
29 Keys - hash 29 Keys - hash
30 Scripting - wazlaf
30 31
31TASKS in progress: 32TASKS in progress:
32 Keys - hash 33 Keys - hash
33 Scripting - wazlaf
34 34
35 Session->Profile - hash => why is this needed? you can not change any settings 35 Session->Profile - hash => why is this needed? you can not change any settings
36 after you start the session, so all you would do is 36 after you start the session, so all you would do is
37 create a duplicate of the profile used to open the 37 create a duplicate of the profile used to open the
38 current session. maybe needed later when you can change 38 current session. maybe needed later when you can change
39 settings while the session is running (colors, fonts...) 39 settings while the session is running (colors, fonts...)
40 zecke => think of that. You try to hook up with a New Device 40 zecke => think of that. You try to hook up with a New Device
41 neither know anything.... speed flow and such stuff 41 neither know anything.... speed flow and such stuff
42 you start to experiment and it starts to work 42 you start to experiment and it starts to work
43 now you want to save the session 43 now you want to save the session
44 44
45 hash => got it. 45 hash => got it.
diff --git a/noncore/apps/opie-console/consoleconfigwidget.cpp b/noncore/apps/opie-console/consoleconfigwidget.cpp
new file mode 100644
index 0000000..70e2e78
--- a/dev/null
+++ b/noncore/apps/opie-console/consoleconfigwidget.cpp
@@ -0,0 +1,95 @@
1#include <qlabel.h>
2#include <qlayout.h>
3#include <qcombobox.h>
4#include <qlineedit.h>
5#include <qpushbutton.h>
6#include <qlistview.h>
7#include <qhbox.h>
8#include <qregexp.h>
9#include <stdio.h>
10
11#include "consoleconfigwidget.h"
12
13ConsoleConfigWidget::ConsoleConfigWidget( const QString& name, QWidget* parent,
14 const char* na )
15 : ProfileDialogConnectionWidget( name, parent, na ) {
16 m_lay = new QVBoxLayout( this );
17 QLabel *label = new QLabel(tr("Command to execute"), this);
18 m_lay->addWidget(label);
19 m_cmd = new QLineEdit(this);
20 m_lay->addWidget(m_cmd);
21 label = new QLabel(tr("Environment Variables"), this);
22 m_lay->addWidget(label);
23 m_env = new QListView(this);
24 m_env->addColumn(tr("Name"));
25 m_env->addColumn(tr("Value"));
26 m_lay->addWidget(m_env);
27
28 QHBox *hbox = new QHBox(this);
29 label = new QLabel(tr("Name :"), hbox);
30 m_name = new QLineEdit(hbox);
31 m_lay->addWidget(hbox);
32
33 hbox = new QHBox(this);
34 label = new QLabel(tr("Value :"), hbox);
35 m_value = new QLineEdit(hbox);
36 m_lay->addWidget(hbox);
37
38 hbox = new QHBox(this);
39 hbox->setSpacing(10);
40 m_remove = new QPushButton(tr("Remove"), hbox);
41 connect(m_remove, SIGNAL(clicked()), this, SLOT(slotRemove()));
42 m_add = new QPushButton(tr("Add"), hbox);
43 connect(m_add, SIGNAL(clicked()), this, SLOT(slotAdd()));
44 m_lay->addWidget(hbox);
45}
46
47void ConsoleConfigWidget::slotAdd() {
48 if (!(m_name->text().isEmpty() || m_value->text().isEmpty())) {
49 QListViewItem *item = new QListViewItem(m_env);
50 item->setText(0, m_name->text());
51 item->setText(1, m_value->text());
52 m_env->insertItem(item);
53 }
54}
55
56void ConsoleConfigWidget::slotRemove() {
57 QListViewItem *item = m_env->currentItem();
58 if (item) {
59 m_env->takeItem(item);
60 }
61}
62
63ConsoleConfigWidget::~ConsoleConfigWidget() {
64}
65
66void ConsoleConfigWidget::load( const Profile& prof ) {
67 m_cmd->setText(prof.readEntry("Command", "/bin/bash"));
68 int envcount = prof.readNumEntry("EnvVars", 0);
69 for (int i=0; i<envcount; i++) {
70 QString name = prof.readEntry("Env_Name_" + QString::number(i), "");
71 QString value = prof.readEntry("Env_Value_" + QString::number(i), "");
72 if (!(name.isEmpty() || value.isEmpty())) {
73 QListViewItem *item = new QListViewItem(m_env);
74 item->setText(0, name);
75 item->setText(1, value);
76 m_env->insertItem(item);
77 }
78 }
79}
80
81void ConsoleConfigWidget::save( Profile& prof ) {
82 prof.writeEntry( "Command", m_cmd->text());
83 QListViewItem *item = m_env->firstChild();
84 int counter = 0;
85 while (item) {
86 QString name = item->text(0);
87 QString value = item->text(1);
88 prof.writeEntry("Env_Name_" + QString::number(counter), name);
89 prof.writeEntry("Env_Value_" + QString::number(counter), value);
90 item = item->nextSibling();
91 counter++;
92 }
93 prof.writeEntry("EnvVars", QString::number(counter));
94}
95
diff --git a/noncore/apps/opie-console/consoleconfigwidget.h b/noncore/apps/opie-console/consoleconfigwidget.h
new file mode 100644
index 0000000..c980cb4
--- a/dev/null
+++ b/noncore/apps/opie-console/consoleconfigwidget.h
@@ -0,0 +1,34 @@
1#ifndef OPIE_CONSOLE_CONFIG_WIDGET_H
2#define OPIE_CONSOLE_CONFIG_WIDGET_H
3
4#include "profiledialogwidget.h"
5
6class QVBoxLayout;
7class QLineEdit;
8class QListView;
9class QPushButton;
10
11class ConsoleConfigWidget : public ProfileDialogConnectionWidget {
12 Q_OBJECT
13public:
14 ConsoleConfigWidget( const QString& name, QWidget* parent, const char* name = 0l );
15 ~ConsoleConfigWidget();
16
17 void load( const Profile& );
18 void save( Profile& );
19
20protected slots:
21 void slotAdd();
22 void slotRemove();
23private:
24 QVBoxLayout *m_lay;
25 QLineEdit *m_cmd;
26 QLineEdit *m_name;
27 QLineEdit *m_value;
28 QListView *m_env;
29 QPushButton *m_add;
30 QPushButton *m_remove;
31};
32
33
34#endif
diff --git a/noncore/apps/opie-console/default.cpp b/noncore/apps/opie-console/default.cpp
index 5d82c6a..b060139 100644
--- a/noncore/apps/opie-console/default.cpp
+++ b/noncore/apps/opie-console/default.cpp
@@ -1,24 +1,25 @@
1#include "io_serial.h" 1#include "io_serial.h"
2#include "io_irda.h" 2#include "io_irda.h"
3#include "io_bt.h" 3#include "io_bt.h"
4#include "io_modem.h" 4#include "io_modem.h"
5#include "filetransfer.h" 5#include "filetransfer.h"
6#include "filereceive.h" 6#include "filereceive.h"
7#include "serialconfigwidget.h" 7#include "serialconfigwidget.h"
8#include "irdaconfigwidget.h" 8#include "irdaconfigwidget.h"
9#include "btconfigwidget.h" 9#include "btconfigwidget.h"
10#include "modemconfigwidget.h" 10#include "modemconfigwidget.h"
11#include "terminalwidget.h" 11#include "terminalwidget.h"
12#include "function_keyboard.h" 12#include "function_keyboard.h"
13#include "consoleconfigwidget.h"
13#include "MyPty.h" 14#include "MyPty.h"
14 15
15#include "default.h" 16#include "default.h"
16 17
17extern "C" { 18extern "C" {
18 // FILE Transfer Stuff 19 // FILE Transfer Stuff
19 FileTransferLayer* newSZTransfer(IOLayer* lay) { 20 FileTransferLayer* newSZTransfer(IOLayer* lay) {
20 return new FileTransfer( FileTransfer::SZ, lay ); 21 return new FileTransfer( FileTransfer::SZ, lay );
21 } 22 }
22 FileTransferLayer* newSYTransfer(IOLayer* lay) { 23 FileTransferLayer* newSYTransfer(IOLayer* lay) {
23 return new FileTransfer( FileTransfer::SY, lay ); 24 return new FileTransfer( FileTransfer::SY, lay );
24 } 25 }
@@ -58,26 +59,26 @@ extern "C" {
58 ProfileDialogWidget* newSerialWidget( const QString& str, QWidget* wid ) { 59 ProfileDialogWidget* newSerialWidget( const QString& str, QWidget* wid ) {
59 return new SerialConfigWidget( str, wid ); 60 return new SerialConfigWidget( str, wid );
60 } 61 }
61 ProfileDialogWidget* newIrDaWidget( const QString& str, QWidget* wid ) { 62 ProfileDialogWidget* newIrDaWidget( const QString& str, QWidget* wid ) {
62 return new IrdaConfigWidget( str, wid ); 63 return new IrdaConfigWidget( str, wid );
63 } 64 }
64 ProfileDialogWidget* newModemWidget( const QString& str, QWidget* wid ) { 65 ProfileDialogWidget* newModemWidget( const QString& str, QWidget* wid ) {
65 return new ModemConfigWidget(str, wid ); 66 return new ModemConfigWidget(str, wid );
66 } 67 }
67 ProfileDialogWidget* newBTWidget( const QString& str, QWidget* wid ) { 68 ProfileDialogWidget* newBTWidget( const QString& str, QWidget* wid ) {
68 return new BTConfigWidget(str, wid ); 69 return new BTConfigWidget(str, wid );
69 } 70 }
70 ProfileDialogWidget* newConsoleWid( const QString& , QWidget* ) { 71 ProfileDialogWidget* newConsoleWid( const QString& str, QWidget* wid ) {
71 return 0l; 72 return new ConsoleConfigWidget(str, wid );
72 } 73 }
73 74
74 75
75 // Terminal Widget(s) 76 // Terminal Widget(s)
76 ProfileDialogWidget* newTerminalWidget(const QString& na, QWidget* wid) { 77 ProfileDialogWidget* newTerminalWidget(const QString& na, QWidget* wid) {
77 return new TerminalWidget(na, wid,0 ); 78 return new TerminalWidget(na, wid,0 );
78 } 79 }
79 80
80 // Function Keyboard Widget 81 // Function Keyboard Widget
81 ProfileDialogWidget* newKeyboardWidget(const QString& na, QWidget *wid) { 82 ProfileDialogWidget* newKeyboardWidget(const QString& na, QWidget *wid) {
82 return new FunctionKeyboardConfig(na, wid); 83 return new FunctionKeyboardConfig(na, wid);
83 } 84 }
@@ -93,29 +94,29 @@ Default::Default( MetaFactory* fact ) {
93 fact->addFileTransferLayer( "SZ", QObject::tr("Z-Modem"), newSZTransfer ); 94 fact->addFileTransferLayer( "SZ", QObject::tr("Z-Modem"), newSZTransfer );
94 fact->addFileTransferLayer( "SY", QObject::tr("Y-Modem"), newSYTransfer ); 95 fact->addFileTransferLayer( "SY", QObject::tr("Y-Modem"), newSYTransfer );
95 fact->addFileTransferLayer( "SX", QObject::tr("X-Modem"), newSXTransfer ); 96 fact->addFileTransferLayer( "SX", QObject::tr("X-Modem"), newSXTransfer );
96 97
97 fact->addReceiveLayer( "SZ", QObject::tr("Z-Modem"), newSZReceive ); 98 fact->addReceiveLayer( "SZ", QObject::tr("Z-Modem"), newSZReceive );
98 fact->addReceiveLayer( "SY", QObject::tr("Y-Modem"), newSYReceive ); 99 fact->addReceiveLayer( "SY", QObject::tr("Y-Modem"), newSYReceive );
99 fact->addReceiveLayer( "SX", QObject::tr("X-Modem"), newSXReceive ); 100 fact->addReceiveLayer( "SX", QObject::tr("X-Modem"), newSXReceive );
100 101
101 fact->addIOLayerFactory( "serial", QObject::tr("Serial"), newSerialLayer ); 102 fact->addIOLayerFactory( "serial", QObject::tr("Serial"), newSerialLayer );
102// fact->addIOLayerFactory( "irda", QObject::tr("Infrared"), newIrDaLayer ); 103// fact->addIOLayerFactory( "irda", QObject::tr("Infrared"), newIrDaLayer );
103// fact->addIOLayerFactory( "bt", QObject::tr("Bluetooth"), newBTLayer ); 104// fact->addIOLayerFactory( "bt", QObject::tr("Bluetooth"), newBTLayer );
104 fact->addIOLayerFactory( "modem", QObject::tr("Modem"), newModemLayer ); 105 fact->addIOLayerFactory( "modem", QObject::tr("Modem"), newModemLayer );
105 fact->addIOLayerFactory( "console", QObject::tr("local Console"), newConsole ); 106 fact->addIOLayerFactory( "console", QObject::tr("Local Console"), newConsole );
106 107
107 fact->addConnectionWidgetFactory( "serial", QObject::tr("Serial"), newSerialWidget ); 108 fact->addConnectionWidgetFactory( "serial", QObject::tr("Serial"), newSerialWidget );
108// fact->addConnectionWidgetFactory( "irda", QObject::tr("Infrared"), newIrDaWidget ); 109// fact->addConnectionWidgetFactory( "irda", QObject::tr("Infrared"), newIrDaWidget );
109 fact->addConnectionWidgetFactory( "modem", QObject::tr("Modem"), newModemWidget ); 110 fact->addConnectionWidgetFactory( "modem", QObject::tr("Modem"), newModemWidget );
110// fact->addConnectionWidgetFactory( "bt", QObject::tr("Bluetooth"), newBTWidget ); 111// fact->addConnectionWidgetFactory( "bt", QObject::tr("Bluetooth"), newBTWidget );
111 fact->addConnectionWidgetFactory( "console", QObject::tr("local Console"), newConsoleWid ); 112 fact->addConnectionWidgetFactory( "console", QObject::tr("Local Console"), newConsoleWid );
112 113
113 fact->addTerminalWidgetFactory( "default", QObject::tr("Default Terminal"), newTerminalWidget ); 114 fact->addTerminalWidgetFactory( "default", QObject::tr("Default Terminal"), newTerminalWidget );
114 fact->addKeyboardWidgetFactory( "defaultKeys", QObject::tr("Default Keyboard"), 115 fact->addKeyboardWidgetFactory( "defaultKeys", QObject::tr("Default Keyboard"),
115 newKeyboardWidget ); 116 newKeyboardWidget );
116 117
117// fact->addEmulationLayer( "default", QObject::tr("Default Terminal"), newVT102 ); 118// fact->addEmulationLayer( "default", QObject::tr("Default Terminal"), newVT102 );
118} 119}
119Default::~Default() { 120Default::~Default() {
120 121
121} 122}
diff --git a/noncore/apps/opie-console/opie-console.pro b/noncore/apps/opie-console/opie-console.pro
index f5737d4..e3f92f0 100644
--- a/noncore/apps/opie-console/opie-console.pro
+++ b/noncore/apps/opie-console/opie-console.pro
@@ -21,25 +21,26 @@ HEADERS = io_layer.h io_serial.h io_irda.h io_bt.h io_modem.h \
21 iolayerbase.h \ 21 iolayerbase.h \
22 serialconfigwidget.h irdaconfigwidget.h \ 22 serialconfigwidget.h irdaconfigwidget.h \
23 btconfigwidget.h modemconfigwidget.h \ 23 btconfigwidget.h modemconfigwidget.h \
24 atconfigdialog.h dialdialog.h \ 24 atconfigdialog.h dialdialog.h \
25 procctl.h \ 25 procctl.h \
26 function_keyboard.h \ 26 function_keyboard.h \
27 receive_layer.h filereceive.h \ 27 receive_layer.h filereceive.h \
28 script.h \ 28 script.h \
29 dialer.h \ 29 dialer.h \
30 terminalwidget.h \ 30 terminalwidget.h \
31 emulation_handler.h TECommon.h \ 31 emulation_handler.h TECommon.h \
32 TEHistroy.h TEScreen.h TEWidget.h \ 32 TEHistroy.h TEScreen.h TEWidget.h \
33 TEmuVt102.h TEmulation.h MyPty.h 33 TEmuVt102.h TEmulation.h MyPty.h \
34 consoleconfigwidget.h
34 35
35SOURCES = io_layer.cpp io_serial.cpp io_irda.cpp io_bt.cpp io_modem.cpp \ 36SOURCES = io_layer.cpp io_serial.cpp io_irda.cpp io_bt.cpp io_modem.cpp \
36 file_layer.cpp filetransfer.cpp \ 37 file_layer.cpp filetransfer.cpp \
37 main.cpp \ 38 main.cpp \
38 metafactory.cpp \ 39 metafactory.cpp \
39 session.cpp \ 40 session.cpp \
40 mainwindow.cpp \ 41 mainwindow.cpp \
41 profile.cpp \ 42 profile.cpp \
42 profileconfig.cpp \ 43 profileconfig.cpp \
43 profilemanager.cpp \ 44 profilemanager.cpp \
44 tabwidget.cpp \ 45 tabwidget.cpp \
45 configdialog.cpp \ 46 configdialog.cpp \
@@ -50,21 +51,22 @@ SOURCES = io_layer.cpp io_serial.cpp io_irda.cpp io_bt.cpp io_modem.cpp \
50 iolayerbase.cpp \ 51 iolayerbase.cpp \
51 serialconfigwidget.cpp irdaconfigwidget.cpp \ 52 serialconfigwidget.cpp irdaconfigwidget.cpp \
52 btconfigwidget.cpp modemconfigwidget.cpp \ 53 btconfigwidget.cpp modemconfigwidget.cpp \
53 atconfigdialog.cpp dialdialog.cpp \ 54 atconfigdialog.cpp dialdialog.cpp \
54 default.cpp procctl.cpp \ 55 default.cpp procctl.cpp \
55 function_keyboard.cpp \ 56 function_keyboard.cpp \
56 receive_layer.cpp filereceive.cpp \ 57 receive_layer.cpp filereceive.cpp \
57 script.cpp \ 58 script.cpp \
58 dialer.cpp \ 59 dialer.cpp \
59 terminalwidget.cpp \ 60 terminalwidget.cpp \
60 emulation_handler.cpp TEHistory.cpp \ 61 emulation_handler.cpp TEHistory.cpp \
61 TEScreen.cpp TEWidget.cpp \ 62 TEScreen.cpp TEWidget.cpp \
62 TEmuVt102.cpp TEmulation.cpp MyPty.cpp 63 TEmuVt102.cpp TEmulation.cpp MyPty.cpp \
64 consoleconfigwidget.cpp
63 65
64 66
65INTERFACES = configurebase.ui editbase.ui 67INTERFACES = configurebase.ui editbase.ui
66INCLUDEPATH += $(OPIEDIR)/include 68INCLUDEPATH += $(OPIEDIR)/include
67DEPENDPATH += $(OPIEDIR)/include 69DEPENDPATH += $(OPIEDIR)/include
68LIBS += -lqpe -lopie 70LIBS += -lqpe -lopie
69TARGET = opie-console 71TARGET = opie-console
70 72