You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The locationServicesEnabled() method on LocationState class only checks if the current "location_mode" is 0 or not.
It assumes that each device will return '0' when location service is off.
But on some of huawei devices(lollipop and marshmallow) and Xiaomi devices,"location_mode" returns '2' when location service is OFF.
Again, samsung lollipop devices return "location_mode" as '1' when location service is on.
Whereas other devices set "location_mode" as '3' when location service is on.
Considering all the devices, the locationServicesEnabled() should return the following:
return locationMode %2 != 0;
The text was updated successfully, but these errors were encountered:
The locationServicesEnabled() method on LocationState class only checks if the current "location_mode" is 0 or not.
It assumes that each device will return '0' when location service is off.
But on some of huawei devices(lollipop and marshmallow) and Xiaomi devices, "location_mode" returns '2' when location service is OFF.
Again, samsung lollipop devices return "location_mode" as '1' when location service is on.
Whereas other devices set "location_mode" as '3' when location service is on.
Considering all the devices, the locationServicesEnabled() should return the following:
return locationMode %2 != 0;
The text was updated successfully, but these errors were encountered: