Commit 59b9deb5 authored by Geoffrey Métais's avatar Geoffrey Métais

Disable remote controle receiver on TV

parent e7ac23ed
......@@ -20,9 +20,11 @@
package org.videolan.vlc;
import android.app.Application;
import android.content.ComponentName;
import android.content.Context;
import android.content.Intent;
import android.content.SharedPreferences;
import android.content.pm.PackageManager;
import android.content.res.Configuration;
import android.content.res.Resources;
import android.preference.PreferenceManager;
......@@ -110,6 +112,12 @@ public class VLCApplication extends Application {
sTV = AndroidDevices.isAndroidTv() || !AndroidDevices.hasTsp();
Dialog.setCallbacks(VLCInstance.get(), mDialogCallbacks);
// Disable remote control receiver on Fire TV.
if (!AndroidDevices.hasTsp())
getPackageManager().setComponentEnabledSetting(
new ComponentName(this, RemoteControlClientReceiver.class),
PackageManager.COMPONENT_ENABLED_STATE_DISABLED, PackageManager.DONT_KILL_APP);
}
/**
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment