Changeset View
Changeset View
Standalone View
Standalone View
kcms/input/kcm/xlib/xlib_config.cpp
Show First 20 Lines • Show All 57 Lines • ▼ Show 20 Line(s) | |||||
58 | { | 58 | { | ||
59 | setupUi(this); | 59 | setupUi(this); | ||
60 | 60 | | |||
61 | handedGroup->setId(rightHanded, static_cast<int>(Handed::Right)); | 61 | handedGroup->setId(rightHanded, static_cast<int>(Handed::Right)); | ||
62 | handedGroup->setId(leftHanded, static_cast<int>(Handed::Left)); | 62 | handedGroup->setId(leftHanded, static_cast<int>(Handed::Left)); | ||
63 | 63 | | |||
64 | connect(handedGroup, SIGNAL(buttonClicked(int)), m_parent, SLOT(changed())); | 64 | connect(handedGroup, SIGNAL(buttonClicked(int)), m_parent, SLOT(changed())); | ||
65 | connect(handedGroup, SIGNAL(buttonClicked(int)), this, SLOT(slotHandedChanged(int))); | 65 | connect(handedGroup, SIGNAL(buttonClicked(int)), this, SLOT(slotHandedChanged(int))); | ||
66 | connect(doubleClick, SIGNAL(clicked()), m_parent, SLOT(changed())); | | |||
67 | 66 | | |||
68 | connect(singleClick, SIGNAL(clicked()), m_parent, SLOT(changed())); | | |||
69 | connect(cbScrollPolarity, SIGNAL(clicked()), m_parent, SLOT(changed())); | 67 | connect(cbScrollPolarity, SIGNAL(clicked()), m_parent, SLOT(changed())); | ||
70 | connect(cbScrollPolarity, SIGNAL(clicked()), this, SLOT(slotScrollPolarityChanged())); | 68 | connect(cbScrollPolarity, SIGNAL(clicked()), this, SLOT(slotScrollPolarityChanged())); | ||
71 | 69 | | |||
72 | connect(accel, SIGNAL(valueChanged(double)), m_parent, SLOT(changed())); | 70 | connect(accel, SIGNAL(valueChanged(double)), m_parent, SLOT(changed())); | ||
73 | connect(thresh, SIGNAL(valueChanged(int)), m_parent, SLOT(changed())); | 71 | connect(thresh, SIGNAL(valueChanged(int)), m_parent, SLOT(changed())); | ||
74 | connect(thresh, SIGNAL(valueChanged(int)), this, SLOT(slotThreshChanged(int))); | 72 | connect(thresh, SIGNAL(valueChanged(int)), this, SLOT(slotThreshChanged(int))); | ||
75 | slotThreshChanged(thresh->value()); | 73 | slotThreshChanged(thresh->value()); | ||
76 | 74 | | |||
▲ Show 20 Lines • Show All 118 Lines • ▼ Show 20 Line(s) | 166 | { | |||
195 | setThreshold(settings->thresholdMove); | 193 | setThreshold(settings->thresholdMove); | ||
196 | setHandedness(settings->handed); | 194 | setHandedness(settings->handed); | ||
197 | 195 | | |||
198 | doubleClickInterval->setValue(settings->doubleClickInterval); | 196 | doubleClickInterval->setValue(settings->doubleClickInterval); | ||
199 | dragStartTime->setValue(settings->dragStartTime); | 197 | dragStartTime->setValue(settings->dragStartTime); | ||
200 | dragStartDist->setValue(settings->dragStartDist); | 198 | dragStartDist->setValue(settings->dragStartDist); | ||
201 | wheelScrollLines->setValue(settings->wheelScrollLines); | 199 | wheelScrollLines->setValue(settings->wheelScrollLines); | ||
202 | 200 | | |||
203 | singleClick->setChecked(settings->singleClick); | | |||
204 | doubleClick->setChecked(!settings->singleClick); | | |||
205 | | ||||
206 | KConfig ac("kaccessrc"); | 201 | KConfig ac("kaccessrc"); | ||
207 | 202 | | |||
208 | KConfigGroup group = ac.group("Mouse"); | 203 | KConfigGroup group = ac.group("Mouse"); | ||
209 | mouseKeys->setChecked(group.readEntry("MouseKeys", false)); | 204 | mouseKeys->setChecked(group.readEntry("MouseKeys", false)); | ||
210 | mk_delay->setValue(group.readEntry("MKDelay", 160)); | 205 | mk_delay->setValue(group.readEntry("MKDelay", 160)); | ||
211 | 206 | | |||
212 | int interval = group.readEntry("MKInterval", 5); | 207 | int interval = group.readEntry("MKInterval", 5); | ||
213 | mk_interval->setValue(interval); | 208 | mk_interval->setValue(interval); | ||
Show All 26 Lines | 232 | { | |||
240 | settings->accelRate = getAccel(); | 235 | settings->accelRate = getAccel(); | ||
241 | settings->thresholdMove = getThreshold(); | 236 | settings->thresholdMove = getThreshold(); | ||
242 | settings->handed = getHandedness(); | 237 | settings->handed = getHandedness(); | ||
243 | 238 | | |||
244 | settings->doubleClickInterval = doubleClickInterval->value(); | 239 | settings->doubleClickInterval = doubleClickInterval->value(); | ||
245 | settings->dragStartTime = dragStartTime->value(); | 240 | settings->dragStartTime = dragStartTime->value(); | ||
246 | settings->dragStartDist = dragStartDist->value(); | 241 | settings->dragStartDist = dragStartDist->value(); | ||
247 | settings->wheelScrollLines = wheelScrollLines->value(); | 242 | settings->wheelScrollLines = wheelScrollLines->value(); | ||
248 | settings->singleClick = !doubleClick->isChecked(); | | |||
249 | settings->reverseScrollPolarity = cbScrollPolarity->isChecked(); | 243 | settings->reverseScrollPolarity = cbScrollPolarity->isChecked(); | ||
250 | 244 | | |||
251 | m_backend->apply(); | 245 | m_backend->apply(); | ||
252 | settings->save(); | 246 | settings->save(); | ||
253 | 247 | | |||
254 | KConfig ac("kaccessrc"); | 248 | KConfig ac("kaccessrc"); | ||
255 | 249 | | |||
256 | KConfigGroup group = ac.group("Mouse"); | 250 | KConfigGroup group = ac.group("Mouse"); | ||
Show All 20 Lines | 270 | { | |||
277 | setThreshold(2); | 271 | setThreshold(2); | ||
278 | setAccel(2); | 272 | setAccel(2); | ||
279 | setHandedness(Handed::Right); | 273 | setHandedness(Handed::Right); | ||
280 | cbScrollPolarity->setChecked(false); | 274 | cbScrollPolarity->setChecked(false); | ||
281 | doubleClickInterval->setValue(400); | 275 | doubleClickInterval->setValue(400); | ||
282 | dragStartTime->setValue(500); | 276 | dragStartTime->setValue(500); | ||
283 | dragStartDist->setValue(4); | 277 | dragStartDist->setValue(4); | ||
284 | wheelScrollLines->setValue(3); | 278 | wheelScrollLines->setValue(3); | ||
285 | doubleClick->setChecked(!KDE_DEFAULT_SINGLECLICK); | | |||
286 | singleClick->setChecked(KDE_DEFAULT_SINGLECLICK); | | |||
287 | 279 | | |||
288 | mouseKeys->setChecked(false); | 280 | mouseKeys->setChecked(false); | ||
289 | mk_delay->setValue(160); | 281 | mk_delay->setValue(160); | ||
290 | mk_interval->setValue(5); | 282 | mk_interval->setValue(5); | ||
291 | mk_time_to_max->setValue(5000); | 283 | mk_time_to_max->setValue(5000); | ||
292 | mk_max_speed->setValue(1000); | 284 | mk_max_speed->setValue(1000); | ||
293 | mk_curve->setValue(0); | 285 | mk_curve->setValue(0); | ||
294 | 286 | | |||
Show All 37 Lines |