/*
@author Lincoln

This is mainly for old JS calls that were popular in the site from the deceased scripts.js
The manily delegate to function that are defined in flipkey_jquery.js or flipkey_prototype.js
depending on the environment
*/

FlipKey.progress_bar = new Image();
FlipKey.progress_bar.src = "/img/rbo/tab_loader.gif";

function showLoading(text)
{
    if (!text) text = "Loading...";
    FlipKey.showLightboxText('<div style="padding: 10px; background-color: white; width: 300px; text-align: center"><b>' + text + '</b><br/><br/><img src="/img/rbo/tab_loader.gif" /><br/></div>', false);
}

//Deprecated
function showWindow(not_sure, element_id, not_used, not_necessary, sad_face)
{
    FlipKey.showLightboxFromDiv(element_id, false, false);
}

//Deprecated
function fadeOut(el)
{
    FlipKey.closeLightbox();
   // console.log(jQuery(el));
}

//Deprecated - should used into FlipKey namespace
function clearDates()
{
    //not sure if jQuery 
    if ($('#arrival_date').val)
    {
        $('#arrival_date').val('(Optional)');
        $('#departure_date').val('(Optional)');
    }
    else {
        $('arrival_date').value = '(Optional)';
        $('departure_date').value = '(Optional)';
    }
}

//LB - All this stuff is old wats to show and hide popups, routing them to thier jQuery/Prototype based functions
function showAjax(url)
{
    FlipKey.showLightboxAjax(url);
}

function closeLightbox()
{
    FlipKey.closeLightbox();
}

function getLeft() {}

function getTop() {}

function dispDiv() {}
