Merge pull request #86824 from alessandrofama/audio-import-playback-position

Fix playback position label update in Audio Stream Importer
This commit is contained in:
Rémi Verschelde 2024-01-08 11:57:31 +01:00
commit e417b7e6e6
No known key found for this signature in database
GPG key ID: C3336907360768E1

View file

@ -277,6 +277,8 @@ void AudioStreamImportSettingsDialog::_draw_indicator() {
rect.size.height -= y_ofs;
}
_current_label->set_text(String::num(_current, 2).pad_decimals(2) + " /");
float ofs_x = (_current - zoom_bar->get_value()) * rect.size.width / zoom_bar->get_page();
if (ofs_x < 0 || ofs_x >= rect.size.width) {
return;
@ -310,8 +312,6 @@ void AudioStreamImportSettingsDialog::_draw_indicator() {
}
}
}
_current_label->set_text(String::num(_current, 2).pad_decimals(2) + " /");
}
void AudioStreamImportSettingsDialog::_on_indicator_mouse_exited() {