I've never used MIUI so I'm gonna make an assumption here that it has the drop-down notification area. When this happens to me on the CM based rom I run, if I pull the notification bar down and disable the GPS from there then re-enable it, it will stay locked for the duration.
God will not save you from that which he will perfect you through. Dr Voddie Baucham
If more people would get a divorce from themselves, they might learn how to live happily with someone else. Dr Ed Young Sr
No man ever sank beneath the burden of the day, it is when tomorrows burdens are added to today that the weight is more than we can bear. Dr Charles Stanley