QDomElement e = item->toXml();
// Make sure we get the correct producer length if it was adjusted in timeline
if (t == COLOR || t == IMAGE || t == SLIDESHOW || t == TEXT) {
- int length = QString(clip->producerProperty("length")).toInt();
- if (length > 0 && !e.hasAttribute("length")) {
- e.setAttribute("length", length);
- }
+ int length = QString(clip->producerProperty("length")).toInt();
+ if (length > 0 && !e.hasAttribute("length")) {
+ e.setAttribute("length", length);
+ }
+ e.setAttribute("duration", clip->getProperty("duration"));
}
resetThumbsProducer(clip);
m_render->getFileProperties(e, item->clipId(), m_listView->iconSize().height(), true);
}
}
if (m_jobList.isEmpty()) return;
- int count = 0;
+
m_jobMutex.lock();
+ int count = 0;
for (int i = 0; i < m_jobList.count(); i++) {
if (m_jobList.at(i)->status() == JOBWORKING || m_jobList.at(i)->status() == JOBWAITING)
count ++;
i--;
}
}
-
- emit jobCount(count);
+ emit jobCount(count);
m_jobMutex.unlock();
-
if (m_jobThreads.futures().isEmpty() || m_jobThreads.futures().count() < KdenliveSettings::proxythreads()) m_jobThreads.addFuture(QtConcurrent::run(this, &ProjectList::slotProcessJobs));
}
MeltJob *jb = static_cast<MeltJob *> (job);
jb->setProducer(currentClip->getProducer(), currentClip->fileURL());
if (jb->isProjectFilter())
- connect(job, SIGNAL(gotFilterJobResults(QString,int, int, stringMap,stringMap)), this, SLOT(slotGotFilterJobResults(QString,int, int,stringMap,stringMap)));
+ connect(job, SIGNAL(gotFilterJobResults(QString,int, int, stringMap,stringMap)), this, SLOT(slotGotFilterJobResults(QString,int, int,stringMap,stringMap)));
else
connect(job, SIGNAL(gotFilterJobResults(QString,int, int, stringMap,stringMap)), this, SIGNAL(gotFilterJobResults(QString,int, int,stringMap,stringMap)));
}
job->description = description;
m_jobList.append(job);
setJobStatus(item, job->jobType, JOBWAITING, 0, job->statusMessage());
+ slotCheckJobProcess();
}
- slotCheckJobProcess();
}
+
void ProjectList::slotPrepareJobsMenu()
{
//kDebug()<<"// FILTER RES:\n"<<filterInfo<<"\n--------------\n"<<results;
ProjectItem *clip = getItemById(id);
if (!clip) return;
+
// Check for return value
int markersType = -1;
if (filterInfo.contains("addmarkers")) markersType = filterInfo.value("addmarkers").toInt();