VIRTUAL KEYBOARD SpaceKey not autosizing
Hello, So my space button wont autosize on the virtual keyboard. It creates the blank space but doesnt autosize to it, after inputing any other key it autosizes correctly. Could use an extra set of eyes to see what im doing wrong
Ill post any relevant code down here
//spaces;
key_space.addEventListener(MouseEvent.CLICK, spaceClickListener);
function spaceClickListener(e:MouseEvent):void
{
if (control == "on" && menu.visible == false )
{
strehrows3();
textSelect.appendText(" ");
shift = false;
//border control;
if (textSelect.width <= 134.05)
{
// textSelect.autoSize = TextFieldAutoSize.RIGHT;
textSelect.x = 1.2;
}
if (textSelect.width >= 134.05)
{
///textSelect.autoSize = TextFieldAutoSize.RIGHT;
textSelect.x = 1.2-(textSelect.width-134.05);
}
//inputTxt.autoSize = TextFieldAutoSize.NONE;
textSelect.setSelection(textSelect.length,textSelect.length);
}
focuser();
strehrows3();
_fontSize();
}
function _keys(event:MouseEvent):void
{
strehrows3();
textSelect.setSelection(textSelect.length,textSelect.length);
if (electoff.currentFrame == 2)
{
ajWidth(event);
}
if (terminalinput.currentFrame == 2)
{
TrWidth(null);
}
if (control == "on" && menu.visible == false )
{
if (! shift)
{
textSelect.appendText(letterButtonSmall[event.target.name]);
}
else
{
textSelect.appendText(letterButtonCaps[event.target.name]);
shift = false;
}
savedTxt = textSelect.text;
textSelect.setSelection(textSelect.length,textSelect.length);
if (textSelect.width <= 134.05 && textSelect == inputClips.inputTxt )
{
textSelect.autoSize = TextFieldAutoSize.RIGHT;
textSelect.x = 1.2;
}
if (textSelect.width >= 134.05 && textSelect == inputClips.inputTxt)
{
textSelect.autoSize = TextFieldAutoSize.RIGHT;
textSelect.x = 1.2-(textSelect.width-134.05);
}
}
textSelect.setSelection(textSelect.length,textSelect.length);
if (electoff.currentFrame == 2)
{
ajWidth(event);
}
if (terminalinput.currentFrame == 2)
{
TrWidth(null);
}
focuser();
strehrows3();
_fontSize();
}
