Rename SendFocusEvent to SetFocus (fixes issue #866)

Also removes CefBrowserHost::SendFocusEvent. Use the existing SetFocus method
instead.
This commit is contained in:
Marshall Greenblatt
2021-09-27 10:50:07 +03:00
parent a74fa88812
commit 41b64e428c
30 changed files with 43 additions and 95 deletions

View File

@@ -9,7 +9,7 @@
// implementations. See the translator.README.txt file in the tools directory
// for more information.
//
// $hash=0109529f61a92116f73bc6c0ff47bfd0423b6f07$
// $hash=08a83d2956014971961d1cf3f93afbc1dae48f76$
//
#include "libcef_dll/cpptoc/browser_host_cpptoc.h"
@@ -874,20 +874,6 @@ browser_host_send_touch_event(struct _cef_browser_host_t* self,
CefBrowserHostCppToC::Get(self)->SendTouchEvent(eventObj);
}
void CEF_CALLBACK
browser_host_send_focus_event(struct _cef_browser_host_t* self, int setFocus) {
shutdown_checker::AssertNotShutdown();
// AUTO-GENERATED CONTENT - DELETE THIS COMMENT BEFORE MODIFYING
DCHECK(self);
if (!self)
return;
// Execute
CefBrowserHostCppToC::Get(self)->SendFocusEvent(setFocus ? true : false);
}
void CEF_CALLBACK
browser_host_send_capture_lost_event(struct _cef_browser_host_t* self) {
shutdown_checker::AssertNotShutdown();
@@ -1350,7 +1336,6 @@ CefBrowserHostCppToC::CefBrowserHostCppToC() {
GetStruct()->send_mouse_move_event = browser_host_send_mouse_move_event;
GetStruct()->send_mouse_wheel_event = browser_host_send_mouse_wheel_event;
GetStruct()->send_touch_event = browser_host_send_touch_event;
GetStruct()->send_focus_event = browser_host_send_focus_event;
GetStruct()->send_capture_lost_event = browser_host_send_capture_lost_event;
GetStruct()->notify_move_or_resize_started =
browser_host_notify_move_or_resize_started;

View File

@@ -9,7 +9,7 @@
// implementations. See the translator.README.txt file in the tools directory
// for more information.
//
// $hash=e53c3c194d40a9bdee41a348a1c9fd65822e4ba9$
// $hash=791e5fd2deefd0e040143477a6ae53593886e706$
//
#include "libcef_dll/ctocpp/browser_host_ctocpp.h"
@@ -764,20 +764,6 @@ void CefBrowserHostCToCpp::SendTouchEvent(const CefTouchEvent& event) {
_struct->send_touch_event(_struct, &event);
}
NO_SANITIZE("cfi-icall")
void CefBrowserHostCToCpp::SendFocusEvent(bool setFocus) {
shutdown_checker::AssertNotShutdown();
cef_browser_host_t* _struct = GetStruct();
if (CEF_MEMBER_MISSING(_struct, send_focus_event))
return;
// AUTO-GENERATED CONTENT - DELETE THIS COMMENT BEFORE MODIFYING
// Execute
_struct->send_focus_event(_struct, setFocus);
}
NO_SANITIZE("cfi-icall") void CefBrowserHostCToCpp::SendCaptureLostEvent() {
shutdown_checker::AssertNotShutdown();
@@ -1015,8 +1001,8 @@ void CefBrowserHostCToCpp::DragSourceSystemDragEnded() {
}
NO_SANITIZE("cfi-icall")
CefRefPtr<
CefNavigationEntry> CefBrowserHostCToCpp::GetVisibleNavigationEntry() {
CefRefPtr<CefNavigationEntry>
CefBrowserHostCToCpp::GetVisibleNavigationEntry() {
shutdown_checker::AssertNotShutdown();
cef_browser_host_t* _struct = GetStruct();

View File

@@ -9,7 +9,7 @@
// implementations. See the translator.README.txt file in the tools directory
// for more information.
//
// $hash=0de1d0125514efd66096e5e900938b6481f0ec1d$
// $hash=1c231cf78fe94d9e395fe8bee9c0c848d81f3ef5$
//
#ifndef CEF_LIBCEF_DLL_CTOCPP_BROWSER_HOST_CTOCPP_H_
@@ -102,7 +102,6 @@ class CefBrowserHostCToCpp : public CefCToCppRefCounted<CefBrowserHostCToCpp,
int deltaX,
int deltaY) override;
void SendTouchEvent(const CefTouchEvent& event) override;
void SendFocusEvent(bool setFocus) override;
void SendCaptureLostEvent() override;
void NotifyMoveOrResizeStarted() override;
int GetWindowlessFrameRate() override;