Issue 31083 — HTML5 controls : DSP widget loses focus after onChange trigger is fired
Status: Solved in 10.2.01
Solution available in patch(es): G101
Description:
Summary: HTML5 controls : DSP widget loses focus after onChange trigger is fired Environment: +Uniface: Uniface 9.7 +Operating System: OS independent +Database: DBMS independent +Additional: - When using HTML5 controls, - Browser specific behavior (details below) To reproduce: 1. A DSP widget on a DSP has proc code in the OnChange trigger. 2. Enter some data and tab from this field to the next field Result: the cursor disappears and no data can be entered in the next field. This problem happens: - Using HTML5 controls - Browsers: - In all browsers when using trigger OnChange - In Internet Explorer using webtrigger OnChange - Using webtrigger OnChange in Chrome or Firefox this problem does not occur. Additionally, when radiogroup item A has focus and a user uses the arrow keys to move focus to radiogroup item B, the focus is lost. An example: An entity with 3 fields are painted on a DSP. In the Onchange trigger for field F1: trigger OnChange public web f3.e1=f1.e1 end In the OnChange trigger F2 for field F2 webtrigger onChange javascript var Occ = uniface.getInstance().getEntity("E1.TEST").getOccurrence(0); Occ.getField("F3").setValue(Occ.getField("F2").getValue()); endjavascript end Click in field F1 or in field F2, type something and tab to the next field. Result is there is no cursor and no value can be entered. In fact bug 28916 (Problems after using TAB key in a field on a DSP when OnChange trigger is used) and bug 29555 (Field on DSP cannot be reached with TAB key) reappear when using HTML5 controls.
Workaround:
There is no known workaround for this problem.
Notes:
When a trigger or operation is called, fields that are in scope are not disabled any more, since this would prevent them from receiving focus; instead, they are set to read-only for the duration of the request. Additionally, elements are not destroyed and re-created if no changes were made to a field's valrep, since this would effectively remove focus from the elements that were destroyed.