how to make cefclient window invisible?

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.

how to make cefclient window invisible?

Postby woodvillage » Sun Sep 10, 2017 9:03 pm

environment: ubuntu 16.04;cef_binary_3.3112.1652.g8c8deea_linux64.

I need to do batch test with cefclient, so I want it to be invisible(windowless). I tried three ways, but doesn't work.
1. add '--off-screen-rendering-enabled' in command line args
2. add root_window.Hide() in RootWindowManager::CreateRootWindow.
3. add '--headless --disable-gpu' in command line args

am I doing sth. wrong? or is there other way to do this?
woodvillage
Newbie
 
Posts: 4
Joined: Sun Aug 27, 2017 9:35 pm

Re: how to make cefclient window invisible?

Postby magreenblatt » Mon Sep 11, 2017 11:39 am

The cefclient sample application does not demonstrate a headless mode. You can implement that yourself using off-screen rendering by not creating a window and not handling the OnPaint callback.
magreenblatt
Site Admin
 
Posts: 12382
Joined: Fri May 29, 2009 6:57 pm

Re: how to make cefclient window invisible?

Postby woodvillage » Tue Sep 12, 2017 3:05 am

magreenblatt wrote:The cefclient sample application does not demonstrate a headless mode. You can implement that yourself using off-screen rendering by not creating a window and not handling the OnPaint callback.

ok,thx very much.
do you have any guide to do this? adding the implementation of CefRenderHandler::OnPaint() in client_handler.cc and make it null?
woodvillage
Newbie
 
Posts: 4
Joined: Sun Aug 27, 2017 9:35 pm

Re: how to make cefclient window invisible?

Postby magreenblatt » Tue Sep 12, 2017 11:14 am

That depends on how much functionality you need. How will you handle mouse and keyboard events, for example? See https://bitbucket.org/chromiumembedded/ ... -rendering
magreenblatt
Site Admin
 
Posts: 12382
Joined: Fri May 29, 2009 6:57 pm

Re: how to make cefclient window invisible?

Postby woodvillage » Fri Sep 15, 2017 4:27 am

magreenblatt wrote:That depends on how much functionality you need. How will you handle mouse and keyboard events, for example? See https://bitbucket.org/chromiumembedded/ ... -rendering

Actually I do not to do anything, no mouse or keyboard operation, just run cefclient background with script.
I use cefclient as a test tool, open some links and write some logs and then just close it.
woodvillage
Newbie
 
Posts: 4
Joined: Sun Aug 27, 2017 9:35 pm


Return to Support Forum

Who is online

Users browsing this forum: Google [Bot] and 31 guests