Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/prusa3d/PrusaSlicer.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorYuSanka <yusanka@gmail.com>2018-11-01 16:16:03 +0300
committerYuSanka <yusanka@gmail.com>2018-11-01 18:24:20 +0300
commit7c673179f62645263da2f2ea165c6c7db326589f (patch)
tree473f3fe9d027f1e51b19d80a2551caf2b1ebab1b
parent259aed3bf362ef41a900a1ce4c18abd4b77b3604 (diff)
Temporary (for testing) crash fixing on get_label from PrusaDoubleSlider
-rw-r--r--src/slic3r/GUI/wxExtensions.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/slic3r/GUI/wxExtensions.cpp b/src/slic3r/GUI/wxExtensions.cpp
index 1ae0448f4..547975c37 100644
--- a/src/slic3r/GUI/wxExtensions.cpp
+++ b/src/slic3r/GUI/wxExtensions.cpp
@@ -1384,6 +1384,8 @@ wxString PrusaDoubleSlider::get_label(const SelectedSlider& selection) const
if (m_label_koef == 1.0 && m_values.empty())
return wxString::Format("%d", value);
+ if (value >= m_values.size())
+ return "ErrVal";
const wxString str = m_values.empty() ?
wxNumberFormatter::ToString(m_label_koef*value, 2, wxNumberFormatter::Style_None) :