"using" directives are no longer used in global namespaces (#219)

This commit is contained in:
Tyler Veness
2016-11-01 23:09:51 -07:00
committed by Peter Johnson
parent 78f0b1562c
commit ba8761e39e
39 changed files with 292 additions and 256 deletions

View File

@@ -11,7 +11,7 @@
GZ_REGISTER_MODEL_PLUGIN(LimitSwitch)
void LimitSwitch::Load(physics::ModelPtr model, sdf::ElementPtr sdf) {
void LimitSwitch::Load(gazebo::physics::ModelPtr model, sdf::ElementPtr sdf) {
this->model = model;
// Parse SDF properties
@@ -36,18 +36,18 @@ void LimitSwitch::Load(physics::ModelPtr model, sdf::ElementPtr sdf) {
std::string scoped_name =
model->GetWorld()->GetName() + "::" + model->GetScopedName();
boost::replace_all(scoped_name, "::", "/");
node = transport::NodePtr(new transport::Node());
node = gazebo::transport::NodePtr(new gazebo::transport::Node());
node->Init(scoped_name);
pub = node->Advertise<msgs::Bool>(topic);
pub = node->Advertise<gazebo::msgs::Bool>(topic);
// Connect to the world update event.
// This will trigger the Update function every Gazebo iteration
updateConn = event::Events::ConnectWorldUpdateBegin(
updateConn = gazebo::event::Events::ConnectWorldUpdateBegin(
boost::bind(&LimitSwitch::Update, this, _1));
}
void LimitSwitch::Update(const common::UpdateInfo& info) {
msgs::Bool msg;
void LimitSwitch::Update(const gazebo::common::UpdateInfo& info) {
gazebo::msgs::Bool msg;
msg.set_data(ls->Get());
pub->Publish(msg);
}