Skip to content

Commit

Permalink
remove topic_ns member and instead pass the parameter to the node_han…
Browse files Browse the repository at this point in the history
…dle constructor
  • Loading branch information
LeroyR committed Jan 19, 2022
1 parent 051af05 commit 010d393
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 6 deletions.
3 changes: 0 additions & 3 deletions include/interactive_markers/interactive_marker_server.h
Original file line number Diff line number Diff line change
Expand Up @@ -212,9 +212,6 @@ class InteractiveMarkerServer : boost::noncopyable

// updates that have to be sent on the next publish
M_UpdateContext pending_updates_;

// topic namespace to use
std::string topic_ns_;

mutable boost::recursive_mutex mutex_;

Expand Down
6 changes: 3 additions & 3 deletions src/interactive_marker_server.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ namespace interactive_markers
{

InteractiveMarkerServer::InteractiveMarkerServer( const std::string &topic_ns, const std::string &server_id, bool spin_thread ) :
topic_ns_(topic_ns),
node_handle_(topic_ns),
seq_num_(0)
{
if ( spin_thread )
Expand All @@ -58,9 +58,9 @@ InteractiveMarkerServer::InteractiveMarkerServer( const std::string &topic_ns, c
server_id_ = ros::this_node::getName();
}

std::string update_topic = topic_ns + "/update";
std::string update_topic = "update";
std::string init_topic = update_topic + "_full";
std::string feedback_topic = topic_ns + "/feedback";
std::string feedback_topic = "feedback";

init_pub_ = node_handle_.advertise<visualization_msgs::InteractiveMarkerInit>( init_topic, 100, true );
update_pub_ = node_handle_.advertise<visualization_msgs::InteractiveMarkerUpdate>( update_topic, 100 );
Expand Down

0 comments on commit 010d393

Please sign in to comment.