Skip to content

Commit 8395cf8

Browse files
authored
Merge pull request #8349 from litetex/fix-PlaybackParameterDialog-resetting
Fixed accidental reset of ``PlaybackParameterDialog`` on initialization
2 parents 0fef4e6 + c2bf7f0 commit 8395cf8

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

app/src/main/java/org/schabi/newpipe/player/helper/PlaybackParameterDialog.java

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -213,7 +213,7 @@ private void initUI() {
213213

214214
getPitchControlModeComponentMappings()
215215
.forEach(this::setupPitchControlModeTextView);
216-
changePitchControlMode(isCurrentPitchControlModeSemitone());
216+
// Initialization is done at the end
217217

218218
// Pitch - Percent
219219
setText(binding.pitchPercentMinimumText, PlayerHelper::formatPitch, MIN_PITCH_OR_SPEED);
@@ -275,6 +275,9 @@ private void initUI() {
275275
skipSilence = isChecked;
276276
updateCallback();
277277
});
278+
279+
// PitchControlMode has to be initialized at the end because it requires the unhookCheckbox
280+
changePitchControlMode(isCurrentPitchControlModeSemitone());
278281
}
279282

280283
// -- General formatting --

0 commit comments

Comments
 (0)