From 84cedbb45e66bfe0a083997b29966500bb4e4e79 Mon Sep 17 00:00:00 2001 From: Michael Jett Date: Tue, 25 Sep 2012 13:24:38 -0400 Subject: [PATCH] Support the "Enter" key on list widget --- .../src/main/webapp/resources/js/admin.js | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/openid-connect-server/src/main/webapp/resources/js/admin.js b/openid-connect-server/src/main/webapp/resources/js/admin.js index de9e9bb49..7a90c3565 100644 --- a/openid-connect-server/src/main/webapp/resources/js/admin.js +++ b/openid-connect-server/src/main/webapp/resources/js/admin.js @@ -60,7 +60,14 @@ }), events:{ - "click button": "addItem" + "click button":"addItem", + "keypress input":function (e) { + if (e.which == 13) { + this.addItem(); + e.preventDefault(); + $("input", this.$el).focus(); + } + } }, initialize:function () {