update narcissus. fix #365

This commit is contained in:
Fabian Jakobs 2011-08-04 12:11:51 +02:00
commit 1b02f2895e
4 changed files with 2817 additions and 1948 deletions

View file

@ -87,7 +87,7 @@ var Document = function(text) {
this.$detectNewLine = function(text) {
var match = text.match(/^.*?(\r?\n)/m);
var match = text.match(/^.*?(\r\n|\r|\n)/m);
if (match) {
this.$autoNewLine = match[1];
} else {
@ -111,7 +111,8 @@ var Document = function(text) {
this.$autoNewLine = "\n";
this.$newLineMode = "auto";
this.setNewLineMode = function(newLineMode) {
if (this.$newLineMode === newLineMode) return;
if (this.$newLineMode === newLineMode)
return;
this.$newLineMode = newLineMode;
};