]> git.mxchange.org Git - flightgear.git/blobdiff - src/Cockpit/panel_io.cxx
Use !strcmp for all property string-value comparisons.
[flightgear.git] / src / Cockpit / panel_io.cxx
index f3b76d8e37cced9b38ee4ffd76fbc35da4f4964c..b81717430377f78988ba13e832d70cb0bbbd1cb3 100644 (file)
@@ -295,7 +295,7 @@ readTransformation (const SGPropertyNode * node, float w_scale, float h_scale)
     type = "rotation";
   }
 
-  if (propName != "") {
+  if (!propName.empty()) {
     target = fgGetNode(propName.c_str(), true);
   }
 
@@ -724,7 +724,7 @@ readPanel (const SGPropertyNode * root)
   // Get multibackground if any...
   //
   string mbgTexture = root->getStringValue("multibackground[0]");
-  if (mbgTexture != (string)"") {
+  if (!mbgTexture.empty()) {
     panel->setMultiBackground(FGTextureManager::createTexture(mbgTexture.c_str()), 0);
     SG_LOG( SG_COCKPIT, SG_INFO, "Set background texture to " << mbgTexture );