示例#1
0
        /// <inheritdoc/>
        public IEntityPickerDialog CreateEntityPickerDialog(EntityHierarchyEditorViewModel editor)
        {
            if (editor == null)
            {
                throw new ArgumentNullException(nameof(editor));
            }
            var picker = new EntityPickerWindow(editor, null);

            return(picker);
        }
示例#2
0
        /// <inheritdoc/>
        public IEntityPickerDialog CreateEntityComponentPickerDialog(EntityHierarchyEditorViewModel editor, Type componentType)
        {
            if (editor == null)
            {
                throw new ArgumentNullException(nameof(editor));
            }
            if (!typeof(EntityComponent).IsAssignableFrom(componentType))
            {
                throw new ArgumentException(@"The given component type does not inherit from EntityComponent.", nameof(componentType));
            }

            var picker = new EntityPickerWindow(editor, componentType);

            return(picker);
        }