Rev 228 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 228 | Rev 231 | ||
---|---|---|---|
Line 76... | Line 76... | ||
76 | </div> |
76 | </div> |
77 | </div> |
77 | </div> |
78 | 78 | ||
79 | <div class="menu-container"> |
79 | <div class="menu-container"> |
80 | <nav class="menu"> |
80 | <nav class="menu"> |
- | 81 | <!-- |
|
81 | <ul> |
82 | <ul> |
82 | <?php foreach ($languages as $key => $name): ?> |
83 | <?php foreach ($languages as $key => $name): ?> |
83 | <li><a |
84 | <li><a |
84 | href="index.<?php echo language_key_short($key); ?>?ani=0" |
85 | href="index.<?php echo language_key_short($key); ?>?ani=0" |
85 | lang="<?php echo $key; ?>" hreflang="<?php echo $key; ?>" |
86 | lang="<?php echo $key; ?>" hreflang="<?php echo $key; ?>" |
86 | class="button<?php if ($language === $key) { ?> selected<?php } ?>" |
87 | class="button<?php if ($language === $key) { ?> selected<?php } ?>" |
87 | tabindex="2" |
88 | tabindex="2" |
88 | ><span class="text"><?php echo language_name($key); ?></span></a></li> |
89 | ><span class="text"><?php echo language_name($key); ?></span></a></li> |
89 | <?php endforeach; ?> |
90 | <?php endforeach; ?> |
90 | </ul> |
91 | </ul> |
91 | <div class="bow" style="margin-bottom: 0.4em; height: 0.4em"> </div> |
92 | <div class="bow" style="margin-bottom: 0.4em; height: 0.4em"> </div> |
- | 93 | --> |
|
92 | <ul style="margin-bottom: 1.2em"> |
94 | <ul style="margin-bottom: 1.2em"> |
93 | <li><a href="<?php echo $menu['scripts']['path']; ?>" |
95 | <li><a href="<?php echo $menu['scripts']['path']; ?>" |
94 | target="_top" class="button" lang="<?php echo $language; ?>" |
96 | target="_top" class="button" lang="<?php echo $language; ?>" |
95 | ><span class="text"><?php echo $menu['scripts']['text']; ?></span></a></li> |
97 | ><span class="text"><?php echo $menu['scripts']['text']; ?></span></a></li> |
96 | <li><a href="<?php echo $menu['es-matrix']['path']; ?>" |
98 | <li><a href="<?php echo $menu['es-matrix']['path']; ?>" |
Line 201... | Line 203... | ||
201 | <span class="text"><?php echo tr('Home'); ?></span> |
203 | <span class="text"><?php echo tr('Home'); ?></span> |
202 | </div> |
204 | </div> |
203 | <div class="analysis" id="analysis"> |
205 | <div class="analysis" id="analysis"> |
204 | <table> |
206 | <table> |
205 | <tr> |
207 | <tr> |
206 | <th lang="<?php echo $language; ?>"><span class="text"><?php echo tr('Display'); ?>:</span></th> |
208 | <th lang="<?php echo $language; ?>"><span class="text"><?php echo tr('Display'); ?></span></th> |
207 | <td lang="<?php echo $language; ?>"><script |
209 | <td lang="<?php echo $language; ?>"><script |
208 | type="text/javascript" |
210 | type="text/javascript" |
209 | > |
211 | > |
210 | var _addEventListener = jsx.dom.addEventListener; |
212 | var _addEventListener = jsx.dom.addEventListener; |
211 | var _runAsync = jsx.dom.timeout.runAsync; |
213 | var _runAsync = jsx.dom.timeout.runAsync; |
Line 283... | Line 285... | ||
283 | }()); |
285 | }()); |
284 | </script> |
286 | </script> |
285 | <noscript><?php echo tr('N/A'); ?></noscript></td> |
287 | <noscript><?php echo tr('N/A'); ?></noscript></td> |
286 | </tr> |
288 | </tr> |
287 | <tr> |
289 | <tr> |
288 | <th lang="<?php echo $language; ?>"><span class="text"><?php echo tr('User Agent'); ?>:</span></th> |
290 | <th lang="<?php echo $language; ?>"><span class="text"><?php echo tr('User Agent'); ?></span></th> |
289 | <td><script type="text/javascript" |
291 | <td><script type="text/javascript" |
290 | src="application/scripts/ua.js" |
292 | src="application/scripts/ua.js" |
291 | ></script> |
293 | ></script> |
292 | <noscript><?php
|
294 | <noscript><?php
|
293 | echo tr('N/A'); ?></noscript></td> |
295 | echo tr('N/A'); ?></noscript></td> |
294 | </tr> |
296 | </tr> |
295 | <tr> |
297 | <tr> |
296 | <th lang="<?php echo $language; ?>"><span class="text"><?php echo tr('Features'); ?>:</span></th> |
298 | <th lang="<?php echo $language; ?>"><span class="text"><?php echo tr('Features'); ?></span></th> |
297 | <td><script type="text/javascript"> |
299 | <td><script type="text/javascript"> |
298 | var fullscreen = jsx.dom.window.fullscreen; |
300 | var fullscreen = jsx.dom.window.fullscreen; |
299 | 301 | ||
300 | (function () { |
302 | (function () { |
301 | function getFeatures () |
303 | function getFeatures () |
Line 456... | Line 458... | ||
456 | onmouseout="return resetStatus()" |
458 | onmouseout="return resetStatus()" |
457 | onfocus="return this.onmouseover()" |
459 | onfocus="return this.onmouseover()" |
458 | onblur="return this.onmouseout()" |
460 | onblur="return this.onmouseout()" |
459 | lang="<?php echo $language; ?>" |
461 | lang="<?php echo $language; ?>" |
460 | ><span class="text"><?php echo tr("Printable"); ?></span></a></li> |
462 | ><span class="text"><?php echo tr("Printable"); ?></span></a></li> |
- | 463 | <li id="cmd3"><script type="text/javascript"> |
|
- | 464 | function toggleFullscreen (button) |
|
- | 465 | { |
|
- | 466 | var nowIsFullscreen = fullscreen.isFullscreen(); |
|
- | 467 | ||
- | 468 | if (nowIsFullscreen) |
|
- | 469 | { |
|
- | 470 | fullscreen.cancel(); |
|
- | 471 | } |
|
- | 472 | else |
|
- | 473 | { |
|
- | 474 | fullscreen.requestOn(document.documentElement, button); |
|
- | 475 | } |
|
- | 476 | } |
|
461 | <li id="cmd3"><div class="button left right" |
477 | </script><div class="button left right" |
462 | style="cursor: not-allowed !important" |
478 | style="cursor: not-allowed !important" |
463 | onclick="fullscreen.requestOn(document.documentElement, this)" |
479 | onclick="toggleFullscreen(this)" |
464 | onkeyup="if (event.keyCode == 13) { this.onclick(); }" |
480 | onkeyup="if (event.keyCode == 13) { this.click(); }" |
465 | lang="<?php echo $language; ?>" |
481 | lang="<?php echo $language; ?>" |
466 | ><span class="text"><script type="text/javascript"> |
482 | ><span class="text"><script type="text/javascript"> |
467 | var cmd3; |
483 | var cmd3; |
468 | if (fullscreen.isSupportedBy(document.documentElement)) |
484 | if (fullscreen.isSupportedBy(document.documentElement)) |
469 | { |
485 | { |
Line 473... | Line 489... | ||
473 | cmd3 = jsx.dom.getElementById("cmd3"); |
489 | cmd3 = jsx.dom.getElementById("cmd3"); |
474 | } |
490 | } |
475 | 491 | ||
476 | if (cmd3) |
492 | if (cmd3) |
477 | { |
493 | { |
478 | cmd3.firstChild.tabIndex = "1"; |
494 | cmd3.lastChild.tabIndex = "1"; |
479 | } |
495 | } |
480 | }); |
496 | }); |
481 | 497 | ||
482 | var fullscreenText = "<?php echo tr("Fullscreen"); ?>"; |
498 | var fullscreenText = "<?php echo tr("Fullscreen"); ?>"; |
483 | document.write(fullscreenText); |
499 | document.write(fullscreenText); |
Line 509... | Line 525... | ||
509 | if (typeof cmd3 == "undefined") |
525 | if (typeof cmd3 == "undefined") |
510 | { |
526 | { |
511 | cmd3 = document.getElementById("cmd3"); |
527 | cmd3 = document.getElementById("cmd3"); |
512 | } |
528 | } |
513 | 529 | ||
514 | var target = cmd3.firstChild; |
- | |
515 | var textTarget = target.firstChild; |
530 | var textTarget = cmd3.lastChild.firstChild; |
516 | if (nowIsFullscreen) |
531 | if (nowIsFullscreen) |
517 | { |
532 | { |
518 | /* FIXME: Do not override event listeners, use the state instead */ |
- | |
519 | oldHandler = target.onclick; |
- | |
520 | target.onclick = function () { |
- | |
521 | fullscreen.cancel(); |
- | |
522 | }; |
- | |
523 | textTarget.textContent = "<?php echo tr("Window"); ?>"; |
533 | textTarget.innerHTML = "<?php echo tr("Window"); ?>"; |
524 | } |
534 | } |
525 | else |
535 | else |
526 | { |
536 | { |
527 | target.onclick = oldHandler; |
- | |
528 | textTarget.textContent = fullscreenText; |
537 | textTarget.innerHTML = fullscreenText; |
529 | } |
538 | } |
530 | 539 | ||
531 | previousIsFullscreen = nowIsFullscreen; |
540 | previousIsFullscreen = nowIsFullscreen; |
532 | } |
541 | } |
533 | } |
542 | } |
534 | }); |
543 | }); |
535 | </script></span> |
544 | </script></span></div></li> |
536 | </div></li> |
- | |
537 | <li id="cmd4"><script type="text/javascript"> |
545 | <li id="cmd4"><script type="text/javascript"> |
538 | var LANG_KLINGON = "<?php echo $klingon; ?>"; |
546 | var LANG_KLINGON = "<?php echo $klingon; ?>"; |
539 | var LANG_VULCAN = "<?php echo $vulcan; ?>"; |
547 | var LANG_VULCAN = "<?php echo $vulcan; ?>"; |
540 | lcars.language = "<?php echo $language; ?>"; |
548 | lcars.language = "<?php echo $language; ?>"; |
541 | </script> |
549 | </script> |
Line 563... | Line 571... | ||
563 | mediaScript(button); |
571 | mediaScript(button); |
564 | 572 | ||
565 | if (!is_alien_language) |
573 | if (!is_alien_language) |
566 | { |
574 | { |
567 | button.setAttribute("data-caption", button.firstChild.textContent); |
575 | button.setAttribute("data-caption", button.firstChild.textContent); |
568 | button.firstChild.textContent = "Latin"; |
576 | button.firstChild.textContent = "<?php echo tr('Latin'); ?>"; |
569 | } |
577 | } |
570 | } |
578 | } |
571 | } |
579 | } |
572 | </script> |
580 | </script> |
573 | <div class="button left right"<?php
|
581 | <div class="button left right"<?php
|
574 | $language_keys = array_keys($languages); |
582 | // $language_keys = array_keys($languages);
|
575 | if (in_array(@$klingon, $language_keys) || in_array(@$vulcan, $language_keys)) |
583 | if (in_array($language, array(@$klingon, @$vulcan))) |
576 | {
|
584 | {
|
577 | ?> tabindex="1" onclick="return toggleScript(this)"<?php |
585 | ?> tabindex="1" onclick="return toggleScript(this)"<?php |
578 | }
|
586 | }
|
579 | else
|
587 | else
|
580 | {
|
588 | {
|
581 | ?> style="cursor: not-allowed !important"<?php |
589 | ?> style="cursor: not-allowed !important"<?php |
582 | }
|
590 | }
|
- | 591 | ?>
|
|
- | 592 | onkeyup="if (event.keyCode == 13) { this.click(); }" |
|
583 | ?>><span class="text" lang="<?php echo $language; ?>"><?php |
593 | ><span class="text" lang="<?php echo $language; ?>"><?php |
584 | switch ($language) |
594 | switch ($language) |
585 | {
|
595 | {
|
586 | case $klingon: echo 'pIqaD'; break; |
596 | case $klingon: echo 'pIqaD'; break; |
587 | case $vulcan: echo 'Hitra-Zukitan'; break; |
597 | case $vulcan: echo 'Hitra-Zukitan'; break; |
588 | default: echo 'Original'; |
598 | // default: echo tr('Original');
|
589 | }
|
599 | }
|
590 | ?></span>
|
600 | ?></span>
|
591 | </div></li> |
601 | </div></li> |
592 | </ul> |
602 | </ul> |
593 | </div> |
603 | </div> |