mirror of
https://github.com/taglib/taglib.git
synced 2026-04-12 17:09:50 -04:00
Inspection: Type can be replaced with auto
This commit is contained in:
@ -192,7 +192,7 @@ void AttachedPictureFrameV22::parseFields(const ByteVector &data)
|
||||
|
||||
int pos = 1;
|
||||
|
||||
String fixedString = String(data.mid(pos, 3), String::Latin1);
|
||||
auto fixedString = String(data.mid(pos, 3), String::Latin1);
|
||||
pos += 3;
|
||||
// convert fixed string image type to mime string
|
||||
if (fixedString.upper() == "JPG") {
|
||||
|
||||
@ -332,9 +332,9 @@ void FrameFactory::rebuildAggregateFrames(ID3v2::Tag *tag) const
|
||||
tag->frameList("TDRC").size() == 1 &&
|
||||
tag->frameList("TDAT").size() == 1)
|
||||
{
|
||||
TextIdentificationFrame *tdrc =
|
||||
auto tdrc =
|
||||
dynamic_cast<TextIdentificationFrame *>(tag->frameList("TDRC").front());
|
||||
UnknownFrame *tdat = dynamic_cast<UnknownFrame *>(tag->frameList("TDAT").front());
|
||||
auto tdat = dynamic_cast<UnknownFrame *>(tag->frameList("TDAT").front());
|
||||
|
||||
if(tdrc &&
|
||||
tdrc->fieldList().size() == 1 &&
|
||||
@ -346,7 +346,7 @@ void FrameFactory::rebuildAggregateFrames(ID3v2::Tag *tag) const
|
||||
if(date.length() == 4) {
|
||||
tdrc->setText(tdrc->toString() + '-' + date.substr(2, 2) + '-' + date.substr(0, 2));
|
||||
if(tag->frameList("TIME").size() == 1) {
|
||||
UnknownFrame *timeframe = dynamic_cast<UnknownFrame *>(tag->frameList("TIME").front());
|
||||
auto timeframe = dynamic_cast<UnknownFrame *>(tag->frameList("TIME").front());
|
||||
if(timeframe && timeframe->data().size() >= 5) {
|
||||
String time(timeframe->data().mid(1), static_cast<String::Type>(timeframe->data()[0]));
|
||||
if(time.length() == 4) {
|
||||
|
||||
Reference in New Issue
Block a user