author | mickeyl <mickeyl> | 2005-06-26 12:27:37 (UTC) |
---|---|---|
committer | mickeyl <mickeyl> | 2005-06-26 12:27:37 (UTC) |
commit | b4d2fa56d4b4608656f6b5cf3ff9375708395e91 (patch) (side-by-side diff) | |
tree | 7b087a487929d9b0f9de67860b9fe123773239f0 | |
parent | 53f924947144ddbb3e15d3bd1ddc877073c7ec7f (diff) | |
download | opie-b4d2fa56d4b4608656f6b5cf3ff9375708395e91.zip opie-b4d2fa56d4b4608656f6b5cf3ff9375708395e91.tar.gz opie-b4d2fa56d4b4608656f6b5cf3ff9375708395e91.tar.bz2 |
ODevice now features a method to gather the preferred qte driver.
The default driver is "Transformed". C7x0 Zaurus devices use "W100" from now on.
-rw-r--r-- | libopie2/opiecore/device/odevice.cpp | 6 | ||||
-rw-r--r-- | libopie2/opiecore/device/odevice.h | 6 | ||||
-rw-r--r-- | libopie2/opiecore/device/odevice_zaurus.cpp | 17 |
3 files changed, 24 insertions, 5 deletions
diff --git a/libopie2/opiecore/device/odevice.cpp b/libopie2/opiecore/device/odevice.cpp index 5e91d8b..56f305f 100644 --- a/libopie2/opiecore/device/odevice.cpp +++ b/libopie2/opiecore/device/odevice.cpp @@ -178,4 +178,5 @@ ODevice::ODevice() d->m_rotation = Rot0; d->m_direction = CW; + d->m_qteDriver = "Transformed"; d->m_holdtime = 1000; // 1000ms @@ -403,4 +404,9 @@ ODirection ODevice::direction() const } +QString ODevice::qteDriver() const +{ + return d->m_qteDriver; +} + /** * This plays an alarm sound diff --git a/libopie2/opiecore/device/odevice.h b/libopie2/opiecore/device/odevice.h index 5db43ff..b8478b9 100644 --- a/libopie2/opiecore/device/odevice.h +++ b/libopie2/opiecore/device/odevice.h @@ -237,9 +237,7 @@ public: // sandman do we want to allow destructions? -zecke? virtual ~ODevice(); - static ODevice *inst(); // information - QString modelString() const; OModel model() const; @@ -257,4 +255,6 @@ public: virtual ODirection direction() const; + QString qteDriver() const; + // system virtual bool suspend(); @@ -360,4 +360,6 @@ class ODeviceData { ODirection m_direction; + QString m_qteDriver; + QValueList <ODeviceButton> *m_buttons; uint m_holdtime; diff --git a/libopie2/opiecore/device/odevice_zaurus.cpp b/libopie2/opiecore/device/odevice_zaurus.cpp index 21d2342..0c421e3 100644 --- a/libopie2/opiecore/device/odevice_zaurus.cpp +++ b/libopie2/opiecore/device/odevice_zaurus.cpp @@ -200,5 +200,6 @@ void Zaurus::init(const QString& cpu_info) // set path to backlight device in kernel 2.6 - switch ( d->m_model ) { + switch ( d->m_model ) + { case Model_Zaurus_SLB600: // fallthrough case Model_Zaurus_SL5500: @@ -210,9 +211,9 @@ void Zaurus::init(const QString& cpu_info) default: m_backlightdev = "/sys/class/backlight/corgi-bl/"; - break; } // set initial rotation - switch( d->m_model ) { + switch( d->m_model ) + { case Model_Zaurus_SL6000: // fallthrough case Model_Zaurus_SLA300: @@ -230,6 +231,16 @@ void Zaurus::init(const QString& cpu_info) default: d->m_rotation = Rot270; + } + + // set default qte driver + switch( d->m_model ) + { + case Model_Zaurus_SLC7x0: + d->m_qteDriver = "W100"; break; + default: + d->m_qteDriver = "Transformed"; } + m_leds[0] = Led_Off; |