From 507620e12da137479ad325f52adeca700dc2c120 Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Wed, 25 Jan 2012 13:49:15 +0530 Subject: [PATCH] ... --- src/calibre/ebooks/oeb/display/cfi.coffee | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/calibre/ebooks/oeb/display/cfi.coffee b/src/calibre/ebooks/oeb/display/cfi.coffee index 6436191da3..efb68a37c0 100644 --- a/src/calibre/ebooks/oeb/display/cfi.coffee +++ b/src/calibre/ebooks/oeb/display/cfi.coffee @@ -322,7 +322,7 @@ class CanonicalFragmentIdentifier point.time = r[1] - 0 # Coerce to number cfi = cfi.substr(r[0].length) - if (r = cfi.match(/^@(-?\d+(\.\d+)?),(-?\d+(\.\d+)?)/)) != null + if (r = cfi.match(/^@(-?\d+(\.\d+)?):(-?\d+(\.\d+)?)/)) != null # Spatial offset point.x = r[1] - 0 # Coerce to number point.y = r[3] - 0 # Coerce to number @@ -416,7 +416,7 @@ class CanonicalFragmentIdentifier rect = target.getBoundingClientRect() px = ((x - rect.left)*100)/target.offsetWidth py = ((y - rect.top)*100)/target.offsetHeight - tail = "#{ tail }@#{ fstr px },#{ fstr py }" + tail = "#{ tail }@#{ fstr px }:#{ fstr py }" else if name != 'audio' # Get the text offset # We use a custom function instead of caretRangeFromPoint as