Libpointing
An open-source cross-platform library to get raw events from pointing devices and master transfer functions.
DummyPointingDevice.h
1 /* -*- mode: c++ -*-
2  *
3  * pointing/input/DummyPointingDevice.h --
4  *
5  * Initial software
6  * Authors: Géry Casiez, Nicolas Roussel
7  * Copyright © Inria
8  *
9  * http://libpointing.org/
10  *
11  * This software may be used and distributed according to the terms of
12  * the GNU General Public License version 2 or any later version.
13  *
14  */
15 
16 #ifndef DummyPointingDevice_h
17 #define DummyPointingDevice_h
18 
19 #include <pointing/input/PointingDevice.h>
20 
21 namespace pointing {
22 
31 
32  int cpi, hz ;
33 
34  public:
35 
40  DummyPointingDevice(URI uri) ;
41 
42  double getResolution(double * /*defval*/=0) const { return cpi ; }
43 
44  double getUpdateFrequency(double * /*defval*/=0) const { return hz ; }
45 
46  URI getURI(bool expanded=false, bool crossplatform=true) const ;
47 
53  void setPointingCallback(PointingCallback /*callback*/, void * /*context*/) {}
54 
56 
57  } ;
58 
59 }
60 
61 #endif
double getResolution(double *=0) const
Resolution of the mouse in CPI (counts per inch).
Definition: DummyPointingDevice.h:42
void setPointingCallback(PointingCallback, void *)
The callback function will never be executed. The purpose of this class is to return specified resolu...
Definition: DummyPointingDevice.h:53
double getUpdateFrequency(double *=0) const
Update frequency of the mouse in Hz.
Definition: DummyPointingDevice.h:44
URI getURI(bool expanded=false, bool crossplatform=true) const
Constructs the URI according to the parameters of the device.
Definition: DummyPointingDevice.cpp:34
Definition: DummyPointingDevice.cpp:23
The PointingDevice class is used to represent Pointing Devices connected to the computer or pseudo-de...
Definition: PointingDevice.h:35
DummyPointingDevice(URI uri)
The constructor.
Definition: DummyPointingDevice.cpp:25
The DummyPointingDevice class is a pseudo-device class. It is used for testing and debugging purposes...
Definition: DummyPointingDevice.h:30
void(* PointingCallback)(void *context, TimeStamp::inttime timestamp, int dx, int dy, int buttons)
Definition: PointingDevice.h:76