uitest: add info whether a tree list box contains check boxes

Change-Id: Id214928de2e74ac7ec707eaf2276e4e808b630a4
Reviewed-on: https://gerrit.libreoffice.org/35697
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Markus Mohrhard <markus.mohrhard@googlemail.com>
This commit is contained in:
Markus Mohrhard
2017-03-26 00:21:04 +01:00
parent 3c979a362b
commit 3df98c595f

View File

@@ -18,6 +18,15 @@ TreeListUIObject::TreeListUIObject(VclPtr<SvTreeListBox> xTreeList):
{
}
namespace {
bool isCheckBoxList(VclPtr<SvTreeListBox> xTreeList)
{
return (xTreeList->GetTreeFlags() & SvTreeFlags::CHKBTN) == SvTreeFlags::CHKBTN;
}
}
StringMap TreeListUIObject::get_state()
{
StringMap aMap = WindowUIObject::get_state();
@@ -26,6 +35,7 @@ StringMap TreeListUIObject::get_state()
aMap["VisibleCount"] = OUString::number(mxTreeList->GetVisibleCount());
aMap["Children"] = OUString::number(mxTreeList->GetChildCount(nullptr));
aMap["LevelChildren"] = OUString::number(mxTreeList->GetLevelChildCount(nullptr));
aMap["CheckBoxList"] = OUString::boolean(isCheckBoxList(mxTreeList));
return aMap;
}