summaryrefslogtreecommitdiff
Side-by-side diff
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--libopie2/opiecore/device/odevice_zaurus.cpp13
1 files changed, 5 insertions, 8 deletions
diff --git a/libopie2/opiecore/device/odevice_zaurus.cpp b/libopie2/opiecore/device/odevice_zaurus.cpp
index 89b9258..59d4eb0 100644
--- a/libopie2/opiecore/device/odevice_zaurus.cpp
+++ b/libopie2/opiecore/device/odevice_zaurus.cpp
@@ -239,7 +239,4 @@ void Zaurus::initButtons()
return;
- if ( isQWS( ) ) {
- addPreHandler(this);
- }
d->m_buttons = new QValueList <ODeviceButton>;
@@ -250,4 +247,7 @@ void Zaurus::initButtons()
case Model_Zaurus_SLC3000: // fallthrough
case Model_Zaurus_SLC7x0:
+ if ( isQWS( ) ) {
+ addPreHandler(this); // hinge-sensor-handler
+ }
pz_buttons = z_buttons_c700;
buttoncount = ARRAY_SIZE(z_buttons_c700);
@@ -604,11 +604,7 @@ OHingeStatus Zaurus::readHingeSensor() const
bool Zaurus::filter ( int /*unicode*/, int keycode, int modifiers, bool isPress, bool autoRepeat )
{
- Transformation rot;
int newkeycode = keycode;
-
if (d->m_model!=Model_Zaurus_SLC3000 && d->m_model!=Model_Zaurus_SLC7x0) return false;
- rot = rotation();
- if (rot==Rot0) return false;
/* map cursor keys depending on the hinge status */
@@ -620,5 +616,5 @@ bool Zaurus::filter ( int /*unicode*/, int keycode, int modifiers, bool isPress,
case Key_Down :
{
- if (rot==Rot90) {
+ if (rotation()==Rot90) {
newkeycode = Key_Left + ( keycode - Key_Left + 3 ) % 4;
}
@@ -635,2 +631,3 @@ bool Zaurus::filter ( int /*unicode*/, int keycode, int modifiers, bool isPress,
return false;
}
+