Commit c569040c authored by Craig Watson's avatar Craig Watson

Fix for documents not being deleted when dragged to trash

When drag-n-dropping a document to the trash, it would reappear in the
"untitled documents" folder on the next restart. (This was introduced by
bd3d8e95)
parent 8d9fc7b0
......@@ -375,8 +375,10 @@ bool UBDocumentTreeWidget::moveDocument(UBDocumentProxyTreeItem* document, UBDoc
QString destinationFolderName;
if (destinationFolder->isTrashFolder())
if (destinationFolder->isTrashFolder()) {
UBApplication::app()->documentController->moveDocumentToTrash(sourceFolder, document, true);
destinationFolderName = document->proxy()->metaData(UBSettings::documentGroupName).toString();
}
else {
if (destinationFolder->groupName() == UBApplication::app()->documentController->defaultDocumentGroupName())
......
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