X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FModuleBase%2FModuleBase_WidgetBoolValue.cpp;h=854a93a4801bf4c1ce7c5b0add5bacbf8b01f078;hb=1a0d48211014d96db9125fe973eacbae895c4490;hp=f1d5f2ba08a1443c15d63d9da31ea051d9bfaae9;hpb=3c0b551f57002a6e5195ef959f8056aa9df72baf;p=modules%2Fshaper.git diff --git a/src/ModuleBase/ModuleBase_WidgetBoolValue.cpp b/src/ModuleBase/ModuleBase_WidgetBoolValue.cpp index f1d5f2ba0..854a93a48 100644 --- a/src/ModuleBase/ModuleBase_WidgetBoolValue.cpp +++ b/src/ModuleBase/ModuleBase_WidgetBoolValue.cpp @@ -1,10 +1,11 @@ // Copyright (C) 2014-20xx CEA/DEN, EDF R&D -// File: ModuleBase_Widgets.h +// File: ModuleBase_WidgetBoolValue.cpp // Created: 04 June 2014 // Author: Vitaly Smetannikov #include +#include #include #include @@ -28,10 +29,15 @@ ModuleBase_WidgetBoolValue::ModuleBase_WidgetBoolValue(QWidget* theParent, QString aToolTip = QString::fromStdString(theData->widgetTooltip()); bool isChecked = theData->getBooleanAttribute(ATTR_DEFAULT, false); - myCheckBox = new QCheckBox(aText, theParent); + myCheckBox = new QCheckBox(aText, this); myCheckBox->setToolTip(aToolTip); myCheckBox->setChecked(isChecked); + QVBoxLayout* aMainLayout = new QVBoxLayout(this); + ModuleBase_Tools::adjustMargins(aMainLayout); + aMainLayout->addWidget(myCheckBox); + setLayout(aMainLayout); + connect(myCheckBox, SIGNAL(toggled(bool)), this, SIGNAL(valuesChanged())); } @@ -66,3 +72,8 @@ QList ModuleBase_WidgetBoolValue::getControls() const aList.append(myCheckBox); return aList; } + +void ModuleBase_WidgetBoolValue::setHighlighted(bool) +{ + return; +}