]> sigrok.org Git - pulseview.git/blobdiff - pv/prop/string.cpp
Don't use deprecated headers.
[pulseview.git] / pv / prop / string.cpp
index b8ecf738630bdea67568e9781357211145215db8..a488e89a3b1fd5d7e30dd615e619ee248f8d908b 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 <cassert>
 
 #include <QLineEdit>
 #include <QSpinBox>
@@ -36,7 +35,7 @@ String::String(QString name,
        Getter getter,
        Setter setter) :
        Property(name, getter, setter),
-       line_edit_(NULL)
+       line_edit_(nullptr)
 {
 }
 
@@ -46,11 +45,11 @@ QWidget* String::get_widget(QWidget *parent, bool auto_commit)
                return line_edit_;
 
        if (!getter_)
-               return NULL;
+               return nullptr;
 
        Glib::VariantBase variant = getter_();
        if (!variant.gobj())
-               return NULL;
+               return nullptr;
 
        string value = Glib::VariantBase::cast_dynamic<Glib::Variant<ustring>>(
                variant).get();