Inheritance: CCMoveBy
Ejemplo n.º 1
0
        public void moveToPage(int page)
        {
            if (page < 0 || page >= layers_.Count)
            {
                CCDebug.Error("CCScrollLayer#moveToPage: {0} - wrong page number, out of bounds. ", page);
                return;
            }
            if (this.delegate_ != null)
            {
                this.delegate_.scrollLayerScrollingStarted(this, page);
            }
            isMoving_ = true;
            CCActionFiniteTime changePage = new CCMoveTo(scrollTime_, this.positionForPageWithNumber(page));

            changePage = CCSequence.Actions(changePage, new CCCallFunc(this, moveToPageEnded));
            this.runAction(changePage);
            prevScreen_    = currentScreen_;
            currentScreen_ = page;
        }
Ejemplo n.º 2
0
		protected override CCAction reverseImpl ()
		{
			CCMoveTo act = new CCMoveTo (_duration, _positionDelta * -1);
			return act;
		}
Ejemplo n.º 3
0
		protected override CCAction copyImpl ()
		{
			CCMoveTo act = new CCMoveTo (this.duration, _endPosition);
			return act;
		}
Ejemplo n.º 4
0
        protected override CCAction reverseImpl()
        {
            CCMoveTo act = new CCMoveTo(_duration, _positionDelta * -1);

            return(act);
        }
Ejemplo n.º 5
0
        protected override CCAction copyImpl()
        {
            CCMoveTo act = new CCMoveTo(this.duration, _endPosition);

            return(act);
        }
Ejemplo n.º 6
0
		public void moveToPage(int page)
		{
			if (page < 0 || page >= layers_.Count) {
				CCDebug.Error("CCScrollLayer#moveToPage: {0} - wrong page number, out of bounds. ", page);
				return;
			}
			if(this.delegate_ != null)
				this.delegate_.scrollLayerScrollingStarted(this, page);
			isMoving_ = true;
			CCActionFiniteTime changePage = new CCMoveTo(scrollTime_, this.positionForPageWithNumber(page));
			changePage = CCSequence.Actions( changePage, new CCCallFunc(this, moveToPageEnded));
			this.runAction(changePage);
			prevScreen_ = currentScreen_;
			currentScreen_ = page;
		}