CHUI 10.1C04 - accelerators/keyboard shortcuts unexpected behaviour

trx

Member
Hello,

OE 10.1C04 CHUI, I have encountered unexpected behaviour while working with accelerators/keyboard shortcuts.
I have attached simple test case to demonstrate it. Both attached files should be placed in /tmp, then in 4GL editor just run /tmp/accel_a.w.
There is window with menu in accel_a.w and simple dialog in accel_b.w, accel_a.w calls accel_b.w. Specific sequence of commands causes hiding frame in accel_b.w without returning control to accel_a.w.

1) in accel_a.w press "a" (that will apply "CHOOSE" to menu-item m_NextWin and run accel_b.w)
2) in accel_b press Tab to select Go button (AUTO-GO)
3) in accel_b press ESC-G (accelerate Go button)
4) in accel_b press Enter/F4 after message is displayed - there is RETURN NO-APPLY which should interrupt GO event and return focus to Go button; instead of that it hides Dialog-Frame in accel_b.w
5) frame Dialog-Frame in accel_b is now hidden, but control remains in accel_b - pressing F4 will hide frame in accel_a.w then display message from disable_ui in accel_b.w

Now, if instead of pressing "a" I choose menu by F3->Main menu->Next window or by its accelerator "W" everything works OK. Also if I skip step 2 also everything works OK (executing steps 1,3,4 then 2,3,4 works OK). Also if I do APPLY "ENTRY" TO EDITOR-1 IN FRAME {&FRAME-NAME}. in accel_b.w after enable_ui everything works OK.

Is anyone able to reproduce it in newer versions of OE?

Also one more unexpected behaviour: pressing CTRL+G on read only EDITOR modifies its contents.
Code:
DEF VAR EDITOR-1 AS CHAR INIT "Press CTRL+G"
    VIEW-AS EDITOR SIZE 40 BY 5.
DEF FRAME fra
    EDITOR-1 AT ROW 1 COL 1.
DISP EDITOR-1 WITH FRAME fra.
EDITOR-1:READ-ONLY = TRUE.
ENABLE EDITOR-1 WITH FRAME fra.
WAIT-FOR CLOSE OF THIS-PROCEDURE.
 

Attachments

  • accel_a.w
    2.1 KB · Views: 3
  • accel_b.w
    1.3 KB · Views: 2
Top