Index: source/gui/CChart.cpp =================================================================== --- source/gui/CChart.cpp +++ source/gui/CChart.cpp @@ -274,7 +274,7 @@ return CSize(); } - return AddText(gui_str, font, 0, buffer_zone, this).GetSize(); + return AddText(gui_str, font, 0, buffer_zone).GetSize(); } void CChart::UpdateBounds() Index: source/gui/CGUIText.h =================================================================== --- source/gui/CGUIText.h +++ source/gui/CGUIText.h @@ -164,7 +164,7 @@ * @param pObject Optional parameter for error output. Used *only* if error parsing fails, * and we need to be able to output which object the error occurred in to aid the user. */ - CGUIText(const CGUI& pGUI, const CGUIString& string, const CStrW& FontW, const float Width, const float BufferZone, const IGUIObject* pObject = nullptr); + CGUIText(const CGUI& pGUI, const CGUIString& string, const CStrW& FontW, const float Width, const float BufferZone, const IGUIObject* pObject); /** * Draw this CGUIText object Index: source/gui/CList.cpp =================================================================== --- source/gui/CList.cpp +++ source/gui/CList.cpp @@ -110,13 +110,13 @@ CGUIText* text; if (!m_List.m_Items[i].GetOriginalString().empty()) - text = &AddText(m_List.m_Items[i], m_Font, width, m_BufferZone, this); + text = &AddText(m_List.m_Items[i], m_Font, width, m_BufferZone); else { // Minimum height of a space character of the current font size CGUIString align_string; align_string.SetValue(L" "); - text = &AddText(align_string, m_Font, width, m_BufferZone, this); + text = &AddText(align_string, m_Font, width, m_BufferZone); } m_ItemsYPositions[i] = buffered_y; Index: source/gui/COList.cpp =================================================================== --- source/gui/COList.cpp +++ source/gui/COList.cpp @@ -74,7 +74,7 @@ CGUIString gui_string; gui_string.SetValue(column.m_Heading); - const CGUIText& text = AddText(gui_string, m_Font, width, m_BufferZone, this); + const CGUIText& text = AddText(gui_string, m_Font, width, m_BufferZone); m_HeadingHeight = std::max(m_HeadingHeight, text.GetSize().cy + COLUMN_SHIFT.y); } @@ -93,13 +93,13 @@ CGUIText* text; if (!column.m_List.m_Items[i].GetOriginalString().empty()) - text = &AddText(column.m_List.m_Items[i], m_Font, width, m_BufferZone, this); + text = &AddText(column.m_List.m_Items[i], m_Font, width, m_BufferZone); else { // Minimum height of a space character of the current font size CGUIString align_string; align_string.SetValue(L" "); - text = &AddText(align_string, m_Font, width, m_BufferZone, this); + text = &AddText(align_string, m_Font, width, m_BufferZone); } shift = std::max(shift, text->GetSize().cy); } Index: source/gui/IGUITextOwner.h =================================================================== --- source/gui/IGUITextOwner.h +++ source/gui/IGUITextOwner.h @@ -58,7 +58,7 @@ /** * Adds a text generated by the given arguments. */ - CGUIText& AddText(const CGUIString& Text, const CStrW& Font, const float& Width, const float& BufferZone, const IGUIObject* pObject = nullptr); + CGUIText& AddText(const CGUIString& Text, const CStrW& Font, const float& Width, const float& BufferZone); /** * Subscribe the custom JS methods. Index: source/gui/IGUITextOwner.cpp =================================================================== --- source/gui/IGUITextOwner.cpp +++ source/gui/IGUITextOwner.cpp @@ -48,10 +48,10 @@ return m_GeneratedTexts.back(); } -CGUIText& IGUITextOwner::AddText(const CGUIString& Text, const CStrW& Font, const float& Width, const float& BufferZone, const IGUIObject* pObject) +CGUIText& IGUITextOwner::AddText(const CGUIString& Text, const CStrW& Font, const float& Width, const float& BufferZone) { // Avoids a move constructor - m_GeneratedTexts.emplace_back(m_pGUI, Text, Font, Width, BufferZone, pObject); + m_GeneratedTexts.emplace_back(m_pGUI, Text, Font, Width, BufferZone, this); return m_GeneratedTexts.back(); }