1 /* 2 * Copyright 2006, Haiku. 3 * Distributed under the terms of the MIT License. 4 * 5 * Authors: 6 * Stephan Aßmus <superstippi@gmx.de> 7 */ 8 9 #ifndef FREEZE_TRANSFORMATION_COMMAND_H 10 #define FREEZE_TRANSFORMATION_COMMAND_H 11 12 #include "Command.h" 13 14 class Shape; 15 class Transformable; 16 17 class FreezeTransformationCommand : public Command { 18 public: 19 FreezeTransformationCommand( 20 Shape** const shapes, 21 int32 count); 22 virtual ~FreezeTransformationCommand(); 23 24 virtual status_t InitCheck(); 25 26 virtual status_t Perform(); 27 virtual status_t Undo(); 28 29 virtual void GetName(BString& name); 30 31 private: 32 void _ApplyTransformation(Shape* shape, 33 const Transformable& transform); 34 35 Shape** fShapes; 36 double* fOriginalTransformations; 37 int32 fCount; 38 }; 39 40 #endif // FREEZE_TRANSFORMATION_COMMAND_H 41