Members of the KDE Community are recommended to subscribe to the kde-community mailing list at https://mail.kde.org/mailman/listinfo/kde-community to allow them to participate in important discussions and receive other important announcements

Commit aa68b1aa authored by Jason Wood's avatar Jason Wood

Fixed some indentation.

Ensure that scenelist generation is on when we create a new document,

svn path=/trunk/kdenlive/; revision=318
parent ff9e7282
......@@ -94,12 +94,12 @@ void KdenliveDoc::removeView(KdenliveView *view)
void KdenliveDoc::setURL(const KURL &url)
{
m_doc_url=url;
m_doc_url=url;
}
const KURL& KdenliveDoc::URL() const
{
return m_doc_url;
return m_doc_url;
}
void KdenliveDoc::slotUpdateAllViews(KdenliveView *sender)
......@@ -172,6 +172,8 @@ bool KdenliveDoc::newDocument()
{
kdDebug() << "Creating new document" << endl;
m_sceneListGeneration = true;
deleteContents();
addVideoTrack();
......@@ -192,18 +194,19 @@ bool KdenliveDoc::openDocument(const KURL& url, const char *format)
if(url.isEmpty()) return false;
if(url.filename().right(9) == ".kdenlive") {
QString tmpfile;
if(KIO::NetAccess::download( url, tmpfile )) {
QFile file(tmpfile);
if(file.open(IO_ReadOnly)) {
QDomDocument doc;
doc.setContent(&file, false);
loadFromXML(doc);
}
KIO::NetAccess::removeTempFile( tmpfile );
setModified(false);
return true;
}
QString tmpfile;
if(KIO::NetAccess::download( url, tmpfile )) {
QFile file(tmpfile);
if(file.open(IO_ReadOnly)) {
QDomDocument doc;
doc.setContent(&file, false);
loadFromXML(doc);
setURL(url);
}
KIO::NetAccess::removeTempFile( tmpfile );
setModified(false);
return true;
}
emit trackListChanged();
} else {
......@@ -378,7 +381,7 @@ int KdenliveDoc::trackIndex(DocTrackBase *track) const
void KdenliveDoc::setModified(bool state)
{
if(m_modified != state) {
m_modified = state;
m_modified = state;
emit modified(state);
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment