15 #ifndef NAV2_RVIZ_PLUGINS__SELECTOR_HPP_
16 #define NAV2_RVIZ_PLUGINS__SELECTOR_HPP_
20 #include <QGridLayout>
21 #include <QScrollArea>
22 #include <QToolButton>
25 #include "rclcpp/node.hpp"
26 #include "rclcpp/publisher.hpp"
27 #include "rviz_common/panel.hpp"
31 #include "std_msgs/msg/string.hpp"
35 namespace nav2_rviz_plugins
42 explicit Selector(QWidget * parent = 0);
48 rclcpp::Node::SharedPtr client_node_;
49 rclcpp::Publisher<std_msgs::msg::String>::SharedPtr pub_controller_;
50 rclcpp::Publisher<std_msgs::msg::String>::SharedPtr pub_planner_;
51 rclcpp::Publisher<std_msgs::msg::String>::SharedPtr pub_goal_checker_;
52 rclcpp::Publisher<std_msgs::msg::String>::SharedPtr pub_smoother_;
53 rclcpp::Publisher<std_msgs::msg::String>::SharedPtr pub_progress_checker_;
54 rclcpp::Publisher<std_msgs::msg::String>::SharedPtr pub_path_handler_;
56 bool plugins_loaded_ =
false;
57 bool server_failed_ =
false;
59 std::thread load_plugins_thread_;
61 QVBoxLayout * main_layout_;
62 QHBoxLayout * row_1_layout_;
63 QHBoxLayout * row_2_layout_;
64 QHBoxLayout * row_3_layout_;
65 QHBoxLayout * row_1_label_layout_;
66 QHBoxLayout * row_2_label_layout_;
67 QHBoxLayout * row_3_label_layout_;
68 QComboBox * controller_;
70 QComboBox * goal_checker_;
71 QComboBox * smoother_;
72 QComboBox * progress_checker_;
73 QComboBox * path_handler_;
77 void setGoalChecker();
79 void setProgressChecker();
80 void setPathHandler();
88 QComboBox * combo_box,
89 rclcpp::Publisher<std_msgs::msg::String>::SharedPtr publisher);
92 QVBoxLayout * layout1 =
new QVBoxLayout;