﻿// cst017-teclado_jrc.js - v1.0 - Copyright (c) 2009 by Juan Rodríguez & Begues Internet, s.l.

tVisible=0; tActivo=80; tAtaActivo=0; tAtaVisible=0; t21equal0=0; cAtajos=0;
document.onkeydown=oirTeclado;

cst200="cst200-castefa_informacion.html";
cst230="cst230-como_buscar_en_el_directorio.html";
cst280="cst280-contactar.html";

function TecladoJRc() {scrollTo(0,0); document.getElementById('divTecladoJRc').innerHTML=t92; if (tVisible==1) {cTeclado() } else {mTeclado() } };
function cTeclado() {document.getElementById("R1").style.display="none"; document.getElementById("R2").style.display="none"; tVisible=0; tAtaVisible=0};
function tTeclado(tt) {if (tActivo==80) {cBloque(80); aBloque(81); tActivo=81} else {cBloque(81); aBloque(80); tActivo=80} };
function control_tAtaActivo() {tAtaActivo=1}; if (tAtaActivo==0) {setTimeout("control_tAtaActivo()", 2000)};
function mTeclado() {aBloque(80); document.getElementById("DivTeclado").style.marginBottom=50+"px"; document.getElementById("DivTeclado").style.display="block"; document.getElementById("DivTeclado").style.visibility="visible"; tActivo=80; tVisible=1; tAtaVisible=1; return }
function cT21() {document.getElementById('cT').value=""; leerTeclado()};
function include(ficheroJS) {var jr=document.createElement("script"); jr.type="text/javascript"; jr.src=ficheroJS; document.body.appendChild(jr); cAtajos=1};
function ok() {document.getElementById('cT').value="*** Ok ***"; leerTeclado()};
function restaurarAtajos() {tAtaActivo=1};

function oirTeclado(e) {
if (document.getElementById('JRcF') )  {return}

var kC; if (!e) var e=window.event; if (e.keyCode) {kC=e.keyCode} else {if (e.which) {kC=e.which} }; 
// alert(kC);
if (kC==19) {window.location="cst249-abeja_castefa.html"}; if ((kC==27) && (tVisible==1)) {cTeclado()}; 
if ((kC==27) && (tAtaVisible==1)) {document.getElementById('divTecladoJRc').innerHTML=""; tAtaVisible=0};
if ((kC==219) || (kC==221)) {window.location=cst230};
if (kC <= 47) {return}; if ((kC >= 91) && (kC <= 95)) {return}; if ((kC >= 106) && (kC <=190)) {return}; if (kC >=193) {return};

if (tAtaActivo==0) {return};
if (tAtaVisible==0) {document.getElementById('divTecladoJRc').innerHTML=t21; tAtaVisible=1};
if (tAtaVisible==1) {document.getElementById('cTeclado').style.visibility="visible"; scrollTo(0,0); document.getElementById('cT').focus()};
if (cAtajos==0) {include("rc/cst018-atajos.js")};
leerTeclado() }

t01='<a ';
t02='<a class="tHelp" ';
t03='href="javascript:void(0)" onclick="cTeclado()" title="Cerrar y ocultar el teclado">Esc</a>';
t04='href="cst231-funciones_teclado.html" title="Ayuda para el teclado del Directorio de Castelldefels">¿?</a>';
t05='href="javascript:void(0)" onclick="tTeclado(0)" title="Intercambiar teclado qwerty / alfabético">&thorn;</a>';
t30=t01+t03; t31=t02+t03; t40=t01+t04; t41=t02+t04; t50=t01+t05; t51=t02+t05;

t21 ='<div id="cTeclado" style="position:absolute; visibility:hidden; width:100%; height:100%; z-index:34">';
t21 +='<div style="width:350px; height:350px; margin-top:50px; margin-left:auto; margin-right:auto; padding:5px 10px; border:1px #234 solid; background-color:#FFFFFF; opacity:0.95; filter:alpha(opacity=95)">';
t21 +='<h2>Atajos: El camino más corto</h2><p style="font-family:Verdana; font-size:8pt" >No es necesario pulsar [Intro]. El sistema busca a medida que Vd. vaya escribiendo. Si sigue viendo esta ventana es que...<br /><br />* Si busca determinado tipo de empresas o profesionales escriba (2 veces) la inicial de la actividad. Por ejemplo: Escriba <b>AA</b> si busca abogados, academias, albañiles,...<br /><br />* Si busca una página en concreto, escríbala. Por ejemplo: <b>tiempo</b> para acceder a la información meteorológica.<br /><br />* Dispone de más información sobre los atajos del Directorio escribiendo <b>ayuda</b>.<br /><br />* Pulse la tecla <b>Esc</b> para cerrar esta venta (También puede escribir <i>esc</i>, <i>salir</i>, <i>sortir</i> o <i>exit</i>).</p> ';
t21 +='<form action="javascript:void(0)" method="post" id="FormAtajos"><p style="text-align:center"><input type="text" name="in" size="10" onkeyup="leerTeclado()"; style="font-size:18pt; color:#800000; text-align:center; background:#CCC; border:1px #234 solid" value="" id="cT" /></p></form></div>';
t21 +='</div>';

t92 ='<div id="R1" style="position:absolute; height:100%; width:100%; background-color:#CCCCCC; opacity:0.75; filter:alpha(opacity=75); z-index:30; top:0; left:0"></div>';
t92 +='<div id="R2" style="position:relative; width:820px; margin:0 auto; z-index:32">';
t92 +='<div style="position:absolute; top:125px; width:800px; height:200px; padding:5px 0">';
t92 =t92+t21;
t92 +='<div id="DivTeclado" style="padding:5px 5px 30px 5px; background-color:#234; border:1px #FFF solid">';
t92 +='<table style="width:100%; margin:10px 0">';
t92 +='<tr><td class="Ttxt">';
t92 +='<h1 style="margin:0 25px; letter-spacing:1px">Directorio de Castelldefels</h1>';
t92 +='<p style="margin-left:25px">Pulse la inicial de la actividad que desea:<br /><b>H</b><i>(si busca <a href="cst-h010-hoteles_castelldefels.html" title="Hoteles en Castelldefels">hoteles</a>, <a href="cst-h020-heladerias.html" title="Heladerías en Castelldefels">heladerías</a>,...),</i><br /><b>R</b><i>(si busca <a href="cst-r015-restaurantes_castelldefels_playa.html" title="Restaurantes en Castelldefels playa (Playafels)">restaurantes</a>, <a href="cst-j020-joyerias.html" title="Joyerías y relojerías">relojerías</a>,...)</i></p>';
t92 +='<p style="margin-left:25px">También puede escribir en su teclado físico:<br /><b>AA</b><i>(si busca <a href="cst-a010-abogados.html" title="Abogados en Castelldefels">abogados</a>, <a href="cst-a040-apartamentos.html" title="Apart hoteles. Apartamentos">apartamentos</a>,...)</i><br /><b>BB</b><i>(si busca <a href="cst-b010-bancos.html" title="Bancos en Castelldefels">bancos</a>, <a href="cst-b020-bares.html" title="Bares, cafeterías y tabernas en Castelldefels">bares</a>,...)</i></p>';
t92 +='</td><td style="vertical-align:bottom">';
tecI2='<td class="tFun"><a href="cst430-emergencias.html" title="Servicios de emergencias para Castelldefels">Sos</a></td><td style="width:10px"></td>';
tecI3='<td class="tFun"><a style="width:50px" href="cst440-agenda.html" title="Teléfonos y direcciones de interés">Agenda</a></td><td style="width:10px"></td>';
tecD1='<td style="width:25px"></td><td><a href="cst100-mundo_laboral.html" title="Mundo Laboral">ML</a></td><td><a href="cst240-el_tiempo_castelldefels.html" title="El tiempo en Castelldefels">ºC</a></td></tr></table>';
tecD2='<td style="width:13px"></td><td><a href="cst200-castefa_informacion.html" title="Mucha + info">+i</a></td><td><a href="cst270-avisos_novedades.html" title="Avisos y novedades en el Directorio de Castelldefels">¡!</a></td></tr></table>';
tecD3='<td style="width:10px"></td><td class="tFun"><a style="width:40px" href="cst210-tarifas.html" title="¡ Apúntese al Directorio !">Altas</a></td><td style="width:23px"></td><td><a href="cst280-contactar.html" title="Contactar con el Directorio">@</a></td>';
t92 +='<div id="Bloque80">';
t92 +='<table class="Teclas"><tr><td class="tFun" id="t30">'+t30+'</td><td><a href="cst328_q.html" title="(Q)">Q</a></td><td><a href="cst334_w.html" title="(W)">W</a></td><td><a href="cst314_e.html" title="(E)">E</a></td><td><a href="cst329_r.html" title="(R)">R</a></td><td><a href="cst331_t.html" title="(T)">T</a></td><td><a href="cst336_y.html" title="(Y)">Y</a></td><td class="tFun"><i>u</i></td><td><a href="cst318_i.html" title="(I)">I</a></td><td><a href="cst326_o.html" title="(O)">O</a></td><td><a href="cst327_p.html" title="(P)">P</a></td>' +tecD1;
t92 +='<table class="Teclas"><tr>'+tecI2+'<td><a href="cst310_a.html" title="(A)">A</a></td><td><a href="cst330_s.html" title="(S)">S</a></td><td><a href="cst313_d.html" title="(D)">D</a></td><td><a href="cst315_f.html" title="(F)">F</a></td><td><a href="cst316_g.html" title="(G)">G</a></td><td><a href="cst317_h.html" title="(H)">H</a></td><td><a href="cst319_j.html" title="(J)">J</a></td><td><a href="cst320_k.html" title="(K)">K</a></td><td><a href="cst321_l.html" title="(L)">L</a></td><td class="tFun"><i>ñ</i></td>' +tecD2;
t92 +='<table class="Teclas"><tr>'+tecI3+'<td><a href="cst337_z.html" title="(Z)">Z</a></td><td><a href="cst335_x.html" title="(X)">X</a></td><td><a href="cst312_c.html" title="(C)">C</a></td><td><a href="cst333_v.html" title="(V)">V</a></td><td><a href="cst311_b.html" title="(B)">B</a></td><td><a href="cst324_n.html" title="(N)">N</a></td><td><a href="cst323_m.html" title="(M)">M</a></td>' +tecD3+'<td class="tFun"><a href="http://www.juan-rodriguez.net" title="Juan Rodríguez [Consultor]">JRc</a></td></tr></table>';
t92 +='</div>';
t92 +='<div id="Bloque81" class="Bloque">';
t92 +='<table class="Teclas"><tr><td class="tFun" id="t35">'+t30+'</td><td><a href="cst310_a.html" title="(A)">A</a></td><td><a href="cst311_b.html" title="(B)">B</a></td><td><a href="cst312_c.html" title="(C)">C</a></td><td><a href="cst313_d.html" title="(D)">D</a></td><td><a href="cst314_e.html" title="(E)">E</a></td><td><a href="cst315_f.html" title="(F)">F</a></td><td><a href="cst316_g.html" title="(G)">G</a></td><td><a href="cst317_h.html" title="(H)">H</a></td><td><a href="cst318_i.html" title="(I)">I</a></td><td><a href="cst319_j.html" title="(J)">J</a></td>' +tecD1;
t92 +='<table class="Teclas"><tr>'+tecI2+'<td><a href="cst320_k.html" title="(K)">K</a></td><td><a href="cst321_l.html" title="(L)">L</a></td><td><a href="cst323_m.html" title="(M)">M</a></td><td><a href="cst324_n.html" title="(N)">N</a></td><td class="tFun"><i>ñ</i></td><td><a href="cst326_o.html" title="(O)">O</a></td><td><a href="cst327_p.html" title="(P)">P</a></td><td><a href="cst328_q.html" title="(Q)">Q</a></td><td><a href="cst329_r.html" title="(R)">R</a></td><td><a href="cst330_s.html" title="(S)">S</a></td>' +tecD2;
t92 +='<table class="Teclas"><tr>'+tecI3+'<td><a href="cst331_t.html" title="(T)">T</a></td><td class="tFun"><i>u</i></td><td><a href="cst333_v.html" title="(V)">V</a></td><td><a href="cst334_w.html" title="(W)">W</a></td><td><a href="cst335_x.html" title="(X)">X</a></td><td><a href="cst336_y.html" title="(Y)">Y</a></td><td><a href="cst337_z.html" title="(Z)">Z</a></td>' +tecD3+'<td class="tFun"><a href="http://www.juan-rodriguez.net" title="Juan Rodríguez [Consultor]">JRc</a></td></tr></table>';
t92 +='</div>';
t92 +='<table class="Teclas"><tr><td class="tFun"><a style="width:70px" href="cst250-noticias.html" title="Noticias de prensa y actualidad">Noticias</a></td><td class="tFun"><a style="width:175px" href="cst300-directorio_castelldefels.html" title="Directorio por actividades">Directorio por actividades</a></td><td class="tFun"><a style="width:55px" href="cst500-mapas_castelldefels.html" title="Mapas de Castelldefels">Mapas</a></td><td class="tFun"><a href="cst234-lo_mas_visitado.html" onclick="LoMas(900); return false" title="Lo más visitado en el Directorio de Castelldefels">L+</a></td><td style="width:17px"></td><td id="t40">'+t40+'</td><td id="t50">'+t50+'</td></tr></table>';
t92 +='</td></tr></table>';
t92 +='<p class="Mensajes"><a onmouseover="tecActHelp(40,t40,t41)" onmouseout="tecAnuHelp(40,t40)" href="javascript:void(0)" title="¿Ayuda?s">¿ Ayuda ?</a><a style="margin:0 40px" href="javascript:void(0)" onmouseover="tecActHelp(50,t50,t51)" onmouseout="tecAnuHelp(50,t50)" title="Ver teclado alfabético">¿ Teclado alfabético o qwerty ?</a><a href="javascript:void(0)" title="Cerrar el teclado" onmouseover="tecActHelp(30,t30,t31)" onmouseout="tecAnuHelp(30,t30)">¿ Cerrar ?</a></p>';
t92 +='</div>';
t92 +='<p style="text-align:center; font-family:Verdana; color:white; font-style:italic; margin:0"><span style="font-size:72pt">Castelldefels</span><br /><span style="font-size:24pt">www.castefa.net</span><br /><span style="font-size:10pt">&copy; Juan Rodríguez [Consultor]</span></p>'
t92 +='</div></div>';

tc=1;
function tecActHelp(t,tn,th) {if ((tActivo==81) && (t==30)) {t=35}; if ((tActivo==81) && (t==40)) {t=45}; if (tc==1) {document.getElementById("t"+t).innerHTML=th; t1=t; tn1=tn; th1=th; setTimeout("tecActHelp2(t1,tn1,th1)",700)} else {tc=1} }
function tecActHelp2(t,tn1,th1) { if (tc==1) {document.getElementById("t"+t).innerHTML=tn1; setTimeout("tecActHelp(t1,tn1,th1)",700)} else {tc=1} }
function tecAnuHelp(t,ti) {tc=0; if ((tActivo==81) && (t==30)) {t=35}; if ((tActivo==81) && (t==40)) {t=45}; document.getElementById("t"+t).innerHTML=ti}
