View Single Post
11/05/17, 02:53 PM   #6
votan
 
votan's Avatar
AddOn Author - Click to view addons
Join Date: Oct 2014
Posts: 577
After taking a look I would suggest:
Lua Code:
  1. local orgShowContextMenu = SharedChatSystem.ShowPlayerContextMenu
  2.     function SharedChatSystem.ShowPlayerContextMenu(...)
  3.         local orgClearMenu = ClearMenu
  4.         local orgShowMenu = ShowMenu
  5.  
  6.         if not ZO_Dialogs_IsShowingDialog() then
  7.             local chat, playerName, rawName = ...
  8.             function ClearMenu(...)
  9.                 ClearMenu = orgClearMenu
  10.                 ClearMenu(...)
  11.                 -- Here: Insert items before
  12.             end
  13.             function ShowMenu(...)
  14.                 ShowMenu = orgShowMenu
  15.                 -- Here: Append items
  16.                 return ShowMenu(...)
  17.             end
  18.         end
  19.         return orgShowContextMenu(...)
  20.     end
But without warranty
  Reply With Quote