Commit 7a4a2d0f authored by Ilia Ryabokon's avatar Ilia Ryabokon

Group container copy scene

parent 559c0bcd
......@@ -205,6 +205,14 @@ UBGraphicsGroupContainerItem *UBGraphicsGroupContainerItem::deepCopy() const
copyItemParameters(copy);
foreach (QGraphicsItem *it, childItems()) {
UBItem *childAsUBItem = dynamic_cast<UBItem*>(it);
if (childAsUBItem) {
QGraphicsItem *cloneItem = dynamic_cast<QGraphicsItem*>(childAsUBItem->deepCopy());
copy->addToGroup(cloneItem);
}
}
return copy;
}
......
......@@ -22,9 +22,6 @@
* along with OpenBoard. If not, see <http://www.gnu.org/licenses/>.
*/
#include "UBDocumentTreeWidget.h"
#include "document/UBDocumentProxy.h"
......@@ -323,6 +320,7 @@ void UBDocumentTreeWidget::dropEvent(QDropEvent *event)
if (scene)
{
UBGraphicsScene* sceneClone = scene->sceneDeepCopy();
// UBGraphicsScene* sceneClone = scene;
UBDocumentProxy *targetDocProxy = targetProxyTreeItem->proxy();
......
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