Remove geolocation API support (issue #2380)

This commit is contained in:
Marshall Greenblatt
2018-02-12 18:51:11 -05:00
parent c3f2c2e91c
commit ac86b61139
43 changed files with 9 additions and 2531 deletions

View File

@ -9,7 +9,7 @@
// implementations. See the translator.README.txt file in the tools directory
// for more information.
//
// $hash=9e43ede1c873111f8ccd125a24a6201c4702f822$
// $hash=74f8efc606edb74535b418345d7a3b9ddcfd3bca$
//
#include "libcef_dll/cpptoc/client_cpptoc.h"
@ -20,7 +20,6 @@
#include "libcef_dll/cpptoc/drag_handler_cpptoc.h"
#include "libcef_dll/cpptoc/find_handler_cpptoc.h"
#include "libcef_dll/cpptoc/focus_handler_cpptoc.h"
#include "libcef_dll/cpptoc/geolocation_handler_cpptoc.h"
#include "libcef_dll/cpptoc/jsdialog_handler_cpptoc.h"
#include "libcef_dll/cpptoc/keyboard_handler_cpptoc.h"
#include "libcef_dll/cpptoc/life_span_handler_cpptoc.h"
@ -146,22 +145,6 @@ client_get_focus_handler(struct _cef_client_t* self) {
return CefFocusHandlerCppToC::Wrap(_retval);
}
struct _cef_geolocation_handler_t* CEF_CALLBACK
client_get_geolocation_handler(struct _cef_client_t* self) {
// AUTO-GENERATED CONTENT - DELETE THIS COMMENT BEFORE MODIFYING
DCHECK(self);
if (!self)
return NULL;
// Execute
CefRefPtr<CefGeolocationHandler> _retval =
CefClientCppToC::Get(self)->GetGeolocationHandler();
// Return type: refptr_same
return CefGeolocationHandlerCppToC::Wrap(_retval);
}
struct _cef_jsdialog_handler_t* CEF_CALLBACK
client_get_jsdialog_handler(struct _cef_client_t* self) {
// AUTO-GENERATED CONTENT - DELETE THIS COMMENT BEFORE MODIFYING
@ -298,7 +281,6 @@ CefClientCppToC::CefClientCppToC() {
GetStruct()->get_drag_handler = client_get_drag_handler;
GetStruct()->get_find_handler = client_get_find_handler;
GetStruct()->get_focus_handler = client_get_focus_handler;
GetStruct()->get_geolocation_handler = client_get_geolocation_handler;
GetStruct()->get_jsdialog_handler = client_get_jsdialog_handler;
GetStruct()->get_keyboard_handler = client_get_keyboard_handler;
GetStruct()->get_life_span_handler = client_get_life_span_handler;

View File

@ -1,63 +0,0 @@
// Copyright (c) 2018 The Chromium Embedded Framework Authors. All rights
// reserved. Use of this source code is governed by a BSD-style license that
// can be found in the LICENSE file.
//
// ---------------------------------------------------------------------------
//
// This file was generated by the CEF translator tool. If making changes by
// hand only do so within the body of existing method and function
// implementations. See the translator.README.txt file in the tools directory
// for more information.
//
// $hash=5bd0f16810c3c46a19a5f64133e02e4681675f04$
//
#include "libcef_dll/cpptoc/geolocation_callback_cpptoc.h"
namespace {
// MEMBER FUNCTIONS - Body may be edited by hand.
void CEF_CALLBACK
geolocation_callback_cont(struct _cef_geolocation_callback_t* self, int allow) {
// AUTO-GENERATED CONTENT - DELETE THIS COMMENT BEFORE MODIFYING
DCHECK(self);
if (!self)
return;
// Execute
CefGeolocationCallbackCppToC::Get(self)->Continue(allow ? true : false);
}
} // namespace
// CONSTRUCTOR - Do not edit by hand.
CefGeolocationCallbackCppToC::CefGeolocationCallbackCppToC() {
GetStruct()->cont = geolocation_callback_cont;
}
template <>
CefRefPtr<CefGeolocationCallback> CefCppToCRefCounted<
CefGeolocationCallbackCppToC,
CefGeolocationCallback,
cef_geolocation_callback_t>::UnwrapDerived(CefWrapperType type,
cef_geolocation_callback_t* s) {
NOTREACHED() << "Unexpected class type: " << type;
return NULL;
}
#if DCHECK_IS_ON()
template <>
base::AtomicRefCount CefCppToCRefCounted<CefGeolocationCallbackCppToC,
CefGeolocationCallback,
cef_geolocation_callback_t>::DebugObjCt
ATOMIC_DECLARATION;
#endif
template <>
CefWrapperType CefCppToCRefCounted<CefGeolocationCallbackCppToC,
CefGeolocationCallback,
cef_geolocation_callback_t>::kWrapperType =
WT_GEOLOCATION_CALLBACK;

View File

@ -1,37 +0,0 @@
// Copyright (c) 2018 The Chromium Embedded Framework Authors. All rights
// reserved. Use of this source code is governed by a BSD-style license that
// can be found in the LICENSE file.
//
// ---------------------------------------------------------------------------
//
// This file was generated by the CEF translator tool. If making changes by
// hand only do so within the body of existing method and function
// implementations. See the translator.README.txt file in the tools directory
// for more information.
//
// $hash=98817821ce951491596ce01e7a13febc669ff1b9$
//
#ifndef CEF_LIBCEF_DLL_CPPTOC_GEOLOCATION_CALLBACK_CPPTOC_H_
#define CEF_LIBCEF_DLL_CPPTOC_GEOLOCATION_CALLBACK_CPPTOC_H_
#pragma once
#if !defined(BUILDING_CEF_SHARED)
#error This file can be included DLL-side only
#endif
#include "include/capi/cef_geolocation_handler_capi.h"
#include "include/cef_geolocation_handler.h"
#include "libcef_dll/cpptoc/cpptoc_ref_counted.h"
// Wrap a C++ class with a C structure.
// This class may be instantiated and accessed DLL-side only.
class CefGeolocationCallbackCppToC
: public CefCppToCRefCounted<CefGeolocationCallbackCppToC,
CefGeolocationCallback,
cef_geolocation_callback_t> {
public:
CefGeolocationCallbackCppToC();
};
#endif // CEF_LIBCEF_DLL_CPPTOC_GEOLOCATION_CALLBACK_CPPTOC_H_

View File

@ -1,109 +0,0 @@
// Copyright (c) 2018 The Chromium Embedded Framework Authors. All rights
// reserved. Use of this source code is governed by a BSD-style license that
// can be found in the LICENSE file.
//
// ---------------------------------------------------------------------------
//
// This file was generated by the CEF translator tool. If making changes by
// hand only do so within the body of existing method and function
// implementations. See the translator.README.txt file in the tools directory
// for more information.
//
// $hash=d4092763acd3a7bfd30586d0bdfd91915d2fab90$
//
#include "libcef_dll/cpptoc/geolocation_handler_cpptoc.h"
#include "libcef_dll/ctocpp/browser_ctocpp.h"
#include "libcef_dll/ctocpp/geolocation_callback_ctocpp.h"
namespace {
// MEMBER FUNCTIONS - Body may be edited by hand.
int CEF_CALLBACK geolocation_handler_on_request_geolocation_permission(
struct _cef_geolocation_handler_t* self,
cef_browser_t* browser,
const cef_string_t* requesting_url,
int request_id,
cef_geolocation_callback_t* callback) {
// AUTO-GENERATED CONTENT - DELETE THIS COMMENT BEFORE MODIFYING
DCHECK(self);
if (!self)
return 0;
// Verify param: browser; type: refptr_diff
DCHECK(browser);
if (!browser)
return 0;
// Verify param: requesting_url; type: string_byref_const
DCHECK(requesting_url);
if (!requesting_url)
return 0;
// Verify param: callback; type: refptr_diff
DCHECK(callback);
if (!callback)
return 0;
// Execute
bool _retval =
CefGeolocationHandlerCppToC::Get(self)->OnRequestGeolocationPermission(
CefBrowserCToCpp::Wrap(browser), CefString(requesting_url),
request_id, CefGeolocationCallbackCToCpp::Wrap(callback));
// Return type: bool
return _retval;
}
void CEF_CALLBACK geolocation_handler_on_cancel_geolocation_permission(
struct _cef_geolocation_handler_t* self,
cef_browser_t* browser,
int request_id) {
// AUTO-GENERATED CONTENT - DELETE THIS COMMENT BEFORE MODIFYING
DCHECK(self);
if (!self)
return;
// Verify param: browser; type: refptr_diff
DCHECK(browser);
if (!browser)
return;
// Execute
CefGeolocationHandlerCppToC::Get(self)->OnCancelGeolocationPermission(
CefBrowserCToCpp::Wrap(browser), request_id);
}
} // namespace
// CONSTRUCTOR - Do not edit by hand.
CefGeolocationHandlerCppToC::CefGeolocationHandlerCppToC() {
GetStruct()->on_request_geolocation_permission =
geolocation_handler_on_request_geolocation_permission;
GetStruct()->on_cancel_geolocation_permission =
geolocation_handler_on_cancel_geolocation_permission;
}
template <>
CefRefPtr<CefGeolocationHandler> CefCppToCRefCounted<
CefGeolocationHandlerCppToC,
CefGeolocationHandler,
cef_geolocation_handler_t>::UnwrapDerived(CefWrapperType type,
cef_geolocation_handler_t* s) {
NOTREACHED() << "Unexpected class type: " << type;
return NULL;
}
#if DCHECK_IS_ON()
template <>
base::AtomicRefCount CefCppToCRefCounted<CefGeolocationHandlerCppToC,
CefGeolocationHandler,
cef_geolocation_handler_t>::DebugObjCt
ATOMIC_DECLARATION;
#endif
template <>
CefWrapperType CefCppToCRefCounted<CefGeolocationHandlerCppToC,
CefGeolocationHandler,
cef_geolocation_handler_t>::kWrapperType =
WT_GEOLOCATION_HANDLER;

View File

@ -1,37 +0,0 @@
// Copyright (c) 2018 The Chromium Embedded Framework Authors. All rights
// reserved. Use of this source code is governed by a BSD-style license that
// can be found in the LICENSE file.
//
// ---------------------------------------------------------------------------
//
// This file was generated by the CEF translator tool. If making changes by
// hand only do so within the body of existing method and function
// implementations. See the translator.README.txt file in the tools directory
// for more information.
//
// $hash=414d9dd69cf3d35b85ccdfcf302884033ed6e04c$
//
#ifndef CEF_LIBCEF_DLL_CPPTOC_GEOLOCATION_HANDLER_CPPTOC_H_
#define CEF_LIBCEF_DLL_CPPTOC_GEOLOCATION_HANDLER_CPPTOC_H_
#pragma once
#if !defined(WRAPPING_CEF_SHARED)
#error This file can be included wrapper-side only
#endif
#include "include/capi/cef_geolocation_handler_capi.h"
#include "include/cef_geolocation_handler.h"
#include "libcef_dll/cpptoc/cpptoc_ref_counted.h"
// Wrap a C++ class with a C structure.
// This class may be instantiated and accessed wrapper-side only.
class CefGeolocationHandlerCppToC
: public CefCppToCRefCounted<CefGeolocationHandlerCppToC,
CefGeolocationHandler,
cef_geolocation_handler_t> {
public:
CefGeolocationHandlerCppToC();
};
#endif // CEF_LIBCEF_DLL_CPPTOC_GEOLOCATION_HANDLER_CPPTOC_H_

View File

@ -1,74 +0,0 @@
// Copyright (c) 2018 The Chromium Embedded Framework Authors. All rights
// reserved. Use of this source code is governed by a BSD-style license that
// can be found in the LICENSE file.
//
// ---------------------------------------------------------------------------
//
// This file was generated by the CEF translator tool. If making changes by
// hand only do so within the body of existing method and function
// implementations. See the translator.README.txt file in the tools directory
// for more information.
//
// $hash=ba9c66f6c7806715268009762248e6f68e94fc8c$
//
#include "libcef_dll/cpptoc/get_geolocation_callback_cpptoc.h"
namespace {
// MEMBER FUNCTIONS - Body may be edited by hand.
void CEF_CALLBACK get_geolocation_callback_on_location_update(
struct _cef_get_geolocation_callback_t* self,
const struct _cef_geoposition_t* position) {
// AUTO-GENERATED CONTENT - DELETE THIS COMMENT BEFORE MODIFYING
DCHECK(self);
if (!self)
return;
// Verify param: position; type: struct_byref_const
DCHECK(position);
if (!position)
return;
// Translate param: position; type: struct_byref_const
CefGeoposition positionObj;
if (position)
positionObj.Set(*position, false);
// Execute
CefGetGeolocationCallbackCppToC::Get(self)->OnLocationUpdate(positionObj);
}
} // namespace
// CONSTRUCTOR - Do not edit by hand.
CefGetGeolocationCallbackCppToC::CefGetGeolocationCallbackCppToC() {
GetStruct()->on_location_update = get_geolocation_callback_on_location_update;
}
template <>
CefRefPtr<CefGetGeolocationCallback>
CefCppToCRefCounted<CefGetGeolocationCallbackCppToC,
CefGetGeolocationCallback,
cef_get_geolocation_callback_t>::
UnwrapDerived(CefWrapperType type, cef_get_geolocation_callback_t* s) {
NOTREACHED() << "Unexpected class type: " << type;
return NULL;
}
#if DCHECK_IS_ON()
template <>
base::AtomicRefCount CefCppToCRefCounted<
CefGetGeolocationCallbackCppToC,
CefGetGeolocationCallback,
cef_get_geolocation_callback_t>::DebugObjCt ATOMIC_DECLARATION;
#endif
template <>
CefWrapperType
CefCppToCRefCounted<CefGetGeolocationCallbackCppToC,
CefGetGeolocationCallback,
cef_get_geolocation_callback_t>::kWrapperType =
WT_GET_GEOLOCATION_CALLBACK;

View File

@ -1,37 +0,0 @@
// Copyright (c) 2018 The Chromium Embedded Framework Authors. All rights
// reserved. Use of this source code is governed by a BSD-style license that
// can be found in the LICENSE file.
//
// ---------------------------------------------------------------------------
//
// This file was generated by the CEF translator tool. If making changes by
// hand only do so within the body of existing method and function
// implementations. See the translator.README.txt file in the tools directory
// for more information.
//
// $hash=5b84f64e6dc130807abd2cf121f4fe8a19ef0194$
//
#ifndef CEF_LIBCEF_DLL_CPPTOC_GET_GEOLOCATION_CALLBACK_CPPTOC_H_
#define CEF_LIBCEF_DLL_CPPTOC_GET_GEOLOCATION_CALLBACK_CPPTOC_H_
#pragma once
#if !defined(WRAPPING_CEF_SHARED)
#error This file can be included wrapper-side only
#endif
#include "include/capi/cef_geolocation_capi.h"
#include "include/cef_geolocation.h"
#include "libcef_dll/cpptoc/cpptoc_ref_counted.h"
// Wrap a C++ class with a C structure.
// This class may be instantiated and accessed wrapper-side only.
class CefGetGeolocationCallbackCppToC
: public CefCppToCRefCounted<CefGetGeolocationCallbackCppToC,
CefGetGeolocationCallback,
cef_get_geolocation_callback_t> {
public:
CefGetGeolocationCallbackCppToC();
};
#endif // CEF_LIBCEF_DLL_CPPTOC_GET_GEOLOCATION_CALLBACK_CPPTOC_H_