author | sandman <sandman> | 2002-08-04 02:52:49 (UTC) |
---|---|---|
committer | sandman <sandman> | 2002-08-04 02:52:49 (UTC) |
commit | 97cdd27f6f7696e4e6f1239c90ecc2b94c087239 (patch) (side-by-side diff) | |
tree | 68057ed5a0a9866addc62650218ec6856863173f | |
parent | a8c65999503fa9ff34db3069c53bbc1685b521ec (diff) | |
download | opie-97cdd27f6f7696e4e6f1239c90ecc2b94c087239.zip opie-97cdd27f6f7696e4e6f1239c90ecc2b94c087239.tar.gz opie-97cdd27f6f7696e4e6f1239c90ecc2b94c087239.tar.bz2 |
Another bug fix for suspend/resume on iPAQs (blinking screen).. this bug
is very hard to trigger and has probably never shown up
-rw-r--r-- | core/launcher/main.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/core/launcher/main.cpp b/core/launcher/main.cpp index 1e741d5..3ee5e26 100644 --- a/core/launcher/main.cpp +++ b/core/launcher/main.cpp @@ -216,48 +216,50 @@ public: switch ( keycode ) { case Key_Left : newkeycode = Key_Right; break; case Key_Right: newkeycode = Key_Left; break; case Key_Up : newkeycode = Key_Down; break; case Key_Down : newkeycode = Key_Up; break; } if ( newkeycode != keycode ) { QWSServer::sendKeyEvent ( -1, newkeycode, modifiers, isPress, autoRepeat ); kill = true; } break; } default: break; } // map Power Button short/long press to F34/F35 switch ( m_model ) { case OMODEL_iPAQ_H31xx: case OMODEL_iPAQ_H36xx: case OMODEL_iPAQ_H37xx: case OMODEL_iPAQ_H38xx: { if ( keycode == Key_SysReq ) { if ( isPress ) { + if ( m_power_timer ) + killTimer ( m_power_timer ); m_power_timer = startTimer ( 500 ); } else if ( m_power_timer ) { killTimer ( m_power_timer ); m_power_timer = 0; QWSServer::sendKeyEvent ( -1, Key_F34, 0, true, false ); QWSServer::sendKeyEvent ( -1, Key_F34, 0, false, false ); } kill = true; } break; } default: break; } return kill; } virtual void timerEvent ( QTimerEvent * ) { killTimer ( m_power_timer ); m_power_timer = 0; QWSServer::sendKeyEvent ( -1, Key_F35, 0, true, false ); QWSServer::sendKeyEvent ( -1, Key_F35, 0, false, false ); } |