Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Back button not working on android emulator

I try to start an android sdk emulator, but when I press the back button this error appears:

INFO    | Critical: Failed to load https://maps.googleapis.com/maps/api/mapsjs/gen_204?csp_test=true: The 'Access-Control-Allow-Origin' header has a value 'qrc://' that is not equal to the supplied origin. Origin 'qrc://' is therefore not allowed access. (qrc:/html/js/common.js:0, (null))

INFO    | Critical: Failed to load https://maps.googleapis.com/maps/api/mapsjs/gen_204?csp_test=true: The 'Access-Control-Allow-Origin' header has a value 'qrc://' that is not equal to the supplied origin. Origin 'qrc://' is therefore not allowed access. (qrc:/html/js/common.js:0, (null))

I use Ubuntu and try to start the emulator through terminal, I use the avdmanager of the google cmdline-tools (latest version) and this is the AVD that I try to use:

    Name: my_avd_29ii
    Path: /home/user/.android/avd/my_avd_29ii.avd
  Target: Google APIs (Google Inc.)
          Based on: Android 10.0 (Q) Tag/ABI: google_apis/x86
  Sdcard: 512 MB
like image 631
TryingHardToProgramm Avatar asked May 09 '26 20:05

TryingHardToProgramm


1 Answers

The best option would (Needs to be done for every emulator you install)

Windows

  1. %USERPROFILE%\.adnroid\avd\<Emulator Name>.avd
  2. Edit config.ini
  3. Change hw.keyboard=no to hw.keyboard=yes

Mac

  1. ~/.android/avd/<Emulator Name>.avd
  2. Edit config.ini
  3. Change hw.keyboard=no to hw.keyboard=yes

The answer is based on this article

like image 164
Tamir Gilany Avatar answered May 11 '26 13:05

Tamir Gilany