Fix null pointer warnings.

This commit is contained in:
Richard Kimberly Heck 2020-02-27 00:05:41 -05:00
parent 79bcf68018
commit f4d5122a10

View File

@ -118,7 +118,7 @@ Inset * TocWidget::itemInset() const
gui_view_.tocModels().currentItem(current_type_, index);
DocIterator const & dit = item.dit();
Inset * inset = 0;
Inset * inset = nullptr;
if (current_type_ == "label"
|| current_type_ == "graphics"
|| current_type_ == "citation"
@ -408,7 +408,7 @@ void TocWidget::enableControls(bool enable)
void TocWidget::updateView()
{
if (!gui_view_.documentBufferView()) {
tocTV->setModel(0);
tocTV->setModel(nullptr);
depthSL->setMaximum(0);
depthSL->setValue(0);
setEnabled(false);