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:
@@ -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);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user