1
0
mirror of https://github.com/godotengine/godot.git synced 2025-11-29 16:16:38 +00:00

Fix audio player not resetting after wav finishes

(cherry picked from commit daa62ccaa3)
This commit is contained in:
kobewi
2021-03-06 22:45:10 +01:00
committed by Rémi Verschelde
parent d5a2fd4e17
commit ba70958b29
2 changed files with 16 additions and 12 deletions

View File

@@ -42,17 +42,18 @@ class AudioStreamEditor : public ColorRect {
GDCLASS(AudioStreamEditor, ColorRect);
Ref<AudioStream> stream;
AudioStreamPlayer *_player;
ColorRect *_preview;
Control *_indicator;
Label *_current_label;
Label *_duration_label;
AudioStreamPlayer *_player = nullptr;
ColorRect *_preview = nullptr;
Control *_indicator = nullptr;
Label *_current_label = nullptr;
Label *_duration_label = nullptr;
ToolButton *_play_button;
ToolButton *_stop_button;
ToolButton *_play_button = nullptr;
ToolButton *_stop_button = nullptr;
float _current;
bool _dragging;
float _current = 0;
bool _dragging = false;
bool _pausing = false;
protected:
void _notification(int p_what);