private void ContextMenuClick(object userData, string[] options, int selected)
{
if ((bool)userData && selected == 0)
{
selected = 1;
}
switch (selected)
{
case 0:
this.DoShowDiff(this.GetGUID());
break;
case 1:
ASEditorBackend.DoAS();
ASEditorBackend.ASWin.ShowHistory();
break;
case 2:
if (!ASEditorBackend.SettingsIfNeeded())
{
Debug.Log("Asset Server connection for current project is not set up");
}
if (EditorUtility.DisplayDialog("Discard changes", "Are you sure you want to discard local changes of selected asset?", "Discard", "Cancel"))
{
AssetServer.DoUpdateWithoutConflictResolutionOnNextTick(new string[]
{
this.GetGUID()
});
}
break;
}
}