Rev 119 | Rev 125 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 119 | Rev 121 | ||
---|---|---|---|
Line 366... | Line 366... | ||
366 | <div class="analysis"> |
366 | <div class="analysis"> |
367 | <table> |
367 | <table> |
368 | <tr> |
368 | <tr> |
369 | <th><?php echo _('Display'); ?>:</th> |
369 | <th><?php echo _('Display'); ?>:</th> |
370 | <td><script type="text/javascript"> |
370 | <td><script type="text/javascript"> |
371 | var dim = { |
371 | (function () { |
- | 372 | var screenInfo = { |
|
372 | getScreen: function () { |
373 | getDim: function () { |
- | 374 | return { |
|
- | 375 | width: screen.width, |
|
373 | return screen.width + "×" + screen.height; |
376 | height: screen.height |
- | 377 | }; |
|
374 | }, |
378 | }, |
375 | 379 | ||
376 | getAvail: function () { |
380 | getAvailDim: function () { |
- | 381 | return { |
|
- | 382 | width: screen.availWidth, |
|
377 | return screen.availWidth + "×" + screen.availHeight; |
383 | height: screen.availHeight |
- | 384 | }; |
|
378 | }, |
385 | }, |
379 | 386 | ||
380 | getInner: function () { |
387 | getInnerDim: function () { |
- | 388 | return { |
|
- | 389 | width: window.innerWidth, |
|
381 | return window.innerWidth + "×" + window.innerHeight; |
390 | height: window.innerHeight |
- | 391 | }; |
|
382 | }, |
392 | }, |
383 | 393 | ||
384 | getColorDepth: function () { |
394 | getColorDepth: function () { |
385 | return (screen.colorDepth || screen.pixelDepth); |
395 | return (screen.colorDepth || screen.pixelDepth); |
386 | } |
396 | } |
387 | }; |
397 | }; |
388 | 398 | ||
389 | var displayInfo; |
399 | var dim = { |
- | 400 | getScreenText: function () { |
|
- | 401 | var screenDim = screenInfo.getDim(); |
|
- | 402 | return screenDim.width + "×" + screenDim.height; |
|
- | 403 | }, |
|
- | 404 | ||
- | 405 | getAvailText: function () { |
|
- | 406 | var availDim = screenInfo.getAvailDim(); |
|
- | 407 | return availDim.width + "×" + availDim.height + " <?php echo _('available'); ?>"; |
|
- | 408 | }, |
|
- | 409 | ||
- | 410 | getInnerText: function () { |
|
- | 411 | var innerDim = screenInfo.getInnerDim(); |
|
- | 412 | return ", " + innerDim.width + "×" + innerDim.height + " <?php echo _('used'); ?>"; |
|
- | 413 | }, |
|
- | 414 | ||
- | 415 | getColorDepthText: function () { |
|
- | 416 | var colorDepth = screenInfo.getColorDepth(); |
|
- | 417 | return colorDepth |
|
- | 418 | ? '2<sup>' + colorDepth + "<\/sup> <?php echo _('colors'); ?>" |
|
390 | (function () { |
419 | : ""; |
391 | displayInfo = |
420 | } |
- | 421 | }; |
|
- | 422 | ||
- | 423 | var screenDimText = dim.getScreenText(); |
|
- | 424 | var availDimText = dim.getAvailText(); |
|
- | 425 | var innerDimText = dim.getInnerText(); |
|
- | 426 | var colorDepthText = dim.getColorDepthText(); |
|
- | 427 | var displayInfo = (screenDimText || availDimText || innerDimText || colorDepthText) |
|
392 | '<span id="screenDim">' + dim.getScreen() + '<\/span>' |
428 | ? (screenDimText ? '<span id="screenDim">' + screenDimText + '<\/span>' : "") |
393 | + ' (<span id="availDim">' + dim.getAvail() + "<\/span> <?php echo _('available'); ?>," |
429 | + (availDimText ? ' (<span id="availDim">' + availDimText + "<\/span>" : "") |
394 | + ' <span id="innerDim">' + dim.getInner() + "<\/span> <?php echo _('used'); ?>) <?php echo _('pixels'); ?>" |
430 | + (innerDimText ? '<span id="innerDim">' + innerDimText + "<\/span>) <?php echo _('pixels'); ?>" : "") |
395 | + ' × 2<sup><span id="colorDepth">' + dim.getColorDepth() + "<\/span><\/sup> <?php echo _('colors'); ?>"; |
431 | + (colorDepthText ? ' × <span id="colorDepth">' + colorDepthText + "<\/span>" : "") |
- | 432 | : "<?php echo _('N/A'); ?>"; |
|
396 | 433 | ||
397 | /* FIXME: Convert HTML to text, update whole title text */ |
434 | /* FIXME: Convert HTML to text, update whole title text */ |
398 | document.write('<span>' + displayInfo + '<\/span>'); |
435 | document.write('<span>' + displayInfo + '<\/span>'); |
399 | }()); |
- | |
400 | 436 | ||
- | 437 | var oScreenDim; |
|
- | 438 | var oAvailDim; |
|
- | 439 | var oInnerDim; |
|
401 | window.onresize = function () { |
440 | window.onresize = function () { |
402 | /* FIXME: Update whole title text */ |
441 | /* FIXME: Also update title attribute value */ |
- | 442 | if (typeof oScreenDim == "undefined") oScreenDim = document.getElementById("screenDim"); |
|
403 | document.getElementById("screenDim").innerHTML = dim.getScreen(); |
443 | if (oScreenDim) oScreenDim.innerHTML = dim.getScreenText(); |
- | 444 | ||
- | 445 | if (typeof oAvailDim == "undefined") oAvailDim = document.getElementById("availDim"); |
|
404 | document.getElementById("availDim").innerHTML = dim.getAvail(); |
446 | if (oAvailDim) oAvailDim.innerHTML = dim.getAvailText(); |
- | 447 | ||
- | 448 | if (typeof oInnerDim == "undefined") oInnerDim = document.getElementById("innerDim"); |
|
405 | document.getElementById("innerDim").innerHTML = dim.getInner(); |
449 | if (oInnerDim) oInnerDim.innerHTML = dim.getInnerText(); |
406 | }; |
450 | }; |
407 | 451 | ||
- | 452 | var oColorDepth; |
|
408 | window.setTimeout(function () { |
453 | window.setTimeout(function () { |
- | 454 | if (typeof oColorDepth == "undefined") |
|
- | 455 | { |
|
- | 456 | oColorDepth = document.getElementById("colorDepth"); |
|
- | 457 | } |
|
- | 458 | ||
- | 459 | if (oColorDepth) |
|
- | 460 | { |
|
409 | /* FIXME: Update whole title text */ |
461 | /* FIXME: Also update title attribute value */ |
410 | document.getElementById("colorDepth").innerHTML = dim.getColorDepth(); |
462 | oColorDepth.innerHTML = dim.getColorDepthText(); |
- | 463 | } |
|
411 | }, 1000); |
464 | }, 1000); |
- | 465 | }()); |
|
412 | </script><noscript><?php echo _('N/A'); ?></noscript></td> |
466 | </script><noscript><?php echo _('N/A'); ?></noscript></td> |
413 | </tr> |
467 | </tr> |
414 | <tr> |
468 | <tr> |
415 | <th><?php echo _('User Agent'); ?>:</th> |
469 | <th><?php echo _('User Agent'); ?>:</th> |
416 | <td><script type="text/javascript"> |
470 | <td><script type="text/javascript"> |
417 | (function () { |
471 | (function () { |
418 | var ua = navigator.userAgent; |
472 | var ua = navigator.userAgent; |
419 | document.write('<span id="ua" title="' + ua + '">' + ua + '<\/span>'); |
473 | document.write('<span id="ua" title="' + ua + '">' + ua + '<\/span>'); |
420 | 474 | ||
- | 475 | var oUA; |
|
421 | window.setTimeout(function () { |
476 | window.setTimeout(function () { |
- | 477 | if (typeof oUA == "undefined") |
|
- | 478 | { |
|
- | 479 | oUA = document.getElementById("ua"); |
|
- | 480 | } |
|
- | 481 | ||
- | 482 | if (oUA) |
|
- | 483 | { |
|
422 | document.getElementById("ua").innerHTML = navigator.userAgent; |
484 | oUA.innerHTML = navigator.userAgent; |
- | 485 | ||
- | 486 | /* Converts CREs */ |
|
- | 487 | oUA.title = oUA.innerHTML; |
|
- | 488 | } |
|
423 | }, 1000); |
489 | }, 1000); |
424 | }()); |
490 | }()); |
425 | </script><noscript><?php echo _('N/A'); ?></noscript></td> |
491 | </script><noscript><?php echo _('N/A'); ?></noscript></td> |
426 | </tr> |
492 | </tr> |
427 | <tr> |
493 | <tr> |
Line 560... | Line 626... | ||
560 | } |
626 | } |
561 | 627 | ||
562 | var sFeatures = getFeatures(); |
628 | var sFeatures = getFeatures(); |
563 | document.write('<span id="features" title="' + sFeatures + '">' + sFeatures + '<\/span>'); |
629 | document.write('<span id="features" title="' + sFeatures + '">' + sFeatures + '<\/span>'); |
564 | 630 | ||
- | 631 | var oFeatures; |
|
565 | window.setTimeout(function () { |
632 | window.setTimeout(function () { |
566 | var sFeatures = getFeatures(); |
633 | if (typeof oFeatures == "undefined") |
- | 634 | { |
|
567 | var oFeatures = document.getElementById("features"); |
635 | oFeatures = document.getElementById("features"); |
- | 636 | } |
|
- | 637 | ||
- | 638 | if (oFeatures) |
|
- | 639 | { |
|
568 | oFeatures.innerHTML = sFeatures; |
640 | oFeatures.innerHTML = getFeatures(); |
- | 641 | ||
569 | /* Converts CREs */ |
642 | /* Converts CREs */ |
570 | oFeatures.title = oFeatures.innerHTML; |
643 | oFeatures.title = oFeatures.innerHTML; |
- | 644 | } |
|
571 | }, 1000); |
645 | }, 1000); |
572 | }()); |
646 | }()); |
573 | </script><noscript><?php echo _('N/A'); ?></noscript></td> |
647 | </script><noscript><?php echo _('N/A'); ?></noscript></td> |
574 | </tr> |
648 | </tr> |
575 | </table> |
649 | </table> |
Line 594... | Line 668... | ||
594 | onblur="return this.onmouseout()" |
668 | onblur="return this.onmouseout()" |
595 | ><span class="text"><?php echo _("Printable"); ?></span></a></li> |
669 | ><span class="text"><?php echo _("Printable"); ?></span></a></li> |
596 | <li id="cmd3"><div class="button left right" |
670 | <li id="cmd3"><div class="button left right" |
597 | style="cursor: not-allowed !important" |
671 | style="cursor: not-allowed !important" |
598 | onclick="fullscreen.requestOn(document.documentElement, this, this.firstChild)" |
672 | onclick="fullscreen.requestOn(document.documentElement, this, this.firstChild)" |
599 | onkeyup="if (event.keyCode == 13) { this.onclick(); this.onmouseup(); }" |
673 | onkeyup="if (event.keyCode == 13) { this.onclick(); }" |
600 | onmouseup="this.blur()" |
- | |
601 | tabindex="1" |
674 | tabindex="1" |
602 | ><span class="text"><script type="text/javascript"> |
675 | ><span class="text"><script type="text/javascript"> |
603 | if (fullscreen.isSupportedBy(document.documentElement)) |
676 | if (fullscreen.isSupportedBy(document.documentElement)) |
604 | { |
677 | { |
605 | <?php /* |
678 | <?php /* |