Catch missing permissions exception
Этот коммит содержится в:
@@ -82,13 +82,21 @@ public class TrackingController implements PositionProvider.PositionListener, Ne
|
|||||||
if (isOnline) {
|
if (isOnline) {
|
||||||
read();
|
read();
|
||||||
}
|
}
|
||||||
|
try {
|
||||||
positionProvider.startUpdates();
|
positionProvider.startUpdates();
|
||||||
|
} catch (SecurityException e) {
|
||||||
|
Log.w(TAG, e);
|
||||||
|
}
|
||||||
networkManager.start();
|
networkManager.start();
|
||||||
}
|
}
|
||||||
|
|
||||||
public void stop() {
|
public void stop() {
|
||||||
networkManager.stop();
|
networkManager.stop();
|
||||||
|
try {
|
||||||
positionProvider.stopUpdates();
|
positionProvider.stopUpdates();
|
||||||
|
} catch (SecurityException e) {
|
||||||
|
Log.w(TAG, e);
|
||||||
|
}
|
||||||
handler.removeCallbacksAndMessages(null);
|
handler.removeCallbacksAndMessages(null);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Ссылка в новой задаче
Block a user