function showTweet(dir)
{ tweetLabel = document.getElementById("tweetControl");
tweetbox = document.getElementById("twitterpanel");
if (dir == "open") { scrollLeft(-253, 1); } else { scrollRight(0,1) }
return; }
function scrollLeft (pos, speed) {
s= speed; position = pos; 
tweetbox.style.left = position + "px"; tweetLabel.innerHTML = "<a href='javascript:showTweet(\"close\");'><img src='images/tweets.gif' border='0' /></a>";
if (position == 0) { return; } else {position = position + s }
s = s +1; delay = setTimeout('scrollLeft(position, s)',10);
}
function scrollRight (pos, speed) {
s= speed; position = pos; 
tweetbox.style.left = position + "px"; tweetLabel.innerHTML = "<a href='javascript:showTweet(\"open\");'><img src='images/tweets.gif' border='0' /></a>";
if (position == -253) { return; } else {position = position - s }
s = s + 1; delay = setTimeout('scrollRight(position, s)',10);
}
function FBscrollLeft(pos, speed) {
s= speed; position = pos; 
FBbox.style.left = position + "px"; FBLabel.innerHTML = "<a href='javascript:FBshow(\"close\");'><img src='images/facebook.gif' border='0' /></a>";
if (position == 0) { return; } else {position = position + s }
s = s +1; delay = setTimeout('FBscrollLeft(position, s)',10);
}
function FBscrollRight (pos, speed) {
s= speed; position = pos; 
FBbox.style.left = position + "px"; FBLabel.innerHTML = "<a href='javascript:FBshow(\"open\");'><img src='images/facebook.gif' border='0' /></a>";
if (position == -300) { return; } else {position = position - s }
s = s + 1; delay = setTimeout('FBscrollRight(position, s)',10);
}
function FBshow(dir)
{ FBLabel = document.getElementById("FBControl");
FBbox = document.getElementById("FBpanel");
if (dir == "open") { FBscrollLeft(-300, 1); } else { FBscrollRight(0,1) }
return; }

