diff --git a/src/webui/www/private/addtrackers.html b/src/webui/www/private/addtrackers.html
index 72f72282e..47901aa93 100644
--- a/src/webui/www/private/addtrackers.html
+++ b/src/webui/www/private/addtrackers.html
@@ -11,16 +11,23 @@
'use strict';
window.addEvent('domready', function() {
- var setLocationKeyboardEvents = new Keyboard({
+ new Keyboard({
defaultEventType: 'keydown',
events: {
- 'enter': function(event) {
+ 'Enter': function(event) {
$('addTrackersButton').click();
event.preventDefault();
+ },
+ 'Escape': function(event) {
+ window.parent.closeWindows();
+ event.preventDefault();
+ },
+ 'Esc': function(event) {
+ window.parent.closeWindows();
+ event.preventDefault();
}
}
- });
- setLocationKeyboardEvents.activate();
+ }).activate();
$('trackersUrls').focus();
$('addTrackersButton').addEvent('click', function(e) {
diff --git a/src/webui/www/private/downloadlimit.html b/src/webui/www/private/downloadlimit.html
index 5dc4066fd..aef12f5e2 100644
--- a/src/webui/www/private/downloadlimit.html
+++ b/src/webui/www/private/downloadlimit.html
@@ -55,10 +55,30 @@
}
}
-
+
diff --git a/src/webui/www/private/edittracker.html b/src/webui/www/private/edittracker.html
index 63b30e903..10f575a5c 100644
--- a/src/webui/www/private/edittracker.html
+++ b/src/webui/www/private/edittracker.html
@@ -11,16 +11,23 @@
'use strict';
window.addEvent('domready', function() {
- var setLocationKeyboardEvents = new Keyboard({
+ new Keyboard({
defaultEventType: 'keydown',
events: {
- 'enter': function(event) {
+ 'Enter': function(event) {
$('editTrackerButton').click();
event.preventDefault();
+ },
+ 'Escape': function(event) {
+ window.parent.closeWindows();
+ event.preventDefault();
+ },
+ 'Esc': function(event) {
+ window.parent.closeWindows();
+ event.preventDefault();
}
}
- });
- setLocationKeyboardEvents.activate();
+ }).activate();
var currentUrl = new URI().getData('url');
if (!currentUrl)
diff --git a/src/webui/www/private/installsearchplugin.html b/src/webui/www/private/installsearchplugin.html
index 7ea7b9d73..c2391bab3 100644
--- a/src/webui/www/private/installsearchplugin.html
+++ b/src/webui/www/private/installsearchplugin.html
@@ -30,10 +30,10 @@
'use strict';
var initInstallSearchPlugin = function() {
- var installSearchPluginKeyboardEvents = new Keyboard({
+ new Keyboard({
defaultEventType: 'keydown',
events: {
- 'enter': function(e) {
+ 'Enter': function(e) {
// accept enter key as a click
new Event(e).stop();
@@ -44,8 +44,7 @@
closeSearchWindow('installSearchPlugin');
}
}
- });
- installSearchPluginKeyboardEvents.activate();
+ }).activate();
$('newPluginPath').select();
};
diff --git a/src/webui/www/private/newcategory.html b/src/webui/www/private/newcategory.html
index 8fcb87a41..18e205c61 100644
--- a/src/webui/www/private/newcategory.html
+++ b/src/webui/www/private/newcategory.html
@@ -11,16 +11,23 @@
-
+