home *** CD-ROM | disk | FTP | other *** search
/ Clickx 47 / Clickx 47.iso / assets / swf / start.swf / scripts / __Packages / clickx / ui / Scroller.as < prev    next >
Encoding:
Text File  |  2008-01-01  |  6.4 KB  |  177 lines

  1. var ┬º\x01┬º = 694;
  2. while(true)
  3. {
  4.    if(eval("\x01") == 694)
  5.    {
  6.       set("\x01",eval("\x01") - 9);
  7.       ┬º┬ºpush(true);
  8.    }
  9.    else if(eval("\x01") == 685)
  10.    {
  11.       set("\x01",eval("\x01") - 239);
  12.       if(┬º┬ºpop())
  13.       {
  14.          set("\x01",eval("\x01") + 57);
  15.       }
  16.    }
  17.    else if(eval("\x01") == 365)
  18.    {
  19.       set("\x01",eval("\x01") + 79);
  20.       if(┬º┬ºpop())
  21.       {
  22.          set("\x01",eval("\x01") - 133);
  23.       }
  24.    }
  25.    else
  26.    {
  27.       if(eval("\x01") == 444)
  28.       {
  29.          set("\x01",eval("\x01") - 133);
  30.          break;
  31.       }
  32.       if(eval("\x01") == 503)
  33.       {
  34.          set("\x01",eval("\x01") - 138);
  35.          ┬º┬ºpush(true);
  36.       }
  37.       else if(eval("\x01") == 311)
  38.       {
  39.          set("\x01",eval("\x01") + 134);
  40.          ┬º┬ºpush(true);
  41.       }
  42.       else
  43.       {
  44.          if(eval("\x01") == 446)
  45.          {
  46.             set("\x01",eval("\x01") + 57);
  47.             break;
  48.          }
  49.          if(eval("\x01") != 445)
  50.          {
  51.             if(eval("\x01") == 493)
  52.             {
  53.                set("\x01",eval("\x01") + 418);
  54.                stopAllSounds();
  55.                break;
  56.             }
  57.             if(eval("\x01") == 911)
  58.             {
  59.                set("\x01",eval("\x01") - 543);
  60.                if(!_global.clickx)
  61.                {
  62.                   _global.clickx = new Object();
  63.                }
  64.                ┬º┬ºpop();
  65.                if(!_global.clickx.ui)
  66.                {
  67.                   _global.clickx.ui = new Object();
  68.                }
  69.                ┬º┬ºpop();
  70.                if(!_global.clickx.ui.Scroller)
  71.                {
  72.                   clickx.ui.Scroller extends MovieClip;
  73.                   var _loc2_ = clickx.ui.Scroller = function()
  74.                   {
  75.                      super();
  76.                   }.prototype;
  77.                   _loc2_.startDragging = function()
  78.                   {
  79.                      this.scrollDrag_mc.startDrag(false,4,20,4,275);
  80.                      this.onEnterFrame = mx.utils.Delegate.create(this,this.adjustListPosition);
  81.                   };
  82.                   _loc2_.stopDragging = function()
  83.                   {
  84.                      this.scrollDrag_mc.stopDrag();
  85.                      delete this.onEnterFrame;
  86.                   };
  87.                   _loc2_.adjustListPosition = function()
  88.                   {
  89.                      var _loc2_ = (this.scrollDrag_mc._y - 20) / 255 * 100;
  90.                      this._parent.scrollTo(Math.round(this._parent.getListMaxScrollPos() / 100 * _loc2_));
  91.                   };
  92.                   _loc2_.adjustSliderPosition = function()
  93.                   {
  94.                      var _loc2_ = this._parent.getListScrollPos() / this._parent.getListMaxScrollPos() * 100;
  95.                      this.scrollDrag_mc._y = 20 + 2.55 * _loc2_;
  96.                   };
  97.                   _loc2_.scrollUp = function()
  98.                   {
  99.                      this.scrollDrag_mc._y -= 4;
  100.                      if(this.scrollDrag_mc._y < 20)
  101.                      {
  102.                         this.scrollDrag_mc._y = 20;
  103.                      }
  104.                      this.adjustListPosition();
  105.                   };
  106.                   _loc2_.scrollDown = function()
  107.                   {
  108.                      this.scrollDrag_mc._y += 4;
  109.                      if(this.scrollDrag_mc._y > 275)
  110.                      {
  111.                         this.scrollDrag_mc._y = 275;
  112.                      }
  113.                      this.adjustListPosition();
  114.                   };
  115.                   _loc2_.startScrollingUp = function()
  116.                   {
  117.                      this.onEnterFrame = mx.utils.Delegate.create(this,this.scrollUp);
  118.                   };
  119.                   _loc2_.startScrollingDown = function()
  120.                   {
  121.                      this.onEnterFrame = mx.utils.Delegate.create(this,this.scrollDown);
  122.                   };
  123.                   _loc2_.stopScrolling = function()
  124.                   {
  125.                      delete this.onEnterFrame;
  126.                   };
  127.                   _loc2_.upReleaseOutside = function()
  128.                   {
  129.                      this.scrollUp_mc.gotoAndStop(1);
  130.                      this.stopScrolling();
  131.                   };
  132.                   _loc2_.downReleaseOutside = function()
  133.                   {
  134.                      this.scrollDown_mc.gotoAndStop(1);
  135.                      this.stopScrolling();
  136.                   };
  137.                   _loc2_.dragReleaseOutside = function()
  138.                   {
  139.                      this.scrollDrag_mc.gotoAndStop(1);
  140.                      delete this.scrollDrag_mc.onEnterFrame;
  141.                      this.stopDragging();
  142.                   };
  143.                   _loc2_.init = function()
  144.                   {
  145.                      this.scrollDrag_mc._y = 20;
  146.                   };
  147.                   _loc2_.onLoad = function()
  148.                   {
  149.                      this.init();
  150.                      clickx.util.ButtonUtil.makeFrame_R_O_Effect(this.scrollDrag_mc,10);
  151.                      clickx.util.ButtonUtil.makeFrame_R_O_Effect(this.scrollUp_mc,10);
  152.                      clickx.util.ButtonUtil.makeFrame_R_O_Effect(this.scrollDown_mc,10);
  153.                      this.scrollDrag_mc.onPress = mx.utils.Delegate.create(this,this.startDragging);
  154.                      this.scrollDrag_mc.onRelease = mx.utils.Delegate.create(this,this.stopDragging);
  155.                      this.scrollUp_mc.onPress = mx.utils.Delegate.create(this,this.startScrollingUp);
  156.                      this.scrollUp_mc.onRelease = mx.utils.Delegate.create(this,this.stopScrolling);
  157.                      this.scrollDown_mc.onPress = mx.utils.Delegate.create(this,this.startScrollingDown);
  158.                      this.scrollDown_mc.onRelease = mx.utils.Delegate.create(this,this.stopScrolling);
  159.                      this.scrollDown_mc.onReleaseOutside = mx.utils.Delegate.create(this,this.downReleaseOutside);
  160.                      this.scrollUp_mc.onReleaseOutside = mx.utils.Delegate.create(this,this.upReleaseOutside);
  161.                      this.scrollDrag_mc.onReleaseOutside = mx.utils.Delegate.create(this,this.dragReleaseOutside);
  162.                   };
  163.                   ┬º┬ºpush(ASSetPropFlags(clickx.ui.Scroller.prototype,null,1));
  164.                }
  165.                ┬º┬ºpop();
  166.             }
  167.             break;
  168.          }
  169.          set("\x01",eval("\x01") + 48);
  170.          if(┬º┬ºpop())
  171.          {
  172.             set("\x01",eval("\x01") + 418);
  173.          }
  174.       }
  175.    }
  176. }
  177.