private void ContextItemMouseover_OnEvent(object sender, IControlHtmlEventArgs e) { var src = e.EventObj.srcElement; src.style.backgroundColor = "lightblue"; src.style.color = "black"; }
private void ContextItemClicked_OnEvent(object sender, IControlHtmlEventArgs e) { var eventObj = e?.EventObj; var contextItem = eventObj?.srcElement; if (contextItem.IsNull()) { return; } CurrentPopup?.Hide(); // Get innerText and find Action string cmd = contextItem.innerText; if (!cmd.IsNullOrEmpty() && PluginCmdActionMap.TryGetValue(cmd, out var action)) { action.Invoke(); } }
private void ContextItemMouseout_OnEvent(object sender, IControlHtmlEventArgs e) { var src = e.EventObj.srcElement; src.style.backgroundColor = "white"; }