in weblib.php convert_tree_to_html()
The li CSS class is not set properly when $tab->linkedwhenselected is set. When set the CSS classes should be set based on the status of inactive, active, seleted, regardless of the linkedwhenselected setting.
attached is a diff to resolve.