Merge pull request #1799 from matjaz321/checkbox-space-ff-issue
Hitting space to check/uncheck checkboxes doesn't work on firefox
(cherry picked from commit fea28f7277)
This commit is contained in:
committed by
Joshua M. Boniface
parent
15e9b645f2
commit
cac6b42dab
@@ -6,7 +6,7 @@ define(['browser', 'dom', 'css!./emby-checkbox', 'webcomponents'], function (bro
|
||||
function onKeyDown(e) {
|
||||
// Don't submit form on enter
|
||||
// Real (non-emulator) Tizen does nothing on Space
|
||||
if (e.keyCode === 13 || e.keyCode === 32) {
|
||||
if (e.keyCode === 13 || (e.keyCode === 32 && browser.tizen)) {
|
||||
e.preventDefault();
|
||||
|
||||
this.checked = !this.checked;
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
define(['layoutManager', 'css!./emby-radio', 'webcomponents'], function (layoutManager) {
|
||||
define(['browser', 'layoutManager', 'css!./emby-radio', 'webcomponents'], function (browser, layoutManager) {
|
||||
'use strict';
|
||||
|
||||
var EmbyRadioPrototype = Object.create(HTMLInputElement.prototype);
|
||||
@@ -7,7 +7,7 @@ define(['layoutManager', 'css!./emby-radio', 'webcomponents'], function (layoutM
|
||||
|
||||
// Don't submit form on enter
|
||||
// Real (non-emulator) Tizen does nothing on Space
|
||||
if (e.keyCode === 13 || e.keyCode === 32) {
|
||||
if (e.keyCode === 13 || (e.keyCode === 32 && browser.tizen)) {
|
||||
e.preventDefault();
|
||||
|
||||
if (!this.checked) {
|
||||
|
||||
Reference in New Issue
Block a user