Skip to content

Commit 85f73d1

Browse files
committed
Added unordered_map<Control*, std::string> mWrappedText to cache the string representing the wrapped text
1 parent 7877185 commit 85f73d1

1 file changed

Lines changed: 3 additions & 0 deletions

File tree

libControls/ToolTip.h

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@
1010
#include <utility>
1111
#include <vector>
1212
#include <optional>
13+
#include <unordered_map>
1314

1415

1516
class ToolTip : public Control
@@ -40,6 +41,8 @@ class ToolTip : public Control
4041

4142
std::vector<std::pair<Control*, std::string>> mControls;
4243

44+
std::unordered_map<Control*, std::string> mWrappedText;
45+
4346
std::optional<int> mCommandedHeight{std::nullopt};
4447
std::optional<int> mCommandedWidth{std::nullopt};
4548

0 commit comments

Comments
 (0)