Commits

Nathan Koenig  committed c5c2a7d

Remove the requirement that worlds be named default

  • Participants
  • Parent commits 2ed06f7
  • Branches remove_default_constraint

Comments (0)

Files changed (5)

File gazebo/Server.cc

 /////////////////////////////////////////////////
 bool Server::OpenWorld(const std::string &_filename)
 {
+  return false;
+  /*
   sdf::SDFPtr sdf(new sdf::SDF);
   if (!sdf::init(sdf))
   {
   worldMsg.set_create(true);
   this->worldModPub->Publish(worldMsg);
   return true;
+  */
 }

File gazebo/gui/JointControlWidget.cc

  * limitations under the License.
  *
  */
+#include "gazebo/gui/Gui.hh"
 #include "gazebo/transport/Node.hh"
 #include "gazebo/transport/Transport.hh"
 #include "gazebo/gui/JointControlWidget.hh"
     this->jointPub = this->node->Advertise<msgs::JointCmd>(
         std::string("~/") + _modelName + "/joint_cmd");
 
-    boost::shared_ptr<msgs::Response> response = transport::request("default",
-        "entity_info", _modelName);
+    boost::shared_ptr<msgs::Response> response =
+      transport::request(gui::get_world(), "entity_info", _modelName);
 
     if (response->response() != "error" &&
         response->type() == modelMsg.GetTypeName())

File gazebo/gui/MainWindow.cc

 void MainWindow::ShowGrid()
 {
   msgs::Scene msg;
-  msg.set_name("default");
+  msg.set_name(gui::get_world());
   msg.set_grid(g_showGridAct->isChecked());
   this->scenePub->Publish(msg);
 }

File gazebo/physics/Road.cc

 void Road::Load(sdf::ElementPtr _elem)
 {
   this->node = transport::NodePtr(new transport::Node());
-  this->node->Init("default");
+  this->node->Init();
 
   this->roadPub = this->node->Advertise<msgs::Road>("~/roads", 10);
 

File gazebo/rendering/Road2d.cc

 Road2d::Road2d()
 {
   this->node = transport::NodePtr(new transport::Node());
-  this->node->Init("default");
+  this->node->Init();
   this->sub = this->node->Subscribe("~/roads", &Road2d::OnRoadMsg, this, true);
 
   this->connections.push_back(