Some optimizations
This commit is contained in:
parent
9466bf5f2b
commit
bab4d91a78
@ -280,7 +280,7 @@ inline bool FileMatroska::IsMyTrack(const Track * aTrack) const
|
|||||||
if (aTrack == 0)
|
if (aTrack == 0)
|
||||||
throw 0;
|
throw 0;
|
||||||
|
|
||||||
for (std::vector<Track*>::const_iterator i = myTracks.begin(); i != myTracks.end(); i ++) {
|
for (std::vector<Track*>::const_iterator i = myTracks.begin(); i != myTracks.end(); ++i) {
|
||||||
if (*i == aTrack)
|
if (*i == aTrack)
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
@ -296,7 +296,7 @@ void FileMatroska::SelectReadingTrack(Track * aTrack, bool select)
|
|||||||
if (IsMyTrack(aTrack)) {
|
if (IsMyTrack(aTrack)) {
|
||||||
// here we have the right track
|
// here we have the right track
|
||||||
// check if it's not already selected
|
// check if it's not already selected
|
||||||
for (std::vector<uint8>::iterator j = mySelectedTracks.begin(); j != mySelectedTracks.end(); j ++) {
|
for (std::vector<uint8>::iterator j = mySelectedTracks.begin(); j != mySelectedTracks.end(); ++j) {
|
||||||
if (*j == aTrack->TrackNumber())
|
if (*j == aTrack->TrackNumber())
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
@ -314,7 +314,7 @@ inline bool FileMatroska::IsReadingTrack(const uint8 aTrackNumber) const
|
|||||||
{
|
{
|
||||||
for (std::vector<uint8>::const_iterator trackIdx = mySelectedTracks.begin();
|
for (std::vector<uint8>::const_iterator trackIdx = mySelectedTracks.begin();
|
||||||
trackIdx != mySelectedTracks.end() && *trackIdx < aTrackNumber;
|
trackIdx != mySelectedTracks.end() && *trackIdx < aTrackNumber;
|
||||||
trackIdx++) {}
|
++trackIdx) {}
|
||||||
|
|
||||||
if (trackIdx == mySelectedTracks.end())
|
if (trackIdx == mySelectedTracks.end())
|
||||||
return false;
|
return false;
|
||||||
|
@ -89,7 +89,7 @@ KaxInternalBlock::KaxInternalBlock(const KaxInternalBlock & ElementToClone)
|
|||||||
std::vector<DataBuffer *>::iterator myItr = myBuffers.begin();
|
std::vector<DataBuffer *>::iterator myItr = myBuffers.begin();
|
||||||
while (Itr != ElementToClone.myBuffers.end()) {
|
while (Itr != ElementToClone.myBuffers.end()) {
|
||||||
*myItr = (*Itr)->Clone();
|
*myItr = (*Itr)->Clone();
|
||||||
Itr++; myItr++;
|
++Itr; ++myItr;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user