Module: Growl
- Defined in:
- lib/growl_helpers.rb,
lib/growl.rb
Overview
Defines a few convenience methods that you can use in your class if you include the Growl module. Eg:
class FoodReporter < OSX::NSObject
include Growl
def hamburger_time!
growl 'YourHamburgerIsReady', 'Your hamburger is ready for consumption!', 'Please pick it up at isle 4.', :priority => 1 do
throw_it_away_before_user_reaches_counter!
end
end
end
Defined Under Namespace
Classes: Notifier
Instance Method Summary collapse
-
#growl(name, title, description, options = {}, &callback) ⇒ Object
Sends a Growl notification.
-
#sticky_growl(name, title, description, options = {}, &callback) ⇒ Object
Sends a sticky Growl notification.
Instance Method Details
#growl(name, title, description, options = {}, &callback) ⇒ Object
Sends a Growl notification. See Growl::Notifier#notify for more info.
17 18 19 |
# File 'lib/growl_helpers.rb', line 17 def growl(name, title, description, = {}, &callback) Growl::Notifier.sharedInstance.notify name, title, description, , &callback end |
#sticky_growl(name, title, description, options = {}, &callback) ⇒ Object
Sends a sticky Growl notification. See Growl::Notifier#notify for more info.
22 23 24 |
# File 'lib/growl_helpers.rb', line 22 def sticky_growl(name, title, description, = {}, &callback) growl name, title, description, .merge!(:sticky => true), &callback end |