From 9cede44af6f22cce192495af69986961b0837379 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Luk=C3=A1=C5=A1=20Lalinsk=C3=BD?= Date: Sun, 4 Nov 2012 09:54:17 +0100 Subject: [PATCH] Remove deprecated constructor from FLAC::Properties --- taglib/flac/flacproperties.cpp | 10 ++-------- taglib/flac/flacproperties.h | 10 +--------- 2 files changed, 3 insertions(+), 17 deletions(-) diff --git a/taglib/flac/flacproperties.cpp b/taglib/flac/flacproperties.cpp index 57de55f4..92f69bdc 100644 --- a/taglib/flac/flacproperties.cpp +++ b/taglib/flac/flacproperties.cpp @@ -34,7 +34,7 @@ using namespace TagLib; class FLAC::Properties::PropertiesPrivate { public: - PropertiesPrivate(ByteVector d, offset_t st, ReadStyle s) : + PropertiesPrivate(const ByteVector &d, offset_t st, ReadStyle s) : data(d), streamLength(st), style(s), @@ -61,18 +61,12 @@ public: // public members //////////////////////////////////////////////////////////////////////////////// -FLAC::Properties::Properties(ByteVector data, offset_t streamLength, ReadStyle style) : AudioProperties(style) +FLAC::Properties::Properties(const ByteVector &data, offset_t streamLength, ReadStyle style) : AudioProperties(style) { d = new PropertiesPrivate(data, streamLength, style); read(); } -FLAC::Properties::Properties(File *file, ReadStyle style) : AudioProperties(style) -{ - d = new PropertiesPrivate(file->streamInfoData(), file->streamLength(), style); - read(); -} - FLAC::Properties::~Properties() { delete d; diff --git a/taglib/flac/flacproperties.h b/taglib/flac/flacproperties.h index 8b59b4d9..a3f6a5fe 100644 --- a/taglib/flac/flacproperties.h +++ b/taglib/flac/flacproperties.h @@ -49,15 +49,7 @@ namespace TagLib { * Create an instance of FLAC::Properties with the data read from the * ByteVector \a data. */ - // BIC: switch to const reference - Properties(ByteVector data, offset_t streamLength, ReadStyle style = Average); - - /*! - * Create an instance of FLAC::Properties with the data read from the - * FLAC::File \a file. - */ - // BIC: remove - Properties(File *file, ReadStyle style = Average); + Properties(const ByteVector &data, offset_t streamLength, ReadStyle style = Average); /*! * Destroys this FLAC::Properties instance.