public
Description: Notification Services for Javascript in Firefox (Growl, and alike)
Homepage: http://icanscale.com/callout/
Clone URL: git://github.com/lackac/callout.git
Click here to lend your support to: callout and make a donation at www.pledgie.com !
name age message
file README.md Wed Oct 14 09:10:30 -0700 2009 Loudspy defunct [lackac]
file build.sh Sun Jun 01 13:26:29 -0700 2008 Importing existing sources [lackac]
file chrome.build.manifest Sun Jun 01 13:26:29 -0700 2008 Importing existing sources [lackac]
file chrome.manifest Sun Jun 01 13:26:29 -0700 2008 Importing existing sources [lackac]
file config_build.sh Sun Jun 01 13:26:29 -0700 2008 Importing existing sources [lackac]
directory content/ Wed Oct 14 07:53:31 -0700 2009 Changed version to 0.3.3, also changed homepage... [lackac]
directory defaults/ Sun Jun 01 13:26:29 -0700 2008 Importing existing sources [lackac]
directory examples/ Wed Oct 14 07:53:31 -0700 2009 Changed version to 0.3.3, also changed homepage... [lackac]
file install.rdf Wed Oct 14 07:53:31 -0700 2009 Changed version to 0.3.3, also changed homepage... [lackac]
directory locale/ Sun Jun 01 13:26:29 -0700 2008 Importing existing sources [lackac]
directory skin/ Sun Jun 01 13:26:29 -0700 2008 Importing existing sources [lackac]
README.md

Callout

Callout is a Firefox extension which delivers an API for web pages and Greasemonkey scripts to notify the user through the notification system of the OS. This would be Growl for Mac OS X users and Windows notifications for Windows users. The extension creates the callout JavaScript object which is usable by both unprivileged JavaScript code and Greasemonkey scripts.

Installation

Install the newest version from addons.mozilla.org.

Requirements

Callout supports Firefox 2.0+ on Windows and Linux and Firefox 3.0+ on Mac OS X. Mac OS X users will also need the Growl notification system. Greasemonkey is only required for userscript support.

Usage

Callout makes a callout JavaScript object available for all webpages and Greasemonkey scripts. The method creates a notification titled title and with the message message.

callout.notify(title, message, [options])

The available options are:

  • icon: with this you can specify an icon for the notification. This should be an URI for the icon. If unspecified the default Callout icon is used.
  • href: this specifies a target page to go to if the user clicks on the notification. This page will be opened in a new tab or window.

Examples

// Simple usage
callout.notify('Hello', 'World!');

// Specifying an icon
callout.notify('Hello World!', 'this is a ninja!',
               {icon: 'http://icanscale.com/callout/images/ninja.png'});

// Specifying a target page
callout.notify('I Can Scale', 'My blog',
               {href: 'http://icanscale.com/'});

Loudspy (defunct)

There is a more elaborate example in the examples directory for a Greasemonkey script which uses Callout. This script works worked on Digg spy and notified the user of each new digg displayed on the page.

Warning: while this could be useful for the digg addict it is a serious distraction from work. :)

This user script can also be installed from the following address: http://github.com/lackac/callout/raw/master/examples/loudspy.user.js

Note: since the old Digg Spy have been retired this userscript is also defunct. Nevertheless it is a good way to see how a userscript which uses Callout could be written.

Credits

Author: László Bácsi

Hungarian blog post: http://lackac.hu/articles/2008/03/26/rendszeruzenetek-firefoxbol-es-turulcsirip-growl

The original idea came from András Bártházi.

Copyright

Copyright (c) 2008-2009 László Bácsi, released under the Mozilla Public License Version 1.1 (or alternatively GPL 2.0 or LGPL 2.1).