summaryrefslogtreecommitdiff
Side-by-side diff
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--noncore/apps/opie-console/PLANS5
-rw-r--r--noncore/apps/opie-console/main.cpp35
-rw-r--r--noncore/apps/opie-console/opie-console.control2
-rw-r--r--noncore/apps/opie-console/opie-console.pro4
4 files changed, 39 insertions, 7 deletions
diff --git a/noncore/apps/opie-console/PLANS b/noncore/apps/opie-console/PLANS
index a7c7578..bef7196 100644
--- a/noncore/apps/opie-console/PLANS
+++ b/noncore/apps/opie-console/PLANS
@@ -30,6 +30,5 @@ keyboard?
Scripting - wazlaf
+ Keys - hash
TASKS in progress:
- Keys - hash
-
Session->Profile - hash => why is this needed? you can not change any settings
@@ -44,3 +43,3 @@ TASKS in progress:
- hash => got it.
+ hash => got it.
diff --git a/noncore/apps/opie-console/main.cpp b/noncore/apps/opie-console/main.cpp
index eafc9b2..58c9c57 100644
--- a/noncore/apps/opie-console/main.cpp
+++ b/noncore/apps/opie-console/main.cpp
@@ -1,2 +1,3 @@
-#include <opie2/oapplicationfactory.h>
+#include <opie2/oapplication.h>
+#include <qwsevent_qws.h>
@@ -4,5 +5,35 @@
+class OConsoleApplication : public Opie::Core::OApplication {
+public:
+ OConsoleApplication(int argc, char* argv[]);
+protected:
+ bool qwsEventFilter( QWSEvent * );
+};
-OPIE_EXPORT_APP( Opie::Core::OApplicationFactory<MainWindow> );
+OConsoleApplication::OConsoleApplication(int argc, char* argv[] )
+ : Opie::Core::OApplication(argc, argv, "opie-console")
+{}
+bool OConsoleApplication::qwsEventFilter( QWSEvent *e) {
+ if( e->type == QWSEvent::Key ) {
+ QWSKeyEvent *key = static_cast<QWSKeyEvent*>(e);
+
+ /* prevent QPEApplication to filter the key */
+ if(key->simpleData.keycode == Qt::Key_Escape)
+ return QApplication::qwsEventFilter(e);
+
+ }
+
+ return Opie::Core::OApplication::qwsEventFilter( e);
+}
+
+
+int main(int argc, char* argv[]) {
+ OConsoleApplication app(argc, argv);
+
+ MainWindow win;
+ app.showMainWidget(&win);
+
+ return app.exec();
+}
diff --git a/noncore/apps/opie-console/opie-console.control b/noncore/apps/opie-console/opie-console.control
index 994e662..e924b79 100644
--- a/noncore/apps/opie-console/opie-console.control
+++ b/noncore/apps/opie-console/opie-console.control
@@ -1,3 +1,3 @@
Package: opie-console
-Files: plugins/application/libopie-console.so* bin/opie-console apps/Applications/opie-console.desktop pics/console/*
+Files: bin/opie-console apps/Applications/opie-console.desktop pics/console/*
Priority: optional
diff --git a/noncore/apps/opie-console/opie-console.pro b/noncore/apps/opie-console/opie-console.pro
index 57bd0f4..6bc42bd 100644
--- a/noncore/apps/opie-console/opie-console.pro
+++ b/noncore/apps/opie-console/opie-console.pro
@@ -1,2 +1,3 @@
-CONFIG += qt warn_on quick-app
+TEMPLATE = app
+CONFIG += qt warn_on
HEADERS = io_layer.h io_serial.h io_irda.h io_bt.h io_modem.h \
@@ -62,2 +63,3 @@ SOURCES = io_layer.cpp io_serial.cpp io_irda.cpp io_bt.cpp io_modem.cpp \
+DESTDIR = $(OPIEDIR)/bin/
INTERFACES = configurebase.ui editbase.ui