commit
c2d680183a
1 changed files with 12 additions and 2 deletions
|
@ -930,11 +930,21 @@ public class AudioVideoNotesPlugin extends OsmandPlugin {
|
||||||
stopRecording(activity, false);
|
stopRecording(activity, false);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void mapActivityResume(MapActivity activity) {
|
||||||
|
this.mapActivity = activity;
|
||||||
|
if (Build.VERSION.SDK_INT < 29) {
|
||||||
|
runAction(activity);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void mapActivityResumeOnTop(MapActivity activity) {
|
public void mapActivityResumeOnTop(MapActivity activity) {
|
||||||
this.mapActivity = activity;
|
this.mapActivity = activity;
|
||||||
// ((AudioManager) activity.getSystemService(Context.AUDIO_SERVICE)).registerMediaButtonEventReceiver(
|
runAction(activity);
|
||||||
// new ComponentName(activity, MediaRemoteControlReceiver.class));
|
}
|
||||||
|
|
||||||
|
private void runAction(MapActivity activity) {
|
||||||
if (runAction != -1) {
|
if (runAction != -1) {
|
||||||
takeAction(activity, actionLon, actionLat, runAction);
|
takeAction(activity, actionLon, actionLat, runAction);
|
||||||
runAction = -1;
|
runAction = -1;
|
||||||
|
|
Loading…
Reference in a new issue