#ifndef TOOLROTATE_H_ #define TOOLROTATE_H_ #include "Tool.h" #include "SidebarView.h" #include "Renderer.h" class ToolRotate : public Tool, private EventHandler, private Renderer { private: GtkWidget *image; EditManager *editManager; SidebarView sidebar; bool pressed, valid; float angle; Vertex v0, v; // prevent shallow copy ToolRotate(const ToolRotate &t); const ToolRotate& operator=(const ToolRotate &t); public: ToolRotate(EditManager *editManager); virtual ~ToolRotate(); virtual void activate(); virtual const char *getType() const { return "ToolRotate"; } virtual const char *getName() const { return "Rotate"; } virtual bool isSensitive() { return TRUE; } virtual GtkWidget *getImage() { return image; } virtual EventHandler* getEventHandler() { return this; } virtual bool buttonPress(unsigned int button); virtual bool buttonRelease(unsigned int button); virtual bool motion(); virtual Renderer *getRenderer() { return this; } virtual void render(const Level &level, const Rectangle &rect, float scale); virtual Sidebar* getSidebar() { return &sidebar; } }; #endif /*TOOLROTATE_H_*/