mirror of
https://gitea.wildfiregames.com/0ad/0ad.git
synced 2026-06-27 18:08:20 +00:00
Draws scrollbar above list to have a correct order for Z sorting after a6cb77a204.
Reported By: nwtour Tested By: nwtour Differential Revision: https://code.wildfiregames.com/D3881 This was SVN commit r25303.
This commit is contained in:
@@ -476,11 +476,11 @@ void CDropDown::Draw()
|
||||
DrawText(m_Selected, m_Enabled ? m_TextColorSelected : m_TextColorDisabled, pos, bz + 0.1f, cliparea);
|
||||
}
|
||||
|
||||
// Disable scrollbar during drawing without sending a setting-changed message
|
||||
bool old = m_ScrollBar;
|
||||
|
||||
if (m_Open)
|
||||
{
|
||||
// Disable scrollbar during drawing without sending a setting-changed message
|
||||
const bool old = m_ScrollBar;
|
||||
|
||||
// TODO: drawScrollbar as an argument of DrawList?
|
||||
if (m_HideScrollBar)
|
||||
m_ScrollBar = false;
|
||||
|
||||
@@ -330,10 +330,6 @@ void CList::DrawList(const int& selected, const CGUISpriteInstance& sprite, cons
|
||||
{
|
||||
float bz = GetBufferedZ();
|
||||
|
||||
// First call draw on ScrollBarOwner
|
||||
if (m_ScrollBar)
|
||||
IGUIScrollBarOwner::Draw();
|
||||
|
||||
{
|
||||
CRect rect = GetListRect();
|
||||
|
||||
@@ -396,6 +392,9 @@ void CList::DrawList(const int& selected, const CGUISpriteInstance& sprite, cons
|
||||
DrawText(i, textcolor, rect.TopLeft() - CVector2D(0.f, scroll - m_ItemsYPositions[i]), bz + 0.1f, cliparea);
|
||||
}
|
||||
}
|
||||
|
||||
if (m_ScrollBar)
|
||||
IGUIScrollBarOwner::Draw();
|
||||
}
|
||||
|
||||
void CList::AddItem(const CGUIString& str, const CGUIString& data)
|
||||
|
||||
Reference in New Issue
Block a user