Can 'Show Asset in...' be added in Customization menu?

SnowSultanSnowSultan Posts: 3,596

Does anyone happen to know if this function, the "Show Asset in - Content Library > Mapped Folder" option that can be brought up by right-clicking on an item in the Smart Content panel, is available in the Customization menu? I checked the Content Library, Smart Content, and a bunch of other sections, but cannot find that particular selection. Thanks for any information.

show_assets.jpg
342 x 195 - 30K

Comments

  • Richard HaseltineRichard Haseltine Posts: 100,960

    I can't immediately see it, no.

  • Richard HaseltineRichard Haseltine Posts: 100,960

    Richard Haseltine said:

    I can't immediately see it, no.

    officially confirmed, I'm afraid.

  • SnowSultanSnowSultan Posts: 3,596

    No problem, thanks for checking. I use it a lot because Smart Content just piles everything together in the product folder, but it's not that big of a deal to right click and find it. Appreciated.

  • Richard HaseltineRichard Haseltine Posts: 100,960

    SnowSultan said:

    No problem, thanks for checking. I use it a lot because Smart Content just piles everything together in the product folder, but it's not that big of a deal to right click and find it. Appreciated.

    Yes, it's necessary with (almost) anything that relies on folder structure to show how a product should be used - which includes a lot of shader sets.

  • SnowSultanSnowSultan Posts: 3,596

    Heh, yeah it's pretty much impossible to use with a pose collection that includes partial poses. Is there a particular reason why Smart Content can't recognize folders within the product installation, but still collects all of the files from within them?

  • Richard HaseltineRichard Haseltine Posts: 100,960

    SnowSultan said:

    Heh, yeah it's pretty much impossible to use with a pose collection that includes partial poses. Is there a particular reason why Smart Content can't recognize folders within the product installation, but still collects all of the files from within them?

    I don't think this is a techncial issue, it would just require that categories be assigned based on the folder structure of the product in these cases. However, the folder structure wouldn't always be useful so I guess there is no policy on when it should or shouldn't be used.

  • wooferwoofer Posts: 17
    edited May 2023

    SnowSultan said:

    Does anyone happen to know if this function, the "Show Asset in - Content Library > Mapped Folder" option that can be brought up by right-clicking on an item in the Smart Content panel, is available in the Customization menu? I checked the Content Library, Smart Content, and a bunch of other sections, but cannot find that particular selection. Thanks for any information.

    What do you mean by Customization menu? Do you mean the application's toolbar, which can be customized via Window -> Workspace -> Customize?

    If so, while I'll take Richard's word that the feature does not exist, you can instead create and pin a script to the toolbar which implements this functionality.

    Here's the code you would need:

    var paneManager = App.getInterface().getPaneMgr();var smartContent = paneManager.findPane('DzSmartContentPane');var tab = smartContent.getCurrentTab();var contentTab = tab.getProductAssetsView().getContentTab();var assets = [];if (contentTab.visible) {    assets = contentTab.getSelectedAssets();} else if (tab.inherits('DzFileContentTab')) {    assets = tab.getSelectedAssets();}if (assets.length > 0) {    var contentLibrary = paneManager.findPane('DzContentLibraryPane');    contentLibrary.showPane();    contentLibrary.browseToAsset(assets[0]);}

     

    Post edited by woofer on
  • Richard HaseltineRichard Haseltine Posts: 100,960

    These commands are avaialble in the Smart Content pane by right-click on a thumbnail - right-click is generally called a context menu, since its content depends on what is under the click.

  • Richard HaseltineRichard Haseltine Posts: 100,960

    Do bear in mind that using undocumented features carries a very high risk that they will change in later versions.

  • wooferwoofer Posts: 17

    I understand that the commands are accessible through the UI, I was just offering OP a method of achieving what they wanted, assuming I correctly understood the ask.

    As for the undocumented feature, that's a fair point. Perhaps ChatGPT will be smart enough to auto-upgrade my scripts if/when the API changes. laugh

  • SnowSultanSnowSultan Posts: 3,596

    Thank you Woofer, but I'll stick to right clicking rather than risk destroying Studio.  ;)

Sign In or Register to comment.