]> git.eshelyaron.com Git - emacs.git/commitdiff
* calc/calc-units.el (math-midi-round): Translate calc-note-threshold
authorJay Belanger <jay.p.belanger@gmail.com>
Sun, 6 Mar 2011 04:36:15 +0000 (22:36 -0600)
committerJay Belanger <jay.p.belanger@gmail.com>
Sun, 6 Mar 2011 04:36:15 +0000 (22:36 -0600)
  to an appropriate fraction.

lisp/calc/calc-units.el

index f022f4f472b7efcc46ab04590a810d2f4f33b808..7f0adc9fe7ed0defcd5f50d49c321f2cb98a2d8c 100644 (file)
@@ -1869,7 +1869,8 @@ In symbolic mode, return the list (^ a b)."
   (let* ((n (math-round num))
          (diff (math-abs
                 (math-sub num n))))
-    (if (< (math-compare diff (math-read-expr calc-note-threshold)) 0)
+    (if (< (math-compare diff 
+                         (math-div (math-read-expr calc-note-threshold) 100)) 0)
         n
       num)))