ros-visualization / rviz

ROS 3D Robot Visualizer
BSD 3-Clause "New" or "Revised" License
831 stars 463 forks source link

Fix vanishing "Global Options" property when adding a RobotModelDisplay #1808

Closed rhaschke closed 11 months ago

rhaschke commented 11 months ago

With Qt 5.15, the Global Options property was vanishing, when a RobotModelDisplay was added with links having no geometry. In this case, the Alpha property of the corresponding link is hidden. However, hiding a property: https://github.com/ros-visualization/rviz/blob/4129ee477ecd47b9c941d90cdf5e3e4f26fad835/src/rviz/properties/property.cpp#L398

during the process of reparenting: https://github.com/ros-visualization/rviz/blob/4129ee477ecd47b9c941d90cdf5e3e4f26fad835/src/rviz/properties/property.cpp#L373

caused setRowHidden to be called with an invalid parentIndex: https://github.com/ros-visualization/rviz/blob/4129ee477ecd47b9c941d90cdf5e3e4f26fad835/src/rviz/properties/property_tree_widget.cpp#L125

which then caused hiding of the corresponding top-level property.