From 9cc032816ebbc15b9739de32ad66bddc081c3458 Mon Sep 17 00:00:00 2001 From: Werner Almesberger Date: Fri, 1 Feb 2013 00:35:16 -0300 Subject: [PATCH] ubb-la/gui.c (pos_step): step one sample at maximum zoom This permits precise interval/frequency calculation with the user-defined reference. --- ubb-la/gui.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ubb-la/gui.c b/ubb-la/gui.c index abd4556..bb45ad8 100644 --- a/ubb-la/gui.c +++ b/ubb-la/gui.c @@ -466,7 +466,7 @@ static void show_divisions(void) static int pos_step(int zoom) { - return 1 << (MAX_ZOOM-zoom+1); + return zoom == MAX_ZOOM ? 1 : 1 << (MAX_ZOOM-zoom+1); }