mirror of
https://bitbucket.org/chromiumembedded/cef
synced 2025-06-05 21:39:12 +02:00
views: Add groups and focus/blur callbacks (issue #2102)
- cefclient: Only make menus focusable when ALT is pressed. - cefclient: Display sample top menu when passed the `--show-top-menu` command-line flag.
This commit is contained in:
@ -326,6 +326,35 @@ void CEF_CALLBACK browser_view_set_id(struct _cef_view_t* self, int id) {
|
||||
id);
|
||||
}
|
||||
|
||||
int CEF_CALLBACK browser_view_get_group_id(struct _cef_view_t* self) {
|
||||
// AUTO-GENERATED CONTENT - DELETE THIS COMMENT BEFORE MODIFYING
|
||||
|
||||
DCHECK(self);
|
||||
if (!self)
|
||||
return 0;
|
||||
|
||||
// Execute
|
||||
int _retval = CefBrowserViewCppToC::Get(reinterpret_cast<cef_browser_view_t*>(
|
||||
self))->GetGroupID();
|
||||
|
||||
// Return type: simple
|
||||
return _retval;
|
||||
}
|
||||
|
||||
void CEF_CALLBACK browser_view_set_group_id(struct _cef_view_t* self,
|
||||
int group_id) {
|
||||
// AUTO-GENERATED CONTENT - DELETE THIS COMMENT BEFORE MODIFYING
|
||||
|
||||
DCHECK(self);
|
||||
if (!self)
|
||||
return;
|
||||
|
||||
// Execute
|
||||
CefBrowserViewCppToC::Get(reinterpret_cast<cef_browser_view_t*>(
|
||||
self))->SetGroupID(
|
||||
group_id);
|
||||
}
|
||||
|
||||
struct _cef_view_t* CEF_CALLBACK browser_view_get_parent_view(
|
||||
struct _cef_view_t* self) {
|
||||
// AUTO-GENERATED CONTENT - DELETE THIS COMMENT BEFORE MODIFYING
|
||||
@ -933,6 +962,8 @@ CefBrowserViewCppToC::CefBrowserViewCppToC() {
|
||||
GetStruct()->base.get_window = browser_view_get_window;
|
||||
GetStruct()->base.get_id = browser_view_get_id;
|
||||
GetStruct()->base.set_id = browser_view_set_id;
|
||||
GetStruct()->base.get_group_id = browser_view_get_group_id;
|
||||
GetStruct()->base.set_group_id = browser_view_set_group_id;
|
||||
GetStruct()->base.get_parent_view = browser_view_get_parent_view;
|
||||
GetStruct()->base.get_view_for_id = browser_view_get_view_for_id;
|
||||
GetStruct()->base.set_bounds = browser_view_set_bounds;
|
||||
|
Reference in New Issue
Block a user