fix dlangide issue 33 - openging of .json file in editor causes crash

This commit is contained in:
Vadim Lopatin 2015-02-19 11:29:33 +03:00
parent fca69bd34e
commit fcda30b159
1 changed files with 4 additions and 2 deletions

View File

@ -503,8 +503,10 @@ class EditableContent {
@property EditableContent syntaxHighlighter(SyntaxHighlighter syntaxHighlighter) { @property EditableContent syntaxHighlighter(SyntaxHighlighter syntaxHighlighter) {
_syntaxHighlighter = syntaxHighlighter; _syntaxHighlighter = syntaxHighlighter;
_syntaxHighlighter.content = this; if (_syntaxHighlighter) {
updateTokenProps(0, cast(int)_lines.length); _syntaxHighlighter.content = this;
updateTokenProps(0, cast(int)_lines.length);
}
return this; return this;
} }