From a927672c27883ee9f40f8b180966b6ff1802699d Mon Sep 17 00:00:00 2001 From: Thomas Goyne Date: Sun, 8 Jan 2012 01:33:33 +0000 Subject: [PATCH] Remove unused private variables in AudioProvider Originally committed to SVN as r6222. --- aegisub/src/audio_provider.cpp | 18 +----------------- aegisub/src/include/aegisub/audio_provider.h | 18 ++++++------------ 2 files changed, 7 insertions(+), 29 deletions(-) diff --git a/aegisub/src/audio_provider.cpp b/aegisub/src/audio_provider.cpp index 62d123ac7..0d8ce5518 100644 --- a/aegisub/src/audio_provider.cpp +++ b/aegisub/src/audio_provider.cpp @@ -56,17 +56,6 @@ #include "frame_main.h" #include "main.h" -/// @brief Constructor -/// -AudioProvider::AudioProvider() : raw(NULL) { -} - -/// @brief Destructor -/// -AudioProvider::~AudioProvider() { - delete[] raw; -} - /// @brief Get audio with volume /// @param buf /// @param start @@ -102,12 +91,7 @@ void AudioProvider::GetAudioWithVolume(void *buf, int64_t start, int64_t count, } } -/// @brief Get provider -/// @param filename -/// @param cache -/// @return -/// -AudioProvider *AudioProviderFactory::GetProvider(wxString filename, int cache) { +AudioProvider *AudioProviderFactory::GetProvider(wxString const& filename, int cache) { AudioProvider *provider = NULL; bool found = false; std::string msg; diff --git a/aegisub/src/include/aegisub/audio_provider.h b/aegisub/src/include/aegisub/audio_provider.h index eda834d35..6eb6900b2 100644 --- a/aegisub/src/include/aegisub/audio_provider.h +++ b/aegisub/src/include/aegisub/audio_provider.h @@ -48,16 +48,7 @@ /// /// DOCME class AudioProvider { -private: - - /// DOCME - char *raw; - - /// DOCME - int raw_len; - protected: - /// DOCME int channels; @@ -75,8 +66,7 @@ protected: wxString filename; public: - AudioProvider(); - virtual ~AudioProvider(); + virtual ~AudioProvider() { } virtual wxString GetFilename() const { return filename; }; virtual void GetAudio(void *buf, int64_t start, int64_t count) const = 0; @@ -100,7 +90,11 @@ public: class AudioProviderFactory : public Factory1 { public: static void RegisterProviders(); - static AudioProvider *GetProvider(wxString filename, int cache=-1); + + /// Get a provider for the file + /// @param filename URI to open + /// @param cache Caching mode + static AudioProvider *GetProvider(wxString const& filename, int cache=-1); }; DEFINE_BASE_EXCEPTION_NOINNER(AudioProviderError, agi::Exception)