
// a cut version of Is
// see is.js for credits

function Is () {
    var agt=navigator.userAgent.toLowerCase();

    this.major = parseInt(navigator.appVersion);
    this.minor = parseFloat(navigator.appVersion);

    this.nav  = ((agt.indexOf('mozilla')!=-1) && ((agt.indexOf('spoofer')==-1)
                && (agt.indexOf('compatible') == -1)));
    this.nav4 = this.nav && (this.major == 4);
    this.nav4up = this.nav && (this.major >= 4);
    this.nav5up = this.nav && (this.major >= 5);

    this.mozilla  = ((agt.indexOf('mozilla')!=-1) && ((agt.indexOf('spoofer')==-1)
                && (agt.indexOf('compatible') == -1)));;
    this.mozilla4 = this.mozilla && (this.major == 4);
    this.mozilla5up = this.mozilla && (this.major >= 5);

    this.ie   = (agt.indexOf("msie") != -1);
    this.ie4up  = this.ie  && (this.major >= 4);

    this.win   = ( (agt.indexOf("win")!=-1) || (agt.indexOf("16bit")!=-1));
    this.win16 = ((agt.indexOf("win16")!=-1)
               || (agt.indexOf("16bit")!=-1) || (agt.indexOf("windows 3.1")!=-1)
               || (agt.indexOf("windows 16-bit")!=-1));
    this.win31 = (agt.indexOf("windows 3.1")!=-1) || (agt.indexOf("win16")!=-1) ||
                 (agt.indexOf("windows 16-bit")!=-1);
    this.os2   = (agt.indexOf("os/2")!=-1)
                 || (navigator.appVersion.indexOf("OS/2")!=-1)
                 || (agt.indexOf("ibm-webexplorer")!=-1);
    this.mac    = (agt.indexOf("mac")!=-1);

}

var is;
is = new Is();