Class: Opine::Native::Alert
- Defined in:
- lib/opine/widgets/alert_osx.rb,
lib/opine/widgets/alert_win.rb
Instance Attribute Summary
Attributes inherited from Alert
Instance Method Summary collapse
-
#initialize(options, &block) ⇒ Alert
constructor
A new instance of Alert.
Constructor Details
#initialize(options, &block) ⇒ Alert
Returns a new instance of Alert.
2 3 4 5 6 7 8 9 |
# File 'lib/opine/widgets/alert_osx.rb', line 2 def initialize(,&block) super application.activateIgnoringOtherApps true alert = Cocoa::NSAlert.alloc.init.autorelease alert.setMessageText text alert.runModal end |