Error when OnPaint should be called.

Having problems with building or using CEF's C/C++ APIs? This forum is here to help. Please do not post bug reports or feature requests here.

Re: Error when OnPaint should be called.

Postby Czarek » Mon Oct 29, 2018 11:18 am

Check command line args passed to the process, if it starts with "--type=renderer" then you got it.
Maintainer of the CEF Python, PHP Desktop and CEF C API projects. My LinkedIn.
User avatar
Czarek
Virtuoso
 
Posts: 1927
Joined: Sun Nov 06, 2011 2:12 am

Re: Error when OnPaint should be called.

Postby Eitu33 » Mon Oct 29, 2018 11:22 am

Czarek wrote:Check command line args passed to the process, if it starts with "--type=renderer" then you got it.

Oh, I only get --type=zygote and --type=gpu-process, but since cefclient example has the same arguments I thought it was fine.
I also managed to make it work in a simpler context without getting --type=renderer.
Eitu33
Techie
 
Posts: 18
Joined: Wed Oct 10, 2018 10:06 am

Re: Error when OnPaint should be called.

Postby magreenblatt » Mon Oct 29, 2018 1:06 pm

Eitu33 wrote:
Czarek wrote:Check command line args passed to the process, if it starts with "--type=renderer" then you got it.

Oh, I only get --type=zygote and --type=gpu-process, but since cefclient example has the same arguments I thought it was fine.
I also managed to make it work in a simpler context without getting --type=renderer.

The zygote process is forked to create renderer processes. Do you see multiple instances of the zygote process?
magreenblatt
Site Admin
 
Posts: 12404
Joined: Fri May 29, 2009 6:57 pm

Re: Error when OnPaint should be called.

Postby Eitu33 » Mon Oct 29, 2018 1:21 pm

magreenblatt wrote:The zygote process is forked to create renderer processes. Do you see multiple instances of the zygote process?

Nope, but after setting a breakpoint in ChromiumRenderProcessHandler::OnContextCreated, I noticed that it is not called and I have no idea why...
What could be the cause of OnContextCreated not being called?
Eitu33
Techie
 
Posts: 18
Joined: Wed Oct 10, 2018 10:06 am

Re: Error when OnPaint should be called.

Postby Eitu33 » Tue Oct 30, 2018 7:43 am

Eitu33 wrote:
magreenblatt wrote:The zygote process is forked to create renderer processes. Do you see multiple instances of the zygote process?

Nope, but after setting a breakpoint in ChromiumRenderProcessHandler::OnContextCreated, I noticed that it is not called and I have no idea why...
What could be the cause of OnContextCreated not being called?

GetRenderProcess is never called in my app.
I also tried launching it with the single process switch but I did not get significant results.

Edit: I managed to make it work with single process enabled.
Eitu33
Techie
 
Posts: 18
Joined: Wed Oct 10, 2018 10:06 am

Re: Error when OnPaint should be called.

Postby magreenblatt » Tue Oct 30, 2018 11:07 am

Are you passing an instance of CefApp that implements GetRenderProcessHandler to CefExecuteProcess? How are you testing if the method is called?
magreenblatt
Site Admin
 
Posts: 12404
Joined: Fri May 29, 2009 6:57 pm

Re: Error when OnPaint should be called.

Postby Eitu33 » Thu Nov 15, 2018 10:29 am

magreenblatt wrote:Are you passing an instance of CefApp that implements GetRenderProcessHandler to CefExecuteProcess?

Yes.
magreenblatt wrote:How are you testing if the method is called?

Using gdb breakpoints.

I actually managed to make it work by modifying the code that was not related to Cef API, even though I still can't explain precisely why this was happening...
Eitu33
Techie
 
Posts: 18
Joined: Wed Oct 10, 2018 10:06 am

Previous

Return to Support Forum

Who is online

Users browsing this forum: clown, Google [Bot] and 36 guests