/*
 * Heads-Up Grid
 * Simple HTML + CSS grid overlay for web design and development.
 *
 * Files: hugrid.css, hugrid.js, example.html
 * 
 * Example and documentation at: http://bohemianalps.com/tools/grid
 * 
 * Shurane, thanks for your help! https://github.com/shurane
 * 
 * Copyright (c) 2011 Jason Simanek
 *
 * Version: 1.5 (09/03/2011)
 * Requires: jQuery v1.6+
 *
 * Licensed under the GPL license:
 *   http://www.gnu.org/licenses/gpl.html
 */

(function($) {
	makeTabs = function(tabnav) {
		$(tabnav+' li a').click(function(e) {
			e.preventDefault();
			if (!$(this).hasClass('active')) {
				//reset all active navs
				$(tabnav+' li a').removeClass('active');
				//reset all visible content
				$(tabnav).siblings('section').hide();
				//set active nav
				$(this).addClass('active');
				//show new content
				var tab = $(this).attr('rel');
				$(tab).show();
			}
		});	
	}
	definegrid = function() {
        var browserWidth = $(window).width();
        if (browserWidth >= 1280) 
        {
            columnwidth = 240;
        }  
        if (browserWidth >= 1024 && browserWidth < 1280) 
        {
            columnwidth = 240;
        } 
        if (browserWidth >= 768 && browserWidth < 1024) 
        {
            columnwidth = 180;
        }
        if (browserWidth >= 480 && browserWidth < 768) 
        {
            columnwidth = 200;
        }
        if (browserWidth < 480) 
        {
            columnwidth = 240;
        }
    }
})(jQuery);

