[Refs #87: Static Analysis] Clarify timer member by explicit use

This commit is contained in:
baldurk
2014-10-05 16:35:39 +01:00
parent e749f42876
commit 8b0f05ca5e
2 changed files with 15 additions and 1 deletions
+12 -1
View File
@@ -41,7 +41,7 @@ namespace renderdocui.Code
{
m_Rate = msCount;
m_Update = up;
m_CameraTick = new System.Threading.Timer(TickCB, this as object, m_Rate, System.Threading.Timeout.Infinite);
Start();
}
private int m_Rate;
@@ -59,6 +59,17 @@ namespace renderdocui.Code
if (me.m_Update != null) me.m_Update();
if (me.m_CameraTick != null) me.m_CameraTick.Change(me.m_Rate, System.Threading.Timeout.Infinite);
}
public void Start()
{
m_CameraTick = new System.Threading.Timer(TickCB, this as object, m_Rate, System.Threading.Timeout.Infinite);
}
public void Stop()
{
m_CameraTick.Dispose();
m_CameraTick = null;
}
}
abstract class CameraControls
+3
View File
@@ -1859,6 +1859,9 @@ namespace renderdocui.Windows
{
m_Core.RemoveLogViewer(this);
m_Updater.Stop();
m_Updater = null;
m_ReqID++;
}