sugarcube 1.3.1 → 1.3.2

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.
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- sugarcube (1.3.1)
4
+ sugarcube (1.3.2)
5
5
 
6
6
  GEM
7
7
  remote: https://rubygems.org/
@@ -1,3 +1,3 @@
1
1
  module SugarCube
2
- Version = '1.3.1'
2
+ Version = '1.3.2'
3
3
  end
@@ -12,7 +12,7 @@ class UIControl
12
12
  # button.on(:touch) { |sender,touch_event| my_code }
13
13
  def on(*events, &block)
14
14
  handler = SugarCube::UIControlCallbackHelper.new
15
- handler.callback = WeakRef.new(block)
15
+ handler.callback = block
16
16
 
17
17
  events.each do |event|
18
18
  event = event.uicontrolevent if event.respond_to?(:uicontrolevent)
@@ -66,7 +66,7 @@ private
66
66
  self.sugarcube_callbacks[notication] << NSNotificationCenter.defaultCenter.addObserverForName(notication,
67
67
  object: self,
68
68
  queue: NSOperationQueue.mainQueue,
69
- usingBlock: WeakRef.new(block))
69
+ usingBlock: block)
70
70
  end
71
71
 
72
72
  def _offEventNotification(nofication)
@@ -193,7 +193,7 @@ private
193
193
  self.addGestureRecognizer(recognizer)
194
194
 
195
195
  @sugarcube_recognizers = {} unless @sugarcube_recognizers
196
- @sugarcube_recognizers[recognizer] = WeakRef.new(proc)
196
+ @sugarcube_recognizers[recognizer] = proc
197
197
 
198
198
  recognizer
199
199
  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.3.1
4
+ version: 1.3.2
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors: