From 0801e0084a5cf87f424235d5947f5158474d5da4 Mon Sep 17 00:00:00 2001 From: Neil Date: Sat, 22 Apr 2017 09:11:03 +1000 Subject: Encapsulate the LexInterface of Document. --- src/ScintillaBase.cxx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/ScintillaBase.cxx') diff --git a/src/ScintillaBase.cxx b/src/ScintillaBase.cxx index 659a37b90..0fbf555d1 100644 --- a/src/ScintillaBase.cxx +++ b/src/ScintillaBase.cxx @@ -581,10 +581,10 @@ LexState::~LexState() { } LexState *ScintillaBase::DocumentLexState() { - if (!pdoc->pli) { - pdoc->pli = new LexState(pdoc); + if (!pdoc->GetLexInterface()) { + pdoc->SetLexInterface(new LexState(pdoc)); } - return static_cast(pdoc->pli); + return static_cast(pdoc->GetLexInterface()); } void LexState::SetLexerModule(const LexerModule *lex) { -- cgit v1.2.3