HTML select boxes not working

81 views
Skip to first unread message

bren...@gmail.com

unread,
Jun 15, 2017, 4:14:45 AM6/15/17
to CEF Python
In web pages displayed by PythonCEF, HTML <SELECT> boxes do not work. This even happens with the hello_world.py example, if I change the starting URL to something like https://developer.mozilla.org/en-US/docs/Web/HTML/Element/select . If I scroll down to the example select, clicking on it has no effect. Nothing drops down. (I'm doing this on Windows 7.)

I see some old discussion of what seems to be a related issue here: http://www.magpcss.org/ceforum/viewtopic.php?f=6&t=11625 . But that thread is more than three years old and is talking about off-screen rendering. I'm hoping there is a way to get SELECT tags to work, otherwise the browser created by CEFPython is pretty badly crippled.

Czarek Tomczak

unread,
Jun 15, 2017, 4:39:43 AM6/15/17
to CEF Python
I can reproduce this in upstream CEF v57, v58 and v59. I have no idea how it got undetected for such a long time. Thanks for reporting.

Reported in CEF Python tracker: https://github.com/cztomczak/cefpython/issues/372
Reported in CEF tracker: https://bitbucket.org/chromiumembedded/cef/issues/2195/html-element-wrongly-positioned-in

For now a temporary solution would be to replace <select> elements with javascript equivalent, for example try google "jquery select replacement". You can inject custom js code that will do this task in LoadHandler.OnLoadStart (attach it to DOMDocumentLoaded event) or LoadHandler.OnLoadEnd (less reliable). Example of using client handlers is available in Tutorial.

Czarek Tomczak

unread,
Jun 20, 2017, 3:22:14 AM6/20/17
to CEF Python
You could try earlier releases like v56 or v55.

Czarek Tomczak

unread,
Jun 30, 2017, 11:35:10 AM6/30/17
to CEF Python
A follow-up on the issue. On Mac <select> boxes do work fine. I have a report by other user that it works fine on Windows 7. Also I don't see no one else reported it in CEF tracker/forum so I guess it's a rare issue and occurs only on some computers.


On Thursday, June 15, 2017 at 8:39:43 AM UTC, Czarek Tomczak wrote:
Reply all
Reply to author
Forward
0 new messages