Disable selection rectangle in Editor

Good afternoon, I am writing my own editor toolkit for working with objects of the world, and in some cases I want to disable the selection rectangle (when i click mouse button and drag) How I can do this?

public void OnSceneGUI()
{
    HandleUtility.AddDefaultControl(GUIUtility.GetControlID(FocusType.Passive));
}

A bit late, but it could help someone else :stuck_out_tongue:

1 Like