aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/Editor.cxx
diff options
context:
space:
mode:
authornyamatongwe <devnull@localhost>2011-10-26 16:54:05 +1100
committernyamatongwe <devnull@localhost>2011-10-26 16:54:05 +1100
commitb0c6298f1a5b7a1b16a20ccd577f6e2318ae95ad (patch)
treeccffc12c65a182ec59140f049c1d0e9faace2152 /src/Editor.cxx
parent576adef9a5df55d74e2730dc3ffb5db9f0a0a3f2 (diff)
downloadscintilla-mirror-b0c6298f1a5b7a1b16a20ccd577f6e2318ae95ad.tar.gz
Implement ILoader interface so that clients can load documents from
background threads.
Diffstat (limited to 'src/Editor.cxx')
-rw-r--r--src/Editor.cxx10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/Editor.cxx b/src/Editor.cxx
index fb7f4c636..d52d2498f 100644
--- a/src/Editor.cxx
+++ b/src/Editor.cxx
@@ -8708,6 +8708,16 @@ sptr_t Editor::WndProc(unsigned int iMessage, uptr_t wParam, sptr_t lParam) {
(reinterpret_cast<Document *>(lParam))->Release();
break;
+ case SCI_CREATELOADER: {
+ Document *doc = new Document();
+ if (doc) {
+ doc->AddRef();
+ doc->Allocate(wParam);
+ doc->SetUndoCollection(false);
+ }
+ return reinterpret_cast<sptr_t>(static_cast<ILoader *>(doc));
+ }
+
case SCI_SETMODEVENTMASK:
modEventMask = wParam;
return 0;