Home
Developers

Developers

  • Documentation
    • Developer Guide
    • API Reference
    • Style Guide
    • How-To
    • Troubleshooting
  • Submit a Flake
  • Support

Pageflakes API Reference

  • Flake System Object
  • Flake User Object
  • Pageflakes Functions
  • Array Extensions
  • String Extensions
  • ContentProxy
  • App
  • RSS
  • Tooltip Manager
  • Public, Shared, and Private Pages
  • Server-Side Scripting
Home » Documentation » API Reference

Tooltip Manager

The TooltipManager object provides methods to handle mouse over and mouse out events properly to facilitate the creation of tooltips. There are two functions:

TM.setTooltip(element, tooltipText);
TM.setTooltipNow(event, element, tooltipText, delay);

The first function automatically adds the correct event handlers and shows the tooltip when the mouse is over the specified element. As such, this function should be called on initialization, and not on mouseover.

For example:

TM.setTooltip( textInputElement, 'Hi this is a tooltip' );

Tooltip

The second function immediately shows the tooltip. To use this, the correct event handler needs to be attached. For example:

PF.addEvent('somebutton', 'mouseover', callback);
function callback(e)
{
TM.showTooltipNow(e, this, 'Hi! This is a tooltip', 500);
}

‹ RSS Feed ExampleupPublic, Shared, and Private Pages ›
»
  • Printer-friendly version
  • Add new comment