From 46af050e93ddda77fd6316b0d041b8e9e6f0cd49 Mon Sep 17 00:00:00 2001 From: Marcelo Fernandez Date: Thu, 21 Sep 2017 00:31:36 -0300 Subject: Rename get_position => get_playback_position and seek_pos => seek on audio classes --- scene/audio/audio_player.cpp | 6 +++--- scene/audio/audio_player.h | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) (limited to 'scene/audio') diff --git a/scene/audio/audio_player.cpp b/scene/audio/audio_player.cpp index 11e6c1b2e1..14dd39a491 100644 --- a/scene/audio/audio_player.cpp +++ b/scene/audio/audio_player.cpp @@ -193,10 +193,10 @@ bool AudioStreamPlayer::is_playing() const { return false; } -float AudioStreamPlayer::get_position() { +float AudioStreamPlayer::get_playback_position() { if (stream_playback.is_valid()) { - return stream_playback->get_position(); + return stream_playback->get_playback_position(); } return 0; @@ -284,7 +284,7 @@ void AudioStreamPlayer::_bind_methods() { ClassDB::bind_method(D_METHOD("stop"), &AudioStreamPlayer::stop); ClassDB::bind_method(D_METHOD("is_playing"), &AudioStreamPlayer::is_playing); - ClassDB::bind_method(D_METHOD("get_position"), &AudioStreamPlayer::get_position); + ClassDB::bind_method(D_METHOD("get_playback_position"), &AudioStreamPlayer::get_playback_position); ClassDB::bind_method(D_METHOD("set_bus", "bus"), &AudioStreamPlayer::set_bus); ClassDB::bind_method(D_METHOD("get_bus"), &AudioStreamPlayer::get_bus); diff --git a/scene/audio/audio_player.h b/scene/audio/audio_player.h index 19b61ea5d8..4bfc44730d 100644 --- a/scene/audio/audio_player.h +++ b/scene/audio/audio_player.h @@ -83,7 +83,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; -- cgit v1.2.3