Added support for Chrome 25.

This commit is contained in:
antisnatchor
2013-03-03 11:24:08 +00:00
parent 0ea1c0bbf8
commit 4e7b983bd3

View File

@@ -428,12 +428,20 @@ beef.browser = {
return (!!window.chrome && !window.webkitPerformance && window.navigator.appVersion.match(/Chrome\/(\d+)\./)) && ((parseInt(window.navigator.appVersion.match(/Chrome\/(\d+)\./)[1], 10) == 24) ? true : false);
},
/**
* Returns true if Chrome 25.
* @example: beef.browser.isC25()
*/
isC25:function () {
return (!!window.chrome && !window.webkitPerformance && window.navigator.appVersion.match(/Chrome\/(\d+)\./)) && ((parseInt(window.navigator.appVersion.match(/Chrome\/(\d+)\./)[1], 10) == 25) ? true : false);
},
/**
* Returns true if Chrome.
* @example: beef.browser.isC()
*/
isC:function () {
return this.isC5() || this.isC6() || this.isC7() || this.isC8() || this.isC9() || this.isC10() || this.isC11() || this.isC12() || this.isC13() || this.isC14() || this.isC15() || this.isC16() || this.isC17() || this.isC18() || this.isC19() || this.isC20() || this.isC21() || this.isC22() || this.isC23() || this.isC24();
return this.isC5() || this.isC6() || this.isC7() || this.isC8() || this.isC9() || this.isC10() || this.isC11() || this.isC12() || this.isC13() || this.isC14() || this.isC15() || this.isC16() || this.isC17() || this.isC18() || this.isC19() || this.isC20() || this.isC21() || this.isC22() || this.isC23() || this.isC24() || this.isC25();
},
/**
@@ -513,6 +521,7 @@ beef.browser = {
C22:this.isC22(), // Chrome 22
C23:this.isC23(), // Chrome 23
C24:this.isC24(), // Chrome 24
C25:this.isC25(), // Chrome 25
C:this.isC(), // Chrome any version
FF2:this.isFF2(), // Firefox 2
@@ -646,7 +655,10 @@ beef.browser = {
return '24'
}
; // Chrome 24
if (this.isC25()) {
return '25'
}
;
if (this.isFF2()) {
return '2'
}