Change trace point value precision to be dynamic based on graph scale (#1148)

* Dynamic precision

* add comments

* feedback

* Update src/Calculator/Views/GraphingCalculator/GraphingCalculator.xaml.cpp

Co-Authored-By: Rudy Huyn <rudyhuyn@gmail.com>

* PR feedback

* Pr comment

Co-authored-by: Rudy Huyn <rudyhuyn@gmail.com>
This commit is contained in:
Pepe Rivera
2020-04-21 17:44:08 -07:00
committed by GitHub
parent 1ded2c57db
commit 0465dc8538
4 changed files with 39 additions and 3 deletions

View File

@@ -232,10 +232,11 @@ public enum class GraphViewChangedReason
{
try
{
if (m_graph != nullptr)
if (m_graph != nullptr && m_renderMain != nullptr)
{
if (auto render = m_graph->GetRenderer())
{
Concurrency::critical_section::scoped_lock lock(m_renderMain->GetCriticalSection());
render->GetDisplayRanges(*xMin, *xMax, *yMin, *yMax);
}
}