1
0
mirror of https://github.com/wolfpld/tracy.git synced 2025-03-20 07:40:02 +08:00

Disable zoom anim on user interaction.

This commit is contained in:
Bartosz Taudul 2018-08-05 01:23:00 +02:00
parent 1b44b31eff
commit cbb45160af

View File

@ -857,6 +857,7 @@ void View::HandleZoneViewMouse( int64_t timespan, const ImVec2& wpos, float w, d
if( ImGui::IsMouseDragging( 1, 0 ) )
{
m_zoomAnim.active = false;
m_pause = true;
const auto delta = ImGui::GetMouseDragDelta( 1, 0 );
const auto dpx = int64_t( delta.x * nspx );
@ -877,6 +878,7 @@ void View::HandleZoneViewMouse( int64_t timespan, const ImVec2& wpos, float w, d
const auto wheel = io.MouseWheel;
if( wheel != 0 )
{
m_zoomAnim.active = false;
m_pause = true;
const double mouse = io.MousePos.x - wpos.x;
const auto p = mouse / w;