uinput-keyboard 0.3 → 0.3.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 055f65c464f1c5f9310cc2d31288a1d36409830f
4
- data.tar.gz: 120db4ff5630594825c319fba7d59b1108a20826
3
+ metadata.gz: 05a16fc441a306844e0daf112c1c69668b5ffd05
4
+ data.tar.gz: ebc6fdc8fb5082947f5db997652660d3b790b203
5
5
  SHA512:
6
- metadata.gz: 0c4e5fb9a2588d4defddae092d735e266e6d153c2893b504f364f9452a5cf90addceac725883ac7979f822d27fa22fa8483d16c589131f73feb192fdf014d08a
7
- data.tar.gz: 755ef4927a1d0bdb840e1d0760d04e452502ce4e9568a2898c67b45ba48185c747e41e74cba8275524010e9fb2cc713932c80cf62a447bdebf00e544556f735c
6
+ metadata.gz: 6fa9084cf61c49a6ae91796ecfc11663bcd0e8046e6a9db08933afc0abef7c4ddec5037445f6c755974f52c4a170b1fc1a51b0503af1ea9458373b7df48bf025
7
+ data.tar.gz: 84dd8bbf70bb182ea9f7fffa87adc01f5aee64fa3e6f6f42883c3d52aee70a4c72534d175e003d7206e4943694f04ff72a385df9237cc2b434d092c9849f663f
@@ -1,11 +1,11 @@
1
- require 'bundler/setup'
2
1
  require 'uinput/device'
3
2
  require 'xkbcommon'
4
- require "uinput/keyboard/version"
5
- require 'uinput/keyboard/system_initializer'
6
3
 
7
4
  module Uinput
8
5
  class Keyboard < Device
6
+ require_relative "keyboard/version"
7
+ require_relative 'keyboard/initializer'
8
+
9
9
  class << self
10
10
  def keymap(names)
11
11
  Xkbcommon::Context.new.keymap_from_names(names)
@@ -1,6 +1,6 @@
1
1
  module Uinput
2
- class Keyboard < Device
3
- class SystemInitializer < Device::SystemInitializer
2
+ class Keyboard
3
+ class Initializer < Device::Initializer
4
4
  def initialize(keyboard, &block)
5
5
  @keyboard = keyboard
6
6
  super(keyboard, &block)
@@ -1,3 +1,5 @@
1
1
  module Uinput
2
- Keyboard_VERSION = "0.3"
2
+ class Keyboard
3
+ VERSION = "0.3.1"
4
+ end
3
5
  end
data/test.rb CHANGED
@@ -1,12 +1,9 @@
1
- $LOAD_PATH.unshift(File.join(File.dirname(__FILE__), 'lib'))
2
- require 'uinput/keyboard'
1
+ require_relative 'lib/uinput/keyboard'
3
2
 
4
3
  begin
5
4
  keymap = Uinput::Keyboard.keymap(rules: 'evdev', model: 'pc104', layout: 'de', variant: 'nodeadkeys')
6
5
  keyboard = Uinput::Keyboard.new(keymap)
7
6
 
8
- sleep 1
9
-
10
7
  puts keyboard.sys_path
11
8
  puts keyboard.dev_path
12
9
 
@@ -14,8 +11,10 @@ begin
14
11
  puts symbols.inspect
15
12
  puts keyboard.symbols_to_keycodes(*symbols).inspect
16
13
 
17
- puts keyboard.type('date').inspect
18
- puts keyboard.tap(:Return).inspect
14
+ sleep 0.1 # the window manager needs some time to register the new keyboard
15
+
16
+ keyboard.type('date')
17
+ keyboard.tap(:Return)
19
18
 
20
19
  #keyboard.type('Ѣ')
21
20
  #('a'..'z').each{ |char| keyboard.tap(char) }
@@ -5,7 +5,7 @@ require 'uinput/keyboard/version'
5
5
 
6
6
  Gem::Specification.new do |spec|
7
7
  spec.name = "uinput-keyboard"
8
- spec.version = Uinput::Keyboard_VERSION
8
+ spec.version = Uinput::Keyboard::VERSION
9
9
  spec.authors = ["Christopher Aue"]
10
10
  spec.email = ["mail@christopheraue.net"]
11
11
 
@@ -16,8 +16,8 @@ Gem::Specification.new do |spec|
16
16
  spec.files = `git ls-files -z`.split("\x0").reject { |f| f.match(%r{^(test|spec|features)/}) }
17
17
  spec.require_paths = ["lib"]
18
18
 
19
+ spec.add_dependency "uinput-device", "~> 0.4"
20
+ spec.add_dependency "xkbcommon", "~> 0.1"
19
21
  spec.add_development_dependency "bundler", "~> 1.8"
20
22
  spec.add_development_dependency "rake", "~> 10.0"
21
- spec.add_dependency "uinput-device", "~> 0.2"
22
- spec.add_dependency "xkbcommon", "~> 0.1"
23
23
  end
metadata CHANGED
@@ -1,71 +1,71 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: uinput-keyboard
3
3
  version: !ruby/object:Gem::Version
4
- version: '0.3'
4
+ version: 0.3.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Christopher Aue
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-12-19 00:00:00.000000000 Z
11
+ date: 2017-04-18 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
- name: bundler
14
+ name: uinput-device
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
17
  - - "~>"
18
18
  - !ruby/object:Gem::Version
19
- version: '1.8'
20
- type: :development
19
+ version: '0.4'
20
+ type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
24
  - - "~>"
25
25
  - !ruby/object:Gem::Version
26
- version: '1.8'
26
+ version: '0.4'
27
27
  - !ruby/object:Gem::Dependency
28
- name: rake
28
+ name: xkbcommon
29
29
  requirement: !ruby/object:Gem::Requirement
30
30
  requirements:
31
31
  - - "~>"
32
32
  - !ruby/object:Gem::Version
33
- version: '10.0'
34
- type: :development
33
+ version: '0.1'
34
+ type: :runtime
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
38
  - - "~>"
39
39
  - !ruby/object:Gem::Version
40
- version: '10.0'
40
+ version: '0.1'
41
41
  - !ruby/object:Gem::Dependency
42
- name: uinput-device
42
+ name: bundler
43
43
  requirement: !ruby/object:Gem::Requirement
44
44
  requirements:
45
45
  - - "~>"
46
46
  - !ruby/object:Gem::Version
47
- version: '0.2'
48
- type: :runtime
47
+ version: '1.8'
48
+ type: :development
49
49
  prerelease: false
50
50
  version_requirements: !ruby/object:Gem::Requirement
51
51
  requirements:
52
52
  - - "~>"
53
53
  - !ruby/object:Gem::Version
54
- version: '0.2'
54
+ version: '1.8'
55
55
  - !ruby/object:Gem::Dependency
56
- name: xkbcommon
56
+ name: rake
57
57
  requirement: !ruby/object:Gem::Requirement
58
58
  requirements:
59
59
  - - "~>"
60
60
  - !ruby/object:Gem::Version
61
- version: '0.1'
62
- type: :runtime
61
+ version: '10.0'
62
+ type: :development
63
63
  prerelease: false
64
64
  version_requirements: !ruby/object:Gem::Requirement
65
65
  requirements:
66
66
  - - "~>"
67
67
  - !ruby/object:Gem::Version
68
- version: '0.1'
68
+ version: '10.0'
69
69
  description:
70
70
  email:
71
71
  - mail@christopheraue.net
@@ -81,7 +81,7 @@ files:
81
81
  - README.md
82
82
  - Rakefile
83
83
  - lib/uinput/keyboard.rb
84
- - lib/uinput/keyboard/system_initializer.rb
84
+ - lib/uinput/keyboard/initializer.rb
85
85
  - lib/uinput/keyboard/version.rb
86
86
  - test.rb
87
87
  - uinput-keyboard.gemspec
@@ -105,8 +105,9 @@ required_rubygems_version: !ruby/object:Gem::Requirement
105
105
  version: '0'
106
106
  requirements: []
107
107
  rubyforge_project:
108
- rubygems_version: 2.4.5.1
108
+ rubygems_version: 2.5.1
109
109
  signing_key:
110
110
  specification_version: 4
111
111
  summary: Ruby wrapper around uinput to create a virtual keyboard.
112
112
  test_files: []
113
+ has_rdoc: