Krita is a free and open source cross-platform application that offers an end-to-end solution for creating digital art files from scratch built on the KDE and Qt frameworks.
C++
Remove KoDocumentResourceManager::globalShapeController()
Dmitry Kazakov0481eea90177
diff --git a/libs/flake/KoDocumentResourceManager.cpp b/libs/flake/KoDocumentResourceManager.cppindex a308e1e230..a54110f74f 100644--- a/libs/flake/KoDocumentResourceManager.cpp+++ b/libs/flake/KoDocumentResourceManager.cpp@@ -142,18 +142,3 @@ QRectF KoDocumentResourceManager::documentRectInPixels() constKIS_SAFE_ASSERT_RECOVER_RETURN_VALUE(hasResource(DocumentRectInPixels), QRectF(0,0, 777, 666));return resource(DocumentRectInPixels).toRectF();}--KoShapeController *KoDocumentResourceManager::globalShapeController() const-{- if (!hasResource(GlobalShapeController))- return 0;-- return resource(GlobalShapeController).value<KoShapeController *>();-}--void KoDocumentResourceManager::setGlobalShapeController(KoShapeController *shapeController)-{- QVariant variant;- variant.setValue(shapeController);- setResource(GlobalShapeController, variant);-}diff --git a/libs/flake/KoDocumentResourceManager.h b/libs/flake/KoDocumentResourceManager.hindex 01ec44a360..02615291a4 100644--- a/libs/flake/KoDocumentResourceManager.h+++ b/libs/flake/KoDocumentResourceManager.h@@ -59,7 +59,6 @@ enum DocumentResource {OdfDocument, ///< OBSOLETE The document this canvas showsGrabSensitivity, ///< The grab sensitivity used for grabbing handles of any kindMarkerCollection, ///< The collection holding all markers- GlobalShapeController, ///< The KoShapeController for the documentDocumentResolution, ///< Pixels-per-inch resoluton of the documentDocumentRectInPixels, ///< Bounds of the document in pixels@@ -204,14 +203,6 @@ enum DocumentResource {qreal documentResolution() const;QRectF documentRectInPixels() const;- /**- * TODO: remove these methods after legacy ODF text shape is removed.- * New code must use documentResolution() and documentRectInPixels()- * instead.- */- Q_DECL_DEPRECATED KoShapeController *globalShapeController() const;- Q_DECL_DEPRECATED void setGlobalShapeController(KoShapeController *globalShapeController);-Q_SIGNALS:/*** This signal is emitted every time a resource is set that is eitherdiff --git a/libs/ui/KisDocument.cpp b/libs/ui/KisDocument.cppindex 34f1198097..71ce6cd3c4 100644--- a/libs/ui/KisDocument.cpp+++ b/libs/ui/KisDocument.cpp@@ -631,7 +631,6 @@ KisDocument::KisDocument(bool addStorage)d->shapeController = new KisShapeController(d->nserver, d->undoStack, this);d->koShapeController = new KoShapeController(0, d->shapeController);- d->shapeController->resourceManager()->setGlobalShapeController(d->koShapeController);slotConfigChanged();}@@ -1209,7 +1208,6 @@ void KisDocument::copyFromDocumentImpl(const KisDocument &rhs, CopyPolicy policyd->shapeController = new KisShapeController(d->nserver, d->undoStack, this);d->koShapeController = new KoShapeController(0, d->shapeController);- d->shapeController->resourceManager()->setGlobalShapeController(d->koShapeController);}setObjectName(rhs.objectName());