rio: 0.0.36 -> 0.0.37
[NixPkgs.git] / pkgs / applications / editors / codeblocks / fix-clipboard-flush.patch
blobee4ebd61af0b66938d866e81a17fd5ee599d060f
1 diff --git a/src/src/app.cpp b/src/src/app.cpp
2 index 81130fd..f98d37b 100644
3 --- a/src/src/app.cpp
4 +++ b/src/src/app.cpp
5 @@ -602,7 +602,8 @@ bool CodeBlocksApp::OnInit()
6 m_BatchWindowAutoClose = true;
7 m_pSingleInstance = nullptr;
9 - wxTheClipboard->Flush();
10 + if (wxTheClipboard->IsOpened())
11 + wxTheClipboard->Flush();
13 wxCmdLineParser& parser = *Manager::GetCmdLineParser();
14 parser.SetDesc(cmdLineDesc);
15 @@ -851,7 +852,8 @@ bool CodeBlocksApp::OnInit()
17 int CodeBlocksApp::OnExit()
19 - wxTheClipboard->Flush();
20 + if (wxTheClipboard->IsOpened())
21 + wxTheClipboard->Flush();
23 if (g_DDEServer) delete g_DDEServer;