/**
 * Init javascript for the dynamic tooltips on the portfolio page.
 * The element right after the "trigger" is used as the tooltip.
 *
 * @require jquery-tooltip.js, cms-activateElements.js
 * @author vclark@vipasolutions.com, bbarber@i2rd.com
 */

// Setup the tooltips when the document is ready.
jQuery(function($){

   var options = {
      offset: [-55, 5]
   };
   
   // Fix positioning on IE 6 and 7.
   if (document.getElementById("ie6only") || document.getElementById("ie7only"))
     options.offset[0] += 85;
   else if (document.getElementById("ie8only"))
     options.offset[0] -= 15;

   $("#portfolio_tb a").tooltip(options);

});

// Make links work when clicking on image or the tooltip.
cms.activateElements("#portfolio_tb td");


