This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
There is a flaw in the CloneableEditorSupport.wrapEditorComponent() method I introduced in issue 60922. This method was introduced to allow the editor component of a CloneableEditor to be wrapped in a more complicated UI. It gets a Component containing the editor pane and is expected to return a Component which contains the first one. The returned component is added to the CloneableEditor. However, because wrapEditorComponent() is in CloneableEditorSupport and doesn't know anything about CloneableEditor, it is impossible to map the returned component to the CloneableEditor this component is added to. I see three ways to fix this: - the method could be removed from CES and added to CE - the method in CES could be deprecated and a new one added to CE - a new method with a CE parameter could be added to CES The first solution is the most clean one IMO. I don't know if it's possible to make an incompatible change at this point. If yes, I would like to implement it cf. the attached diff.
Created attachment 27349 [details] Proposed change
Yarda showed me today the API change can be made compatibly by adding a wrapEditorComponent() method to CloneableEditor which delegates to CES.wEC(). Yarda also convinced me that I don't really need this API change for what I need to do in the SQL editor. Considering the API change can be done compatibly later and that it maybe won't be needed at all for the features in promo-G, I don't see a reason to push it now. I'm attaching an updated diff though, it will be helpful if I decide to reopen later. Yardo, thanks for your help!
Created attachment 27406 [details] Proposed compatible change