+ if (proxyPath.isEmpty()) return;
+ QUndoCommand *proxyCommand = new QUndoCommand();
+ proxyCommand->setText(i18n("Remove Proxy"));
+ QTreeWidgetItemIterator it(m_listView);
+ ProjectItem *item;
+ while (*it) {
+ if ((*it)->type() == PROJECTCLIPTYPE) {
+ item = static_cast <ProjectItem *>(*it);
+ if (item->referencedClip()->getProperty("proxy") == proxyPath) {
+ QMap <QString, QString> props;
+ props.insert("proxy", QString());
+ new EditClipCommand(this, item->clipId(), item->referencedClip()->properties(), props, true, proxyCommand);
+
+ }
+ }
+ ++it;
+ }
+ if (proxyCommand->childCount() == 0)
+ delete proxyCommand;
+ else
+ m_commandStack->push(proxyCommand);
+ QFile::remove(proxyPath);
+}
+
+void ProjectList::setProxyStatus(const QString proxyPath, PROXYSTATUS status, int progress)
+{
+ if (proxyPath.isEmpty() || m_abortAllProxies) return;
+ QTreeWidgetItemIterator it(m_listView);
+ ProjectItem *item;
+ while (*it) {
+ if ((*it)->type() == PROJECTCLIPTYPE) {
+ item = static_cast <ProjectItem *>(*it);
+ if (item->referencedClip()->getProperty("proxy") == proxyPath) {
+ setProxyStatus(item, status, progress);
+ }
+ }
+ ++it;
+ }