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 TRANSFORM_SHAPES_BOX_H 10 #define TRANSFORM_SHAPES_BOX_H 11 12 #include "CanvasTransformBox.h" 13 14 class Shape; 15 16 class TransformShapesBox : public CanvasTransformBox { 17 public: 18 TransformShapesBox(CanvasView* view, 19 const Shape** objects, 20 int32 count); 21 virtual ~TransformShapesBox(); 22 23 // Observer interface (Manipulator is an Observer) 24 virtual void ObjectChanged(const Observable* object); 25 26 // TransformBox interface 27 virtual void Update(bool deep = true); 28 29 virtual TransformCommand* MakeCommand(const char* actionName, 30 uint32 nameIndex); 31 32 // TransformShapesBox 33 Shape** Shapes() const 34 { return fShapes; } 35 int32 CountShapes() const 36 { return fCount; } 37 38 private: 39 Shape** fShapes; 40 int32 fCount; 41 42 // saves the transformable objects transformation states 43 // prior to this transformation 44 double* fOriginals; 45 46 Transformable fParentTransform; 47 }; 48 49 #endif // TRANSFORM_SHAPES_BOX_H 50 51