Hi AXatak,
I can't do the work for you, but can give you hints only. The forum is not a place for outsourcing work ;). If you are not familiar with development, you have to find a developer which would be able to help you.
The next line is inserting the remove button.
selRemove = popupMenu.insertItem("@SYS301894", false, !btnUserRoleRemove.enabled());//"Remove"
It would be possible to have a condition with an "if" statement to let the form know if the button needs to be created or not. Like:
if (<<some condition>>)
{
selRemove = popupMenu.insertItem("@SYS301894", false, !btnUserRoleRemove.enabled());//"Remove"
}