-rw-r--r-- | core/launcher/desktop.cpp | 58 | ||||
-rw-r--r-- | core/launcher/main.cpp | 13 | ||||
-rw-r--r-- | core/launcher/taskbar.cpp | 47 | ||||
-rw-r--r-- | core/launcher/taskbar.h | 4 |
4 files changed, 53 insertions, 69 deletions
diff --git a/core/launcher/desktop.cpp b/core/launcher/desktop.cpp index ab4f14a..7662e48 100644 --- a/core/launcher/desktop.cpp +++ b/core/launcher/desktop.cpp | |||
@@ -45,2 +45,4 @@ | |||
45 | 45 | ||
46 | #include <opie/odevice.h> | ||
47 | |||
46 | #include <qgfx_qws.h> | 48 | #include <qgfx_qws.h> |
@@ -269,3 +271,3 @@ bool DesktopApplication::qwsEventFilter( QWSEvent *e ) | |||
269 | } | 271 | } |
270 | if ( press ) | 272 | if (( press && !autoRepeat ) || ( !press && autoRepeat )) |
271 | qpedesktop->keyClick(); | 273 | qpedesktop->keyClick(); |
@@ -329,6 +331,2 @@ QPE_MEMALERTER_IMPL | |||
329 | 331 | ||
330 | #if defined(CUSTOM_SOUND_IMPL) | ||
331 | CUSTOM_SOUND_IMPL | ||
332 | #endif | ||
333 | |||
334 | //=========================================================================== | 332 | //=========================================================================== |
@@ -341,6 +339,2 @@ Desktop::Desktop() : | |||
341 | { | 339 | { |
342 | #ifdef CUSTOM_SOUND_INIT | ||
343 | CUSTOM_SOUND_INIT; | ||
344 | #endif | ||
345 | |||
346 | qpedesktop = this; | 340 | qpedesktop = this; |
@@ -758,6 +752,4 @@ void Desktop::keyClick() | |||
758 | { | 752 | { |
759 | #ifdef CUSTOM_SOUND_KEYCLICK | 753 | if ( keyclick ) |
760 | if ( keyclick ) | 754 | ODevice::inst ( )-> keySound ( ); |
761 | CUSTOM_SOUND_KEYCLICK; | ||
762 | #endif | ||
763 | } | 755 | } |
@@ -766,6 +758,4 @@ void Desktop::screenClick() | |||
766 | { | 758 | { |
767 | #ifdef CUSTOM_SOUND_TOUCH | 759 | if ( touchclick ) |
768 | if ( touchclick ) | 760 | ODevice::inst ( )-> touchSound ( ); |
769 | CUSTOM_SOUND_TOUCH; | ||
770 | #endif | ||
771 | } | 761 | } |
@@ -774,23 +764,21 @@ void Desktop::soundAlarm() | |||
774 | { | 764 | { |
775 | #ifdef CUSTOM_SOUND_ALARM | 765 | if ( qpedesktop-> alarmsound ) |
776 | if (qpedesktop->alarmsound) | 766 | ODevice::inst ( )-> alarmSound ( ); |
777 | CUSTOM_SOUND_ALARM; | ||
778 | #endif | ||
779 | } | 767 | } |
780 | 768 | ||
781 | bool Desktop::eventFilter( QObject *w, QEvent *ev ) | 769 | bool Desktop::eventFilter( QObject *, QEvent *ev ) |
782 | { | 770 | { |
783 | if ( ev->type() == QEvent::KeyPress ) { | 771 | if ( ev-> type ( ) == QEvent::KeyPress ) { |
784 | QKeyEvent *ke = (QKeyEvent *)ev; | 772 | QKeyEvent *ke = (QKeyEvent *) ev; |
785 | if ( ke->key() == Qt::Key_F11 ) { // menu key | 773 | if ( ke-> key ( ) == Qt::Key_F11 ) { // menu key |
786 | QWidget *active = qApp->activeWindow(); | 774 | QWidget *active = qApp-> activeWindow ( ); |
787 | if ( active && active->isPopup() ) { | 775 | |
788 | active->close(); | 776 | if ( active && active-> isPopup ( )) |
789 | } | 777 | active->close(); |
790 | raiseMenu(); | ||
791 | return TRUE; | ||
792 | } | ||
793 | } | ||
794 | return FALSE; | ||
795 | } | ||
796 | 778 | ||
779 | raiseMenu ( ); | ||
780 | return true; | ||
781 | } | ||
782 | } | ||
783 | return false; | ||
784 | } | ||
diff --git a/core/launcher/main.cpp b/core/launcher/main.cpp index 347eee9..b3c331b 100644 --- a/core/launcher/main.cpp +++ b/core/launcher/main.cpp | |||
@@ -31,2 +31,4 @@ | |||
31 | 31 | ||
32 | #include <opie/odevice.h> | ||
33 | |||
32 | #include <qfile.h> | 34 | #include <qfile.h> |
@@ -36,4 +38,2 @@ | |||
36 | 38 | ||
37 | #include <opie/ohwinfo.h> | ||
38 | |||
39 | #include <stdlib.h> | 39 | #include <stdlib.h> |
@@ -195,3 +195,3 @@ public: | |||
195 | 195 | ||
196 | m_model = OHwInfo::inst ( )-> model ( ); | 196 | m_model = ODevice::inst ( )-> model ( ); |
197 | m_power_timer = 0; | 197 | m_power_timer = 0; |
@@ -210,3 +210,3 @@ public: | |||
210 | 210 | ||
211 | virtual bool filter ( int unicode, int keycode, int modifiers, bool isPress, bool autoRepeat ) | 211 | virtual bool filter ( int /*unicode*/, int keycode, int modifiers, bool isPress, bool autoRepeat ) |
212 | { | 212 | { |
@@ -269,5 +269,4 @@ public: | |||
269 | private: | 269 | private: |
270 | OHwModel m_model; | 270 | OModel m_model; |
271 | bool m_power_press; | 271 | int m_power_timer; |
272 | int m_power_timer; | ||
273 | }; | 272 | }; |
diff --git a/core/launcher/taskbar.cpp b/core/launcher/taskbar.cpp index 5e95c99..e38b9fe 100644 --- a/core/launcher/taskbar.cpp +++ b/core/launcher/taskbar.cpp | |||
@@ -39,2 +39,4 @@ | |||
39 | 39 | ||
40 | #include <opie/odevice.h> | ||
41 | |||
40 | #include <qlabel.h> | 42 | #include <qlabel.h> |
@@ -255,25 +257,24 @@ void TaskBar::receive( const QCString &msg, const QByteArray &data ) | |||
255 | { | 257 | { |
256 | QDataStream stream( data, IO_ReadOnly ); | 258 | QDataStream stream( data, IO_ReadOnly ); |
257 | if ( msg == "message(QString)" ) { | 259 | if ( msg == "message(QString)" ) { |
258 | QString text; | 260 | QString text; |
259 | stream >> text; | 261 | stream >> text; |
260 | setStatusMessage( text ); | 262 | setStatusMessage( text ); |
261 | } else if ( msg == "hideInputMethod()" ) { | 263 | } else if ( msg == "hideInputMethod()" ) { |
262 | inputMethods->hideInputMethod(); | 264 | inputMethods->hideInputMethod(); |
263 | } else if ( msg == "showInputMethod()" ) { | 265 | } else if ( msg == "showInputMethod()" ) { |
264 | inputMethods->showInputMethod(); | 266 | inputMethods->showInputMethod(); |
265 | } else if ( msg == "reloadInputMethods()" ) { | 267 | } else if ( msg == "reloadInputMethods()" ) { |
266 | inputMethods->loadInputMethods(); | 268 | inputMethods->loadInputMethods(); |
267 | } else if ( msg == "reloadApplets()" ) { | 269 | } else if ( msg == "reloadApplets()" ) { |
268 | sysTray->loadApplets(); | 270 | sysTray->loadApplets(); |
269 | } else if ( msg == "soundAlarm()" ) { | 271 | } else if ( msg == "soundAlarm()" ) { |
270 | Desktop::soundAlarm(); | 272 | Desktop::soundAlarm(); |
271 | } | 273 | } |
272 | #ifdef CUSTOM_LEDS | 274 | else if ( msg == "setLed(int,bool)" ) { |
273 | else if ( msg == "setLed(int,bool)" ) { | 275 | int led, status; |
274 | int led, status; | 276 | stream >> led >> status; |
275 | stream >> led >> status; | 277 | |
276 | CUSTOM_LEDS( led, status ); | 278 | ODevice::inst ( )-> setLed ( led, status ? OLED_BlinkSlow : OLED_Off ); |
277 | } | 279 | } |
278 | #endif | ||
279 | } | 280 | } |
diff --git a/core/launcher/taskbar.h b/core/launcher/taskbar.h index 78c4722..40983af 100644 --- a/core/launcher/taskbar.h +++ b/core/launcher/taskbar.h | |||
@@ -23,6 +23,2 @@ | |||
23 | 23 | ||
24 | #if defined( QT_QWS_CUSTOM ) || defined( QT_QWS_IPAQ ) | ||
25 | #include <qpe/custom.h> | ||
26 | #endif | ||
27 | |||
28 | #include <qhbox.h> | 24 | #include <qhbox.h> |