Add touch pressure information for touch events on iOS (#1090)

* Add touch pressure information for touch events on iOS

* Add a variant for calibrated touch pressure
This commit is contained in:
Aleksi Juvani
2019-08-14 01:12:13 +03:00
committed by Osspial
parent 8e73287646
commit 1366dc326a
10 changed files with 131 additions and 14 deletions

View File

@@ -39,6 +39,7 @@ pub(crate) fn implement_touch<T: 'static>(
),
phase: TouchPhase::Started,
location: (x, y).into(),
force: None, // TODO
id: id as u64,
}),
wid,
@@ -61,6 +62,7 @@ pub(crate) fn implement_touch<T: 'static>(
),
phase: TouchPhase::Ended,
location: pt.location.into(),
force: None, // TODO
id: id as u64,
}),
pt.wid,
@@ -78,6 +80,7 @@ pub(crate) fn implement_touch<T: 'static>(
),
phase: TouchPhase::Moved,
location: (x, y).into(),
force: None, // TODO
id: id as u64,
}),
pt.wid,
@@ -94,6 +97,7 @@ pub(crate) fn implement_touch<T: 'static>(
),
phase: TouchPhase::Cancelled,
location: pt.location.into(),
force: None, // TODO
id: pt.id as u64,
}),
pt.wid,

View File

@@ -918,6 +918,7 @@ impl<T: 'static> EventProcessor<T> {
device_id: mkdid(xev.deviceid),
phase,
location,
force: None, // TODO
id: xev.detail as u64,
}),
})