var help_table;
function print_preview(){
var _1=get_active_tab();
var _2=_1.element_.html();
$("#printHTML").val(_2);
$("#printForm").get(0).submit();
}
function make_drop_down(_3,_4,_5,_6){
var t=document.createElement("TABLE");
var _8=document.createElement("TBODY");
t.appendChild(_8);
for(var i=0;i<_3.length;++i){
var tr=document.createElement("TR");
var td=document.createElement("TD");
$(td).text(_3[i]);
$(td).css({padding:"5px 10px",cursor:"hand"});
$(td).css({cursor:"pointer"});
$(td).css({fontSize:"12px"});
tr.appendChild(td);
_8.appendChild(tr);
(function(_c){
$(td).click(function(e){
_4(_c);
t.parentNode.removeChild(t);
});
})(i);
$(td).mouseover(function(e){
$(this).css({"background":"#DCEBFD"});
});
$(td).mouseout(function(e){
$(this).css({"background":"#fafbfb"});
});
}
$(t).css({position:"absolute",border:"1px solid #DDE9F9",background:"#fafbfb",top:_5,left:_6});
document.body.appendChild(t);
return t;
}
function select_help(i){
help_table=null;
var _11=$("#helpspan").attr("src");
var _12=_11.replace(/icons([a-zA-Z\-]*)/,"icons");
$("#helpspan").attr("src",_12);
if(i==0){
var _13=getLANG().toLowerCase();
window.location.href="./"+_13+"/demo-editor.html";
}
if(i==1){
var _13=getLANG().toLowerCase();
var url="./"+_13+"/help.html";
window.open(url);
}
}
function show_help(){
var p=$("#helpspan").position();
if(help_table&&help_table.style.display!="none"){
help_table.parentNode.removeChild(help_table);
var _16=$("#helpspan").attr("src");
var _17=_16.replace(/icons([a-zA-Z\-]*)/,"icons");
$("#helpspan").attr("src",_17);
help_table=null;
}else{
help_table=make_drop_down(["Interactive Demo","Correcting Words"],select_help,p.top+25,p.left-90);
$(help_table).attr("id","help_table");
show_popup("#help_table",function(){
if(help_table){
var _18=$("#helpspan").attr("src");
var _19=_18.replace(/icons([a-zA-Z\-]*)/,"icons");
$("#helpspan").attr("src",_19);
$(help_table).remove();
help_table=null;
}
});
var _1a=$("#helpspan").attr("src");
var _1b=_1a.replace(/icons([a-zA-Z\-]*)/,"icons-pushed");
$("#helpspan").attr("src",_1b);
}
}
function setCookie(key,_1d,p){
var t=new Date();
var _20=new Date(t.getFullYear()+1,t.getMonth(),t.getDate());
if(!p){
document.cookie=key+"="+escape(_1d)+";expires="+_20.toGMTString()+"; path=/";
}else{
document.cookie=key+"="+escape(_1d)+";expires="+_20.toGMTString()+"; path="+p.toLowerCase();
}
}
function readCookie(key){
var _22=document.cookie;
var _23=_22.indexOf(key+"=");
if(_23>=0){
var str=_22.substring(_23,_22.length);
var _25=str.indexOf(";");
if(_25<0){
_25=str.length;
}
str=str.substring(0,_25).split("=");
return unescape(str[1]);
}else{
return null;
}
}
function eraseCookie(key){
var _27=new Date(1970);
document.cookie=key+"= ; expires="+_27.toGMTString()+"; path=/";
}
function changeCookie(){
eraseCookie();
if(navigator.cookieEnabled){
setCookie("lang",__lang__);
}
}
function getCurrentLangCookieValue(){
var _28="Hindi";
if(navigator.cookieEnabled){
lang=readCookie("lang");
if(lang!=null){
return lang;
}
}
return "Hindi";
}
function continue_demo(){
window.location.href="../"+$("#demo_langlist").val().toLowerCase()+"/demo-editor2.html";
}
function replay_animation(){
var _29=document.getElementById("animation");
if(_29&&!_29.IsPlaying()){
_29.Play();
}
window.setTimeout("replay_animation()",1000);
}

