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.
120 121 122 |
# File 'lib/ios/sugarcube-factories/uialertcontroller.rb', line 120 def initialize(callback) @callback = callback.respond_to?('weak!') ? callback.weak! : callback end |
Instance Method Details
#call(button) ⇒ Object
124 125 126 |
# File 'lib/ios/sugarcube-factories/uialertcontroller.rb', line 124 def call() @callback.call() end |