J = jQuery.noConflict();

J(document).ready(function(){

    /* Add First and Last classes to lists */
    J('ul li:last-child').addClass('last');
    J('ul li:first-child').addClass('first');
    
	if (_gaq) {
		Enterprise.Tabs.prototype.baseSelect = Enterprise.Tabs.prototype.select;
		Object.extend(Enterprise.Tabs.prototype, {
			select: function () {
				var tabLabel = this.activeTab.getElementsByTagName('span')[0].textContent;
				_gaq.push(['_trackEvent', 'Product', 'Tabs', tabLabel, null, true]);
				this.baseSelect();
			}
		});

		J('a[id^="dl_"]').live('click', function(e) {
			_gaq.push(['_trackEvent', 'Download', J(this).attr('id').split('_')[1], J(this).attr('href').split(/\//).pop(), null, true]);
		});
	}
}); 


