OpenDream icon indicating copy to clipboard operation
OpenDream copied to clipboard

Can't load DMF with duplicate elements

Open ike709 opened this issue 1 year ago • 1 comments

BYOND apparently not only allows this, but still displays both options and they both work as expected:

elem "icon64"
    name = "&64x64 (2x)"
    command = ".winset \"mapwindow.map.icon-size=64\""
    category = "&Display"
    can-check = true
    group = "size"
    saved-params = "is-checked"
elem "icon64"
    name = "&48x48 (1.5x)"
    command = ".winset \"mapwindow.map.icon-size=48\""
    category = "&Display"
    can-check = true
    group = "size"
    saved-params = "is-checked"
    ```
    
   Need to make a test case to see if BYOND can only refer to the first or the last element with name `icon64`.

ike709 avatar Sep 28 '24 23:09 ike709

I tested in BYOND with:

menu "menu"
    elem "foo"
        name = "Show Popup"
        command = ".winset \"testwindow.is-visible=true\""
        category = "Menu"
    elem "foo"
        name = "Hide Popup"
        command = ".winset \"testwindow.is-visible=false\""
        category = "Menu"

usr << "[json_encode(winget(usr, "menu.foo", "category"))]" returns an empty string usr << "[json_encode(winget(usr, "menu.*", "category"))]" returns both elements

ike709 avatar Oct 06 '24 17:10 ike709