Giter Site home page Giter Site logo

switch-gba's Issues

The B button isn't working properly

The behavior of the B button is awkward. Maybe you should try a different approach than the iframe.
The following snippets was tested on switch browser and worked very well.

Using window.location.hash:

<html>
<script>
var cnt = 0;

window.location.hash = "#1";
function beginHistory() {
  window.location.hash = "#2";
  setInterval(function(){
    if (window.location.hash != "#2") {
      window.location.hash = "#2";
      ++cnt;
      document.getElementById('content').innerHTML = 'PRESS #' + cnt;
    }
  }, 1);
}

setTimeout(function(){beginHistory();}, 1);
</script>

<div id='content'></div>
</html>

Using HTML5 pushState: (dont know why, but this doesn't work on my Chorme)

<html>

<script>
var cnt = 0;

history.pushState("#1", null, "");
function beginHistory() {
  history.pushState("#2", null, "");
  window.onpopstate = function(event) {
    history.pushState("#2", null, "");
    ++cnt;
    document.getElementById('content').innerHTML = 'PRESS #' + cnt;
  };
}
setTimeout(function(){beginHistory();}, 1);

</script>

<div id='content'></div>

</html>

the second one is better, because it does not rely on a interval polling the hash value.

Emulator does not load

When choosing an rom, the screen stays black, only showing slot, turbo, go back, reset and reload page buttons.

EDIT: Issue occurs only when using NGINX as a reverse proxy.

"You are now leaving this screen" on "B" button press

After playing for a while, I'll often get this message:

"Due to the size of the page, not all content could be displayed. try reloading the page?"

After doing the reload, the "B" button workaround sorta stops working. Every press of B works, but I get a pop up saying:

"You are now leaving this screen. Any information you have entered will not be saved"

I've found that doing a reload using the "Reload page" in the bottom right fixes this though.

Certainly not a huge issue, I more wanted to log an issue in case anyone else is having the issue and hasn't found the workaround.

Alerts can stop execution

By choking up the system, any alert can cause a content size warning which stops some functionality if it’s displayed for too long.

Related:
#1

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. πŸ“ŠπŸ“ˆπŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.