diff options
Diffstat (limited to 'indra/llui/llscrolllistctrl.cpp')
-rw-r--r-- | indra/llui/llscrolllistctrl.cpp | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/indra/llui/llscrolllistctrl.cpp b/indra/llui/llscrolllistctrl.cpp index 98dddfb542..f442855aca 100644 --- a/indra/llui/llscrolllistctrl.cpp +++ b/indra/llui/llscrolllistctrl.cpp @@ -136,6 +136,19 @@ BOOL LLScrollListCheck::handleClick() } // +// LLScrollListSeparator +// +LLScrollListSeparator::LLScrollListSeparator(S32 width) : mWidth(width) +{ +} + +void LLScrollListSeparator::drawToWidth(S32 width, const LLColor4& color, const LLColor4& highlight_color) const +{ + //*FIXME: use dynamic item heights and make separators narrow, and inactive + gl_line_2d(5, 8, llmax(5, width - 5), 8, color); +} + +// // LLScrollListText // U32 LLScrollListText::sCount = 0; @@ -2750,6 +2763,10 @@ LLScrollListItem* LLScrollListCtrl::addElement(const LLSD& value, EAddPosition p LLRect(0, 0, width, width), "label"); new_item->setColumn(index, new LLScrollListCheck(ctrl,width)); } + else if (type == "separator") + { + new_item->setColumn(index, new LLScrollListSeparator(width)); + } else { new_item->setColumn(index, new LLScrollListText(value.asString(), font, width, font_style, font_alignment)); |