Click or drag to resize

ViewManagerOnViewContextMenuOpeningEvent Event

View Context Menu Opening Event

Namespace:  VIZCore3D.NET.Manager
Assembly:  VIZCore3D.NET (in VIZCore3D.NET.dll) Version: 2.8.24.1104 (2.8.24.1104)
Syntax
C#
public event ViewContextMenuOpeningEventHandler OnViewContextMenuOpeningEvent

Value

Type: ViewContextMenuOpeningEventHandler
Examples
C#
// VIZCore3D.NET Control
private VIZCore3D.NET.VIZCore3DControl vizcore3d;

private void Example()
{
    vizcore3d.View.OnViewContextMenuOpeningEvent += View_OnViewContextMenuOpeningEvent;
}

private void View_OnViewContextMenuOpeningEvent(object sender, Event.EventManager.ViewContextMenuEventArgs e)
{
    // 노드 단일 선택 Context Menu 인 경우만 활성화 허용
    if (e.Kind == Data.ViewContextMenuKind.NODE_SINGLE)
        e.Cancel = false;
    // 다른 Context Menu는 사용안함
    else
        e.Cancel = true;
}
See Also