Refactor, added a pattern data display

This commit is contained in:
WerWolv
2020-11-10 21:31:04 +01:00
parent 01b4ac8661
commit 35946564a6
13 changed files with 481 additions and 317 deletions

View File

@@ -18,8 +18,8 @@ namespace hex {
void loop();
template<std::derived_from<View> T, typename ... Args>
T* addView(Args& ... args) {
this->m_views.emplace_back(new T(args...));
T* addView(Args&& ... args) {
this->m_views.emplace_back(new T(std::forward<Args>(args)...));
return static_cast<T*>(this->m_views.back());
}