s4gh commented on PR #7925: URL: https://github.com/apache/netbeans/pull/7925#issuecomment-3284289695
@neilcsmith-net thank you for comment. I can make approach with adding icon to action and loading action with Utilities.actionsForPath work for "collapseAll" action defined here - https://github.com/apache/netbeans/blob/d10bf812d744914b323ab01d5266bf4e836de602/ide/projectui/src/org/netbeans/modules/project/ui/ProjectTab.java#L880 This works because all action needs to know whether is is physical or logical view and you know this during creation of the view. However I am having some issues applying same approach to "navigate to" actions. There are 2 of them - for logical and physical views actions are separate. 1. when I add iconBase here https://github.com/apache/netbeans/blob/d10bf812d744914b323ab01d5266bf4e836de602/ide/projectui/src/org/netbeans/modules/project/ui/actions/SelectNodeAction.java#L44 I am getting warning in NetBeans "iconBase unused on eager registrations". And there is icon usage here https://github.com/apache/netbeans/blob/d10bf812d744914b323ab01d5266bf4e836de602/ide/projectui/src/org/netbeans/modules/project/ui/actions/SelectNodeAction.java#L63 - but this is not the icon I want. It will be confusion to use icon for "Project" or "Files" view in "navigate to" action. 2. to navigate to a file which is opened in active code editor tab I need to put corrsponding file object into action context https://github.com/s4gh/netbeans/blob/d5eded2b93f9e66ca8a0bba2db4cec687fe0b024/ide/projectui/src/org/netbeans/modules/project/ui/ProjectTab.java#L272 I can't do this one time in constructor. I need to update context every time someone click "navigate to" button sine "active file" will change over time. So Actions.connect(button, action) is not enough in this case. Based on this is this ok for me to keep exiting approach for "navigate to" button? Or is there any way to address both this issues to work with Utilities.actionsForPath and Actions.connect(button, action) ? -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: notifications-unsubscr...@netbeans.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: notifications-unsubscr...@netbeans.apache.org For additional commands, e-mail: notifications-h...@netbeans.apache.org For further information about the NetBeans mailing lists, visit: https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists