public EditorGUIElement_EditPropertySingleValue_Basic_BuiltIn_String(EditProperty_Single_Value p) : base(p) { use_word_wrap = p.HasCustomAttributeOfType <WordWrapAttribute>(true); multiline_attribute = p.GetCustomAttributeOfType <MultilineAttribute>(true); auto_multiline_attribute = p.GetCustomAttributeOfType <AutoMultilineAttribute>(true); }
protected override LabeledSpritePoint DrawValueInternal(Rect rect, LabeledSpritePoint value) { string label = value.GetLabel(); Vector2 position = value.GetPosition(); EditProperty_Single_Value sprite_property = GetProperty().GetTarget().ForcePropertyValue("target_asset"); Rect label_rect; Rect position_rect; rect.SplitByXLeftPercent(0.4f, out rect, out position_rect); rect.SplitByYBottomOffset(LINE_HEIGHT, out label_rect, out rect); label = EditorGUIExtensions.TextField(label_rect, label); if (sprite_property != null) { Sprite sprite; if (sprite_property.TryGetContentValues <Sprite>(out sprite)) { position_rect = GUIExtensions.DrawSprite(position_rect, sprite); position = EditorGUIExtensions.XYControl( position_rect, position, new FloatRange(0.0f, 1.0f), new FloatRange(0.0f, 1.0f) ); } } return(new LabeledSpritePoint(label, position)); }
public EditorGUIElement_Complex_EditPropertySingleValue_CustomAsset(EditProperty_Single_Value p) : base(p) { }
public EditorGUIElement_EditPropertySingleValue_Combo_TypeMethodInfo(EditProperty_Single_Value p, EditProperty_Single_Value t) : base(p) { type_property = t; }
public EditorGUIElement_Composite_EditPropertySingleValue_Generic(EditProperty_Single_Value p) : base(p) { }
public EditorGUIElement_EditPropertySingleValue(EditProperty_Single_Value p) { property = p; }
public EditorGUIElement_EditPropertySingleValue_Popup(EditProperty_Single_Value p) : base(p) { }
public EditorGUIElement_Foldout_EditPropertySingleValue(EditProperty_Single_Value p, string t, T c, float h) : base(t, c, h) { edit_property_value = p; }
public EditorGUIElement_EditPropertySingleValue_Popup_SortingLayerEX(EditProperty_Single_Value p) : base(p) { }
public EditorGUIElement_EditPropertySingleValue_Popup_TypeSubType(EditProperty_Single_Value p, EditProperty_Single_Value t) : base(p) { type_property = t; }
public EditorGUIElement_Complex_EditPropertySingleValue_TypedObject(EditProperty_Single_Value p, EditProperty_Single_Value t) : base(p) { type_property = t; }
public EditorGUIElement_EditPropertySingleValue_Popup_GameObjectComponentType(EditProperty_Single_Value p, EditProperty_Single_Value g) : base(p) { game_object_property = g; }
public EditorGUIElement_EditPropertySingleValue_Basic_Sprite(EditProperty_Single_Value p) : base(p) { }
public EditorGUIElement_EditPropertySingleValue_Browse_AudioClip(EditProperty_Single_Value p) : base(p) { }
public EditorGUIElement_Foldout_EditPropertySingleValue_VerticalStrip(EditProperty_Single_Value s, string t) : this(s, t, EditorGUIElement_Single.DEFAULT_HEIGHT) { }
public EditorGUIElement_Composite_EditPropertySingleValue_UnityObject(EditProperty_Single_Value p) : this(p, p.GetPropertyType()) { }
public BuiltIn(EditProperty_Single_Value p, Type s) : base(p) { specific_type = s; }
public EditorGUIElement_EditPropertySingleValue_Basic_BuiltIn_Number(EditProperty_Single_Value p) : base(p) { range_attribute = p.GetCustomAttributeOfType <RangeAttribute>(true); }
public EditorGUIElement_Foldout_EditPropertySingleValue(EditProperty_Single_Value p, string t, T c) : this(p, t, c, EditorGUIElement_Single.DEFAULT_HEIGHT) { }
public EditorGUIElement_EditPropertySingleValue_Basic_BuiltIn_Number_Long(EditProperty_Single_Value p) : base(p) { }
public EditorGUIElement_EditPropertySingleValue_Basic_BuiltIn(EditProperty_Single_Value p) : base(p) { label = new EditorGUIElementAttachment_Singular_Label_GUIContent_Inline(); }
public EditorGUIElement_EditPropertySingleValue_Combo_Type(EditProperty_Single_Value p) : base(p) { }
public EditorGUIElement_EditPropertySingleValue_Selector_Asset(EditProperty_Single_Value p, bool non_null) : base(p) { should_force_non_null = non_null; }
public EditorGUIElement_EditPropertySingleValue_Browse(EditProperty_Single_Value p, Predicate <AssetInfo> pre) : base(p) { predicate = pre; }
public EditorGUIElement_EditPropertySingleValue_Basic_OctoSubTile(EditProperty_Single_Value p) : base(p) { }
public EditorGUIElement_EditPropertySingleValue_Browse(EditProperty_Single_Value p) : this(p, a => true) { }
public EditorGUIElement_Complex_EditPropertySingleValue_ScriptletArgument(EditProperty_Single_Value p) : base(p) { }
public EditorGUIElement_EditPropertySingleValue_Popup_GamepadStickId(EditProperty_Single_Value p) : base(p) { }
protected override EditorGUIElement PushState() { CustomAsset asset; EditProperty_Single_Value property = GetProperty(); Type field_type = property.GetPropertyType(); EditorGUIElement_Container_Auto container = new EditorGUIElement_Container_Auto_Simple_VerticalStrip(); EditorGUIElement_Container_Flow_Line type_container = container.AddChild(new EditorGUIElement_Container_Flow_Line()); if (property.TryGetContentValues <CustomAsset>(out asset, true)) { switch (asset.GetAssetType()) { case AssetType.None: case AssetType.External: type_container.AddWeightedChild(1.0f, new EditorGUIElement_EditPropertySingleValue_Selector_Asset(property, false) ); break; case AssetType.Internal: type_container.AddWeightedChild(1.0f, new EditorGUIElement_Popup_ProcessOperation <Type>( GetInternalCustomAssetTypes(field_type), t => property.SetContentValues(CustomAssets.CreateInternalCustomAsset(t)), (out Type t) => property.TryGetContentsType(out t) ) ); break; } type_container.AddFixedChild(64.0f, new EditorGUIElement_Process(delegate(Rect rect) { AssetType new_type = EditorGUIExtensions.EnumPopup(rect, asset.GetAssetType()); if (asset.GetAssetType() != new_type) { switch (new_type) { case AssetType.None: property.SetContentValues(null); break; case AssetType.External: property.SetContentValues( CustomAssets.GetExternalCustomAssetsOfType(field_type) .GetFirst() ); break; case AssetType.Internal: property.SetContentValues( CustomAssets.CreateInternalCustomAsset( GetInternalCustomAssetTypes(field_type) .GetFirst() ) ); break; } } })); if (asset != null && asset.IsInternalAsset()) { container.AddChild(new EditorGUIElement_Complex_EditTarget(new EditTarget(asset))); } } return(container); }
public EditorGUIElement_Composite_EditPropertySingleValue_UnityObject(EditProperty_Single_Value p, Type s) : base(p) { specific_type = s; }