X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FModuleBase%2FModuleBase_WidgetBoolValue.h;h=121fae5ffd0fb1589a77d53f788c2f2bac0eb1e2;hb=b3025c793455da0df5d0fe83455a7f45c64e885e;hp=5325b4d995b257d960f811eaffe91dd87d7f4b18;hpb=5b24ea6ca4e9754fa89f7c742dce060abb2f3cda;p=modules%2Fshaper.git diff --git a/src/ModuleBase/ModuleBase_WidgetBoolValue.h b/src/ModuleBase/ModuleBase_WidgetBoolValue.h index 5325b4d99..121fae5ff 100644 --- a/src/ModuleBase/ModuleBase_WidgetBoolValue.h +++ b/src/ModuleBase/ModuleBase_WidgetBoolValue.h @@ -1,8 +1,22 @@ -// Copyright (C) 2014-20xx CEA/DEN, EDF R&D - -// File: ModuleBase_WidgetBoolValue.h -// Created: 04 June 2014 -// Author: Vitaly Smetannikov +// Copyright (C) 2014-2017 CEA/DEN, EDF R&D +// +// This library is free software; you can redistribute it and/or +// modify it under the terms of the GNU Lesser General Public +// License as published by the Free Software Foundation; either +// version 2.1 of the License, or (at your option) any later version. +// +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Lesser General Public License for more details. +// +// You should have received a copy of the GNU Lesser General Public +// License along with this library; if not, write to the Free Software +// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +// +// See http://www.salome-platform.org/ or +// email : webmaster.salome@opencascade.com +// #ifndef ModuleBase_WidgetBoolValue_H #define ModuleBase_WidgetBoolValue_H @@ -15,6 +29,7 @@ class QWidget; class QCheckBox; /** +* \ingroup GUI * Implementation of widget for boolean input (check box) */ class MODULEBASE_EXPORT ModuleBase_WidgetBoolValue : public ModuleBase_ModelWidget @@ -24,19 +39,22 @@ Q_OBJECT /// Constructor /// \param theParent the parent object /// \param theData the widget configuation. The attribute of the model widget is obtained from - /// \param theParentId is Id of a parent of the current attribute - ModuleBase_WidgetBoolValue(QWidget* theParent, const Config_WidgetAPI* theData, - const std::string& theParentId); + ModuleBase_WidgetBoolValue(QWidget* theParent, const Config_WidgetAPI* theData); virtual ~ModuleBase_WidgetBoolValue(); - virtual bool storeValue() const; - - virtual bool restoreValue(); + virtual bool canAcceptFocus() const { return false; }; virtual QList getControls() const; - QWidget* getControl() const; + virtual void setHighlighted(bool isHighlighted); + +protected: + /// Saves the internal parameters to the given feature + /// \return True in success + virtual bool storeValueCustom(); + + virtual bool restoreValueCustom(); private: /// The check box