detect instance of devtools

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.

detect instance of devtools

Postby Tiph » Thu Sep 11, 2014 8:06 am

Hey

I d like to detect in the OnAfterCreated callback if the browser is an instance of DevTools I try to use the url but its always NULL

Code: Select all
   CefString url (browser->GetFocusedFrame()->GetURL());
   CefString url (browser->GetFocusedFrame()->GetURL());





Thank for the help
Tiph
Techie
 
Posts: 13
Joined: Mon Aug 11, 2014 12:01 pm

Re: detect instance of devtools

Postby magreenblatt » Thu Sep 11, 2014 11:23 am

The URL is not available in OnAfterCreated. You either need to maintain that state yourself (a variable in your application that is set before ShowDevTools is called and referenced in OnAfterCreated) or wait for the OnLoadStart notification.
magreenblatt
Site Admin
 
Posts: 12409
Joined: Fri May 29, 2009 6:57 pm


Return to Support Forum

Who is online

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