2025-07-06 20:43:53 +03:00
|
|
|
#pragma once
|
|
|
|
|
#include <include/core/SkCanvas.h>
|
|
|
|
|
#include "../DrawData.hpp"
|
|
|
|
|
#include "../DrawComponents/DrawComponent.hpp"
|
|
|
|
|
|
|
|
|
|
class DrawingProgram;
|
|
|
|
|
|
|
|
|
|
class EraserTool {
|
|
|
|
|
public:
|
|
|
|
|
EraserTool(DrawingProgram& initDrawP);
|
|
|
|
|
void gui_toolbox();
|
|
|
|
|
void tool_update();
|
2025-07-23 16:04:16 +03:00
|
|
|
void reset_tool();
|
2025-07-06 20:43:53 +03:00
|
|
|
void draw(SkCanvas* canvas, const DrawData& drawData);
|
2025-07-26 21:20:14 +03:00
|
|
|
|
2025-07-27 16:53:22 +03:00
|
|
|
bool prevent_undo_or_redo();
|
|
|
|
|
|
2025-07-24 16:35:48 +03:00
|
|
|
std::unordered_set<CollabListType::ObjectInfoPtr> erasedComponents;
|
|
|
|
|
std::unordered_set<std::shared_ptr<DrawingProgramCacheBVHNode>> erasedBVHNodes;
|
2025-07-26 21:20:14 +03:00
|
|
|
private:
|
2025-07-06 20:43:53 +03:00
|
|
|
|
|
|
|
|
DrawingProgram& drawP;
|
|
|
|
|
};
|