From: vsv Date: Fri, 10 Oct 2014 11:17:21 +0000 (+0400) Subject: Optimized access to boolean value X-Git-Tag: V_0.5~104 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=9d397846914c40af6ce803f4742bd6fa6b085e56;p=modules%2Fshaper.git Optimized access to boolean value --- diff --git a/src/ModuleBase/ModuleBase_WidgetShapeSelector.cpp b/src/ModuleBase/ModuleBase_WidgetShapeSelector.cpp index 0b433e663..f07c339ca 100644 --- a/src/ModuleBase/ModuleBase_WidgetShapeSelector.cpp +++ b/src/ModuleBase/ModuleBase_WidgetShapeSelector.cpp @@ -108,11 +108,7 @@ ModuleBase_WidgetShapeSelector::ModuleBase_WidgetShapeSelector(QWidget* theParen std::string aTypes = theData->getProperty("shape_types"); myShapeTypes = QString(aTypes.c_str()).split(' '); - std::string aUseSubShapes = theData->getProperty("use_subshapes"); - if (aUseSubShapes.length() > 0) { - QString aVal(aUseSubShapes.c_str()); - myUseSubShapes = (aVal.toUpper() == "TRUE"); - } + myUseSubShapes = theData->getBooleanAttribute("use_subshapes", false); } //********************************************************************