jsdialog: use unified naming for treeview icons

unified header and no header treeviews
icon shouldn't contain old extension

Signed-off-by: Szymon Kłos <szymon.klos@collabora.com>
Change-Id: I0778d49395c084e4ac9adc848b3327529ee37e61
This commit is contained in:
Szymon Kłos 2023-01-03 08:36:55 +01:00 committed by Szymon Kłos
parent 7dcd8a12fc
commit 1aeeda61ac

View file

@ -207,7 +207,11 @@ function _headerlistboxEntry(parentContainer, treeViewData, entry, builder) {
if (entry.columns[i].collapsed || entry.columns[i].expanded) {
var iconId = entry.columns[i].collapsed ? entry.columns[i].collapsed : entry.columns[i].expanded;
iconId = iconId.replaceAll('/', '');
var newLength = iconId.lastIndexOf('.');
if (newLength > 0)
iconId = iconId.substr(0, newLength).replaceAll('/', '');
else
iconId = iconId.replaceAll('/', '');
var icon = L.DomUtil.create('img', 'ui-listview-icon', td);
icon.src = builder._createIconURL(iconId, true);
} else if (entry.columns[i].text)