AGS.Editor.GUIController.ShowPropertiesEditorFromPropertyGrid C# (CSharp) Метод

ShowPropertiesEditorFromPropertyGrid() приватный Метод

private ShowPropertiesEditorFromPropertyGrid ( AGS.Types.CustomProperties props, object objectThatHasProperties ) : void
props AGS.Types.CustomProperties
objectThatHasProperties object
Результат void
        private void ShowPropertiesEditorFromPropertyGrid(CustomProperties props, object objectThatHasProperties)
        {
            CustomPropertyAppliesTo propertyTypes;
            if (objectThatHasProperties is Character)
            {
                propertyTypes = CustomPropertyAppliesTo.Characters;
            }
            else if (objectThatHasProperties is RoomHotspot)
            {
                propertyTypes = CustomPropertyAppliesTo.Hotspots;
            }
            else if (objectThatHasProperties is InventoryItem)
            {
                propertyTypes = CustomPropertyAppliesTo.InventoryItems;
            }
            else if (objectThatHasProperties is RoomObject)
            {
                propertyTypes = CustomPropertyAppliesTo.Objects;
            }
            else if (objectThatHasProperties is Room)
            {
                propertyTypes = CustomPropertyAppliesTo.Rooms;
            }
            else
            {
                throw new AGSEditorException("Object not recognised to contain properties: " + objectThatHasProperties.ToString());
            }

            Factory.GUIController.CustomPropertiesEditor(props, propertyTypes);
        }
GUIController