CEFGlue - GeoLocation handling

Having problems with building or using the CefGlue .NET/Mono binding? Ask your questions here.

Moderator: fddima

CEFGlue - GeoLocation handling

Postby aidenfry » Wed Jul 09, 2014 10:49 am

Hey everybody.

Our embedded browser needs to use geolocation stuff, let me know if this is the wrong way of going about it.

I need to implement the CefGeolocationHandler and overwrite the OnRequestGeolocationpermission to return true like this.

Code: Select all
class ExampleCEFGeoLocationHandler : CefGeolocationHandler{

            protected override void OnRequestGeolocationPermission(CefBrowser browser, string requestingUrl, int requestId, CefGeolocationCallback callback)
            {
                MessageBox.Show("On Request Geolocation");
                callback.Continue(true);

            }

            protected override void OnCancelGeolocationPermission(CefBrowser browser, string requesting_url, int request_id)
            {
            }

        }



Now I am struggling to actually implement my ExampleCEFGeolocationHandler so that this override takes place.

I can not find anywhere in the documentation that allows me to set this handler. Anyone know how I can do this?

(Yes I have set up the Places API key variables)
aidenfry
Newbie
 
Posts: 4
Joined: Thu Jun 05, 2014 5:24 am

Return to CefGlue Forum

Who is online

Users browsing this forum: No registered users and 19 guests