Class: SugarCube::UIAlertControllerCallbackHelper
- Defined in:
- lib/ios/sugarcube-factories/uialertcontroller.rb
Instance Method Summary collapse
- #call(button) ⇒ Object
-
#initialize(callback) ⇒ UIAlertControllerCallbackHelper
constructor
A new instance of UIAlertControllerCallbackHelper.
Constructor Details
#initialize(callback) ⇒ UIAlertControllerCallbackHelper
Returns a new instance of UIAlertControllerCallbackHelper.
103 104 105 |
# File 'lib/ios/sugarcube-factories/uialertcontroller.rb', line 103 def initialize(callback) @callback = callback.respond_to?('weak!') ? callback.weak! : callback end |
Instance Method Details
#call(button) ⇒ Object
107 108 109 |
# File 'lib/ios/sugarcube-factories/uialertcontroller.rb', line 107 def call() @callback.call() end |