// Place your application-specific JavaScript functions and classes here
// This file is automatically included by javascript_include_tag :defaults

function showJobDetail(jobId) {
    $$('.job_entry').each(function(el) {
        if (el.visible() && el.identify() != jobId)
            Effect.BlindUp(el.identify(), {
                duration: 0.5
            });
    });

    if ( ! Element.visible(jobId)) {
        Effect.BlindDown(jobId, { 
            duration: 0.5
        });
        Effect.ScrollTo($(jobId), {
            duration: 0.5
        });
    }
}



function initContactMap() {
    var eventLatitude = 49.219671;
    var eventLongitude = 16.599184;

    if (GBrowserIsCompatible()) {
        map = new GMap2($('contact_map'));
        map.setCenter(new GLatLng(eventLatitude, eventLongitude), 12);
        map.addControl(new GLargeMapControl());
        map.addControl(new GMapTypeControl());
        var marker = new GMarker(new GLatLng(eventLatitude, eventLongitude));
        map.addOverlay(marker);
        marker.openInfoWindowHtml(
            '<strong>GMV Martini CZ s.r.o.</strong> <br />' +
            'Poděbradova 63 <br />' +
            '61200 Brno');
    }
}
