Skip to content

Commit 9be9fab

Browse files
authored
Fix preferred tools loading names (#1321)
1 parent ad4813f commit 9be9fab

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

rviz_common/src/rviz_common/tool_manager.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -79,17 +79,17 @@ void ToolManager::initialize()
7979
// get a list of available tool plugin class ids
8080
auto plugins = factory_->getDeclaredPlugins();
8181
// define a list of preferred tool names (they will be listed first in the toolbar)
82-
std::vector<const char *> preferred_tool_names = {
82+
std::vector<const char *> preferred_tool_class_ids = {
8383
"rviz_default_plugins/MoveCamera",
8484
"rviz_default_plugins/Interact",
8585
"rviz_default_plugins/Select",
8686
"rviz_default_plugins/SetInitialPose",
8787
"rviz_default_plugins/SetGoal",
8888
};
8989
// attempt to load each preferred tool in order
90-
for (const auto & preferred_tool_name : preferred_tool_names) {
90+
for (const auto & preferred_tool_class_id : preferred_tool_class_ids) {
9191
for (const auto & plugin : plugins) {
92-
if (plugin.name.toStdString() == preferred_tool_name) {
92+
if (plugin.id.toStdString() == preferred_tool_class_id) {
9393
addTool(plugin);
9494
}
9595
}

0 commit comments

Comments
 (0)