issue when open iframe inner iframe

44 views
Skip to first unread message

hossein akhoondi

unread,
Feb 4, 2025, 4:30:58 AMFeb 4
to noVNC
Hi, I opened an iframe in another iframe . I know this is not logical, but it was for testing and personal experience. While working with the second iframe, I noticed a problem with the keyboard. Some of the keyboard keys do not work in the child iframe. For this reason, I took the console log. Some keys, such as backspace, are entered in the parent iframe, but not in the child iframe. Some keys, such as the = key, have a different scancode entered in the parent iframe than the scancode in the child iframe.
whats the reason?

I insert this key in second iframe and in continue send log:
backspace ,= , g

parent iframe:
Sending key (down): keysym 65288, scancode 14
rfb.js:480 Sending key (up): keysym 65288, scancode 14
rfb.js:480 Sending key (down): keysym 61, scancode 13
rfb.js:480 Sending key (up): keysym 61, scancode 13
rfb.js:480 Sending key (down): keysym 103, scancode 34
rfb.js:480 Sending key (up): keysym 103, scancode 34

child iframe:
Sending key (down): keysym 65469, scancode 89
rfb.js:480 Sending key (up): keysym 65469, scancode 89
rfb.js:480 Sending key (down): keysym 103, scancode 34
rfb.js:480 Sending key (up): keysym 103, scancode 34

hossein akhoondi

unread,
Feb 4, 2025, 4:51:49 AMFeb 4
to noVNC
I forgot to say I use 1.3 version of novnc

Pierre Ossman

unread,
Feb 7, 2025, 8:43:14 AMFeb 7
to no...@googlegroups.com, hossein akhoondi
On 04/02/2025 10:30, hossein akhoondi wrote:
> Hi, I opened an iframe in another iframe . I know this is not logical, but
> it was for testing and personal experience. While working with the second
> iframe, I noticed a problem with the keyboard. Some of the keyboard keys do
> not work in the child iframe. For this reason, I took the console log. Some
> keys, such as backspace, are entered in the parent iframe, but not in the
> child iframe. Some keys, such as the = key, have a different scancode
> entered in the parent iframe than the scancode in the child iframe.
> whats the reason?
>

This could be a browser bug or limitation. They tend to restrict iframes
a lot.

Could you test putting this web page in a similar nested setup and see
how it reports events:

https://dvcs.w3.org/hg/d4e/raw-file/tip/key-event-test.html

Regards,
--
Pierre Ossman Software Development
Cendio AB https://cendio.com
Teknikringen 8 https://twitter.com/ThinLinc
583 30 Linköping https://facebook.com/ThinLinc
Phone: +46-13-214600

A: Because it messes up the order in which people normally read text.
Q: Why is top-posting such a bad thing?

hossein akhoondi

unread,
Feb 8, 2025, 6:44:25 AMFeb 8
to noVNC

Using the tool you introduced, I figured out the reason. I was using a fork of TigerVNC that had mapped the digital keys to the numpad (I don't know why). When I used the original version of TigerVNC, the problem was solved.

I have another question:
 Is there a way for the server to know from the NoVNC client that the client's language has changed? I checked the issues before, but I didn't find anything

Pierre Ossman

unread,
Feb 8, 2025, 7:02:38 AMFeb 8
to no...@googlegroups.com, hossein akhoondi
On 2/8/25 12:44, hossein akhoondi wrote:
>
>
> Using the tool you introduced, I figured out the reason. I was using a fork
> of TigerVNC that had mapped the digital keys to the numpad (I don't know
> why). When I used the original version of TigerVNC, the problem was solved.
>
> I have another question:
> Is there a way for the server to know from the NoVNC client that the
> client's language has changed? I checked the issues before, but I didn't
> find anything

No, I'm afraid the VNC protocol does not transfer any such information.
Reply all
Reply to author
Forward
0 new messages