Update to Scintilla 1.53

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@22080 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Robin Dunn
2003-07-18 06:43:31 +00:00
parent 15d9a04c68
commit e14d10b039
51 changed files with 2613 additions and 756 deletions

View File

@@ -16,6 +16,7 @@
#include "ScintillaWX.h"
#include "ExternalLexer.h"
#include "wx/stc/stc.h"
#include "PlatWX.h"
@@ -337,12 +338,7 @@ void ScintillaWX::Copy() {
if (currentPos != anchor) {
SelectionText st;
CopySelectionRange(&st);
if (wxTheClipboard->Open()) {
wxTheClipboard->UsePrimarySelection(FALSE);
wxString text = stc2wx(st.s, st.len);
wxTheClipboard->SetData(new wxTextDataObject(text));
wxTheClipboard->Close();
}
CopyToClipboard(st);
}
}
@@ -372,6 +368,16 @@ void ScintillaWX::Paste() {
}
void ScintillaWX::CopyToClipboard(const SelectionText& st) {
if (wxTheClipboard->Open()) {
wxTheClipboard->UsePrimarySelection(FALSE);
wxString text = stc2wx(st.s, st.len);
wxTheClipboard->SetData(new wxTextDataObject(text));
wxTheClipboard->Close();
}
}
bool ScintillaWX::CanPaste() {
bool canPaste = FALSE;
bool didOpen;
@@ -474,6 +480,11 @@ long ScintillaWX::WndProc(unsigned int iMessage, unsigned long wParam, long lPar
break;
}
#ifdef SCI_LEXER
case SCI_LOADLEXERLIBRARY:
LexerManager::GetInstance()->Load((const char*)lParam);
break;
#endif
default:
return ScintillaBase::WndProc(iMessage, wParam, lParam);
}