The HOME button does not work, can I listen to it?

Ok, here is my problem. Whenever I press the HOME button, nothing happens. If I am in the application and click it, I do not go to the main screen as I should be.

However, if the screen is locked and I press, the screen will light up (because the key is pressed).

So, from what I can say, the system registers the HOME key press, but does not cause the intent of "android.intent.category.HOME".

Is there a way to control the HOME button, and if it clicks the "android.intent.category.HOME" button from my application? I looked at StackOverflow, but cannot find any working way to listen for the HOME key if the HOME intent is not activated.

Problem Overview:

Pressing the HOME button wakes the system up when it locks, so the key obviously works.

Button

HOME will not lead to the intention of "android.intent.category.HOME" to activate and will not send all open applications to the background.

Any help?

+6
source share
3 answers

I had this problem on my TF101, I think I deleted some Android settings using Titanium Backup. After I rebooted the device, the "Home" button did nothing, some quick settings will not appear, and the power button will display very few parameters.

A lot of sites prompted me to do a factory reset (it will take all day to backup and restore). After trying several possible solutions, I came to this topic http://forum.cyanogenmod.org/topic/19605-home-button-issues-striking-back/ , which solved it.

I used the sroid sroid installed on my Ubuntu using the following steps:

  • Use adb as su to get the Android settings database:

    sudo platform-tools / adb -d pull / data / data / com.android.providers.settings / databases / settings.db settings.db

  • Use sqlite3 to check if device_provisioned = 1 (this parameter was missing)

    tools / sqlite3 settings.db "select * from secure;" | Giving grep

the correct answer would be "nnn | device_provisioned | 1", where nnn is the line number. If there was no answer, you need to add this parameter to the file.

  1. Use sqlite3 to add this parameter to the file

    tools / sqlite3 settings.db "INSERT INTO secure (name, value) VALUES ('device_provisioned', '1');

  2. Return the file to your Android device.

    sudo platform-tools / adb -d push settings.db / data / data / com.android.providers.settings / databases / settings.db

  3. Power down android (at first I tried the reboot option in the power button menu, but somehow restored my faulty settings. After that I pressed the power button until the device turned off.)

  4. Turn on the power. The Home button worked again (along with other missing features).

+12
source

However, if the screen is locked and I press, the screen will light up (because the key is pressed).

This is the abnormal behavior of Android devices, as others have commented. Perhaps this is normal for your phone model, and in this case I am sorry to hear this, since your battery life may suck, since you will permanently press the HOME button and turn on the screen.

Is there a way to control the HOME button, and if it clicks the "android.intent.category.HOME" button from my application?

Not. You can write an action that implements the main screen, but that is unlikely to help you here.

Any help?

Most likely, you have an application on your device that is your default default screen and is incorrect. Try to find and delete it. Or reboot your phone in safe mode and see if it gives you control so that you can find and delete it. Or factory - reset your phone.

For further discussion of this topic, please visit http://android.stackexchange.com for questions for Android end users.

0
source

For anyone looking for this problem, my device home button is disabled after a crash. I tried everything, including rebooting. There were some other functional problems.

||| As soon as I received and answered the phone, the problem was somehow fixed. |||

Perhaps the service was disabled during the accident, and telephony restarted it, but I hope this will help anyone who is disappointed with this problem.

0
source

Source: https://habr.com/ru/post/893966/


All Articles