Fabrizio Ferrari
Fabrizio Ferrari

Reputation: 989

How to fix wrong click location in Android Studio emulator?

I am a newbie of Android programming, and I am using the latest version of Android Studio on a Mac.

My problem is with the emulator, in particular, the tablet emulators (Pixel C, Nexus 9, and 10) which is giving me a hard time understanding why any click I do on the emulator display is displaced up (on the y axis) a great number of pixels. For example, if I click the Chrome icon present on the home screen, in reality, the emulator is taking the click about 100-150 pixels up that location! Why's that?

I have no problems with all phone emulators. This issue appears only with tablets. Any ideas?

Thanks in advance for any possible solutions to this problem.

All the best, Fab.

Upvotes: 3

Views: 1273

Answers (3)

Kyle Evangelista
Kyle Evangelista

Reputation: 11

Got this error today, here's what I did to fix it

  1. Close emulator
  2. If using another IDE, open Android Studio
  3. Go to device manager
  4. Click on the kebab menu
  5. Cold boot

Fixed!

Upvotes: 1

Aleem Ehsan
Aleem Ehsan

Reputation: 11

im using VS-Code with Android Emulator (Pixel 3 API 34 extension level 7)

I got this issue and searched on google for it. The Solution which worked for me is I restarted my PC and then launched the Emulator in Android Studio from DeviceManager

and then wrong click location error was Fixed.

then I ran the Emulator from VS-Code and there also the Click location was exact the same where I was clicking

Upvotes: 0

Fabrizio Ferrari
Fabrizio Ferrari

Reputation: 989

Ok, I solved this problem by unchecking the option Launch in a tool window" inside Preferences > Tools > Emulator.

It appears that making the emulator run inside a window is buggy and gives this click-location issue.

Upvotes: 6

Related Questions