From 77ea6d92cbfadc1a1c90cee5064dc78501c4d031 Mon Sep 17 00:00:00 2001 From: Lawrence Lee <45837045+Lawrence37@users.noreply.github.com> Date: Sun, 9 May 2021 12:31:26 -0700 Subject: [PATCH] Pin inspector whenever scrolling or zooming --- rtgui/inspector.cc | 3 +++ 1 file changed, 3 insertions(+) diff --git a/rtgui/inspector.cc b/rtgui/inspector.cc index 0453564f9..675da51c6 100644 --- a/rtgui/inspector.cc +++ b/rtgui/inspector.cc @@ -277,6 +277,8 @@ bool Inspector::on_scroll_event(GdkEventScroll *event) if (!currImage || !window) return false; + pinned = true; + bool alt = event->state & GDK_MOD1_MASK; int deviceScale = get_scale_factor(); int imW = currImage->imgBuffer.getWidth(); @@ -381,6 +383,7 @@ void Inspector::beginZoom(double x, double y) void Inspector::on_zoom_begin(GdkEventSequence *s) { double x, y; + pinned = true; if (gestureZoom->get_point(s, x, y)) beginZoom(x, y); }