]> OCCT Git - occt-copy.git/commitdiff
0032068: Inspectors - Last command don't have the time value CR0_DMUReviewer_IR-2019-08-30
authorsshutina <sshutina@opencascade.com>
Tue, 19 Jan 2021 16:18:08 +0000 (19:18 +0300)
committersshutina <sshutina@opencascade.com>
Tue, 19 Jan 2021 16:18:08 +0000 (19:18 +0300)
src/Message/Message_Report.cxx

index 9edb2c6a4d99277898020aba1b3d6698351bb4ff..15cbe29442795656146fd1ba68daade7d4816007 100644 (file)
@@ -227,10 +227,9 @@ void Message_Report::RemoveLevel (Message_Level* theLevel)
   for (int aLevelIndex = myAlertLevels.Size(); aLevelIndex >= 1; aLevelIndex--)
   {
     Message_Level* aLevel = myAlertLevels.Value (aLevelIndex);
-    if (myAlertLevels.Size() == 1) // the last level, the root item should be stopped
-    {
-      Message_AttributeMeter::StopAlert (aLevel->RootAlert());
-    }
+    // The last level, the root item should be stopped always
+    // as AddLevel necessarily creates the root label.
+    Message_AttributeMeter::StopAlert (aLevel->RootAlert());
 
     myAlertLevels.Remove (aLevelIndex);
     if (aLevel == theLevel)