Change how tools get switched

This commit is contained in:
Yousef Khadadeh 2025-08-02 20:39:21 +03:00
parent 90374da228
commit c2301ae9f5
27 changed files with 68 additions and 96 deletions

View file

@ -133,8 +133,6 @@ void DrawingProgramSelection::deselect_all() {
DrawComponent::client_send_transform_many(drawP, transformsToSend);
drawP.reset_tools();
if(!isSingleThread)
drawP.force_rebuild_cache();
@ -159,8 +157,6 @@ void DrawingProgramSelection::deselect_all() {
DrawComponent::client_send_transform_many(drawP, transformsToSend);
drawP.reset_tools();
if(!isSingleThread)
drawP.force_rebuild_cache();
@ -326,7 +322,7 @@ void DrawingProgramSelection::update() {
void DrawingProgramSelection::paste_clipboard() {
auto& clipboard = drawP.world.main.clipboard;
drawP.controls.selectedTool = DrawingProgramToolType::RECTSELECT;
drawP.switch_to_tool(DrawingProgramToolType::RECTSELECT);
uint64_t allPlacement = drawP.components.client_list().size();
std::vector<std::shared_ptr<DrawComponent>> placedComponents;