From 60bf133ac28c76bcbef79e6610f34c6b66e5e82e Mon Sep 17 00:00:00 2001 From: Romain Vimont Date: Sat, 15 Jan 2022 23:04:37 +0100 Subject: [PATCH] Add final modifier to ScreenEncoder fields These fields are only set from the constructor. --- .../main/java/com/genymobile/scrcpy/ScreenEncoder.java | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/server/src/main/java/com/genymobile/scrcpy/ScreenEncoder.java b/server/src/main/java/com/genymobile/scrcpy/ScreenEncoder.java index f98c53d0..ce6b556a 100644 --- a/server/src/main/java/com/genymobile/scrcpy/ScreenEncoder.java +++ b/server/src/main/java/com/genymobile/scrcpy/ScreenEncoder.java @@ -30,11 +30,11 @@ public class ScreenEncoder implements Device.RotationListener { private final AtomicBoolean rotationChanged = new AtomicBoolean(); private final ByteBuffer headerBuffer = ByteBuffer.allocate(12); - private String encoderName; - private List codecOptions; - private int bitRate; - private int maxFps; - private boolean sendFrameMeta; + private final String encoderName; + private final List codecOptions; + private final int bitRate; + private final int maxFps; + private final boolean sendFrameMeta; private long ptsOrigin; public ScreenEncoder(boolean sendFrameMeta, int bitRate, int maxFps, List codecOptions, String encoderName) {