DisableGadgetContextMenu possible?

Just starting out? Need help? Post your questions and find answers here.
Dirk Geppert
Posts: 282
Joined: Fri Sep 22, 2017 7:02 am

DisableGadgetContextMenu possible?

Post by Dirk Geppert »

Code: Select all

Procedure DisableSiteContextMenu(state)
  If state
    ! $('body').attr("oncontextmenu", "return false;");
  Else
    ! $('body').attr("oncontextmenu", "");
  EndIf
 EndProcedure
Is it possible to disable the contexmenu for a special gadget, e.g. the listicongadget() to use the own popupmenu?
Otherwise I could working with onfocus and lostfocus and global en/disable..