﻿/* File Created: January 8, 2012 */
/// <reference path="jquery-1.5.1-vsdoc.js" />


$(window).load(function () {

    // Get the height of the content window and apply to a new div to display pre-loader

    var height = $("#main-image").height()
    
    $("<div id=\"\loader\"\></div>").height(height).appendTo("#content")
    $("#content").height(height)

    $("#loader").fadeOut("slow")
    $("#main-image").load().css("visibility", "visible")

});



//Show the map when location icon is clicked

$(document).ready(function () {
    $("#location").click(function () {




        $(".image-info").hide()
        $("#site-map").hide()
        $(".map-container").css("margin-left", "0")
        $(".close-map").css("margin-top", "0")
        $("#about-the-photographer").hide()


    });

    //Show image info

    $("#info").click(function () {
        $(".image-info").fadeIn("slow")
        $("#site-map").hide()
        $("#about-the-photographer").hide()
    });


    $(".close").click(function () {
        $(".image-info").hide()
        $(".map-container").css("margin-left", "-9999px")
        $(".close-map").css("margin-top", "-9999px")
        $("#site-map").hide()
        $("#about-the-photographer").hide()
    });


    $("#site-nav").click(function () {
        $(".image-info").hide()
        $("#about-the-photographer").hide()
        $(".map-container").css("margin-left", "-9999px")
        $(".close-map").css("margin-top", "-9999px")
        $("#site-map").fadeIn("slow")
    });
     $("#about").click(function () {
        $(".image-info").hide()
        $(".map-container").css("margin-left", "-9999px")
        $(".close-map").css("margin-top", "-9999px")
        $("#about-the-photographer").fadeIn("slow")
        $("#site-map").hide()
    });
});
