xinput_wrapperplus 0.4.2 → 0.4.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- checksums.yaml.gz.sig +0 -0
- data.tar.gz.sig +0 -0
- data/lib/xinput_wrapperplus.rb +14 -5
- metadata +2 -2
- metadata.gz.sig +0 -0
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 17f7c9962bda5c450ccf2255914fcc3d578f4bfd1881c4297b728764afcaeb0d
|
4
|
+
data.tar.gz: f9e67bdc4325d252e5dacb74b75c2c0ebae60252d52c2900e577c2d0cadc0e23
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 5352fc684255d867db2432619244b302e6a34a98acc536402a4da073b3ee660667caf33c307fdfffc860dd886f2cca6f6168c4d78978d541c5689e427f4b37e4
|
7
|
+
data.tar.gz: 170ed7c1a421a4f0a0c1ac1b86d7b2cec01ff72169d48725eb8e2051e3dbb5aa80e353e33ec6965e82b81a203dce4f6b83f80b56627b2c8c0780dbbdd77e8d19
|
checksums.yaml.gz.sig
CHANGED
Binary file
|
data.tar.gz.sig
CHANGED
Binary file
|
data/lib/xinput_wrapperplus.rb
CHANGED
@@ -9,18 +9,22 @@ require 'xinput_wrapper'
|
|
9
9
|
|
10
10
|
class XInputWrapperPlus < XInputWrapper
|
11
11
|
|
12
|
-
def initialize(
|
12
|
+
def initialize(host: 'sps', port: '59000',
|
13
13
|
topic: 'input', verbose: true, lookup: {},
|
14
14
|
debug: false, capture_all: false, keys: [],
|
15
|
-
keypress_detection: true)
|
15
|
+
keypress_detection: true, motion_detection: true)
|
16
16
|
|
17
|
-
|
17
|
+
puts 'before super'
|
18
|
+
super(verbose: verbose, lookup: lookup,
|
18
19
|
debug: debug, keys: keys)
|
20
|
+
puts 'after super'
|
19
21
|
|
20
22
|
@topic, @capture_all = topic, capture_all
|
21
23
|
@keypress_detection = keypress_detection
|
22
|
-
|
24
|
+
@motion_detection = motion_detection
|
25
|
+
|
23
26
|
@sps = SPSPub.new host: host, port: port
|
27
|
+
|
24
28
|
@sk = SecretKnock.new short_delay: 0.25, long_delay: 0.5,
|
25
29
|
external: self, verbose: verbose, debug: debug
|
26
30
|
@sk.detect timeout: 0.7
|
@@ -86,6 +90,11 @@ class XInputWrapperPlus < XInputWrapper
|
|
86
90
|
puts "on_mousemove() x: %s y: %s" % [x, y]
|
87
91
|
end
|
88
92
|
|
93
|
+
if @motion_detection and (Time.now > @t2 + 30) then
|
94
|
+
message 'motion detected', nil
|
95
|
+
@t2 = Time.now
|
96
|
+
end
|
97
|
+
=begin
|
89
98
|
@timer.exit if @timer
|
90
99
|
|
91
100
|
@a << [x,y]
|
@@ -100,7 +109,7 @@ class XInputWrapperPlus < XInputWrapper
|
|
100
109
|
@a = []
|
101
110
|
|
102
111
|
end
|
103
|
-
|
112
|
+
=end
|
104
113
|
|
105
114
|
end
|
106
115
|
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: xinput_wrapperplus
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.4.
|
4
|
+
version: 0.4.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- James Robertson
|
@@ -35,7 +35,7 @@ cert_chain:
|
|
35
35
|
MAr0EaAbP4GPbdRnYZObrq03xJQOARWVRbH726l6usXEpiepoBKFXfqGNXX6DDt/
|
36
36
|
2f3lRa47HGk7I26OxNboAPZQ
|
37
37
|
-----END CERTIFICATE-----
|
38
|
-
date: 2020-08-
|
38
|
+
date: 2020-08-28 00:00:00.000000000 Z
|
39
39
|
dependencies:
|
40
40
|
- !ruby/object:Gem::Dependency
|
41
41
|
name: sps-pub
|
metadata.gz.sig
CHANGED
Binary file
|