diff --git a/index.html b/index.html index 182b6245..fcd2939e 100644 --- a/index.html +++ b/index.html @@ -180,6 +180,19 @@ a.dropdown-toggle { -moz-border-radius:6px 0 6px 6px; border-radius:6px 0 6px 6px; } +.emubevel { + padding:4%; + background:#333; +} +.emuvideo { + border-radius:20px; + border: 4px solid #222; + padding: 30px; + margin-top: 20px; + margin-bottom: 20px; + background: #000; + outline-color: #666; +} canvas.pixelated { image-rendering: optimizeSpeed; /* Older versions of FF */ image-rendering: -moz-crisp-edges; /* FF 6.0+ */ @@ -209,7 +222,7 @@ canvas.pixelated {
  • VIC Dual
  • Midway 8080
  • -
  • Scramble Hardware
  • +
  • Galaxian/Scramble Hardware
  • Atari Color Vector (Z80)
  • Williams (Z80)
  • Williams Sound (Z80)
  • diff --git a/src/emu.js b/src/emu.js index 4d02f2f6..812d7c05 100644 --- a/src/emu.js +++ b/src/emu.js @@ -12,14 +12,13 @@ function __createCanvas(mainElement, width, height) { // TODO var fsElement = document.createElement('div'); fsElement.style.position = "relative"; - fsElement.style.padding = "5%"; fsElement.style.overflow = "hidden"; - fsElement.style.background = "black"; + fsElement.classList.add("emubevel"); var canvas = document.createElement('canvas'); canvas.width = width; canvas.height = height; - canvas.style['class'] = "emuvideo"; + canvas.classList.add("emuvideo"); canvas.style.width = "100%"; canvas.style.height = "100%"; canvas.tabIndex = "-1"; // Make it focusable @@ -39,10 +38,10 @@ var RasterVideo = function(mainElement, width, height, options) { if (options && options.rotate) { // TODO: aspect ratio? canvas.style.transform = "rotate("+options.rotate+"deg)"; - if (canvas.width > canvas.height) - canvas.style.paddingTop = canvas.style.paddingBottom = "10%"; - else + if (canvas.width < canvas.height) canvas.style.paddingLeft = canvas.style.paddingRight = "10%"; + //else + // canvas.style.paddingTop = canvas.style.paddingBottom = "10%"; } ctx = canvas.getContext('2d'); imageData = ctx.createImageData(width, height);