﻿berryAlloc.countryLanguageLanding = function () {
    this.BindEvents();
    this.Initialize();
};
berryAlloc.countryLanguageLanding.prototype = {
	BindEvents: function () {
		var me = this;
		$("#CountryLanguageLanding_Close").click(function () { me.HideLandingOverlay(); });
		$("a.countryLanguage").click(function () { me.RegisterSelection($(this).data("code")); });
	},
	Initialize: function () {
		var me = this;
		me.LogState();

	},
	HideLandingOverlay: function () {
		$("#CountryLanguageLanding_Overlay").slideUp();
	},
	LogState: function () {
		DelawareCommons.logToConsole("FirstTimeVisit:" + $("#inp_FirstTimeVisit").val());
		DelawareCommons.logToConsole("CountryMisMatch:" + $("#inp_CountryMisMatch").val());
	},
	RegisterSelection: function (code) {
		berryAlloc.setAnalyticsCustomVar(1, 'CountryLanguageLanding', code, 1);
		return true;
	}
};

