mirror of
https://bitbucket.org/chromiumembedded/cef
synced 2025-06-05 21:39:12 +02:00
Add CefTaskManager::GetTaskIdForBrowserId
Update https://tests/task_manager to show the current browser's renderer task in bold. Approved-by: Nik Pavlov
This commit is contained in:
@@ -9,7 +9,7 @@
|
||||
// implementations. See the translator.README.txt file in the tools directory
|
||||
// for more information.
|
||||
//
|
||||
// $hash=07933b22615488a634fd4df87e9691156ae23ec4$
|
||||
// $hash=93050197dccd1c7999c7b90700a6144e5225c773$
|
||||
//
|
||||
|
||||
#include "libcef_dll/cpptoc/task_manager_cpptoc.h"
|
||||
@@ -155,6 +155,26 @@ int CEF_CALLBACK task_manager_kill_task(struct _cef_task_manager_t* self,
|
||||
return _retval;
|
||||
}
|
||||
|
||||
int64_t CEF_CALLBACK
|
||||
task_manager_get_task_id_for_browser_id(struct _cef_task_manager_t* self,
|
||||
int browser_id) {
|
||||
shutdown_checker::AssertNotShutdown();
|
||||
|
||||
// AUTO-GENERATED CONTENT - DELETE THIS COMMENT BEFORE MODIFYING
|
||||
|
||||
DCHECK(self);
|
||||
if (!self) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
// Execute
|
||||
int64_t _retval =
|
||||
CefTaskManagerCppToC::Get(self)->GetTaskIdForBrowserId(browser_id);
|
||||
|
||||
// Return type: simple
|
||||
return _retval;
|
||||
}
|
||||
|
||||
} // namespace
|
||||
|
||||
// CONSTRUCTOR - Do not edit by hand.
|
||||
@@ -164,6 +184,8 @@ CefTaskManagerCppToC::CefTaskManagerCppToC() {
|
||||
GetStruct()->get_task_ids_list = task_manager_get_task_ids_list;
|
||||
GetStruct()->get_task_info = task_manager_get_task_info;
|
||||
GetStruct()->kill_task = task_manager_kill_task;
|
||||
GetStruct()->get_task_id_for_browser_id =
|
||||
task_manager_get_task_id_for_browser_id;
|
||||
}
|
||||
|
||||
// DESTRUCTOR - Do not edit by hand.
|
||||
|
@@ -9,7 +9,7 @@
|
||||
// implementations. See the translator.README.txt file in the tools directory
|
||||
// for more information.
|
||||
//
|
||||
// $hash=56907c5bc7334bc3289f0a97dbc4a70c3ac9b41a$
|
||||
// $hash=5838ce3611dda9523ff072eceb36137663828dd6$
|
||||
//
|
||||
|
||||
#include "libcef_dll/ctocpp/task_manager_ctocpp.h"
|
||||
@@ -132,6 +132,24 @@ NO_SANITIZE("cfi-icall") bool CefTaskManagerCToCpp::KillTask(int64_t task_id) {
|
||||
return _retval ? true : false;
|
||||
}
|
||||
|
||||
NO_SANITIZE("cfi-icall")
|
||||
int64_t CefTaskManagerCToCpp::GetTaskIdForBrowserId(int browser_id) {
|
||||
shutdown_checker::AssertNotShutdown();
|
||||
|
||||
cef_task_manager_t* _struct = GetStruct();
|
||||
if (CEF_MEMBER_MISSING(_struct, get_task_id_for_browser_id)) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
// AUTO-GENERATED CONTENT - DELETE THIS COMMENT BEFORE MODIFYING
|
||||
|
||||
// Execute
|
||||
int64_t _retval = _struct->get_task_id_for_browser_id(_struct, browser_id);
|
||||
|
||||
// Return type: simple
|
||||
return _retval;
|
||||
}
|
||||
|
||||
// CONSTRUCTOR - Do not edit by hand.
|
||||
|
||||
CefTaskManagerCToCpp::CefTaskManagerCToCpp() {}
|
||||
|
@@ -9,7 +9,7 @@
|
||||
// implementations. See the translator.README.txt file in the tools directory
|
||||
// for more information.
|
||||
//
|
||||
// $hash=d51db130ffb459b22574d7393e63e87c87dd75e0$
|
||||
// $hash=2d35ee921c7a1abda4c83b66708bce2451b38f20$
|
||||
//
|
||||
|
||||
#ifndef CEF_LIBCEF_DLL_CTOCPP_TASK_MANAGER_CTOCPP_H_
|
||||
@@ -38,6 +38,7 @@ class CefTaskManagerCToCpp : public CefCToCppRefCounted<CefTaskManagerCToCpp,
|
||||
bool GetTaskIdsList(TaskIdList& task_ids) override;
|
||||
bool GetTaskInfo(int64_t task_id, CefTaskInfo& info) override;
|
||||
bool KillTask(int64_t task_id) override;
|
||||
int64_t GetTaskIdForBrowserId(int browser_id) override;
|
||||
};
|
||||
|
||||
#endif // CEF_LIBCEF_DLL_CTOCPP_TASK_MANAGER_CTOCPP_H_
|
||||
|
Reference in New Issue
Block a user