mirror of
https://github.com/yse/easy_profiler.git
synced 2024-12-27 08:41:02 +08:00
(profiler gui) fix potencial zero pointer
This commit is contained in:
parent
7a87d681a1
commit
485c2a64ac
@ -1441,6 +1441,12 @@ void EasyGraphicsView::setScrollbar(EasyGraphicsScrollbar* _scrollbar)
|
|||||||
disconnect(m_pScrollbar, &EasyGraphicsScrollbar::valueChanged, this, &This::onGraphicsScrollbarValueChange);
|
disconnect(m_pScrollbar, &EasyGraphicsScrollbar::valueChanged, this, &This::onGraphicsScrollbarValueChange);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if(!_scrollbar)
|
||||||
|
{
|
||||||
|
qWarning() << "Zero pointer in EasyGraphicsView::setScrollbar(EasyGraphicsScrollbar*): " << __LINE__ << " in file " << __FILE__;
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
m_pScrollbar = _scrollbar;
|
m_pScrollbar = _scrollbar;
|
||||||
m_pScrollbar->setMinimapFrom(0, nullptr);
|
m_pScrollbar->setMinimapFrom(0, nullptr);
|
||||||
m_pScrollbar->hideChrono();
|
m_pScrollbar->hideChrono();
|
||||||
|
Loading…
x
Reference in New Issue
Block a user