5

Some HTC phones have a feature called Fast boot (can be enabled under Preferences -> Power). As I have understood it this works like hibernation.

When started again no BOOT_COMPLETEDetc. will be sent, instead applications will be 'resumed'. This is very hard for me to handle in my application (auto-start, depends on SD-card etc).

I think the best I could do right now is inform the user to disable Fast boot for the best experience.

As this is a non-standard setting how can I detect if it is enabled?

CommonsWare
  • 986,068
  • 189
  • 2,389
  • 2,491
tidbeck
  • 2,363
  • 24
  • 35
  • Note that what you define as "best experience" (disabling the fast boot) is clearly not the same as what the HTC understands by it. You should make sure your application is indeed bringing the user enough benefits to justify tweaking OS-level settings for it. Otherwise you risk alienating power users that like the feature, and losing regular users that just won't bother doing it and will blame your app for behaving badly. – Franci Penov Dec 28 '11 at 17:14
  • @FranciPenov you are right. At this time that would require a lot of changes but the question maybe should be 'How can I detect that I am restarted from hibernation?' – tidbeck Dec 28 '11 at 17:23
  • Very interesting question. AFAIK fastboot in HTC is some kind of trick but I don't know if it keeps refreshing the RAM (for your question I understand it doesn't). – Mister Smith Dec 28 '11 at 17:34

1 Answers1

4

I would suggest looking into the ACTION_USER_PRESENT broadcast which is typically sent when the user unlocks the phone. From what I was able to find about the HTC fast-boot (terrible name, as it conflicts in search results with the regular fastboot), it is just putting the phone in sleep mode and wakes up to a lock screen.

Another alternative to explore is ACTION_SCREEN_ON

Franci Penov
  • 74,861
  • 18
  • 132
  • 169
  • Maybe not the answer I was hoping for but I realize that this probably is the only way to do it. – tidbeck Dec 29 '11 at 09:57
  • Thanks for the info, My application has same kind of problems when it comes to HTC's fastboot. Let me go ahead and try your solution. – sku Jul 26 '12 at 23:28