zamojski / TowerCollector

The OpenCellID and MLS contributor's app.
Mozilla Public License 2.0
217 stars 27 forks source link

Temporarily disable GPS while airplane mode is enabled #163

Open rmh2022 opened 2 years ago

rmh2022 commented 2 years ago

When phone is in airplane mode, GPS readings have no use since TowerCollector can't obtain tower cell data. So we could save a lot of battery by temporarily disabling GPS until phone exits airplane mode.

This small change is very useful to me as I regularly toggle airplane mode in my phone but can't remember to start and stop TowerCollector every time. It's much less hassle if I can just leave TowerCollector running all the time and let it enable/disable GPS when it needs to.

rmh2022 commented 2 years ago

Hi! Any concerns with this pull request? I've been using it for a month and app behaves as expected, haven't found any problems.