Commit 1b0dd916 authored by Dmitry.Shahtanov's avatar Dmitry.Shahtanov Committed by Alexander.Trofimov

fix: Bug 19639 - Часть листов книги отсутствует при открытии документа

git-svn-id: svn://192.168.3.15/activex/AVS/Sources/TeamlabOffice/trunk/OfficeWeb@49006 954022d7-b5bf-4e40-9824-e11837661b57
parent bdb2946e
......@@ -50,7 +50,10 @@ Date.prototype.isLeapYear = function () {
};
Date.prototype.getDaysInMonth = function () {
return arguments.callee[this.isLeapYear() ? 'L' : 'R'][this.getMonth()];
// return arguments.callee[this.isLeapYear() ? 'L' : 'R'][this.getMonth()];
return this.isLeapYear() ?
this.getDaysInMonth.L[this.getMonth()] :
this.getDaysInMonth.R[this.getMonth()]
};
// durations of months for the regular year
......@@ -3431,6 +3434,28 @@ function parseNum( str ) {
return !isNaN( str );
}
function searchRegExp(str, flags){
var vFS = str
.replace( /(\\)/g, "\\" )
.replace( /(\^)/g, "\\^" )
.replace( /(\()/g, "\\(" )
.replace( /(\))/g, "\\)" )
.replace( /(\+)/g, "\\+" )
.replace( /(\[)/g, "\\[" )
.replace( /(\])/g, "\\]" )
.replace( /(\{)/g, "\\{" )
.replace( /(\})/g, "\\}" )
.replace( /(\$)/g, "\\$" )
.replace( /(~)?\*/g, function ( $0, $1 ) {
return $1 ? $0 : '(.*)';
} )
.replace( /(~)?\?/g, function ( $0, $1 ) {
return $1 ? $0 : '.';
} )
.replace( /(~\*)/g, "\\*" ).replace( /(~\?)/g, "\\?" );
return new RegExp( vFS + "$", flags ? flags : "i" );
}
function phi( x ) {
return 0.39894228040143268 * Math.exp( -(x * x) / 2.0 );
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment