sugarcube 1.6.1 → 1.6.2

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: dfd01b6a399450ae3f6505e720773a82d9eda7e7
4
- data.tar.gz: e8d3ba59a5979aae34b4557a7d1e430967b73676
3
+ metadata.gz: 5d9eed068aefa36110d9d6c3ed2bc8112130cbf5
4
+ data.tar.gz: 5db0b4efefcc5461ee1c3acf98f7b6b9a414b4ad
5
5
  SHA512:
6
- metadata.gz: 3030d35dc2928c73c4a92a25ab5eb3a342ae82d14310fcce3177027edc52152a23a77a151f1858aeaa16f92c300aa86ad482abde786b590eec9b3015c00fa634
7
- data.tar.gz: fd8129000d4b66904a045e73962765168a4ba94f82291948fb2177635553eeb6314ad29b29956540b3fe5b306fbc55f98389776a0906bcde7b9674c7434f9dbf
6
+ metadata.gz: cd9bee65e81c76b809712b67d0c6f5611375333a14cdd38ea1dab06b3fbe4bed2a03fbeef3f4caa20d249b98b85b1376c98484dd3b740722fb3fcfec35adaea5
7
+ data.tar.gz: dbe5117f12f8fdd0f907dfce17558b00112c36be5957ee1bf4c37b1d88028faacee6a2237735f2f70233f5a86d667e30b0603806243d56acfcf8984776084b72
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- sugarcube (1.6.1)
4
+ sugarcube (1.6.2)
5
5
 
6
6
  GEM
7
7
  remote: https://rubygems.org/
data/README.md CHANGED
@@ -297,7 +297,7 @@ button.on(:touch_up_outside, :touch_cancel) { |event|
297
297
 
298
298
  # remove handlers
299
299
  button.off(:touch, :touch_up_outside, :touch_cancel)
300
- button.off(:all)
300
+ button.off # all events
301
301
  ```
302
302
 
303
303
  You can only remove handlers by "type", not by the action. e.g. If you bind
@@ -44,10 +44,6 @@ class CAAnimation
44
44
  elsif options.key?(:path)
45
45
  path = options[:path]
46
46
  if path.is_a?(UIBezierPath)
47
- p = UIBezierPath.bezierPath
48
- p.moveToPoint([0, 0])
49
- p.addCurveToPoint([1, 0], controlPoint1: [0.9, 0], controlPoint2: [0.1, 0])
50
-
51
47
  path = path.CGPath
52
48
  end
53
49
  animation.path = path
@@ -58,19 +58,19 @@ class UIActionSheet
58
58
  if buttons.is_a?(NSDictionary)
59
59
  button_titles = buttons.keys
60
60
  if buttons.key?(:cancel)
61
- args << (buttons[:cancel] && buttons[:cancel].localized)
61
+ args << (buttons[:cancel] && NSBundle.mainBundle.localizedStringForKey(buttons[:cancel], value: nil, table: nil))
62
62
  else
63
63
  args << nil
64
64
  end
65
65
  if buttons.key?(:destructive)
66
- args << (buttons[:destructive] && buttons[:destructive].localized)
66
+ args << (buttons[:destructive] && NSBundle.mainBundle.localizedStringForKey(buttons[:destructive], value: nil, table: nil))
67
67
  else
68
68
  args << nil
69
69
  end
70
- args.concat(buttons.select { |k, m| k != :cancel && k != :destructive }.map { |k, m| m && m.localized })
70
+ args.concat(buttons.select { |k, m| k != :cancel && k != :destructive }.map { |k, m| m && NSBundle.mainBundle.localizedStringForKey(m, value: nil, table: nil) })
71
71
  else
72
72
  button_titles = buttons
73
- args.concat(buttons.map { |m| m && m.localized })
73
+ args.concat(buttons.map { |m| m && NSBundle.mainBundle.localizedStringForKey(m, value: nil, table: nil) })
74
74
  end
75
75
  args << nil # otherButtonTitles:..., nil
76
76
 
@@ -67,14 +67,14 @@ class UIAlertView
67
67
  if buttons.is_a?(NSDictionary)
68
68
  button_titles = buttons.keys
69
69
  if buttons.key?(:cancel)
70
- args << (buttons[:cancel] && buttons[:cancel].localized)
70
+ args << (buttons[:cancel] && NSBundle.mainBundle.localizedStringForKey(buttons[:cancel], value: nil, table: nil))
71
71
  else
72
72
  args << nil
73
73
  end
74
- args.concat(buttons.select { |k, m| k != :cancel }.map { |k, m| m && m.localized })
74
+ args.concat(buttons.select { |k, m| k != :cancel }.map { |k, m| m && NSBundle.mainBundle.localizedStringForKey(m, value: nil, table: nil) })
75
75
  else
76
76
  button_titles = buttons
77
- args.concat(buttons.map { |m| m && m.localized })
77
+ args.concat(buttons.map { |m| m && NSBundle.mainBundle.localizedStringForKey(m, value: nil, table: nil) })
78
78
  end
79
79
  delegate.buttons = button_titles
80
80
  args << nil # otherButtonTitles:..., nil
@@ -3,7 +3,7 @@ class NSString
3
3
  # This can be called as `"Hello".localized` or `"Hello"._`. The `str._`
4
4
  # syntax is meant to be reminiscent of gettext-style `_(str)`.
5
5
  def localized(value=nil, table=nil)
6
- @localized = NSBundle.mainBundle.localizedStringForKey(self, value:value, table:table)
6
+ @localized = NSBundle.mainBundle.localizedStringForKey(self, value: value, table: table)
7
7
  end
8
8
  alias _ localized
9
9
 
@@ -1,100 +1,90 @@
1
- module Kernel
1
+ module MotionRepl
2
2
 
3
- private
4
3
  def adjust(*args)
5
4
  SugarCube::Adjust.adjust(*args)
6
5
  end
7
- def a(*args)
8
- SugarCube::Adjust.adjust(*args)
6
+ alias a adjust
7
+
8
+ def tree(*args)
9
+ SugarCube::Adjust.tree(*args)
9
10
  end
10
- def frame(*args)
11
- SugarCube::Adjust.frame(*args)
11
+
12
+ def root(*args)
13
+ SugarCube::Adjust.root(*args)
12
14
  end
13
- def f(*args)
15
+
16
+ def frame(*args)
14
17
  SugarCube::Adjust.frame(*args)
15
18
  end
19
+ alias f frame
20
+
16
21
  def left(*args)
17
22
  SugarCube::Adjust.left(*args)
18
23
  end
19
- def l(*args)
20
- SugarCube::Adjust.left(*args)
21
- end
24
+ alias l left
25
+
22
26
  def right(*args)
23
27
  SugarCube::Adjust.right(*args)
24
28
  end
25
- def r(*args)
26
- SugarCube::Adjust.right(*args)
27
- end
29
+ alias r right
30
+
28
31
  def up(*args)
29
32
  SugarCube::Adjust.up(*args)
30
33
  end
31
- def u(*args)
32
- SugarCube::Adjust.up(*args)
33
- end
34
+ alias u up
35
+
34
36
  def down(*args)
35
37
  SugarCube::Adjust.down(*args)
36
38
  end
37
- def d(*args)
38
- SugarCube::Adjust.down(*args)
39
- end
39
+ alias d down
40
+
40
41
  def origin(*args)
41
42
  SugarCube::Adjust.origin(*args)
42
43
  end
43
- def o(*args)
44
- SugarCube::Adjust.origin(*args)
45
- end
44
+ alias o origin
45
+
46
46
  def thinner(*args)
47
47
  SugarCube::Adjust.thinner(*args)
48
48
  end
49
- def n(*args)
50
- SugarCube::Adjust.thinner(*args)
51
- end
49
+ alias n thinner
50
+
52
51
  def wider(*args)
53
52
  SugarCube::Adjust.wider(*args)
54
53
  end
55
- def w(*args)
56
- SugarCube::Adjust.wider(*args)
57
- end
54
+ alias w wider
55
+
58
56
  def shorter(*args)
59
57
  SugarCube::Adjust.shorter(*args)
60
58
  end
61
- def s(*args)
62
- SugarCube::Adjust.shorter(*args)
63
- end
59
+ alias s shorter
60
+
64
61
  def taller(*args)
65
62
  SugarCube::Adjust.taller(*args)
66
63
  end
67
- def t(*args)
68
- SugarCube::Adjust.taller(*args)
69
- end
64
+ alias t taller
65
+
70
66
  def size(*args)
71
67
  SugarCube::Adjust.size(*args)
72
68
  end
73
- def z(*args)
74
- SugarCube::Adjust.size(*args)
75
- end
69
+ alias z size
70
+
76
71
  def center(*args)
77
72
  SugarCube::Adjust.center(*args)
78
73
  end
79
- def c(*args)
80
- SugarCube::Adjust.center(*args)
81
- end
74
+ alias c center
75
+
82
76
  def shadow(*args)
83
77
  SugarCube::Adjust.shadow(*args)
84
78
  end
85
- def h(*args)
86
- SugarCube::Adjust.shadow(*args)
87
- end
88
- def tree(*args)
89
- SugarCube::Adjust.tree(*args)
90
- end
91
- def root(*args)
92
- SugarCube::Adjust.root(*args)
93
- end
79
+ alias h shadow
80
+
81
+
94
82
  def restore(*args)
95
83
  SugarCube::Adjust.restore(*args)
96
84
  end
85
+
97
86
  def blink(*args)
98
87
  SugarCube::Adjust.blink(*args)
99
88
  end
89
+
100
90
  end
@@ -1,3 +1,3 @@
1
1
  module SugarCube
2
- Version = '1.6.1'
2
+ Version = '1.6.2'
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: sugarcube
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.6.1
4
+ version: 1.6.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Colin T.A. Gray
@@ -11,7 +11,7 @@ authors:
11
11
  autorequire:
12
12
  bindir: bin
13
13
  cert_chain: []
14
- date: 2014-05-13 00:00:00.000000000 Z
14
+ date: 2014-05-27 00:00:00.000000000 Z
15
15
  dependencies: []
16
16
  description: |
17
17
  == Description
@@ -145,7 +145,7 @@ files:
145
145
  - lib/sugarcube-pointer.rb
146
146
  - lib/sugarcube-pointer/nsarray.rb
147
147
  - lib/sugarcube-repl.rb
148
- - lib/sugarcube-repl/kernel.rb
148
+ - lib/sugarcube-repl/repl.rb
149
149
  - lib/sugarcube-resources.rb
150
150
  - lib/sugarcube-timer.rb
151
151
  - lib/sugarcube-timer/timer.rb