forked from Blendman974/faceclaw
Port fixes from Glassly fork
This commit is contained in:
1 parent
4973fd2aea
commit
188bdff0d1
4 files changed
+41
-24
No files matched your search
@@ -164,6 +164,9 @@ class BleProtocol {
|
||||
|
||||
const val EVENT_HEAD_UP: Int = 12
|
||||
|
||||
/** Faceclaw/38: IMU head-down (the head returning after a lift), forwarded while a page is up. */
|
||||
const val EVENT_HEAD_DOWN: Int = 15
|
||||
|
||||
const val EVENT_SOURCE_GLASSES_R: Int = 1
|
||||
|
||||
const val EVENT_SOURCE_RING: Int = 2
|
||||
|
||||
+8
@@ -1570,6 +1570,14 @@ class GlassesSessionCore(
|
||||
// deferred head-up wake produces from a dark display.
|
||||
decoded = G2Event("display-wake", "", BleProtocol.EVENT_HEAD_UP, decoded.eventSource, 0)
|
||||
logLine("head-up forwarded by CFW while page on screen")
|
||||
} else if (decoded != null
|
||||
&& "sys-event" == decoded.kind
|
||||
&& decoded.eventType == BleProtocol.EVENT_HEAD_DOWN) {
|
||||
// Faceclaw/38 also forwards the head coming back down. Nothing
|
||||
// uses it yet; as an unknown input it would count as activity
|
||||
// and keep the screen awake, so drop it here.
|
||||
logLine("head-down forwarded by CFW (ignored)")
|
||||
decoded = null
|
||||
}
|
||||
event = decoded
|
||||
if (decoded != null) {
|
||||
|
||||
Reference in new issue
Block a user