diff --git a/source/flixel/addons/ui/FlxSlider.hx b/source/flixel/addons/ui/FlxSlider.hx new file mode 100644 index 00000000..1eee52b5 --- /dev/null +++ b/source/flixel/addons/ui/FlxSlider.hx @@ -0,0 +1,506 @@ +package flixel.addons.ui; + +#if FLX_MOUSE +import flixel.FlxG; +import flixel.FlxSprite; +import flixel.group.FlxSpriteGroup; +import flixel.text.FlxText; +import flixel.util.FlxDestroyUtil; +import flixel.math.FlxMath; +import flixel.math.FlxPoint; +import flixel.math.FlxRect; +import flixel.util.FlxSpriteUtil; +import flixel.util.FlxColor; + +/** + * A slider GUI element for float and integer manipulation. + * @author Gama11 + */ +class FlxSlider extends FlxSpriteGroup +{ + /** + * The horizontal line in the background. + */ + public var body:FlxSprite; + + /** + * The dragable handle - loadGraphic() to change its graphic. + */ + public var handle:FlxSprite; + + /** + * The text under the left border - equals minValue by default. + */ + public var minLabel:FlxText; + + /** + * The text under the right border - equals maxValue by default. + */ + public var maxLabel:FlxText; + + /** + * A text above the slider that displays its name. + */ + public var nameLabel:FlxText; + + /** + * A text under the slider that displays the current value. + */ + public var valueLabel:FlxText; + + /** + * Stores the current value of the variable - updated each frame. + */ + public var value:Float; + + /** + * Mininum value the variable can be changed to. + */ + public var minValue:Float; + + /** + * Maximum value the variable can be changed to. + */ + public var maxValue:Float; + + /** + * How many decimals the variable can have at max. Default is zero, + * or "only whole numbers". + */ + public var decimals:Int = 0; + + /** + * Sound that's played whenever the slider is clicked. + */ + public var clickSound:String; + + /** + * Sound that's played whenever the slider is hovered over. + */ + public var hoverSound:String; + + /** + * The alpha value the slider uses when it's hovered over. 1 to turn the effect off. + */ + public var hoverAlpha:Float = 0.5; + + /** + * A function to be called when the slider was used. + * The current relativePos is passed as an argument. + */ + public var callback:Float->Void = null; + + /** + * Whether the slider sets the variable it tracks. Can be useful to deactivate this in conjunction with callbacks. + */ + public var setVariable:Bool = true; + + /** + * The expected position of the handle based on the current variable value. + */ + public var expectedPos(get, never):Float; + + /** + * The position of the handle relative to the slider / max value. + */ + public var relativePos(get, never):Float; + + /** + * Stores the variable the slider controls. + */ + public var varString(default, set):String; + + /** + * The dragable area for the handle. Is configured automatically. + */ + var _bounds:FlxRect; + + /** + * The width of the slider. + */ + var _width:Int; + + /** + * The height of the slider - make sure to call createSlider() if you + * want to change this. + */ + var _height:Int; + + /** + * The thickness of the slider - make sure to call createSlider() if you + * want to change this. + */ + var _thickness:Int; + + /** + * The color of the slider - make sure to call createSlider() if you + * want to change this. + */ + var _color:FlxColor; + + /** + * The color of the handle - make sure to call createSlider() if you + * want to change this. + */ + var _handleColor:FlxColor; + + /** + * Stores a reference to parent object. + */ + var _object:Dynamic; + + /** + * Helper var for callbacks. + */ + var _lastPos:Float; + + /** + * Helper variable to avoid the clickSound playing every frame. + */ + var _justClicked:Bool = false; + + /** + * Helper variable to avoid the hoverSound playing every frame. + */ + var _justHovered:Bool = false; + + /** + * Creates a new FlxSlider. + * + * @param Object Reference to the parent object of the variable + * @param VarString Variable that the slider controls + * @param X x Position + * @param Y y Position + * @param MinValue Mininum value the variable can be changed to + * @param MaxValue Maximum value the variable can be changed to + * @param Width Width of the slider + * @param Height Height of the slider + * @param Thickness Thickness of the slider + * @param Color Color of the slider background and all texts except for valueText showing the current value + * @param HandleColor Color of the slider handle and the valueText showing the current value + */ + public function new(Object:Dynamic, VarString:String, X:Float = 0, Y:Float = 0, MinValue:Float = 0, MaxValue:Float = 10, Width:Int = 100, Height:Int = 15, + Thickness:Int = 3, Color:Int = 0xFF000000, HandleColor:Int = 0xFF828282) + { + super(); + + x = X; + y = Y; + + if (MinValue == MaxValue) + { + FlxG.log.error("FlxSlider: MinValue and MaxValue can't be the same (" + MinValue + ")"); + } + + // Determine the amount of decimals to show + decimals = FlxMath.getDecimals(MinValue); + + if (FlxMath.getDecimals(MaxValue) > decimals) + { + decimals = FlxMath.getDecimals(MaxValue); + } + + decimals++; + + // Assign all those constructor vars + minValue = MinValue; + maxValue = MaxValue; + _object = Object; + varString = VarString; + _width = Width; + _height = Height; + _thickness = Thickness; + _color = Color; + _handleColor = HandleColor; + + // Create the slider + createSlider(); + } + + /** + * Initially creates the slider with all its objects. + */ + function createSlider():Void + { + offset.set(7, 18); + _bounds = FlxRect.get(x + offset.x, y + offset.y, _width, _height); + + // Creating the "body" of the slider + body = new FlxSprite(offset.x, offset.y); + var colorKey:String = "slider:W=" + _width + "H=" + _height + "C=" + _color.toHexString() + "T=" + _thickness; + body.makeGraphic(_width, _height, 0, false, colorKey); + body.scrollFactor.set(); + FlxSpriteUtil.drawLine(body, 0, _height / 2, _width, _height / 2, {color: _color, thickness: _thickness}); + + handle = new FlxSprite(offset.x, offset.y); + handle.makeGraphic(_thickness, _height, _handleColor); + handle.scrollFactor.set(); + + // Creating the texts + nameLabel = new FlxText(offset.x, 0, _width, varString); + nameLabel.alignment = "center"; + nameLabel.color = _color; + nameLabel.scrollFactor.set(); + + var textOffset:Float = _height + offset.y + 3; + + valueLabel = new FlxText(offset.x, textOffset, _width); + valueLabel.alignment = "center"; + valueLabel.color = _handleColor; + valueLabel.scrollFactor.set(); + + minLabel = new FlxText(-50 + offset.x, textOffset, 100, Std.string(minValue)); + minLabel.alignment = "center"; + minLabel.color = _color; + minLabel.scrollFactor.set(); + + maxLabel = new FlxText(_width - 50 + offset.x, textOffset, 100, Std.string(maxValue)); + maxLabel.alignment = "center"; + maxLabel.color = _color; + maxLabel.scrollFactor.set(); + + // Add all the objects + add(body); + add(handle); + add(nameLabel); + add(valueLabel); + add(minLabel); + add(maxLabel); + } + + override public function update(elapsed:Float):Void + { + // Clicking and sound logic + if (mouseInRect(_bounds)) + { + if (hoverAlpha != 1) + { + alpha = hoverAlpha; + } + + #if FLX_SOUND_SYSTEM + if (hoverSound != null && !_justHovered) + { + FlxG.sound.play(hoverSound); + } + #end + + _justHovered = true; + + if (FlxG.mouse.pressed) + { + handle.x = FlxG.mouse.getPositionInCameraView(camera).x; + updateValue(); + + #if FLX_SOUND_SYSTEM + if (clickSound != null && !_justClicked) + { + FlxG.sound.play(clickSound); + _justClicked = true; + } + #end + } + if (!FlxG.mouse.pressed) + { + _justClicked = false; + } + } + else + { + if (hoverAlpha != 1) + { + alpha = 1; + } + + _justHovered = false; + } + + // Update the target value whenever the slider is being used + if ((FlxG.mouse.pressed) && (mouseInRect(_bounds))) + { + updateValue(); + } + + // Update the value variable + if ((varString != null) && (Reflect.getProperty(_object, varString) != null)) + { + value = Reflect.getProperty(_object, varString); + } + + // Changes to value from outside update the handle pos + if (handle.x != expectedPos) + { + handle.x = expectedPos; + } + + // Finally, update the valueLabel + valueLabel.text = Std.string(FlxMath.roundDecimal(value, decimals)); + + super.update(elapsed); + } + + private function mouseInRect(rect:flixel.math.FlxRect) + { + if (FlxMath.pointInFlxRect(FlxG.mouse.getPositionInCameraView(camera).x,FlxG.mouse.getPositionInCameraView(camera).y,rect)) return true; + else return false; + } + + /** + * Function that is called whenever the slider is used to either update the variable tracked or call the Callback function. + */ + function updateValue():Void + { + if (_lastPos != relativePos) + { + if ((setVariable) && (varString != null)) + { + Reflect.setProperty(_object, varString, (relativePos * (maxValue - minValue)) + minValue); + } + + _lastPos = relativePos; + + if (callback != null) + callback(relativePos); + } + } + + /** + * Handy function for changing the textfields. + * + * @param Name Text of nameLabel - null to hide + * @param Value Whether to show the valueText or not + * @param Min Text of minLabel - null to hide + * @param Max Text of maxLabel - null to hide + * @param Size Size to use for the texts + */ + public function setTexts(Name:String, Value:Bool = true, ?Min:String, ?Max:String, Size:Int = 8):Void + { + if (Name == null) + { + nameLabel.visible = false; + } + else + { + nameLabel.text = Name; + nameLabel.visible = true; + } + + if (Min == null) + { + minLabel.visible = false; + } + else + { + minLabel.text = Min; + minLabel.visible = true; + } + + if (Max == null) + { + maxLabel.visible = false; + } + else + { + maxLabel.text = Max; + maxLabel.visible = true; + } + + if (!Value) + { + valueLabel.visible = false; + } + else + { + valueLabel.visible = true; + } + + nameLabel.size = Size; + valueLabel.size = Size; + minLabel.size = Size; + maxLabel.size = Size; + } + + /** + * Cleaning up memory. + */ + override public function destroy():Void + { + body = FlxDestroyUtil.destroy(body); + handle = FlxDestroyUtil.destroy(handle); + minLabel = FlxDestroyUtil.destroy(minLabel); + maxLabel = FlxDestroyUtil.destroy(maxLabel); + nameLabel = FlxDestroyUtil.destroy(nameLabel); + valueLabel = FlxDestroyUtil.destroy(valueLabel); + + _bounds = FlxDestroyUtil.put(_bounds); + + super.destroy(); + } + + function get_expectedPos():Float + { + var pos:Float = x + offset.x + ((_width - handle.width) * ((value - minValue) / (maxValue - minValue))); + + // Make sure the pos stays within the bounds + if (pos > x + _width + offset.x) + { + pos = x + _width + offset.x; + } + else if (pos < x + offset.x) + { + pos = x + offset.x; + } + + return pos; + } + + function get_relativePos():Float + { + var pos:Float = (handle.x - x - offset.x) / (_width - handle.width); + + // Relative position can't be bigger than 1 + if (pos > 1) + { + pos = 1; + } + + return pos; + } + + function set_varString(Value:String):String + { + try + { + Reflect.getProperty(_object, Value); + varString = Value; + } + catch (e:Dynamic) + { + FlxG.log.error("Could not create FlxSlider - '" + Value + "' is not a valid field of '" + _object + "'"); + varString = null; + } + + return Value; + } + + override function set_x(value:Float):Float + { + super.set_x(value); + updateBounds(); + return x = value; + } + + override function set_y(value:Float):Float + { + super.set_y(value); + updateBounds(); + return y = value; + } + + inline function updateBounds() + { + if (_bounds != null) + _bounds.set(x + offset.x, y + offset.y, _width, _height); + } +} +#end \ No newline at end of file diff --git a/source/meta/data/options/NoteOffsetState.hx b/source/meta/data/options/NoteOffsetState.hx index 6191f43e..0faded39 100644 --- a/source/meta/data/options/NoteOffsetState.hx +++ b/source/meta/data/options/NoteOffsetState.hx @@ -1,7 +1,5 @@ package meta.data.options; -import flixel.ui.FlxBar; - import objects.userinterface.menu.*; import objects.background.*; @@ -23,7 +21,6 @@ class NoteOffsetState extends MusicBeatState var barPercent:Float = 0; var delayMin:Int = 0; var delayMax:Int = 500; - var timeBarBG:FlxSprite; var timeBar:FlxBar; var timeTxt:FlxText; var beatText:Alphabet; @@ -50,6 +47,7 @@ class NoteOffsetState extends MusicBeatState persistentUpdate = true; FlxG.sound.pause(); + // Stage var bg:BGSprite = new BGSprite('stages/stage/stageback', -600, -200, 0.9, 0.9); add(bg); @@ -159,22 +157,13 @@ class NoteOffsetState extends MusicBeatState barPercent = ClientPrefs.noteOffset; updateNoteDelay(); - timeBarBG = new FlxSprite(0, timeTxt.y + 8).loadGraphic(Paths.image('timeBar')); - timeBarBG.setGraphicSize(Std.int(timeBarBG.width * 1.2)); - timeBarBG.updateHitbox(); - timeBarBG.cameras = [camHUD]; - timeBarBG.screenCenter(X); - timeBarBG.visible = false; - - timeBar = new FlxBar(0, timeBarBG.y + 4, LEFT_TO_RIGHT, Std.int(timeBarBG.width - 8), Std.int(timeBarBG.height - 8), this, 'barPercent', delayMin, delayMax); + timeBar = new Bar(0, timeTxt.y + (timeTxt.height / 3), 'healthBar', function() return barPercent, delayMin, delayMax); timeBar.scrollFactor.set(); timeBar.screenCenter(X); - timeBar.createFilledBar(0xFF000000, 0xFFFFFFFF); - timeBar.numDivisions = 800; //How much lag this causes?? Should i tone it down to idk, 400 or 200? timeBar.visible = false; timeBar.cameras = [camHUD]; + timeBar.leftBar.color = FlxColor.LIME; - add(timeBarBG); add(timeBar); add(timeTxt); @@ -496,7 +485,6 @@ class NoteOffsetState extends MusicBeatState comboNums.visible = onComboMenu; dumbTexts.visible = onComboMenu; - timeBarBG.visible = !onComboMenu; timeBar.visible = !onComboMenu; timeTxt.visible = !onComboMenu; beatText.visible = !onComboMenu; @@ -509,4 +497,4 @@ class NoteOffsetState extends MusicBeatState changeModeText.text = changeModeText.text.toUpperCase(); FlxG.mouse.visible = onComboMenu; } -} +} \ No newline at end of file diff --git a/source/meta/state/PlayState.hx b/source/meta/state/PlayState.hx index e7685f12..2c697b3e 100644 --- a/source/meta/state/PlayState.hx +++ b/source/meta/state/PlayState.hx @@ -3727,8 +3727,10 @@ class PlayState extends MusicBeatState cancelMusicFadeTween(); MusicBeatState.switchState(new CharacterEditorState(SONG.player2)); } + + if (health > 2) health = 2; - if (startedCountdown) + if (startedCountdown && !paused) Conductor.songPosition += FlxG.elapsed * 1000 * playbackRate; if (startingSong) @@ -3769,6 +3771,7 @@ class PlayState extends MusicBeatState // RESET = Quick Game Over Screen if (!ClientPrefs.noReset && controls.RESET && !inCutscene && !endingSong) { + health = 0; doDeathCheck(true); #if sys ArtemisIntegration.sendBoyfriendHealth (health); @@ -3924,11 +3927,11 @@ class PlayState extends MusicBeatState public dynamic function updateIconsScale(elapsed:Float) { - var mult:Float = FlxMath.lerp(1, iconP1.scale.x, Math.exp(-elapsed * 9 * playbackRate)); + var mult:Float = FlxMath.lerp(1, iconP1.scale.x, FlxMath.bound(1 - (elapsed * 9 * playbackRate), 0, 1)); iconP1.scale.set(mult, mult); iconP1.updateHitbox(); - var mult:Float = FlxMath.lerp(1, iconP2.scale.x, Math.exp(-elapsed * 9 * playbackRate)); + var mult:Float = FlxMath.lerp(1, iconP2.scale.x, FlxMath.bound(1 - (elapsed * 9 * playbackRate), 0, 1)); iconP2.scale.set(mult, mult); iconP2.updateHitbox(); } @@ -3940,9 +3943,10 @@ class PlayState extends MusicBeatState iconP2.x = healthBar.barCenter - (150 * iconP2.scale.x) / 2 - iconOffset * 2; } + var iconsAnimations:Bool = true; function set_health(value:Float):Float { - if (healthBar == null || !healthBar.enabled || healthBar.valueFunction == null) + if (!iconsAnimations || healthBar == null || !healthBar.enabled || healthBar.valueFunction == null) { health = value; return health; diff --git a/source/meta/state/editors/CharacterEditorState.hx b/source/meta/state/editors/CharacterEditorState.hx index 4c05773e..1919896d 100644 --- a/source/meta/state/editors/CharacterEditorState.hx +++ b/source/meta/state/editors/CharacterEditorState.hx @@ -4,10 +4,6 @@ import openfl.net.FileReference; import openfl.events.Event; import openfl.events.IOErrorEvent; -import animateatlas.AtlasFrameMaker; - -import flixel.input.keyboard.FlxKey; -import flixel.graphics.FlxGraphic; import flixel.addons.ui.FlxInputText; import flixel.addons.ui.FlxUI9SliceSprite; import flixel.addons.ui.FlxUI; @@ -64,10 +60,10 @@ class CharacterEditorState extends MusicBeatState var changeBGbutton:FlxButton; var leHealthIcon:HealthIcon; + var healthBar:Bar; var characterList:Array = []; var cameraFollowPointer:FlxSprite; - var healthBarBG:FlxSprite; override function create() { @@ -105,10 +101,10 @@ class CharacterEditorState extends MusicBeatState loadChar(!daAnim.startsWith('bf'), false); - healthBarBG = new FlxSprite(30, FlxG.height - 75).loadGraphic(Paths.image('healthBar')); - healthBarBG.scrollFactor.set(); - add(healthBarBG); - healthBarBG.cameras = [camHUD]; + healthBar = new Bar(30, FlxG.height - 75); + healthBar.scrollFactor.set(); + add(healthBar); + healthBar.cameras = [camHUD]; leHealthIcon = new HealthIcon(char.healthIcon, false); leHealthIcon.y = FlxG.height - 150; @@ -806,17 +802,17 @@ class CharacterEditorState extends MusicBeatState else if(sender == healthColorStepperR) { char.healthColorArray[0] = Math.round(healthColorStepperR.value); - healthBarBG.color = FlxColor.fromRGB(char.healthColorArray[0], char.healthColorArray[1], char.healthColorArray[2]); + resetHealthBarColor(); } else if(sender == healthColorStepperG) { char.healthColorArray[1] = Math.round(healthColorStepperG.value); - healthBarBG.color = FlxColor.fromRGB(char.healthColorArray[0], char.healthColorArray[1], char.healthColorArray[2]); + resetHealthBarColor(); } else if(sender == healthColorStepperB) { char.healthColorArray[2] = Math.round(healthColorStepperB.value); - healthBarBG.color = FlxColor.fromRGB(char.healthColorArray[0], char.healthColorArray[1], char.healthColorArray[2]); + resetHealthBarColor(); } } } @@ -1066,7 +1062,7 @@ class CharacterEditorState extends MusicBeatState healthColorStepperR.value = char.healthColorArray[0]; healthColorStepperG.value = char.healthColorArray[1]; healthColorStepperB.value = char.healthColorArray[2]; - healthBarBG.color = FlxColor.fromRGB(char.healthColorArray[0], char.healthColorArray[1], char.healthColorArray[2]); + healthBar.leftBar.color = healthBar.rightBar.color = FlxColor.fromRGB(character.healthColorArray[0], character.healthColorArray[1], character.healthColorArray[2]); } function updatePresence() { diff --git a/source/objects/FlxUIDropDownMenuCustom.hx b/source/objects/FlxUIDropDownMenuCustom.hx index 7e523617..0ec0e4c5 100644 --- a/source/objects/FlxUIDropDownMenuCustom.hx +++ b/source/objects/FlxUIDropDownMenuCustom.hx @@ -1,8 +1,14 @@ package objects; +import flash.geom.Rectangle; import flixel.addons.ui.interfaces.IFlxUIClickable; import flixel.addons.ui.interfaces.IFlxUIWidget; import flixel.addons.ui.interfaces.IHasParams; + +import flixel.ui.FlxButton; + +import flixel.util.FlxDestroyUtil; +import flixel.util.FlxStringUtil; import flixel.addons.ui.FlxUIGroup; import flixel.addons.ui.FlxUIText; import flixel.addons.ui.FlxUIButton; @@ -11,7 +17,7 @@ import flixel.addons.ui.FlxUI9SliceSprite; import flixel.addons.ui.FlxUIAssets; import flixel.addons.ui.StrNameLabel; import flixel.addons.ui.FlxUI; -import flixel.ui.FlxButton; + /* @@ -144,7 +150,7 @@ class FlxUIDropDownMenuCustom extends FlxUIGroup implements IFlxUIWidget impleme public var callback:String->Void; - // private var _ui_control_callback:Bool->FlxUIDropDownMenuCustom->Void; + // private var _ui_control_callback:Bool->FlxUIDropDownMenu->Void; /** * This creates a new dropdown menu. @@ -159,7 +165,7 @@ class FlxUIDropDownMenuCustom extends FlxUIGroup implements IFlxUIWidget impleme * @param UIControlCallback Used internally by FlxUI */ public function new(X:Float = 0, Y:Float = 0, DataList:Array, ?Callback:String->Void, ?Header:FlxUIDropDownHeader, - ?DropPanel:FlxUI9SliceSprite, ?ButtonList:Array, ?UIControlCallback:Bool->FlxUIDropDownMenuCustom->Void) + ?DropPanel:FlxUI9SliceSprite, ?ButtonList:Array, ?UIControlCallback:Bool->FlxUIDropDownMenu->Void) { super(X, Y); callback = Callback; @@ -223,7 +229,7 @@ class FlxUIDropDownMenuCustom extends FlxUIGroup implements IFlxUIWidget impleme for (i in 0...currentScroll) { //Hides buttons that goes before the current scroll var button:FlxUIButton = list[i]; if(button != null) { - button.y = -99999; + button.y = FlxG.height + 250; } } for (i in currentScroll...list.length) @@ -376,7 +382,7 @@ class FlxUIDropDownMenuCustom extends FlxUIGroup implements IFlxUIWidget impleme return t; } - /*public function setUIControlCallback(UIControlCallback:Bool->FlxUIDropDownMenuCustom->Void):Void { + /*public function setUIControlCallback(UIControlCallback:Bool->FlxUIDropDownMenu->Void):Void { _ui_control_callback = UIControlCallback; }*/ public function changeLabelByIndex(i:Int, NewLabel:String):Void @@ -426,21 +432,22 @@ class FlxUIDropDownMenuCustom extends FlxUIGroup implements IFlxUIWidget impleme if (dropPanel.visible) { if(list.length > 1 && canScroll) { + var lastScroll:Int = currentScroll; if(FlxG.mouse.wheel > 0 || FlxG.keys.justPressed.UP) { // Go up --currentScroll; if(currentScroll < 0) currentScroll = 0; - updateButtonPositions(); } else if (FlxG.mouse.wheel < 0 || FlxG.keys.justPressed.DOWN) { // Go down currentScroll++; if(currentScroll >= list.length) currentScroll = list.length-1; - updateButtonPositions(); } + + if(lastScroll != currentScroll) updateButtonPositions(); } - if (FlxG.mouse.justPressed && !mouseOverlapping()) + if (FlxG.mouse.justPressed && !FlxG.mouse.overlaps(this,camera)) { showList(false); } @@ -448,18 +455,6 @@ class FlxUIDropDownMenuCustom extends FlxUIGroup implements IFlxUIWidget impleme #end } - function mouseOverlapping() - { - var mousePoint = FlxG.mouse.getScreenPosition(camera); - var objPoint = this.getScreenPosition(null, camera); - if(mousePoint.x >= objPoint.x && mousePoint.y >= objPoint.y && - mousePoint.x < objPoint.x + this.width && mousePoint.y < objPoint.y + this.height) - { - return true; - } - return false; - } - override public function destroy():Void { super.destroy(); @@ -515,7 +510,7 @@ class FlxUIDropDownMenuCustom extends FlxUIGroup implements IFlxUIWidget impleme * * @param StringArray The strings to use as data - used for both label and string ID. * @param UseIndexID Whether to use the integer index of the current string as ID. - * @return The StrIDLabel array ready to be used in FlxUIDropDownMenuCustom's constructor + * @return The StrIDLabel array ready to be used in FlxUIDropDownMenu's constructor */ public static function makeStrIdLabelArray(StringArray:Array, UseIndexID:Bool = false):Array { @@ -534,7 +529,7 @@ class FlxUIDropDownMenuCustom extends FlxUIGroup implements IFlxUIWidget impleme } /** - * Header for a FlxUIDropDownMenuCustom + * Header for a FlxUIDropDownMenu */ class FlxUIDropDownHeader extends FlxUIGroup { @@ -554,7 +549,7 @@ class FlxUIDropDownHeader extends FlxUIGroup public var button:FlxUISpriteButton; /** - * Creates a new dropdown header to be used in a FlxUIDropDownMenuCustom. + * Creates a new dropdown header to be used in a FlxUIDropDownMenu. * * @param Width Width of the dropdown - only relevant when no back sprite was specified * @param Back Optional sprite to be placed in the background @@ -619,4 +614,4 @@ enum FlxUIDropDownMenuDropDirection Automatic; Down; Up; -} +} \ No newline at end of file