<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><div dir="ltr"><div class="gmail_extra"><br></div><div class="gmail_extra"><span style="font-size:12.8000001907349px">KisCanvasResourceProvider is the class that in the central managing the resources so the preset should be coordinated there, maybe make a sub manager class there. </span><span style="font-size:12.8000001907349px">I would keep the KoResourceItemChooser as it is.</span></div><div class="gmail_extra"><br></div></div></blockquote><div>Well i will still have to modify it because currently it doesn't give enough flexibility to be composed with other classes/widgets, as with the case of the relayout: it chooses not to inform through signals that a new resource has been selected, so you end up having only a visual selection of the resource (while having no choice on what it should actually select).</div><div><br></div><div>Also the distinction between UI and NonUI call paths it's pretty important (KoResourceItemChooser::activate can be called due to a call to setCurrentResource/setCurrentItem, or due to an actual input from the chooser UI).</div><div>In this case while the call paths comes from setCurrentResource, the activate function shouldn't be called, otherwise classes handling the resourceSelected signal will think that another resource is selected and unnecessary work to check if it's a valid selection has to be done.</div><div><br></div><div>Modifications on how it deals with slotBeforeResourcesLayoutReset and slotAfterResourcesLayoutReset() have to be done too.</div>

</div></div></div>