* use std::move() for local variables that are copied but not reused
Addresses ~140 Coverity "Variable copied when it could be moved"
defects across 74 files. Every std::move() targets a local variable
whose value is consumed by push_back, emplace, assignment, lambda
capture, or a function call and is never read again afterward.
Co-Authored-By: Claude Opus 4.6 (1M context) <[email protected]>
* clang: use std::make_shared
* clang: use std::make_unique
* address feedback
---------
Co-authored-by: Claude Opus 4.6 (1M context) <[email protected]>
Linux iconv does not support "UCS-2-INTERNAL" and conversion will fail if SDL
is compiled with native iconv support. SDL version 2.32.2 fixed this by
changing the macro to use "UCS-2" instead. Unfortunately in my tests this
worked perfectly in Linux but was broken on Mac in the rocket_ui code. However
simply using proper endianess appears to work on all test platforms.
Additionally this fixes a bad memory leak as SDL_iconv_string() allocates it's
return string and this was never free'd before. So every character of text
input resulted in a memory leak of 6+ bytes.
* Set ver to C++17
* remove deprecated shuffle
* Fix std::iterator being deprecated
* Work around codecvt deprecation
* Fix std::result_of deprecation
* Another random_shuffle
* another text conversion replacement
* read access to controls
* Early draft of checking keypresses in scpui
* detangle some code and prepare it for API usage
* API access to the core methods required
* move these checks into the UI methods
* comment
* fix bugs
* be smarter
* Need this stuff, too
* some more presets work
* unify func naming scheme
* cleanup and clarifications
* get detect keypress working
* allow searching and creating new presets based on current controls
* address feedback
* return nil if no preset is matched
* use the builtin methods which do the same thing, but slightly cleaner
* typo
This gives every document their own environment instead of using the
global environment. Previously it was necessary to store variables in
the global namespace since otherwise they could not be accessed by event
listeners.
This creates a separate environment table for every document so that all
<script> blocks and event handlers share the same "global" environment.
This emulates the "scrolling text" effect that is present in briefings.
It is not exactly the same since it just goes pixel wise and not by
character but it looks good enough.
The largest new feature is that it is now possible to include other
files into the RML by using the "include" tag. This is useful for making
markup files more modular.
Also added some more options for existing things (e.g. built-in detail
options).