isMoving = false;
thisDirection = 1;
thisOffset = 1;
thisSpeed = 50;
thisTimer = null;
thisObj = null;
thisLoc = -500;

function startScrolling() {
	thisObj = document.getElementById("ni_portfolio_pics");
	
	/* is not currently moving, initiate move request */
	if (!isMoving) {
		isMoving = true;
		thisTimer = setInterval('moveObj()', thisSpeed);
	}
}

function moveObj() {
	if (((thisDirection == -1) && (thisLoc < -540)) || ((thisDirection == 1) && (thisLoc > 0))) {
		stopScrolling();
	} else {
		thisLoc += (thisOffset * thisDirection);
		thisObj.style.left = thisLoc;
	}
		window.status = thisLoc;
}

function stopScrolling() {
	clearInterval(thisTimer);
	isMoving = false;
}

function expandSection() {
	crnrObj = document.getElementById("ni_crv_bot");
	crnrObj.style.top = crnrObj.parentNode.offsetHeight - 41;
}