mirror of
https://github.com/RGBCube/serenity
synced 2025-07-13 19:37:34 +00:00

Also add a Tool base class, and an empty BucketTool subclass which is the next thing to implement.
18 lines
372 B
C++
18 lines
372 B
C++
#pragma once
|
|
|
|
class GMouseEvent;
|
|
class PaintableWidget;
|
|
|
|
class Tool {
|
|
public:
|
|
virtual ~Tool();
|
|
|
|
virtual const char* class_name() const = 0;
|
|
|
|
virtual void on_mousedown(PaintableWidget&, GMouseEvent&) { }
|
|
virtual void on_mousemove(PaintableWidget&, GMouseEvent&) { }
|
|
virtual void on_mouseup(PaintableWidget&, GMouseEvent&) { }
|
|
|
|
protected:
|
|
Tool();
|
|
};
|