Removed some manual management.

Apparently, the layout engine is written in something resembling
either Java or Google's G+.  It's "C++", but there's no exceptions,
manual memory management, etc.  But it's also attempting to recreate
a subset of the Java Collections framework in C++.  It's a common
pattern in both beginner and older C++.

I'll completely replace all of this with standard C++ library types.
This commit is contained in:
2025-03-02 17:28:31 -05:00
parent bdbd30873f
commit 6d05779dd2
2 changed files with 19 additions and 22 deletions

View File

@ -5,6 +5,10 @@
# error Do not include this file directly, use "core.hh" instead.
#endif
#include <memory>
#include <string>
#include <unordered_map>
namespace dw {
namespace core {
@ -181,8 +185,9 @@ private:
bool scrollIdleNotInterrupted;
/* Anchors of the widget tree */
lout::container::typed::HashTable <lout::object::String, Anchor>
*anchorsTable;
//lout::container::typed::HashTable <lout::object::String, Anchor>
//*anchorsTable;
std::unordered_map< std::string, std::unique_ptr< Anchor > > anchorsTable;
SelectionState selectionState;
FindtextState findtextState;