mirror of
https://bitbucket.org/chromiumembedded/cef
synced 2025-06-05 21:39:12 +02:00
Update to Chromium revision 272007.
- Remove CefSettings.accelerated_compositing option (see https://crbug.com/363772). - Remove experimental x-webkit-speech support (see https://crbug.com/223198). - Execute CefGeolocationHandler callbacks on the UI thread (see https://crbug.com/304341#c212). git-svn-id: https://chromiumembedded.googlecode.com/svn/trunk@1711 5089003a-bbd8-11dd-ad1f-f1f9622dbc98
This commit is contained in:
@ -43,15 +43,14 @@ class CefGeolocationPermissionContext
|
||||
callback_(callback) {}
|
||||
|
||||
virtual void Continue(bool allow) OVERRIDE {
|
||||
if (CEF_CURRENTLY_ON_IOT()) {
|
||||
if (CEF_CURRENTLY_ON_UIT()) {
|
||||
if (!callback_.is_null()) {
|
||||
// Callback must be executed on the UI thread.
|
||||
CEF_POST_TASK(CEF_UIT,
|
||||
base::Bind(&CallbackImpl::Run, callback_, allow));
|
||||
callback_.Run(allow);
|
||||
context_->RemoveCallback(bridge_id_);
|
||||
}
|
||||
} else {
|
||||
CEF_POST_TASK(CEF_IOT,
|
||||
CEF_POST_TASK(CEF_UIT,
|
||||
base::Bind(&CallbackImpl::Continue, this, allow));
|
||||
}
|
||||
}
|
||||
@ -77,18 +76,16 @@ class CefGeolocationPermissionContext
|
||||
CefGeolocationPermissionContext() {}
|
||||
|
||||
virtual void RequestGeolocationPermission(
|
||||
int render_process_id,
|
||||
int render_view_id,
|
||||
content::WebContents* web_contents,
|
||||
int bridge_id,
|
||||
const GURL& requesting_frame,
|
||||
bool user_gesture,
|
||||
base::Callback<void(bool)> callback) // NOLINT(readability/function)
|
||||
OVERRIDE {
|
||||
CEF_REQUIRE_IOT();
|
||||
CEF_REQUIRE_UIT();
|
||||
|
||||
CefRefPtr<CefBrowserHostImpl> browser =
|
||||
CefBrowserHostImpl::GetBrowserForView(render_process_id,
|
||||
render_view_id);
|
||||
CefBrowserHostImpl::GetBrowserForContents(web_contents);
|
||||
if (browser.get()) {
|
||||
CefRefPtr<CefClient> client = browser->GetClient();
|
||||
if (client.get()) {
|
||||
@ -110,19 +107,17 @@ class CefGeolocationPermissionContext
|
||||
}
|
||||
|
||||
// Disallow geolocation access by default.
|
||||
CEF_POST_TASK(CEF_UIT, base::Bind(callback, false));
|
||||
callback.Run(false);
|
||||
}
|
||||
|
||||
virtual void CancelGeolocationPermissionRequest(
|
||||
int render_process_id,
|
||||
int render_view_id,
|
||||
content::WebContents* web_contents,
|
||||
int bridge_id,
|
||||
const GURL& requesting_frame) OVERRIDE {
|
||||
RemoveCallback(bridge_id);
|
||||
|
||||
CefRefPtr<CefBrowserHostImpl> browser =
|
||||
CefBrowserHostImpl::GetBrowserForView(render_process_id,
|
||||
render_view_id);
|
||||
CefBrowserHostImpl::GetBrowserForContents(web_contents);
|
||||
if (browser.get()) {
|
||||
CefRefPtr<CefClient> client = browser->GetClient();
|
||||
if (client.get()) {
|
||||
@ -138,7 +133,7 @@ class CefGeolocationPermissionContext
|
||||
}
|
||||
|
||||
void RemoveCallback(int bridge_id) {
|
||||
CEF_REQUIRE_IOT();
|
||||
CEF_REQUIRE_UIT();
|
||||
|
||||
// Disconnect the callback and remove the reference from the map.
|
||||
CallbackMap::iterator it = callback_map_.find(bridge_id);
|
||||
@ -295,6 +290,10 @@ content::GeolocationPermissionContext*
|
||||
return geolocation_permission_context_;
|
||||
}
|
||||
|
||||
content::BrowserPluginGuestManager* CefBrowserContextImpl::GetGuestManager() {
|
||||
return NULL;
|
||||
}
|
||||
|
||||
quota::SpecialStoragePolicy* CefBrowserContextImpl::GetSpecialStoragePolicy() {
|
||||
return NULL;
|
||||
}
|
||||
|
Reference in New Issue
Block a user