core: changed ortho node ID
Fixes collision where transform and ortho nodes had the same ID. Renames ortho ID and automatically corrects old projects with the old ID. Bumps the project version as a result.
This commit is contained in:
+1
-1
@@ -71,7 +71,7 @@
|
||||
namespace olive {
|
||||
|
||||
Core* Core::instance_ = nullptr;
|
||||
const uint Core::kProjectVersion = 201118;
|
||||
const uint Core::kProjectVersion = 201122;
|
||||
|
||||
Core::Core(const CoreParams& params) :
|
||||
main_window_(nullptr),
|
||||
|
||||
@@ -66,7 +66,7 @@ QString MatrixGenerator::ShortName() const
|
||||
|
||||
QString MatrixGenerator::id() const
|
||||
{
|
||||
return QStringLiteral("org.olivevideoeditor.Olive.transform");
|
||||
return QStringLiteral("org.olivevideoeditor.Olive.ortho");
|
||||
}
|
||||
|
||||
QVector<Node::CategoryID> MatrixGenerator::Category() const
|
||||
|
||||
@@ -139,6 +139,14 @@ void Sequence::Load(QXmlStreamReader *reader, XMLNodeData& xml_node_data, uint v
|
||||
}
|
||||
}
|
||||
|
||||
if (version <= 201118) {
|
||||
// After version 201118, the orthographic matrix node ID was changed from
|
||||
// "org.olivevideoeditor.Olive.transform" to "org.olivevideoeditor.Olive.ortho"
|
||||
if (id == QStringLiteral("org.olivevideoeditor.Olive.transform")) {
|
||||
id = QStringLiteral("org.olivevideoeditor.Olive.ortho");
|
||||
}
|
||||
}
|
||||
|
||||
node = NodeFactory::CreateFromID(id);
|
||||
break;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user