ruby-anything 0.0.3 → 0.0.4

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: 2f91218523e649abb9017e748299d868ad5e833f
4
- data.tar.gz: c0c8b9882a64aeca3e762b469626f824387e2a9c
3
+ metadata.gz: 4dd81e98faed770f1e10c8f68e6f0785e8983948
4
+ data.tar.gz: 9f27b060abd00d2e236f42c26acaab28a88b4d67
5
5
  SHA512:
6
- metadata.gz: 884d5ea53e184a7d76a1bb002eb57a191922a6992354a48536dddc9f97b1474205105649c67a3a163f70be0e60d47bf91c12882cf7ef160852e7863139aea69c
7
- data.tar.gz: c4aca462bd34cf78f3b1cc0d8b01a3e14ef1f8774ec26e1933199e04b6ae662f1cdb319c4fc5b3523788a7fc3436c2ebcc8e07ccf2972c973bdf80ef1ab63592
6
+ metadata.gz: 9b3c1141a5b71996544597063304cb7a616a6e40f73c3be12a328145acacba9913a89cac2308af8c987fd300783e194894cd86d8e84b39cffaa35bf63e6d5eef
7
+ data.tar.gz: 2837931b12eec418137afe0affbf1ff877a85329693bbf3a3a29615a7fc28d6d172a494e1e81649b5cd59532765c4384b82945abedf6f369f6e50fda9f6e3925
@@ -13,6 +13,7 @@ module RubyAnything
13
13
  left: [ Curses::Key::LEFT, 2 ],
14
14
  right: [ Curses::Key::RIGHT, 6 ],
15
15
  enter: [ 10 ],
16
+ backspace: [ 127 ],
16
17
  interrupt: [ 3, 4 ]
17
18
  }
18
19
  # Public: initialize BaseWindow
@@ -1,3 +1,3 @@
1
1
  module RubyAnything
2
- VERSION = "0.0.3"
2
+ VERSION = "0.0.4"
3
3
  end
@@ -19,19 +19,20 @@ module RubyAnything
19
19
  # require 'logger'
20
20
  # @logger ||= Logger.new('/tmp/ch.txt')
21
21
  # @logger.info ch
22
+
22
23
  case ch
23
24
  when *KEYS[:left]
24
25
  left
25
26
  when *KEYS[:right]
26
27
  right
27
- when Curses::Key::BACKSPACE
28
- delete
28
+ when *KEYS[:backspace]
29
+ backspace
29
30
  when String
30
31
  insert ch
31
32
  end
32
33
  end
33
34
 
34
- def delete
35
+ def backspace
35
36
  cursor.left
36
37
  text.delete cursor.x
37
38
  @parent.filter text.to_s
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ruby-anything
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.3
4
+ version: 0.0.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Takatoshi Matsumoto
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2013-12-09 00:00:00.000000000 Z
11
+ date: 2013-12-12 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rspec