Setting Drag Boundaries

For a project I am working on, the user can see sections of the website by dragging around horizontally or vertically on the screen. I have set up a dragging function for that. I am having trouble setting the boundaries however. When I reach the limit I have set for the dragging, the movieClips inside the movieClip I am dragging jump for half a second. The whole thing looks really bad. This is my code for dragging


private function dragIt(e:MouseEvent):void
        {
            difX = xPos - stageRef.mouseX;
            difY = yPos - stageRef.mouseY;
            
            if((target.x)-(difX)/3>1200)
            {
                target.x = 1200;
            }
            if((target.x)-(difX)/3<-1500)
            {
                target.x = -1500;
                
            }
            if((target.y)-(difY)/3>1000)
            {
                target.y = 1000;
                
            }
            if((target.y)-(difY)/3<-1000)
            {
                target.y = -1000;
            }
            if ((target.y)-(difY)/3>-1000 && (target.x)-(difX)/3<1200 && (target.x)-(difX)/3>-1500 && (target.y)-(difY)/3<1000)
            {
                TweenLite.to(target, 0.5, {x:(target.x)-(difX)/3,y:(target.y)-(difY)/3});    
            }
            
            e.updateAfterEvent();
        }

I am setting the limits here. But can’t get rid of the jump. How, do I make this smooth. Please help.