Optimized the Location manager updates to occur in intervals only when the Activity is running.