protected override IMGUIContainer EnsureNamingConventions(ChangeEvent <string> evt = null) { IMGUIContainer container = base.EnsureNamingConventions(evt); if (container != null) { container.style.alignItems = Align.FlexEnd; container.style.paddingBottom = 20; container.name += "_NamingConvention"; if (InspectorEnabled) { objectNameSetter = new Button(SetObjectName); objectNameSetter.name = "objectNameSetter"; objectNameSetter.text = "Fix Naming Convention"; container.Add(objectNameSetter); RootVisualElement.Add(container); container.SendToBack(); } else { RootVisualElement.Add(container); container.SendToBack(); } } else if (objectNameSetter != null) { objectNameSetter.TryRemoveFromParent(); } return(null); }
protected void AddIMGUIContainer() { RootVisualElement.Add(container); }