﻿/// <reference path="jquery-1.3.2.js"/>
function ShowCurrentRegion() {
    HideAllCountries();
    $("#regionSelectorCurrent").show();
}

function ShowAllRegions() {    
    $("#regionSelectorRegions").show();
}

function ShowCountries(regionId, countryId) {
    HideAllCountries();
    $(countryId).css("left", $(regionId).position().left - 5);
    $(countryId).css("top", $(regionId).position().top + $(regionId).height());
    $(countryId).slideDown(200);
}

function HideAllCountries() {
    $(".rgnv_popupCountryMenu").slideUp(200);
}

function HideCountries(countryId) {
    $(countryId).slideUp(200);
}

$(document).ready(function() {
    $("#regionSelectorRegions").hover(null, function() {
        $("#regionSelectorRegions").hide(ShowCurrentRegion());
    });

    $("#regionSelectorCurrent").hover(function() {
        $("#regionSelectorCurrent").hide(ShowAllRegions());
    });
});