From 166f2d37e968becb4deb6a6211ce63eb111685da Mon Sep 17 00:00:00 2001 From: Nick White Date: Fri, 24 Jun 2011 18:50:44 +0100 Subject: Nice little cleanups --- COPYING | 2 +- chromium/background.html | 1 - keybind.js | 8 +++----- simplyread.js | 6 +----- 4 files changed, 5 insertions(+), 12 deletions(-) diff --git a/COPYING b/COPYING index cf4e447..06c4579 100644 --- a/COPYING +++ b/COPYING @@ -1,4 +1,4 @@ -SimplyRead is Copyright 2010 Nick White. It is licensed under the +SimplyRead is Copyright 2010,2011 Nick White. It is licensed under the GNU Affero General Public License version 3, or any later version. GNU AFFERO GENERAL PUBLIC LICENSE diff --git a/chromium/background.html b/chromium/background.html index 7850bd2..ce0042e 100644 --- a/chromium/background.html +++ b/chromium/background.html @@ -4,7 +4,6 @@ sendResponse({}); }; - /* called on page load if viable */ chrome.extension.onRequest.addListener(onRequest); chrome.pageAction.onClicked.addListener(function(tab) { diff --git a/keybind.js b/keybind.js index ed5ae3a..c89b715 100644 --- a/keybind.js +++ b/keybind.js @@ -1,11 +1,9 @@ -/* - * See COPYING file for copyright, license and warranty details. - */ +/* See COPYING file for copyright, license and warranty details. */ + (function() { document.addEventListener('keydown', keybind, false); })(); function keybind(e) { - if (e.keyIdentifier == "U+0052" && e.ctrlKey && e.altKey) // ctrl-alt-r - simplyread(); + if(e.keyCode == 82 && e.ctrlKey && e.altKey) simplyread(); } diff --git a/simplyread.js b/simplyread.js index f7e3d3e..e7e9e27 100755 --- a/simplyread.js +++ b/simplyread.js @@ -1,8 +1,4 @@ -/* - * SimplyRead - Stop browsing, start reading - * - * See COPYING file for copyright, license and warranty details. - */ +/* See COPYING file for copyright, license and warranty details. */ if(window.content && window.content.document.simplyread_original === undefined) window.content.document.simplyread_original = false; -- cgit v1.2.3