Q_ASSERT(model->m_subtitleList.count(start)==0);//returns warning if sub at start time position already exists ,i.e. count !=0
//Q_ASSERT(model->m_subtitleList.count(start)==0); //returns warning if sub at start time position already exists ,i.e. count !=0
if(m_subtitleList[start].first==str){
qDebug()<<"already present in model"<<"string :"<<m_subtitleList[start].first<<" start time "<<start.frames(pCore->getCurrentFps())<<"end time : "<<m_subtitleList[start].second.frames(pCore->getCurrentFps());
return;
}
autoit=model->m_subtitleList.lower_bound(start);// returns the key and its value *just* greater than start.
Q_ASSERT(it->first<model->m_subtitleList.end()->second.second);// returns warning if added subtitle start time is less than last subtitle's end time
//Q_ASSERT(it->first < model->m_subtitleList.end()->second.second); // returns warning if added subtitle start time is less than last subtitle's end time
intinsertRow=static_cast<int>(model->m_subtitleList.size());//converts the returned unsigned size() to signed int
/* For adding it in the middle of the list */
if(it!=model->m_subtitleList.end()){// check if the subtitle greater than added subtitle is not the same as the last one