]> sigrok.org Git - pulseview.git/blobdiff - pv/prop/enum.cpp
Build fixes for Qt5 Windows/mingw/MXE support.
[pulseview.git] / pv / prop / enum.cpp
index 473e3d5f1a3ad36582a3d5c770d4793f607b6124..a4c542af55fb9f05caaccd5043b0d7b098bbdaf2 100644 (file)
  * GNU General Public License for more details.
  *
  * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301 USA
+ * along with this program; if not, see <http://www.gnu.org/licenses/>.
  */
 
 #include <assert.h>
 
 #include <QComboBox>
 
-#include "enum.h"
+#include "enum.hpp"
 
 using std::pair;
 using std::vector;
@@ -35,11 +34,7 @@ Enum::Enum(QString name,
        Getter getter, Setter setter) :
        Property(name, getter, setter),
        values_(values),
-       selector_(NULL)
-{
-}
-
-Enum::~Enum()
+       selector_(nullptr)
 {
 }
 
@@ -49,11 +44,11 @@ QWidget* Enum::get_widget(QWidget *parent, bool auto_commit)
                return selector_;
 
        if (!getter_)
-               return NULL;
+               return nullptr;
 
        Glib::VariantBase variant = getter_();
        if (!variant.gobj())
-               return NULL;
+               return nullptr;
 
        selector_ = new QComboBox(parent);
        for (unsigned int i = 0; i < values_.size(); i++) {