mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 02:07:36 +00:00
PixelPaint: Add a new "Rectangle Select" tool :^)
This patch only adds the tool along with a toolbar icon for it. It doesn't do anything yet.
This commit is contained in:
parent
ab840423a8
commit
4bd905de0e
5 changed files with 62 additions and 0 deletions
24
Userland/Applications/PixelPaint/RectangleSelectTool.h
Normal file
24
Userland/Applications/PixelPaint/RectangleSelectTool.h
Normal file
|
@ -0,0 +1,24 @@
|
|||
/*
|
||||
* Copyright (c) 2021, Andreas Kling <kling@serenityos.org>
|
||||
*
|
||||
* SPDX-License-Identifier: BSD-2-Clause
|
||||
*/
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "Tool.h"
|
||||
|
||||
namespace PixelPaint {
|
||||
|
||||
class RectangleSelectTool final : public Tool {
|
||||
public:
|
||||
RectangleSelectTool();
|
||||
virtual ~RectangleSelectTool();
|
||||
|
||||
virtual void on_mousedown(Layer&, GUI::MouseEvent&, GUI::MouseEvent&) override;
|
||||
virtual void on_mousemove(Layer&, GUI::MouseEvent&, GUI::MouseEvent&) override;
|
||||
virtual void on_mouseup(Layer&, GUI::MouseEvent&, GUI::MouseEvent&) override;
|
||||
virtual void on_second_paint(Layer const&, GUI::PaintEvent&) override;
|
||||
};
|
||||
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue