Annotation of XNU/iokit/Families/IOHIDSystem/IOHITabletPointer.cpp, revision 1.1.1.1

1.1       root        1: #include <IOKit/hidsystem/IOHITabletPointer.h>
                      2: 
                      3: OSDefineMetaClassAndStructors(IOHITabletPointer, IOHIDevice)
                      4: 
                      5: UInt16 IOHITabletPointer::generateDeviceID()
                      6: {
                      7:     static _nextDeviceID = 0;
                      8:     return _nextDeviceID++;
                      9: }
                     10: 
                     11: bool IOHITabletPointer::init( OSDictionary *propTable )
                     12: {
                     13:     if (!IOHIDevice::init(propTable)) {
                     14:         return false;
                     15:     }
                     16: 
                     17:     _deviceID = generateDeviceID();
                     18:     setProperty(kIOHITabletPointerDeviceID, (unsigned long long)_deviceID, 16);
                     19: 
                     20:     return true;
                     21: }
                     22: 
                     23: bool IOService::attach( IOService * provider )
                     24: {
                     25:     if (!IOHIDevice::attach(provider)) {
                     26:         return false;
                     27:     }
                     28: 
                     29:     _tablet = OSDynamicCast(IOHITablet, provider);
                     30: 
                     31:     return true;
                     32: }
                     33: 
                     34: void IOHITabletPointer::dispatchTabletEvent(NXEventData *tabletEvent,
                     35:                                             AbsoluteTime ts)
                     36: {
                     37:     if (_tablet) {
                     38:         _tablet->dispatchTabletEvent(tabletEvent, ts);
                     39:     }
                     40: }
                     41: 
                     42: void IOHITabletPointer::dispatchProximityEvent(NXEventData *proximityEvent,
                     43:                                                AbsoluteTime ts)
                     44: {
                     45:     if (_tablet) {
                     46:         _tablet->dispatchProximityEvent(proximityEvent, ts);
                     47:     }
                     48: }

unix.superglobalmegacorp.com

This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.