Opened 3 years ago

Closed 3 years ago

#18893 closed defect (wontfix)

deprecated KeyboardEvent methods (Chrome)

Reported by: awallat Owned by:
Priority: undecided Milestone: tbd
Component: Dijit Version: 1.11.2
Keywords: Cc:
Blocked By: Blocking:

Description

In Chrome I get one of these warnings, when using a ValidationTextBox?:

'KeyboardEvent.keyIdentifier' is deprecated and will be removed in M53, around September 2016. See https://www.chromestatus.com/features/5316065118650368 for more details.

I'm afraid that my code won't work soon in Chrome, when they remove this feature.

This is related to #17824.

Change History (1)

comment:1 Changed 3 years ago by bill

Component: GeneralDijit
Resolution: wontfix
Status: newclosed

OK, don't be afraid. Once keyIdentifier is removed, that warning will go away, and the code will still work.

It's from this code in _TextBoxMixin.js, which copies over all the properties in the event object... well actually it tries to avoid copying properties that will cause warnings like above, but (although it skips keyLocation) it doesn't skip keyIdentifier:

if(!/^(layer[XY]|returnValue|keyLocation)$/.test(attr)){ // prevent WebKit warnings
	var v = e[attr];
	if(typeof v != "function" && typeof v != "undefined"){
		faux[attr] = v;
	}
} 

But I don't think it's worth suppressing that warning since it will go away next month anyway.

Note: See TracTickets for help on using tickets.