mirror of
https://github.com/moonlight-stream/moonlight-android.git
synced 2025-07-18 18:42:46 +00:00
Fix Lint errors on API level 16
This commit is contained in:
parent
112d9c41eb
commit
8c910101c7
@ -603,7 +603,9 @@ public class Game extends Activity implements SurfaceHolder.Callback,
|
||||
try {
|
||||
Field field = windowLayoutParams.getClass().getDeclaredField("preferMinimalPostProcessing");
|
||||
field.set(windowLayoutParams, isPreferred);
|
||||
} catch (NoSuchFieldException | IllegalAccessException e) {
|
||||
} catch (NoSuchFieldException e) {
|
||||
e.printStackTrace();
|
||||
} catch (IllegalAccessException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
}
|
||||
|
@ -335,10 +335,10 @@ public class MediaCodecHelper {
|
||||
}
|
||||
|
||||
public static boolean decoderSupportsLowLatency(MediaCodecInfo decoderInfo, String mimeType) {
|
||||
// KitKat added CodecCapabilities.isFeatureSupported()
|
||||
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.KITKAT) {
|
||||
try {
|
||||
if (decoderInfo.getCapabilitiesForType(mimeType).
|
||||
isFeatureSupported(FEATURE_LowLatency))
|
||||
{
|
||||
if (decoderInfo.getCapabilitiesForType(mimeType).isFeatureSupported(FEATURE_LowLatency)) {
|
||||
LimeLog.info("Low latency decoding mode supported (FEATURE_LowLatency)");
|
||||
return true;
|
||||
}
|
||||
@ -346,6 +346,7 @@ public class MediaCodecHelper {
|
||||
// Tolerate buggy codecs
|
||||
e.printStackTrace();
|
||||
}
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user