Delete ListBox element under mouse

hello,

i created a listbox with custom items/converter
in each listbox item, there is a delete button
but i can’t find a way to delete the item that is under the mouse

if i use listBox.removeItem(listBox.getFocusItem());
it removes the selection, not the item under the mouse cursor

so i was thingking about adding an index to the button action
but i cant access attributes of elements already created by the listbox mechanism

how can i achieve this ?


[controlDefinition name="proceduresListItem" controller="de.lessvoid.nifty.controls.listbox.ListBoxItemController" inputMapping="de.lessvoid.nifty.input.mapping.MenuInputMapping"]
      [interact onClick="listBoxItemClicked()" onMouseOver="$mouseHoverAction" /]
      [effect]
        [onCustom customKey="select" name="colorBar" color="#ffff" post="false" neverStopRendering="true" timeType="infinite" inset="1px"/]
        [onHover name="focus" /]
        [onClick name="focus" targetElement="#parent#parent"/]
      [/effect]
      [panel childLayout="absolute" width="100%" height="34px" align="left" backgroundColor="#bbb0" ]
        [panel id="selectionBackground" childLayout="horizontal" width="99%" height="32px" align="left" backgroundColor="#0008" x="1" y="1" isibleToMouse="true"]
          [control id="ProcedureName" name="label" align="left" textHAlign="left" width="*" height="32px" wrap="false" backgroundColor="#00f8" color="#ffff"/]
           [control id="DeleteButton" name="commandButtonSmall" imageFile="Textures/Delete.png" action="doAction(DeleteProcedure)"/]
        [/panel]
      [/panel]
   [/controlDefinition]