synaptiks::MouseDevicesModel Class Reference
A Qt model class to manager mouse devices through HAL.
More...
#include <mousedevicesmodel.h>
List of all members.
Detailed Description
A Qt model class to manager mouse devices through HAL.
Constructor & Destructor Documentation
| MouseDevicesModel::MouseDevicesModel |
( |
QObject * |
parent = 0 |
) |
|
Create a new object.
- Parameters:
-
| parent | same as for QObject(QObject*) |
| MouseDevicesModel::~MouseDevicesModel |
( |
|
) |
[virtual] |
Member Function Documentation
| QStringList synaptiks::MouseDevicesModel::checkedDevices |
( |
|
) |
const |
Query the checked devices.
- Returns:
- a list of all checked devices
| void synaptiks::MouseDevicesModel::checkedDevicesChanged |
( |
const QStringList & |
devices |
) |
[signal] |
Emitted, if the the list of checked devices changes.
- Parameters:
-
| devices | the new list of checked devices |
| QVariant MouseDevicesModel::data |
( |
const QModelIndex & |
index, |
|
|
int |
role | |
|
) |
| | const |
Return the data for the given index and the given role.
- Parameters:
-
| index | points to the data to fetch |
| role | the role that data is needed for |
- Returns:
- the data
| Qt::ItemFlags MouseDevicesModel::flags |
( |
const QModelIndex & |
index |
) |
const |
Returns the item flags for the given index.
Items of this model are enabled and checkable, but not selectable.
- Parameters:
-
| index | the item to return flags for |
| int MouseDevicesModel::rowCount |
( |
const QModelIndex & |
parent = QModelIndex() |
) |
const |
Return the number of rows in this model.
- Parameters:
-
| parent | ignored, required by base class |
- Returns:
- the number of rows
| void MouseDevicesModel::setCheckedDevices |
( |
const QStringList & |
devices |
) |
|
| bool MouseDevicesModel::setData |
( |
const QModelIndex & |
index, |
|
|
const QVariant & |
value, |
|
|
int |
role | |
|
) |
| | |
Sets the data for the given index and the given role to the given value. If data was changed, true is returned and the itemChanged(const QModelIndex&, const QModelIndex&) signal is emitted.
The only data, that can be changed for this model, is the check state.
- Parameters:
-
| index | the index to set data for |
| value | the value |
| role | the role to set data for |
- Returns:
true, if data was changed, false otherwise
| void MouseDevicesModel::setTouchpadsIgnored |
( |
bool |
ignore |
) |
|
Ignore touchpads. Generally touchpads are mouses too and displayed by this model. However, there are cases, in which touchpads should not be considered as mouse devices. For such cases, you can have the model ignore touchpads with this function.
Setting this will reset the model.
By default, mouse devices are not ignored.
- Parameters:
-
| ignore | if true, ignore touchpads |
| bool synaptiks::MouseDevicesModel::touchpadsIgnored |
( |
|
) |
const |
Are touchpads ignored by this model?
- Returns:
true, if this model ignores touchpads, false otherwise
Property Documentation
QStringList MouseDevicesModel::checkedDevices [read, write] |
bool MouseDevicesModel::touchpadsIgnored [read, write] |
The documentation for this class was generated from the following files:
- /home/lunar/devel/projects/synaptiks/kcmodule/mousedevicesmodel.h
- /home/lunar/devel/projects/synaptiks/kcmodule/mousedevicesmodel.cpp