nodeview: implemented copying/pasting nodes

Re-uses XML-based project saving/loading functions to store nodes, their
parameters, and their connections in a text-based format in the clipboard.
This commit is contained in:
itsmattkc
2020-03-15 20:01:58 +11:00
parent 50061e4e55
commit 34f60e639a
24 changed files with 306 additions and 71 deletions
+6 -1
View File
@@ -23,7 +23,7 @@
#include <QDir>
#include <QFileInfo>
#include "common/xmlreadloop.h"
#include "common/xmlutils.h"
#include "core.h"
#include "dialog/progress/progress.h"
#include "window/mainwindow/mainwindow.h"
@@ -137,3 +137,8 @@ ColorManager *Project::color_manager()
{
return &color_manager_;
}
QList<ItemPtr> Project::get_items_of_type(Item::Type type) const
{
return root_.get_children_of_type(type, true);
}