Fixed memory leaks
--HG-- branch : develop
This commit is contained in:
parent
17d2df653d
commit
6bba2e435b
|
@ -1184,6 +1184,22 @@ void MainWindow::SyncMeasurements()
|
||||||
void MainWindow::ToolBarOption()
|
void MainWindow::ToolBarOption()
|
||||||
{
|
{
|
||||||
ui->toolBarOption->clear();
|
ui->toolBarOption->clear();
|
||||||
|
if (mouseCoordinate != nullptr)
|
||||||
|
{
|
||||||
|
delete mouseCoordinate;
|
||||||
|
mouseCoordinate = nullptr;
|
||||||
|
}
|
||||||
|
if (gradationHeights != nullptr)
|
||||||
|
{
|
||||||
|
delete gradationHeights;
|
||||||
|
gradationHeights = nullptr;
|
||||||
|
}
|
||||||
|
if (gradationSizes != nullptr)
|
||||||
|
{
|
||||||
|
delete gradationSizes;
|
||||||
|
gradationSizes = nullptr;
|
||||||
|
}
|
||||||
|
|
||||||
if (qApp->patternType() == MeasurementsType::Standard)
|
if (qApp->patternType() == MeasurementsType::Standard)
|
||||||
{
|
{
|
||||||
const QStringList listHeights = VMeasurement::ListHeights(doc->GetGradationHeights(), qApp->patternUnit());
|
const QStringList listHeights = VMeasurement::ListHeights(doc->GetGradationHeights(), qApp->patternUnit());
|
||||||
|
|
Loading…
Reference in New Issue
Block a user