Add reset button to min bin value fields.

This commit is contained in:
Bartosz Taudul 2019-06-17 01:12:24 +02:00
parent add5c0fb87
commit eed849c589

View File

@ -6264,6 +6264,8 @@ void View::DrawFindZone()
ImGui::SetNextItemWidth( ImGui::CalcTextSize( "123456890123456" ).x ); ImGui::SetNextItemWidth( ImGui::CalcTextSize( "123456890123456" ).x );
ImGui::InputInt( "##minBinVal", &m_findZone.minBinVal ); ImGui::InputInt( "##minBinVal", &m_findZone.minBinVal );
if( m_findZone.minBinVal < 1 ) m_findZone.minBinVal = 1; if( m_findZone.minBinVal < 1 ) m_findZone.minBinVal = 1;
ImGui::SameLine();
if( ImGui::Button( "Reset" ) ) m_findZone.minBinVal = 1;
const auto cumulateTime = m_findZone.cumulateTime; const auto cumulateTime = m_findZone.cumulateTime;
@ -8631,6 +8633,8 @@ void View::DrawInfo()
ImGui::SetNextItemWidth( ImGui::CalcTextSize( "123456890123456" ).x ); ImGui::SetNextItemWidth( ImGui::CalcTextSize( "123456890123456" ).x );
ImGui::InputInt( "##minBinVal", &m_frameSortData.minBinVal ); ImGui::InputInt( "##minBinVal", &m_frameSortData.minBinVal );
if( m_frameSortData.minBinVal < 1 ) m_frameSortData.minBinVal = 1; if( m_frameSortData.minBinVal < 1 ) m_frameSortData.minBinVal = 1;
ImGui::SameLine();
if( ImGui::Button( "Reset" ) ) m_frameSortData.minBinVal = 1;
TextDisabledUnformatted( "Time range:" ); TextDisabledUnformatted( "Time range:" );
ImGui::SameLine(); ImGui::SameLine();