From 32b00774da771892ee8dcfb748ca3f78ed39cba1 Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Tue, 3 Nov 2015 20:59:42 +0530 Subject: [PATCH] E-book viewer: Set the foreground color as well as the background color for the reference mode popup. Makes it legibile even when the user specifies a different color theme for the viewer. --- resources/viewer/referencing.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/resources/viewer/referencing.js b/resources/viewer/referencing.js index 7c2a9d0a3f..fd921d8e8e 100644 --- a/resources/viewer/referencing.js +++ b/resources/viewer/referencing.js @@ -11,7 +11,7 @@ var reference_last_highlighted_para = null; function show_reference_panel(ref) { panel = $("#calibre_reference_panel"); if (panel.length < 1) { - $(document.body).append('
Paragraph

None

') + $(document.body).append('
Paragraph

None

'); panel = $("#calibre_reference_panel"); } $("> p", panel).text(ref); @@ -47,7 +47,7 @@ function leave_reference_mode() { $("p").unbind("mouseenter mouseleave", toggle_reference); panel = $("#calibre_reference_panel"); if (panel.length > 0) panel.hide(); - if (reference_last_highlighted_para != null) + if (reference_last_highlighted_para !== null) reference_last_highlighted_para.css({backgroundColor:reference_old_bgcol}); } @@ -66,7 +66,7 @@ function goto_reference(ref) { window.paged_display.scroll_to_xpos(xpos, true, true, 1000); } else $.scrollTo(dest, 1000, - {onAfter:function(){window.py_bridge.animated_scroll_done()}}); + {onAfter:function(){window.py_bridge.animated_scroll_done();}}); }