//  PhotoGallery.js
//
//  JavaScript functions used by the various Photo Gallery pages
//  for its basic slide navigation

var counter = 0
var stopSS = 0;

function showFirst() {
  counter = 0
  document.hotphoto.src = Images[counter]
}

function showPrev() {
  if (--counter < 0) counter += len
  document.hotphoto.src = Images[counter]
}

function rotate() {
  if (!stopSS) {
    document.hotphoto.src = Images[counter]
    if (++counter == len) counter -= len
    setTimeout("rotate()", 3 * 1000);
  }
}

function stopShow() {
  stopSS = 1;
  if (--counter < 0) counter += len
}

function showNext() {
  if (++counter == len) counter -= len
  document.hotphoto.src = Images[counter]
}

function showLast() {
  counter = len-1
  document.hotphoto.src = Images[counter]
}
