fusuma-plugin-keypress 0.2.0 → 0.2.1

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: b88b42e81a482a2aed17b29813b519f561566943f36fb38f71b433e13fdd73eb
4
- data.tar.gz: c3700f1b2a0b3376a593c7862c9c04247b1a81811e23661984b50ab4be09de3b
3
+ metadata.gz: e119f537a5a9039591ab5434fbef52509f91af1531308d1ec6e35663fa42593e
4
+ data.tar.gz: a65839a395f388f0c3f0772046838f3897efac6f43467f9808e6ee79db543383
5
5
  SHA512:
6
- metadata.gz: 13b9a2be307562d6b76a3e157e1eb170168f4396a0078ec5b6eb11ce33c98f3b41790144f665fcf483a9f1e6926b860b744a204b335e2cb310d67f8ca82097d3
7
- data.tar.gz: 99b3c0d90b6baa117b77a9c188843dd8e0cbc387225681e20dfc7d5f881df0e5fb3134e795a1a7a156b41186ba9828f5a61e133ad55875391ab2e36ac3d69f14
6
+ metadata.gz: b273ceac36e18505e04acb3c439f8f114b2886a6eba939f2876d5ca5949599347a4b087ff3f72c05f93eb1621a64d8a4902b493993cf848205fdeaffb1b4dbff
7
+ data.tar.gz: 730630bd6f215507ad26d4c4ee8b6dd10e40dc5ba133a400da35eebf92414751fd398b2a874f9a63ab9df8a0daaa12a45fa7b28eaa341efc3d62ca9f3b93fe12
data/.gitignore CHANGED
@@ -10,3 +10,4 @@
10
10
 
11
11
  # rspec failure tracking
12
12
  .rspec_status
13
+ .ruby-version
data/README.md CHANGED
@@ -4,7 +4,7 @@
4
4
  Keyboard + Touchpad combination plugin for [Fusuma](https://github.com/iberianpig/fusuma)
5
5
 
6
6
  * Customize gestures with modifier keys
7
- * Supports multiple modifier key combinations
7
+ * Supports multiple modifier key combinations
8
8
 
9
9
  ## Installation
10
10
 
@@ -18,24 +18,25 @@ This plugin requires [Fusuma](https://github.com/iberianpig/fusuma#update) versi
18
18
  $ sudo gem install fusuma-plugin-keypress
19
19
  ```
20
20
 
21
- ### Add show-keycode option
21
+ ### Add show-keycodes option
22
22
 
23
23
  Open `~/.config/fusuma/config.yml` and add the following code at the bottom.
24
24
 
25
25
  ```yaml
26
- plugin:
26
+ plugin:
27
27
  inputs:
28
28
  libinput_command_input:
29
- show-keycode: true
29
+ show-keycodes: true
30
30
  ```
31
31
 
32
- **NOTE: fusuma can read your keyboard inputs if show-keycode option is true**
32
+ **NOTE: fusuma can read your keyboard inputs if show-keycodes option is true**
33
33
 
34
34
  ## Properties
35
35
 
36
36
  Add `keypress:` property in `~/.config/fusuma/config.yml`.
37
37
 
38
38
  Keys following are available for `keypress`.
39
+
39
40
  * `CAPSLOCK`
40
41
  * `LEFTALT`
41
42
  * `LEFTCTRL`
@@ -68,15 +69,15 @@ swipe:
68
69
  LEFTMETA+LEFTALT:
69
70
  command: 'xdotool key --clearmodifiers XF86AudioLowerVolume'
70
71
 
71
- plugin:
72
+ plugin:
72
73
  inputs:
73
74
  libinput_command_input:
74
- show-keycode: true
75
+ show-keycodes: true
75
76
  ```
76
77
 
77
78
  * Swipe up/down with four fingers while keypress LEFTMETA key to change display brightnes .
78
79
  * Swipe up/down with four fingers while keypress LEFTMETA and LEFTALT keys to change audio volume.
79
- - If you want to combine a gesture with two keys, combine modifier keys with `+`
80
+ - If you want to combine a gesture with two keys, combine modifier keys with `+`
80
81
 
81
82
  ## Contributing
82
83
 
@@ -15,14 +15,15 @@ module Fusuma
15
15
 
16
16
  return if buffer.empty?
17
17
 
18
- records = buffer.events.map(&:record)
19
-
20
- index = create_index(records: records)
18
+ records = buffer.events.select do |e|
19
+ e.record.status == 'pressed'
20
+ end.map(&:record)
21
21
 
22
22
  index_record = Events::Records::IndexRecord.new(
23
- index: index,
23
+ index: create_index(records: records),
24
24
  position: :surfix
25
25
  )
26
+
26
27
  create_event(record: index_record)
27
28
  end
28
29
 
@@ -3,7 +3,7 @@
3
3
  module Fusuma
4
4
  module Plugin
5
5
  module Keypress
6
- VERSION = '0.2.0'
6
+ VERSION = '0.2.1'
7
7
  end
8
8
  end
9
9
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fusuma-plugin-keypress
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.0
4
+ version: 0.2.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - iberianpig
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2020-03-18 00:00:00.000000000 Z
11
+ date: 2020-04-15 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: fusuma
@@ -209,7 +209,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
209
209
  - !ruby/object:Gem::Version
210
210
  version: '0'
211
211
  requirements: []
212
- rubygems_version: 3.0.6
212
+ rubygems_version: 3.1.2
213
213
  signing_key:
214
214
  specification_version: 4
215
215
  summary: Keypress plugin for Fusuma