Merge branch '2.6.x' into feature/backmerge

This commit is contained in:
Chris Thrasher 2022-12-29 22:29:57 -07:00
commit 15cdb40fc2
No known key found for this signature in database
GPG Key ID: 56FB686C9DFC8E2C
5 changed files with 9639 additions and 9470 deletions

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@ -75,8 +75,8 @@ public:
/// \brief Load the image from a file on disk
///
/// The supported image formats are bmp, png, tga, jpg, gif,
/// psd, hdr and pic. Some format options are not supported,
/// like progressive jpeg.
/// psd, hdr, pic and pnm. Some format options are not supported,
/// like jpeg with arithmetic coding or ASCII pnm.
/// If this function fails, the image is left unchanged.
///
/// \param filename Path of the image file to load
@ -92,8 +92,8 @@ public:
/// \brief Load the image from a file in memory
///
/// The supported image formats are bmp, png, tga, jpg, gif,
/// psd, hdr and pic. Some format options are not supported,
/// like progressive jpeg.
/// psd, hdr, pic and pnm. Some format options are not supported,
/// like jpeg with arithmetic coding or ASCII pnm.
/// If this function fails, the image is left unchanged.
///
/// \param data Pointer to the file data in memory
@ -110,8 +110,8 @@ public:
/// \brief Load the image from a custom stream
///
/// The supported image formats are bmp, png, tga, jpg, gif,
/// psd, hdr and pic. Some format options are not supported,
/// like progressive jpeg.
/// psd, hdr, pic and pnm. Some format options are not supported,
/// like jpeg with arithmetic coding or ASCII pnm.
/// If this function fails, the image is left unchanged.
///
/// \param stream Source stream to read from

View File

@ -421,7 +421,7 @@ bool eventProcess(sf::Event& event)
event.key.shift = shiftDown();
event.key.system = systemDown();
keyMap[kb] = inputEvent.value;
keyMap[static_cast<std::size_t>(kb)] = inputEvent.value;
if (special && inputEvent.value)
doDeferredText = special;
@ -501,7 +501,7 @@ bool eventProcess(sf::Event& event)
//
// We only clear the ICANON flag for the time of reading
newTerminalConfig.c_lflag &= ~(tcflag_t)ICANON;
newTerminalConfig.c_lflag &= ~static_cast<tcflag_t>(ICANON);
tcsetattr(STDIN_FILENO, TCSANOW, &newTerminalConfig);
timeval timeout;
@ -572,7 +572,7 @@ bool InputImpl::isKeyPressed(Keyboard::Key key)
return false;
update();
return keyMap[key];
return keyMap[static_cast<std::size_t>(key)];
}
@ -698,14 +698,14 @@ void InputImpl::setTerminalConfig()
std::scoped_lock lock(inputMutex);
initFileDescriptors();
tcgetattr(STDIN_FILENO, &newTerminalConfig); // get current terminal config
oldTerminalConfig = newTerminalConfig; // create a backup
newTerminalConfig.c_lflag &= ~(tcflag_t)ECHO; // disable console feedback
newTerminalConfig.c_lflag &= ~(tcflag_t)ISIG; // disable signals
newTerminalConfig.c_lflag |= ICANON; // disable noncanonical mode
newTerminalConfig.c_iflag |= IGNCR; // ignore carriage return
tcsetattr(STDIN_FILENO, TCSANOW, &newTerminalConfig); // set our new config
tcflush(STDIN_FILENO, TCIFLUSH); // flush the buffer
tcgetattr(STDIN_FILENO, &newTerminalConfig); // get current terminal config
oldTerminalConfig = newTerminalConfig; // create a backup
newTerminalConfig.c_lflag &= ~static_cast<tcflag_t>(ECHO); // disable console feedback
newTerminalConfig.c_lflag &= ~static_cast<tcflag_t>(ISIG); // disable signals
newTerminalConfig.c_lflag |= ICANON; // disable noncanonical mode
newTerminalConfig.c_iflag |= IGNCR; // ignore carriage return
tcsetattr(STDIN_FILENO, TCSANOW, &newTerminalConfig); // set our new config
tcflush(STDIN_FILENO, TCIFLUSH); // flush the buffer
}

View File

@ -175,7 +175,7 @@ bool CursorImpl::loadFromSystem(Cursor::Type type)
case Cursor::Arrow: shape = XC_arrow; break;
case Cursor::Wait: shape = XC_watch; break;
case Cursor::Text: shape = XC_xterm; break;
case Cursor::Hand: shape = XC_hand1; break;
case Cursor::Hand: shape = XC_hand2; break;
case Cursor::SizeHorizontal: shape = XC_sb_h_double_arrow; break;
case Cursor::SizeVertical: shape = XC_sb_v_double_arrow; break;
case Cursor::SizeLeft: shape = XC_left_side; break;