(function() {
  var __hasProp = Object.prototype.hasOwnProperty, __extends = function(child, parent) {
    for (var key in parent) { if (__hasProp.call(parent, key)) child[key] = parent[key]; }
    function ctor() { this.constructor = child; }
    ctor.prototype = parent.prototype;
    child.prototype = new ctor;
    child.__super__ = parent.prototype;
    return child;
  };
  $(document).ready(function() {
    var Cameroun, Canada, Pin, cameroun, canada, changePin;
    Pin = (function() {
      function Pin(name) {
        this.name = name;
      }
      Pin.prototype.changeImage = function(url) {
        return $("#polaroid").attr("src", url);
      };
      return Pin;
    })();
    Canada = (function() {
      __extends(Canada, Pin);
      function Canada() {
        Canada.__super__.constructor.apply(this, arguments);
      }
      Canada.prototype.changeImage = function() {
        return Canada.__super__.changeImage.call(this, "/img/accueil/polaroid-can-1.png");
      };
      return Canada;
    })();
    Cameroun = (function() {
      __extends(Cameroun, Pin);
      function Cameroun() {
        Cameroun.__super__.constructor.apply(this, arguments);
      }
      Cameroun.prototype.changeImage = function() {
        return Cameroun.__super__.changeImage.call(this, "/img/accueil/polaroid-cam-1.png");
      };
      return Cameroun;
    })();
    canada = new Canada;
    cameroun = new Cameroun;
    changePin = function(clickedPin) {
      var pin, pins, _i, _len, _results;
      pins = ["can-pin", "cam-pin"];
      _results = [];
      for (_i = 0, _len = pins.length; _i < _len; _i++) {
        pin = pins[_i];
        _results.push($(clickedPin).attr("id") === pin ? $(clickedPin).find("img").addClass("selected") : $("#" + pin).find("img").removeClass("selected"));
      }
      return _results;
    };
    $("#can-pin").hover(function() {
      canada.changeImage();
      return changePin(this);
    });
    $("#cam-pin").hover(function() {
      cameroun.changeImage();
      return changePin(this);
    });
    $('#nouvelles-texte').bxSlider({
      controls: false,
      speed: 1000,
      pause: 6000,
      auto: true,
      pager: true,
      pagerSelector: '#news-nav'
    });
    return $('.pager-link').text("");
  });
}).call(this);

