
/* gettext library */

var catalog = new Array();

function pluralidx(n) {
  var v=n==1 ? 0 : n%10>=2 && n%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2;
  if (typeof(v) == 'boolean') {
    return v ? 1 : 0;
  } else {
    return v;
  }
}
catalog['Maximum field size exceeded!'] = 'Przekroczono dopuszczaln\u0105 liczb\u0119 znak\u00f3w!';
catalog['Print open letter'] = 'Drukuj list otwarty';
catalog['Reply to this comment'] = 'Odpowiedz na komentarz';
catalog['Stop replying to this comment'] = 'Przerwij odpowiadanie na ten komentarz';
catalog['Stop supporting open letter'] = 'Przewij dodawanie poparcia dla tego listu otwartego';
catalog['You have to select one or more categories!'] = 'Musisz wybra\u0107 jedn\u0105 lub kilka kategorii!';


function gettext(msgid) {
  var value = catalog[msgid];
  if (typeof(value) == 'undefined') {
    return msgid;
  } else {
    return (typeof(value) == 'string') ? value : value[0];
  }
}

function ngettext(singular, plural, count) {
  value = catalog[singular];
  if (typeof(value) == 'undefined') {
    return (count == 1) ? singular : plural;
  } else {
    return value[pluralidx(count)];
  }
}

function gettext_noop(msgid) { return msgid; }

function interpolate(fmt, obj, named) {
  if (named) {
    return fmt.replace(/%\(\w+\)s/g, function(match){return String(obj[match.slice(2,-2)])});
  } else {
    return fmt.replace(/%s/g, function(match){return String(obj.shift())});
  }
}
