Форум Flasher.ru

Форум Flasher.ru (http://www.flasher.ru/forum/index.php)
-   ActionScript 1.0/2.0 (http://www.flasher.ru/forum/forumdisplay.php?f=93)
-   -   подсказки и их положение (http://www.flasher.ru/forum/showthread.php?t=118097)

zzz_dmg 14.11.2008 13:46

подсказки и их положение
 
есть такой код для подсказок. пытаюсь сделать так, чтобы для половины флеша они показывались с правой стороны, а для другой половины - с левой. но что-то не выходит(
Код:

var imgNameFormat:TextFormat = new TextFormat();
imgNameFormat.font = "Arial";
imgNameFormat.size = 12;
imgNameFormat.indent = 2;
function viewHint(mc:MovieClip) {
        hint_list = _root.createTextField("hint_list", 1001, _root._xmouse, _root._ymouse, 50, 10);
        hint_list.selectable = false;
        hint_list.border = true;
        hint_list.borderColor = 0x6A6A6A;
        hint_list.background = true;
        hint_list.backgroundColor = 0x858585;
        if(z0 == true){
        hint_list.text = "  Thought-Leader Engagement";}
        if(z1 == true){
        hint_list.text = "  Meeting Planning";}
        if(z2 == true){
        hint_list.text = "  Product Team Workshops & Education";}
        if(z3 == true){
        hint_list.text = "  Strategic Services";}
        if(z4 == true){
        hint_list.text = "  Medical Writin";}
        hint_list.textColor = 0xffffff;
        hint_list.setTextFormat(imgNameFormat);
        hint_list._width = hint_list.textWidth+10;
        hint_list._height = hint_list.textHeight+4;
        if (_root._xmouse <401) {
        mc.onMouseMove = function() {
                hint_list._x = _root._xmouse;
                hint_list._y = _root._ymouse;
                updateAfterEvent();
        }
        }
        if (_root._xmouse > 400) {
        mc.onMouseMove = function() {
                hint_list._x = -_root._xmouse;
                hint_list._y = -_root._ymouse;
                updateAfterEvent();
        }
        }
}

Добавлено через 35 минут
сорри, уже все получилось)


Часовой пояс GMT +4, время: 20:51.

Copyright © 1999-2008 Flasher.ru. All rights reserved.
Работает на vBulletin®. Copyright ©2000 - 2026, Jelsoft Enterprises Ltd. Перевод: zCarot
Администрация сайта не несёт ответственности за любую предоставленную посетителями информацию. Подробнее см. Правила.