khaelys / SmartEnvironments-old

1 stars 0 forks source link

Enabling bluetooth problem #11

Closed khaelys closed 6 years ago

khaelys commented 6 years ago

If bluetooth is off, we have to ask the user to enable it via a new Activity (which destroy the current one). In this case i think it's better to resume the previous activity capturing the user input (ok / cancel). Even if the answer was "cancel" we must resume the previous activity, because the user could not understand what's going on.

khaelys commented 6 years ago

Useful links: https://stackoverflow.com/questions/18116666/bluetoothadapter-action-request-enable-calls-onactivityresult-immediately

khaelys commented 6 years ago

Trying adding FLAG_ACTIVITY_NEW_TASK to intent flag

khaelys commented 6 years ago

The problem was a finish() call in the CameraActivity.