DICE PACKS BUNDLE
  1. #1

    Removing Radial Menu Options

    I'm working on an extension that adds a radial menu to the "Attack" button and lets you quickly roll an attack with a modifier applied, saving the user the time of opening the Modifiers window and clicking on one.

    I noticed that when I create a radial menu on the attack button, it inherits the menu options of the control above it.



    Note in the gif above that the "Rest" option from the other radial menu is coming along in my attack button's radial menu. The other options all were as well (you can see the "Clone Item" option in the bottom right, too), but I can replace all but one of these options with my own by repositioning things. I'm short one item to actually "override" all those slots, though, and it doesn't make any sense to me to have any of those inherited menu options come along. I want them gone.

    Things I tried:

    1. resetMenuItems() - no effect, all the old options still appear unless overridden
    2. calling registerMenuItem("", "", 8); to try to see if that would clear it out. It just ignores that (maybe because it can't find an image named ""?)

    Interestingly, the documentation for registerMenuItem says "Trying to redefine an existing menu item will fail.", and that clearly isn't the case here (I replaced all those other options), making me think I don't really understand the relationship of how those items are chaining down from some control up above to the attack button control.
    Last edited by Sterno; March 25th, 2021 at 16:12.

  2. #2
    I really wish everyone would stop using animated GIFs. It makes it hard to see what is happening at beginning and end of segment; as well as impossible to stop and review what is happening.

    Radial options are added up the chain of inheritance. If a containing window defines a radial menu, it will always appear in the radial slot unless specifically overriden.

    Regards,
    JPG

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
5E Character Create Playlist

Log in

Log in