Open IR0NSIGHT opened 3 weeks ago
addition: on first glance it seems impossible to get a clean solution for reverse engineering a radius operation too. App will call setRadius on RadiusOperations. There is no preexisting hook for keyboard/mouseevents as far as i can tell too
so no way to catch a mousewheel event without extra steps.
I thought I already addressed this in the snapshot version I delivered, but it's been a while so maybe not, or this is something new. I'll take a look.
Yes there was a similar problem: FilteredOperation
Basically all existing operations (inheriting from abstractoperation) require a WorldPainterView for their constructor. WorldPainterView is hidden inside App, which is a. private field, b. not part of public api
Therefore its impossible for plugins right now to inherit and instantiate operations that are more specialized than AbstractBrushOperation
But i would really like to use RadiusOperation for my plugin.
Right now: public List AbstractPlugins.getOperations()
delivers operations.
I suggest instead: public List getOperations(WorldPainterView view)
to allow plugins to use the full range of preexisting operations. AbstractPlugins.getOperations() can be kept or deprecated.
alternatively a App.getView or dimension.getWorldView getter would also do.