6

I need to be able to select and deselect "pointer locations" from the developer options menu using adb. adb shell am start -n com.android.settings/.DevelopmentSettings, but once I'm there I can't figure out how to select and de-select pointer locations.

I tried just using shell keyevent 'xx' to move the focus, but it seems problematic and unreliable. Is there a simple set of commands that will allow me to just jump to the selection?

1 Answer 1

10

To enable Pointer locations, the command is:

adb shell settings put system pointer_location 1

Change 1 to 0 to disable it.

Enter adb shell settings to understand its usage and what the aforesaid command is doing.

6
  • adb shell settings put system pointer_location 1 /system/bin/sh: settings: not found Commented Aug 31, 2015 at 5:00
  • Are you using an Android earlier than Android 4.2.1? settings command was introduced starting from Android 4.2.1.
    – Firelord
    Commented Aug 31, 2015 at 9:35
  • Thanks :) We're using 4.1.1 but will keep this in mind for the future. Commented Aug 31, 2015 at 20:24
  • @Firelord I'm trying these commands, but they don't affect Tinder on Androd for example: ~/Android/Sdk/platform-tools$ ./adb -s 2C051FDH3002LA shell appops set com.google.android.gms android:mock_location allow ~/Android/Sdk/platform-tools$ ./adb -s 2C051FDH3002LA shell am broadcast -a android.intent.action.GEO_LOCATION --es "lat" "38.6979" --es "long" "-9.2064" --ei "error" "10" Broadcasting: Intent { act=android.intent.action.GEO_LOCATION flg=0x400000 (has extras) } Broadcast completed: result=0
    – Elad Benda
    Commented Aug 6, 2023 at 13:53
  • @EladBenda hi. I don't think your command applies to either the question or my answer. Consider creating a question instead and add as much details as you have.
    – Firelord
    Commented Aug 6, 2023 at 17:27

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .