Thin brush panel, preview, and node utility shells

This commit is contained in:
2026-06-16 23:57:39 +02:00
parent cb9751dcc7
commit acee4db356
14 changed files with 402 additions and 302 deletions

View File

@@ -4,12 +4,61 @@
#include "app.h"
#include "asset.h"
#include "legacy_brush_ui_services.h"
#include "node_panel_brush.h"
#include <fstream>
#include <functional>
#include <memory>
void NodePanelBrush::execute_texture_list_plan(const pp::app::BrushTextureListPlan& plan)
{
const auto status = pp::panopainter::execute_legacy_brush_texture_list_plan(*this, plan);
if (!status.ok()) {
LOG("Brush texture list action failed: %s", status.message);
}
}
int NodePanelBrush::find_brush(const std::string& name) const
{
return pp::panopainter::LegacyBrushPanelServices(const_cast<NodePanelBrush&>(*this)).find_brush(name);
}
std::string NodePanelBrush::get_texture_path(int index) const
{
return pp::panopainter::LegacyBrushPanelServices(const_cast<NodePanelBrush&>(*this)).get_texture_path(index);
}
std::string NodePanelBrush::get_thumb_path(int index) const
{
return pp::panopainter::LegacyBrushPanelServices(const_cast<NodePanelBrush&>(*this)).get_thumb_path(index);
}
bool NodePanelBrush::save()
{
return pp::panopainter::LegacyBrushPanelServices(*this).save();
}
bool NodePanelBrush::restore()
{
return pp::panopainter::LegacyBrushPanelServices(*this).restore();
}
void NodePanelBrush::clear()
{
pp::panopainter::LegacyBrushPanelServices(*this).clear();
}
void NodePanelBrush::scan()
{
pp::panopainter::LegacyBrushPanelServices(*this).scan();
}
void NodePanelBrush::reload()
{
pp::panopainter::LegacyBrushPanelServices(*this).reload();
}
namespace pp::panopainter {
LegacyBrushPanelServices::LegacyBrushPanelServices(NodePanelBrush& panel) noexcept