forked from mirrors/0ad
Fix Lobby/MP Gamesetup chat lag with many messages.
CText requires re-rendering every message when adding a new one, which quickly becomes very slow. Use CList and a custom method to work around this. These classes are in need of a more complete refactoring. Based on a patch by: nani Differential Revision: https://code.wildfiregames.com/D1781 This was SVN commit r24306.
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
/* Copyright (C) 2019 Wildfire Games.
|
||||
/* Copyright (C) 2020 Wildfire Games.
|
||||
* This file is part of 0 A.D.
|
||||
*
|
||||
* 0 A.D. is free software: you can redistribute it and/or modify
|
||||
@@ -38,6 +38,7 @@ void CGUI::AddObjectTypes()
|
||||
{
|
||||
m_ProxyData.insert(JSI_GUIProxy<IGUIObject>::CreateData(*m_ScriptInterface));
|
||||
m_ProxyData.insert(JSI_GUIProxy<CText>::CreateData(*m_ScriptInterface));
|
||||
m_ProxyData.insert(JSI_GUIProxy<CList>::CreateData(*m_ScriptInterface));
|
||||
|
||||
AddObjectType("button", &CButton::ConstructObject);
|
||||
AddObjectType("chart", &CChart::ConstructObject);
|
||||
|
||||
Reference in New Issue
Block a user