Diffstat (limited to 'libopie2/opiecore/device/odevice_ipaq.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r-- | libopie2/opiecore/device/odevice_ipaq.cpp | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/libopie2/opiecore/device/odevice_ipaq.cpp b/libopie2/opiecore/device/odevice_ipaq.cpp index 791e409..21fed99 100644 --- a/libopie2/opiecore/device/odevice_ipaq.cpp +++ b/libopie2/opiecore/device/odevice_ipaq.cpp | |||
@@ -148,50 +148,49 @@ void iPAQ::init(const QString& model) | |||
148 | case Model_iPAQ_H22xx: | 148 | case Model_iPAQ_H22xx: |
149 | d->m_rotation = Rot0; | 149 | d->m_rotation = Rot0; |
150 | break; | 150 | break; |
151 | case Model_iPAQ_H36xx: | 151 | case Model_iPAQ_H36xx: |
152 | case Model_iPAQ_H37xx: | 152 | case Model_iPAQ_H37xx: |
153 | case Model_iPAQ_H39xx: | 153 | case Model_iPAQ_H39xx: |
154 | default: | 154 | default: |
155 | d->m_rotation = Rot270; | 155 | d->m_rotation = Rot270; |
156 | break; | 156 | break; |
157 | 157 | ||
158 | } | 158 | } |
159 | 159 | ||
160 | m_leds [0] = m_leds [1] = Led_Off; | 160 | m_leds [0] = m_leds [1] = Led_Off; |
161 | 161 | ||
162 | m_power_timer = 0; | 162 | m_power_timer = 0; |
163 | 163 | ||
164 | } | 164 | } |
165 | 165 | ||
166 | void iPAQ::initButtons() | 166 | void iPAQ::initButtons() |
167 | { | 167 | { |
168 | if ( d->m_buttons ) | 168 | if ( d->m_buttons ) |
169 | return; | 169 | return; |
170 | 170 | ||
171 | if ( isQWS( ) ) { | 171 | if ( isQWS( ) ) { |
172 | Opie::Core::OKeyFilter::inst()->addPreHandler(this); | 172 | addPreHandler(this); |
173 | //QWSServer::setKeyboardFilter ( this ); | ||
174 | } | 173 | } |
175 | 174 | ||
176 | d->m_buttons = new QValueList <ODeviceButton>; | 175 | d->m_buttons = new QValueList <ODeviceButton>; |
177 | 176 | ||
178 | for ( uint i = 0; i < ( sizeof( ipaq_buttons ) / sizeof( i_button )); i++ ) { | 177 | for ( uint i = 0; i < ( sizeof( ipaq_buttons ) / sizeof( i_button )); i++ ) { |
179 | i_button *ib = ipaq_buttons + i; | 178 | i_button *ib = ipaq_buttons + i; |
180 | ODeviceButton b; | 179 | ODeviceButton b; |
181 | 180 | ||
182 | if (( ib->model & d->m_model ) == d->m_model ) { | 181 | if (( ib->model & d->m_model ) == d->m_model ) { |
183 | b. setKeycode ( ib->code ); | 182 | b. setKeycode ( ib->code ); |
184 | b. setUserText ( QObject::tr ( "Button", ib->utext )); | 183 | b. setUserText ( QObject::tr ( "Button", ib->utext )); |
185 | b. setPixmap ( Resource::loadPixmap ( ib->pix )); | 184 | b. setPixmap ( Resource::loadPixmap ( ib->pix )); |
186 | b. setFactoryPresetPressedAction ( OQCopMessage ( makeChannel ( ib->fpressedservice ), ib->fpressedaction )); | 185 | b. setFactoryPresetPressedAction ( OQCopMessage ( makeChannel ( ib->fpressedservice ), ib->fpressedaction )); |
187 | b. setFactoryPresetHeldAction ( OQCopMessage ( makeChannel ( ib->fheldservice ), ib->fheldaction )); | 186 | b. setFactoryPresetHeldAction ( OQCopMessage ( makeChannel ( ib->fheldservice ), ib->fheldaction )); |
188 | 187 | ||
189 | d->m_buttons->append ( b ); | 188 | d->m_buttons->append ( b ); |
190 | } | 189 | } |
191 | } | 190 | } |
192 | reloadButtonMapping(); | 191 | reloadButtonMapping(); |
193 | 192 | ||
194 | QCopChannel *sysch = new QCopChannel ( "QPE/System", this ); | 193 | QCopChannel *sysch = new QCopChannel ( "QPE/System", this ); |
195 | connect ( sysch, SIGNAL( received(const QCString&,const QByteArray&)), this, SLOT( systemMessage(const QCString&,const QByteArray&))); | 194 | connect ( sysch, SIGNAL( received(const QCString&,const QByteArray&)), this, SLOT( systemMessage(const QCString&,const QByteArray&))); |
196 | } | 195 | } |
197 | 196 | ||