From 610ce4da3d97a9a88ddd8c53a9af909e6cfb3479 Mon Sep 17 00:00:00 2001 From: Vyrtsev Mikhail Date: Sun, 10 Sep 2023 23:38:31 +0300 Subject: [PATCH] Remove unused properties --- MiddleMe/OpenMultitouchSupport/OpenMTEvent.h | 3 --- MiddleMe/OpenMultitouchSupport/OpenMTEvent.m | 4 ---- .../OpenMultitouchSupport/OpenMTManager.m | 8 -------- MiddleMe/OpenMultitouchSupport/OpenMTTouch.h | 20 ------------------- MiddleMe/OpenMultitouchSupport/OpenMTTouch.m | 16 --------------- 5 files changed, 51 deletions(-) diff --git a/MiddleMe/OpenMultitouchSupport/OpenMTEvent.h b/MiddleMe/OpenMultitouchSupport/OpenMTEvent.h index 08918c6..99b45ef 100644 --- a/MiddleMe/OpenMultitouchSupport/OpenMTEvent.h +++ b/MiddleMe/OpenMultitouchSupport/OpenMTEvent.h @@ -14,9 +14,6 @@ @interface OpenMTEvent: NSObject @property (strong, readwrite) NSArray *touches; -@property (assign, readwrite) int deviceID; -@property (assign, readwrite) int frameID; -@property (assign, readwrite) double timestamp; @end diff --git a/MiddleMe/OpenMultitouchSupport/OpenMTEvent.m b/MiddleMe/OpenMultitouchSupport/OpenMTEvent.m index 311d637..8682897 100644 --- a/MiddleMe/OpenMultitouchSupport/OpenMTEvent.m +++ b/MiddleMe/OpenMultitouchSupport/OpenMTEvent.m @@ -11,9 +11,5 @@ @implementation OpenMTEvent -- (NSString *)description { - return [NSString stringWithFormat:@"Touches: %@, Device ID: %i, Frame ID: %i, Timestamp: %f", _touches.description, _deviceID, _frameID, _timestamp]; -} - @end diff --git a/MiddleMe/OpenMultitouchSupport/OpenMTManager.m b/MiddleMe/OpenMultitouchSupport/OpenMTManager.m index 3336693..6c709ff 100644 --- a/MiddleMe/OpenMultitouchSupport/OpenMTManager.m +++ b/MiddleMe/OpenMultitouchSupport/OpenMTManager.m @@ -215,16 +215,8 @@ static void contactEventHandler(MTDeviceRef eventDevice, MTTouch eventTouches[], OpenMTEvent *event = OpenMTEvent.new; event.touches = touches; - event.deviceID = (int)eventDevice; - event.frameID = frame; - event.timestamp = timestamp; [OpenMTManager.sharedManager handleMultitouchEvent:event]; } -//static void pathEventHandler(MTDeviceRef device, long pathID, long state, MTTouch* touch) { -// OpenMTTouch *otouch = [[OpenMTTouch alloc] initWithMTTouch:touch]; -// [OpenMTManager.sharedManager handlePathEvent:otouch]; -//} - @end diff --git a/MiddleMe/OpenMultitouchSupport/OpenMTTouch.h b/MiddleMe/OpenMultitouchSupport/OpenMTTouch.h index 23bb2ac..24982d2 100644 --- a/MiddleMe/OpenMultitouchSupport/OpenMTTouch.h +++ b/MiddleMe/OpenMultitouchSupport/OpenMTTouch.h @@ -12,31 +12,11 @@ #import #import "OpenMTInternal.h" -typedef NS_ENUM(NSUInteger, OpenMTState) { - OpenMTStateNotTouching = 0, - OpenMTStateStarting, - OpenMTStateHovering, - OpenMTStateMaking, - OpenMTStateTouching, - OpenMTStateBreaking, - OpenMTStateLingering, - OpenMTStateLeaving -}; - @interface OpenMTTouch: NSObject - (id)initWithMTTouch:(MTTouch *)touch; -//@property (assign, readonly) int identifier; -//@property (assign, readonly) OpenMTState state; @property (assign, readonly) float posX, posY; -//@property (assign, readonly) float velX, velY; -//@property (assign, readonly) float total; -//@property (assign, readonly) float pressure; -//@property (assign, readonly) float minorAxis, majorAxis; -//@property (assign, readonly) float angle; -//@property (assign, readonly) float density; -//@property (assign, readonly) double timestamp; @end diff --git a/MiddleMe/OpenMultitouchSupport/OpenMTTouch.m b/MiddleMe/OpenMultitouchSupport/OpenMTTouch.m index 2f6c744..6f9a72d 100644 --- a/MiddleMe/OpenMultitouchSupport/OpenMTTouch.m +++ b/MiddleMe/OpenMultitouchSupport/OpenMTTouch.m @@ -12,27 +12,11 @@ @implementation OpenMTTouch - (id)initWithMTTouch:(MTTouch *)touch { if (self = [super init]) { -// _identifier = touch->identifier; -// _state = touch->state; _posX = touch->normalizedPosition.position.x; _posY = touch->normalizedPosition.position.y; -// _velX = touch->normalizedPosition.velocity.x; -// _velY = touch->normalizedPosition.velocity.y; -// _total = touch->total; -// _pressure = touch->pressure; -// _minorAxis = touch->minorAxis; -// _majorAxis = touch->majorAxis; -// _angle = touch->angle; -// _density = touch->density; -// _timestamp = touch->timestamp; } return self; } -//- (NSString *)description { -// return [NSString stringWithFormat:@"ID: %i, State: %lu, Position: [%f, %f], Velocity: [%f, %f], Total: %f, Pressure: %f, Minor: %f, Major: %f, Angle: %f, Density: %f, Timestamp: %lf", -// _identifier, _state, _posX, _posY, _velX, _velY, _total, _pressure, _minorAxis, _majorAxis, _angle, _density, _timestamp]; -//} - @end