- 01
- 02
- 03
- 04
- 05
- 06
- 07
- 08
- 09
- 10
- 11
- 12
- 13
- 14
- 15
- 16
- 17
- 18
- 19
- 20
- 21
- 22
- 23
- 24
- 25
- 26
- 27
- 28
- 29
- 30
- 31
- 32
- 33
- 34
- 35
- 36
- 37
- 38
- 39
- 40
- 41
- 42
- 43
- 44
- 45
- 46
- 47
- 48
- 49
- 50
- 51
- 52
- 53
- 54
- 55
- 56
- 57
- 58
- 59
- 60
- 61
- 62
- 63
- 64
- 65
- 66
- 67
- 68
- 69
- 70
- 71
- 72
- 73
- 74
- 75
- 76
- 77
- 78
- 79
- 80
- 81
- 82
- 83
- 84
- 85
- 86
public function getKey (event:MouseEvent):void
{
if (!currTf) return;
var keyId:String = event.currentTarget.name;
keyId = keyId.replace('kbtn_', '');
var keyArr:Array = keyId.split('zn_');
if (isUpper) ClipsCreator.setColor(orange, MovieClip(this['kbtn_zn_10']).getChildAt(0), 0);
if (keyArr[1])
{
keyId = '';
switch (keyArr[1])
{
case '0':
keyId = '%';
break;
case '1':
if (currTf.length > 0) currTf.text = currTf.text.slice(0, currTf.text.length - 1);
break;
case '2':
keyId = '\n';
break;
case '4':
keyId = '!';
break;
case '5':
keyId = '?';
break;
case '6':
keyId = ':';
break;
case '7':
keyId = ',';
break;
case '8':
keyId = '.';
break;
case '9':
keyId = ' ';
break;
case '10':
isUpper = true;
ClipsCreator.setColor(orange, MovieClip(this['kbtn_zn_10']).getChildAt(0), 0.3);
break;
case '11':
changeState(FrameList.COMMENTS_EN);
break;
case '12':
changeState(FrameList.COMMENTS_UA);
break;
case '13':
changeState(FrameList.COMMENTS_RU);
break;
case '15':
keyId = '@';
break;
case '16':
keyId = 'є';
break;
case '17':
keyId = 'ч';
break;
}
}
else
{
if (isUpper)
{
keyId = keyId.toUpperCase();
isUpper = false;
}
}
if (keyId) currTf.text += keyId;
if (_tf_comment.text.length > 10 && _tf_name.text.length > 1 && _tf_fone.length > 4)
{
_btn_send.alpha = 1;
_btn_send.mouseChildren = _btn_send.mouseEnabled = true;
}
else
{
_btn_send.alpha = 0.4;
_btn_send.mouseChildren = _btn_send.mouseEnabled = false;
}
}
wvxvw 04.02.2012 00:07 # +1