/* SIFR */
var K2font = "/Style Library/_fIles/K2Font.swf";
if(typeof sIFR == "function")
{
	sIFR.replaceElement(named(
		{
		sSelector:".sifr_font_01",
		sFlashSrc:"/Style Library/_fIles/K2Font.swf",
		sColor:"#454545",
		sWmode: 'transparent'
		}
	));
	sIFR.replaceElement(named(
		{
		sSelector:".sifr_font_02",
		sFlashSrc:"/Style Library/_fIles/K2Font.swf",
		sColor:"#000000",
		sWmode: 'transparent'
		}
	));
	sIFR.replaceElement(named(
		{
		sSelector:".sifr_font_03",
		sFlashSrc:"/Style Library/_fIles/K2Font.swf",
		sColor:"#333333",
		sWmode: 'transparent'
		}
	));
	sIFR.replaceElement(named(
		{
		sSelector:".sifr_font_04",
		sFlashSrc:"/Style Library/_fIles/K2Font.swf",
		sColor:"#666666",
		sWmode: 'transparent'
		}
	));
	
		sIFR.replaceElement(named(
		{
		sSelector:".sifr_font_05",
		sFlashSrc:"/Style Library/_fIles/K2Font.swf",
		sColor:"#454545",
		sWmode: 'transparent'
		}
	));
	
	sIFR.replaceElement(named(
		{
		sSelector:".sifr_font_06",
		sFlashSrc:"/Style Library/_fIles/K2Font.swf",
		sColor:"#454545",
		sWmode: 'transparent'
		}
	));
	sIFR.replaceElement(named(
		{
		sSelector:".sifr_font_07",
		sFlashSrc:"/Style Library/_fIles/K2Font.swf",
		sColor:"#333333",
		sWmode: 'transparent'
		}
	));



	
	
	sIFR.replaceElement(named(
		{
		sSelector:".level-header .headertitle",
		sFlashSrc:"/Style Library/_fIles/K2Font.swf",
		sColor:"#333333",
		sWmode: 'transparent'
		}
	));
	
	sIFR.replaceElement(named(
		{
		sSelector:".ms-standardheader",
		sFlashSrc:"/Style Library/_fIles/K2Font.swf",
		sColor:"#333333",
		sWmode: 'transparent'
		}
	));

	
	
	


}

$(".sifr_font_01").attr("target","_self");






/* change fonts size */

/*var fontSize = ''; // zmienna globalna - moze przyjac jedna z 3-ech wartosci: small, normal, big
var fontSizeCookieName = 'k2_font_size'; //nazwa cookie dla rozmiaru czcionki

if ($.cookie(fontSizeCookieName) != null)
{
	if ($.cookie(fontSizeCookieName) == "medium")
	{
		$(".small").each(function () {
	    	var fontSize = GetFontSize($(this));
	    	var lineHeight = GetLineHeight($(this));
	    	fontSize += 2;
	    	lineHeight += 2;
	    	$(".small").css("font-size",fontSize + "px");
	    	$(".small").css("line-height",lineHeight + "px");
	    	$(".small").addClass("medium");
	    	$(".medium").removeClass("small");
	   	});
	}
	else if ($.cookie(fontSizeCookieName) == "big")
	{
		$(".small").each(function () {
	    	var fontSize = GetFontSize($(this));
	    	var lineHeight = GetLineHeight($(this));
	    	fontSize += 4;
	    	lineHeight += 4;
	    	$(".small").css("font-size",fontSize + "px");
	    	$(".small").css("line-height",lineHeight + "px");
	    	$(".small").addClass("big");
	    	$(".big").removeClass("small");
	   	});
	}
}*/

function GetFontSize(obj)
{
	var fontSize = obj.css("font-size");
	return parseInt(fontSize.split("px")[0]);
}
function GetLineHeight(obj)
{
	var lineHeight = obj.css("line-height");
	return parseInt(lineHeight.split("px")[0]);
}

$(".smallFont").click(function () { 
	$(".medium").each(function () {
    	var fontSize = GetFontSize($(this));
    	var lineHeight = GetLineHeight($(this));
    	fontSize -= 2;
    	lineHeight -= 2;
    	$(".medium").css("font-size",fontSize + "px");
    	$(".medium").css("line-height",lineHeight + "px");
    	$(".medium").addClass("small");
    	$(".small").removeClass("medium");
   	});
	$(".big").each(function () {
    	var fontSize = GetFontSize($(this));
    	var lineHeight = GetLineHeight($(this));
    	fontSize -= 4;
    	lineHeight -= 4;
    	$(".big").css("font-size",fontSize + "px");
    	$(".big").css("line-height",lineHeight + "px");
    	$(".big").addClass("small");
    	$(".small").removeClass("big");
   	});
   	//fontSize = "small";
   	//$.cookie(fontSizeCookieName,fontSize, { expires: 7 });
});

$(".mediumFont").click(function () { 

	$(".small").each(function () {
    	var fontSize = GetFontSize($(this));
    	var lineHeight = GetLineHeight($(this));
    	fontSize += 2;
    	lineHeight += 2;
    	$(".small").css("font-size",fontSize + "px");
    	$(".small").css("line-height",lineHeight + "px");
    	$(".small").addClass("medium");
    	$(".medium").removeClass("small");
   	});
   	$(".big").each(function () {
    	var fontSize = GetFontSize($(this));
    	var lineHeight = GetLineHeight($(this));
    	fontSize -= 2;
    	lineHeight -= 2;
    	$(".big").css("font-size",fontSize + "px");
    	$(".big").css("line-height",lineHeight + "px");
    	$(".big").addClass("medium");
    	$(".medium").removeClass("big");
   	});
   	//fontSize = "medium";
   	//$.cookie(fontSizeCookieName,fontSize, { expires: 7 });
});

$(".bigFont").click(function () { 
	$(".small").each(function () {
    	var fontSize = GetFontSize($(this));
    	var lineHeight = GetLineHeight($(this));
    	fontSize += 4;
    	lineHeight += 4;
    	$(".small").css("font-size",fontSize + "px");
    	$(".small").css("line-height",lineHeight + "px");
    	$(".small").addClass("big");
    	$(".big").removeClass("small");
   	});
   	$(".medium").each(function () {
    	var fontSize = GetFontSize($(this));
    	var lineHeight = GetLineHeight($(this));
    	fontSize += 2;
    	lineHeight += 2;
    	$(".medium").css("font-size",fontSize + "px");
    	$(".medium").css("line-height",lineHeight + "px");
    	$(".medium").addClass("big");
    	$(".big").removeClass("medium");
   	});
   	//fontSize = "big";
   	//$.cookie(fontSizeCookieName,fontSize, { expires: 7 });
});

/* drukowanie */
$(".print ").click(function(){window.print()});

/* linki dla rozwiazan - wdrozyc po stworzeniu rozwiazan
$("#sol_01").attr("href","/rozwiazania/Strony/RozwiazaniaDedykowane.aspx"); // cap (Rozwiązania dedykowane)
$("#sol_02").attr("href","/rozwiazania/Strony/RozwiazaniaDlabankowosci.aspx"); // bnk (Rozwiązania bankowości i instytucji finansowych)
$("#sol_03").attr("href","/rozwiazania/Strony/CustomerRelationshipManagement.aspx"); // crm (Customer Relationship Management)
$("#sol_04").attr("href","/rozwiazania/Strony/BusinessIntelligence.aspx"); // bi (Business Intelligence)
$("#sol_05").attr("href","/rozwiazania/Strony/OcenaiRozwojPracownikow.aspx"); // eas (Ocena i rozwój pracowników)
$("#sol_06").attr("href","/rozwiazania/Strony/IntegracjaAplikacji.aspx"); // eai (Integracja aplikacji)
$("#sol_07").attr("href","/rozwiazania/Strony/ObiegiArchiwizacjaDokumentow.aspx"); // dms (Obieg i archiwizacja dokumentów)
$("#sol_08").attr("href","/rozwiazania/Strony/PrzetwarzanieDokumentowFinansowych.aspx"); // fdp (Przetwarzanie dokumentów finansowych)
$("#sol_09").attr("href","/rozwiazania/Strony/PortaleKorporacyjne.aspx"); // cp (Portale korporacyjne)
$("#sol_10").attr("href","/rozwiazania/Strony/ZarzadzanieProcesamiBiznesowymi.aspx"); // bpm (Zarządzanie procesami biznesowymi)
 */
 
/* linki dla produktow */
$("#product_01").attr("href","/produkty/Strony/K2Kredyt.aspx"); // K2 Kredyt
$("#product_02").attr("href","/produkty/Strony/K2Rozliczenia.aspx"); // K2 Rozliczenia
$("#product_03").attr("href","/produkty/Strony/K2Dokumenty.aspx"); // K2 Dokumenty
$("#product_04").attr("href","/produkty/Strony/K2Scoring.aspx"); // K2 Scoring
$("#product_05").attr("href","/produkty/Strony/K2Kompetencje.aspx"); // K2 Kompetencje
$("#product_06").attr("href","/produkty/Strony/K2WebParts.aspx"); // K2 Webparts

 
 

