diff options
author | Thales Lima Oliveira <thaleslima.ufu@gmail.com> | 2018-05-03 17:22:22 -0300 |
---|---|---|
committer | Thales Lima Oliveira <thaleslima.ufu@gmail.com> | 2018-05-03 17:22:22 -0300 |
commit | 726ec7832947397e61196e94f2f3ee66d6f6340d (patch) | |
tree | 01e93fcf1240a9a0243cb9a61f8c7256caed641f | |
parent | 2b7409b5dd3714d14112e40a1ead8776a6da1576 (diff) | |
download | PSP.git-726ec7832947397e61196e94f2f3ee66d6f6340d.tar.gz PSP.git-726ec7832947397e61196e94f2f3ee66d6f6340d.tar.xz PSP.git-726ec7832947397e61196e94f2f3ee66d6f6340d.zip |
Clipboard fix
-rw-r--r-- | Project/DataReport.cpp | 11 | ||||
-rw-r--r-- | Project/Project.project | 2 |
2 files changed, 7 insertions, 6 deletions
diff --git a/Project/DataReport.cpp b/Project/DataReport.cpp index 2742471..1511079 100644 --- a/Project/DataReport.cpp +++ b/Project/DataReport.cpp @@ -1030,11 +1030,12 @@ void DataReport::GridKeyHandler(wxGrid* grid, wxKeyEvent& event) } } } - - wxOpenClipboard(); - wxEmptyClipboard(); - wxSetClipboardData(wxDF_TEXT, copyData.mb_str(), 0, 0); // In Windows need this for UNICODE - wxCloseClipboard(); + + if (wxTheClipboard->Open()) + { + wxTheClipboard->SetData(new wxTextDataObject(copyData)); + wxTheClipboard->Close(); + } } else if(event.GetKeyCode() == 'A' && event.GetModifiers() == wxMOD_CONTROL) { // Select all grid->SelectAll(); } diff --git a/Project/Project.project b/Project/Project.project index 1447966..2d8fb46 100644 --- a/Project/Project.project +++ b/Project/Project.project @@ -513,7 +513,7 @@ <Preprocessor Value="NDEBUG"/> <Preprocessor Value="UNICODE"/> </Compiler> - <Linker Options="$(shell wx-config --libs std,ribbon,aui,propgrid,richtext,gl);-mwindows" Required="yes"/> + <Linker Options="$(shell wx-config --libs std,ribbon,aui,propgrid,richtext,stc,gl);-mwindows" Required="yes"/> <ResourceCompiler Options="$(shell wx-config --rcflags)" Required="no"/> <General OutputFile="$(IntermediateDirectory)/pspufu" IntermediateDirectory="./Release_Windows_x64" Command="./pspufu" CommandArguments="" UseSeparateDebugArgs="no" DebugArguments="" WorkingDirectory="$(IntermediateDirectory)" PauseExecWhenProcTerminates="no" IsGUIProgram="yes" IsEnabled="yes"/> <BuildSystem Name="Default"/> |