Proofreading (#1155)

---------

Co-authored-by: Urs Fleisch <ufleisch@users.sourceforge.net>
This commit is contained in:
nmariusp
2023-10-08 06:58:33 +03:00
committed by GitHub
parent 2e3a66cc31
commit 3f25d3c342
12 changed files with 27 additions and 29 deletions

View File

@@ -143,7 +143,7 @@ Frame *Frame::createTextualFrame(const String &key, const StringList &values) //
frame->setText(values.front());
return frame;
}
// if non of the above cases apply, we use a TXXX frame with the key as description
// if none of the above cases apply, we use a TXXX frame with the key as description
return new UserTextIdentificationFrame(keyToTXXX(key), values, String::UTF8);
}

View File

@@ -193,7 +193,7 @@ Frame *FrameFactory::createFrame(const ByteVector &data, Frame::Header *header,
ByteVector frameID = header->frameID();
// This is where things get necessarily nasty. Here we determine which
// Frame subclass (or if none is found simply an Frame) based
// Frame subclass (or if none is found simply a Frame) based
// on the frame ID. Since there are a lot of possibilities, that means
// a lot of if blocks.
@@ -488,7 +488,7 @@ bool FrameFactory::updateFrame(Frame::Header *header) const
return false;
}
// ID3v2.2 only used 3 bytes for the frame ID, so we need to convert all of
// ID3v2.2 only used 3 bytes for the frame ID, so we need to convert all
// the frames to their 4 byte ID3v2.4 equivalent.
for(const auto &[o, t] : frameConversion2) {

View File

@@ -182,7 +182,7 @@ String ID3v2::Tag::genre() const
// ID3v2.4 lists genres as the fields in its frames field list. If the field
// is simply a number it can be assumed that it is an ID3v1 genre number.
// Here was assume that if an ID3v1 string is present that it should be
// Here was assumed that if an ID3v1 string is present then it should be
// appended to the genre string. Multiple fields will be appended as the
// string is built.

View File

@@ -220,7 +220,7 @@ void MPEG::Header::parse(File *file, offset_t offset, bool checkLength)
std::array { 11025, 12000, 8000, 0 } // Version 2.5
};
// The sample rate index is encoded as two bits in the 3nd byte, i.e. xxxx11xx
// The sample rate index is encoded as two bits in the 3rd byte, i.e. xxxx11xx
const int samplerateIndex = (static_cast<unsigned char>(data[2]) >> 2) & 0x03;
@@ -230,7 +230,7 @@ void MPEG::Header::parse(File *file, offset_t offset, bool checkLength)
return;
}
// The channel mode is encoded as a 2 bit value at the end of the 3nd byte,
// The channel mode is encoded as a 2 bit value at the end of the 3rd byte,
// i.e. xxxxxx11
d->channelMode = static_cast<ChannelMode>((static_cast<unsigned char>(data[3]) >> 6) & 0x03);