diff options
author | Marcelo Fernandez <marcelofg55@gmail.com> | 2017-09-21 00:31:36 -0300 |
---|---|---|
committer | RĂ©mi Verschelde <rverschelde@gmail.com> | 2017-09-23 16:55:00 +0200 |
commit | 46af050e93ddda77fd6316b0d041b8e9e6f0cd49 (patch) | |
tree | e155e527741cfc132b82b52014967849d30b812f /scene/2d | |
parent | 650e0cf3186df2239cbcb6c178533a09732f3f02 (diff) |
Rename get_position => get_playback_position and seek_pos => seek on audio classes
Diffstat (limited to 'scene/2d')
-rw-r--r-- | scene/2d/audio_stream_player_2d.cpp | 6 | ||||
-rw-r--r-- | scene/2d/audio_stream_player_2d.h | 2 |
2 files changed, 4 insertions, 4 deletions
diff --git a/scene/2d/audio_stream_player_2d.cpp b/scene/2d/audio_stream_player_2d.cpp index c11f13d2bd..c40aeb764e 100644 --- a/scene/2d/audio_stream_player_2d.cpp +++ b/scene/2d/audio_stream_player_2d.cpp @@ -284,10 +284,10 @@ bool AudioStreamPlayer2D::is_playing() const { return false; } -float AudioStreamPlayer2D::get_position() { +float AudioStreamPlayer2D::get_playback_position() { if (stream_playback.is_valid()) { - return stream_playback->get_position(); + return stream_playback->get_playback_position(); } return 0; @@ -395,7 +395,7 @@ void AudioStreamPlayer2D::_bind_methods() { ClassDB::bind_method(D_METHOD("stop"), &AudioStreamPlayer2D::stop); ClassDB::bind_method(D_METHOD("is_playing"), &AudioStreamPlayer2D::is_playing); - ClassDB::bind_method(D_METHOD("get_position"), &AudioStreamPlayer2D::get_position); + ClassDB::bind_method(D_METHOD("get_playback_position"), &AudioStreamPlayer2D::get_playback_position); ClassDB::bind_method(D_METHOD("set_bus", "bus"), &AudioStreamPlayer2D::set_bus); ClassDB::bind_method(D_METHOD("get_bus"), &AudioStreamPlayer2D::get_bus); diff --git a/scene/2d/audio_stream_player_2d.h b/scene/2d/audio_stream_player_2d.h index 112d05856b..85104fce21 100644 --- a/scene/2d/audio_stream_player_2d.h +++ b/scene/2d/audio_stream_player_2d.h @@ -72,7 +72,7 @@ public: void seek(float p_seconds); void stop(); bool is_playing() const; - float get_position(); + float get_playback_position(); void set_bus(const StringName &p_bus); StringName get_bus() const; |