Fix X11 selections (#55)

This fixes all the issues with the X11 selection in addition to switching the clipboard to always be UTF-8.
This commit is contained in:
DS
2021-08-30 21:44:56 +02:00
committed by GitHub
parent 75b4c05741
commit 9c4b6f25ab
6 changed files with 245 additions and 83 deletions

View File

@ -56,7 +56,8 @@ const core::stringc& COSOperator::getOperatingSystemVersion() const
//! copies text to the clipboard
void COSOperator::copyToClipboard(const c8* text) const
//! \param text: text in utf-8
void COSOperator::copyToClipboard(const c8 *text) const
{
if (strlen(text)==0)
return;
@ -103,7 +104,7 @@ void COSOperator::copyToClipboard(const c8* text) const
//! gets text from the clipboard
//! \return Returns 0 if no string is in there.
//! \return Returns 0 if no string is in there, otherwise an utf-8 string.
const c8* COSOperator::getTextFromClipboard() const
{
#if defined(_IRR_XBOX_PLATFORM_)