Search in sources :

Example 1 with VoiceRouter

use of net.osmand.plus.routing.VoiceRouter in project Osmand by osmandapp.

the class WakeLockHelper method onStart.

public void onStart(Activity a) {
    this.active = true;
    if (wakeLock == null) {
        VoiceRouter voiceRouter = app.getRoutingHelper().getVoiceRouter();
        voiceRouter.removeVoiceMessageListener(this);
    }
}
Also used : VoiceRouter(net.osmand.plus.routing.VoiceRouter)

Example 2 with VoiceRouter

use of net.osmand.plus.routing.VoiceRouter in project Osmand by osmandapp.

the class WakeLockHelper method onStop.

public void onStop(Activity a) {
    this.active = false;
    OsmandSettings settings = app.getSettings();
    if (!a.isFinishing() && (settings.WAKE_ON_VOICE_INT.get() > 0)) {
        VoiceRouter voiceRouter = app.getRoutingHelper().getVoiceRouter();
        voiceRouter.addVoiceMessageListener(this);
    }
}
Also used : VoiceRouter(net.osmand.plus.routing.VoiceRouter) OsmandSettings(net.osmand.plus.OsmandSettings)

Aggregations

VoiceRouter (net.osmand.plus.routing.VoiceRouter)2 OsmandSettings (net.osmand.plus.OsmandSettings)1