29 #include <Inventor/SbRotation.h>
30 #include <Inventor/SbVec3f.h>
36 const std::shared_ptr<memoryxcontroller::MemoryXController>& memoryXController,
37 const std::shared_ptr<scene3D::Scene>& scene,
38 const std::string& objectId,
39 const SbRotation& oldRotation,
40 const SbRotation& newRotation,
41 const SbVec3f& oldPosition,
42 const SbVec3f& newPosition) :
43 Operation(memoryXController, scene, objectId),
44 oldRotation(oldRotation),
45 newRotation(newRotation),
46 oldPosition(oldPosition),
47 newPosition(newPosition)
54 std::shared_ptr<controller::Operation> inverseOperation(
62 return inverseOperation;
68 getMemoryXController()->getWorkingMemoryController()->rotateTranslateObject(
69 getObjectId(), newRotation, newPosition);
75 std::shared_ptr<scene3D::Scene> scene = getScene();
80 throw std::logic_error(
"Object does not exist");
83 object->setRotation(newRotation);
84 object->setTranslation(newPosition);
87 scene->getManipulatorManager()->applyManipulator(
object);
89 if (scene->getSelectionManager()->isSelected(
object))
91 scene->getManipulatorManager()->addManipulator(
object);
98 std::shared_ptr<scene3D::Scene> scene = getScene();
106 return object->isMutable();