sugarcube 1.3.1 → 1.3.2
Sign up to get free protection for your applications and to get access to all the features.
data/Gemfile.lock
CHANGED
data/lib/sugarcube/version.rb
CHANGED
@@ -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 =
|
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:
|
69
|
+
usingBlock: block)
|
70
70
|
end
|
71
71
|
|
72
72
|
def _offEventNotification(nofication)
|