Skip to content

Commit 892b4a1

Browse files
author
thefalsedev
authored
Change player progress bar update from 500 ms to 1 s
Just like in the issue 7062, #7062, this doesn't affect UI as it updates every one second anyway, but reduces very heavy android widget progress bar high cpu usage. With every 500s there is 6% cpu usage and with 1s only 4%. However further changes will have to be made to disable updating of player progress bar when screen is off to further reduce power consumption. With this, total power savings would be 20% in mAh consumption.
1 parent 6a1d81f commit 892b4a1

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

app/src/main/java/org/schabi/newpipe/player/Player.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -238,7 +238,7 @@ public final class Player implements
238238
//////////////////////////////////////////////////////////////////////////*/
239239

240240
public static final int PLAY_PREV_ACTIVATION_LIMIT_MILLIS = 5000; // 5 seconds
241-
public static final int PROGRESS_LOOP_INTERVAL_MILLIS = 500; // 500 millis
241+
public static final int PROGRESS_LOOP_INTERVAL_MILLIS = 1000; // 1 second
242242
public static final int DEFAULT_CONTROLS_DURATION = 300; // 300 millis
243243
public static final int DEFAULT_CONTROLS_HIDE_TIME = 2000; // 2 Seconds
244244
public static final int DPAD_CONTROLS_HIDE_TIME = 7000; // 7 Seconds

0 commit comments

Comments
 (0)