mirror of
https://bitbucket.org/chromiumembedded/cef
synced 2025-06-05 21:39:12 +02:00
Update to Chromium version 135.0.7049.0 (#1427262)
This commit is contained in:
@@ -378,11 +378,11 @@ void CefBrowserContentsDelegate::RenderViewReady() {
|
||||
void CefBrowserContentsDelegate::PrimaryMainFrameRenderProcessGone(
|
||||
base::TerminationStatus status) {
|
||||
static_assert(static_cast<int>(CEF_RESULT_CODE_CHROME_FIRST) ==
|
||||
static_cast<int>(chrome::RESULT_CODE_CHROME_START),
|
||||
static_cast<int>(CHROME_RESULT_CODE_CHROME_START),
|
||||
"CEF_RESULT_CODE_CHROME_FIRST must match "
|
||||
"chrome::RESULT_CODE_CHROME_START");
|
||||
static_assert(static_cast<int>(CEF_RESULT_CODE_CHROME_LAST) ==
|
||||
static_cast<int>(chrome::RESULT_CODE_CHROME_LAST_CODE),
|
||||
static_cast<int>(CHROME_RESULT_CODE_CHROME_LAST_CODE),
|
||||
"CEF_RESULT_CODE_CHROME_LAST must match "
|
||||
"chrome::RESULT_CODE_CHROME_LAST_CODE");
|
||||
|
||||
|
@@ -246,7 +246,8 @@ void CefBrowserContext::RemoveCefRequestContext(
|
||||
Shutdown();
|
||||
|
||||
// Allow the current call stack to unwind before deleting |this|.
|
||||
content::BrowserThread::DeleteSoon(CEF_UIT, FROM_HERE, this);
|
||||
content::BrowserThread::GetTaskRunnerForThread(CEF_UIT)->DeleteSoon(
|
||||
FROM_HERE, this);
|
||||
}
|
||||
}
|
||||
|
||||
|
@@ -602,7 +602,7 @@ ChromeContentBrowserClientCef::CreateLoginDelegate(
|
||||
scoped_refptr<net::HttpResponseHeaders> response_headers,
|
||||
bool first_auth_attempt,
|
||||
content::GuestPageHolder* guest,
|
||||
LoginAuthRequiredCallback auth_required_callback) {
|
||||
content::LoginDelegate::LoginAuthRequiredCallback auth_required_callback) {
|
||||
// |web_contents| is nullptr for CefURLRequests without an associated frame.
|
||||
if (!web_contents || base::CommandLine::ForCurrentProcess()->HasSwitch(
|
||||
switches::kDisableChromeLoginPrompt)) {
|
||||
|
@@ -134,7 +134,8 @@ class ChromeContentBrowserClientCef : public ChromeContentBrowserClient {
|
||||
scoped_refptr<net::HttpResponseHeaders> response_headers,
|
||||
bool first_auth_attempt,
|
||||
content::GuestPageHolder* guest,
|
||||
LoginAuthRequiredCallback auth_required_callback) override;
|
||||
content::LoginDelegate::LoginAuthRequiredCallback auth_required_callback)
|
||||
override;
|
||||
void ExposeInterfacesToRenderer(
|
||||
service_manager::BinderRegistry* registry,
|
||||
blink::AssociatedInterfaceRegistry* associated_registry,
|
||||
|
@@ -110,7 +110,7 @@ class CefContext {
|
||||
int exit_code_ = -1;
|
||||
|
||||
// The thread on which the context was initialized.
|
||||
base::PlatformThreadId init_thread_id_ = 0;
|
||||
base::PlatformThreadId init_thread_id_;
|
||||
|
||||
CefSettings settings_;
|
||||
CefRefPtr<CefApp> application_;
|
||||
|
@@ -12,8 +12,8 @@
|
||||
#include "cef/libcef/common/api_version_util.h"
|
||||
#include "chrome/browser/about_flags.h"
|
||||
#include "chrome/browser/browser_process.h"
|
||||
#include "components/flags_ui/pref_service_flags_storage.h"
|
||||
#include "components/variations/synthetic_trials_active_group_id_provider.h"
|
||||
#include "components/webui/flags/pref_service_flags_storage.h"
|
||||
|
||||
namespace {
|
||||
|
||||
|
@@ -117,8 +117,7 @@ bool CefMainRunner::Initialize(CefSettings* settings,
|
||||
if (exit_code_ != content::RESULT_CODE_NORMAL_EXIT) {
|
||||
// Some exit codes are used to exit early, but are otherwise a normal
|
||||
// result. Don't log for those codes.
|
||||
if (!chrome::IsNormalResultCode(
|
||||
static_cast<chrome::ResultCode>(exit_code_))) {
|
||||
if (!IsNormalResultCode(static_cast<ResultCode>(exit_code_))) {
|
||||
LOG(ERROR) << "ContentMainRun failed with exit code " << exit_code_;
|
||||
}
|
||||
return false;
|
||||
@@ -460,7 +459,7 @@ void CefMainRunner::FinishShutdownOnUIThread() {
|
||||
ChromeProcessSingleton::DeleteInstance();
|
||||
}
|
||||
|
||||
static_cast<content::ContentMainRunnerImpl*>(main_runner_.get())
|
||||
static_cast<content::ContentMainRunnerImpl*>(main_runner_.get())
|
||||
->ShutdownOnUIThread();
|
||||
}
|
||||
|
||||
|
@@ -111,11 +111,12 @@ void RunCallbackOnIOThread(
|
||||
}
|
||||
} // namespace
|
||||
|
||||
LoginDelegate::LoginDelegate(const net::AuthChallengeInfo& auth_info,
|
||||
content::WebContents* web_contents,
|
||||
const content::GlobalRequestID& request_id,
|
||||
const GURL& origin_url,
|
||||
LoginAuthRequiredCallback callback)
|
||||
LoginDelegate::LoginDelegate(
|
||||
const net::AuthChallengeInfo& auth_info,
|
||||
content::WebContents* web_contents,
|
||||
const content::GlobalRequestID& request_id,
|
||||
const GURL& origin_url,
|
||||
content::LoginDelegate::LoginAuthRequiredCallback callback)
|
||||
: callback_(std::move(callback)), weak_ptr_factory_(this) {
|
||||
CEF_REQUIRE_UIT();
|
||||
|
||||
|
@@ -29,7 +29,7 @@ class LoginDelegate : public content::LoginDelegate {
|
||||
content::WebContents* web_contents,
|
||||
const content::GlobalRequestID& request_id,
|
||||
const GURL& origin_url,
|
||||
LoginAuthRequiredCallback callback);
|
||||
content::LoginDelegate::LoginAuthRequiredCallback callback);
|
||||
|
||||
void Continue(const CefString& username, const CefString& password);
|
||||
void Cancel();
|
||||
@@ -40,7 +40,7 @@ class LoginDelegate : public content::LoginDelegate {
|
||||
const content::GlobalRequestID& request_id,
|
||||
const GURL& origin_url);
|
||||
|
||||
LoginAuthRequiredCallback callback_;
|
||||
content::LoginDelegate::LoginAuthRequiredCallback callback_;
|
||||
base::WeakPtrFactory<LoginDelegate> weak_ptr_factory_;
|
||||
};
|
||||
|
||||
|
@@ -103,8 +103,8 @@ class ResourceContextData : public base::SupportsUserData::Data {
|
||||
// Maybe the browser was destroyed while AddProxyOnUIThread was pending.
|
||||
if (!web_contents) {
|
||||
// Delete on the IO thread as expected by mojo bindings.
|
||||
content::BrowserThread::DeleteSoon(content::BrowserThread::IO, FROM_HERE,
|
||||
proxy);
|
||||
content::BrowserThread::GetTaskRunnerForThread(CEF_IOT)->DeleteSoon(
|
||||
FROM_HERE, proxy);
|
||||
return;
|
||||
}
|
||||
|
||||
|
@@ -197,7 +197,7 @@ struct PopulateAxNodeAttributes {
|
||||
case ax::mojom::IntAttribute::kAriaNotificationPriorityDeprecated: {
|
||||
auto state =
|
||||
static_cast<ax::mojom::AriaNotificationPriority>(attr.second);
|
||||
if (ax::mojom::AriaNotificationPriority::kNone != state) {
|
||||
if (ax::mojom::AriaNotificationPriority::kNormal != state) {
|
||||
attributes->SetString(ToString(attr.first), ToString(state));
|
||||
}
|
||||
} break;
|
||||
|
@@ -1864,8 +1864,7 @@ void CefRenderWidgetHostViewOSR::RequestImeCompositionUpdate(
|
||||
|
||||
void CefRenderWidgetHostViewOSR::ImeCompositionRangeChanged(
|
||||
const gfx::Range& range,
|
||||
const std::optional<std::vector<gfx::Rect>>& character_bounds,
|
||||
const std::optional<std::vector<gfx::Rect>>& line_bounds) {
|
||||
const std::optional<std::vector<gfx::Rect>>& character_bounds) {
|
||||
if (browser_impl_.get()) {
|
||||
CefRange cef_range(range.start(), range.end());
|
||||
CefRenderHandler::RectList rcList;
|
||||
|
@@ -185,8 +185,7 @@ class CefRenderWidgetHostViewOSR
|
||||
viz::SurfaceId GetCurrentSurfaceId() const override;
|
||||
void ImeCompositionRangeChanged(
|
||||
const gfx::Range& range,
|
||||
const std::optional<std::vector<gfx::Rect>>& character_bounds,
|
||||
const std::optional<std::vector<gfx::Rect>>& line_bounds) override;
|
||||
const std::optional<std::vector<gfx::Rect>>& character_bounds) override;
|
||||
std::unique_ptr<content::SyntheticGestureTarget>
|
||||
CreateSyntheticGestureTarget() override;
|
||||
bool TransformPointToCoordSpaceForView(
|
||||
|
@@ -62,12 +62,12 @@ CEF_LABEL_BUTTON_IMPL_T class CefLabelButtonImpl : public CEF_BUTTON_IMPL_D {
|
||||
CEF_LABEL_BUTTON_IMPL_T void CEF_LABEL_BUTTON_IMPL_D::SetText(
|
||||
const CefString& text) {
|
||||
CEF_REQUIRE_VALID_RETURN_VOID();
|
||||
ParentClass::root_view()->SetText(text);
|
||||
ParentClass::root_view()->SetText(text.ToString16());
|
||||
}
|
||||
|
||||
CEF_LABEL_BUTTON_IMPL_T CefString CEF_LABEL_BUTTON_IMPL_D::GetText() {
|
||||
CEF_REQUIRE_VALID_RETURN(CefString());
|
||||
return ParentClass::root_view()->GetText();
|
||||
return std::u16string(ParentClass::root_view()->GetText());
|
||||
}
|
||||
|
||||
CEF_LABEL_BUTTON_IMPL_T void CEF_LABEL_BUTTON_IMPL_D::SetImage(
|
||||
|
@@ -77,12 +77,12 @@ bool CefTextfieldImpl::IsReadOnly() {
|
||||
|
||||
CefString CefTextfieldImpl::GetText() {
|
||||
CEF_REQUIRE_VALID_RETURN(CefString());
|
||||
return root_view()->GetText();
|
||||
return std::u16string(root_view()->GetText());
|
||||
}
|
||||
|
||||
void CefTextfieldImpl::SetText(const CefString& text) {
|
||||
CEF_REQUIRE_VALID_RETURN_VOID();
|
||||
root_view()->SetText(text);
|
||||
root_view()->SetText(text.ToString16());
|
||||
}
|
||||
|
||||
void CefTextfieldImpl::AppendText(const CefString& text) {
|
||||
@@ -102,7 +102,7 @@ bool CefTextfieldImpl::HasSelection() {
|
||||
|
||||
CefString CefTextfieldImpl::GetSelectedText() {
|
||||
CEF_REQUIRE_VALID_RETURN(CefString());
|
||||
return root_view()->GetSelectedText();
|
||||
return std::u16string(root_view()->GetSelectedText());
|
||||
}
|
||||
|
||||
void CefTextfieldImpl::SelectAll(bool reversed) {
|
||||
@@ -208,12 +208,12 @@ void CefTextfieldImpl::ClearEditHistory() {
|
||||
|
||||
void CefTextfieldImpl::SetPlaceholderText(const CefString& text) {
|
||||
CEF_REQUIRE_VALID_RETURN_VOID();
|
||||
root_view()->SetPlaceholderText(text);
|
||||
root_view()->SetPlaceholderText(text.ToString16());
|
||||
}
|
||||
|
||||
CefString CefTextfieldImpl::GetPlaceholderText() {
|
||||
CEF_REQUIRE_VALID_RETURN(CefString());
|
||||
return root_view()->GetPlaceholderText();
|
||||
return std::u16string(root_view()->GetPlaceholderText());
|
||||
}
|
||||
|
||||
void CefTextfieldImpl::SetPlaceholderTextColor(cef_color_t color) {
|
||||
|
@@ -11,6 +11,7 @@
|
||||
#include "cef/include/internal/cef_logging_internal.h"
|
||||
#include "cef/include/internal/cef_thread_internal.h"
|
||||
#include "cef/include/internal/cef_trace_event_internal.h"
|
||||
#include "cef/libcef/common/api_version_util.h"
|
||||
|
||||
namespace {
|
||||
|
||||
@@ -218,13 +219,13 @@ CEF_EXPORT void cef_log(const char* file,
|
||||
}
|
||||
|
||||
CEF_EXPORT cef_platform_thread_id_t cef_get_current_platform_thread_id() {
|
||||
return base::PlatformThread::CurrentId();
|
||||
return base::PlatformThread::CurrentId().raw();
|
||||
}
|
||||
|
||||
CEF_EXPORT cef_platform_thread_handle_t
|
||||
cef_get_current_platform_thread_handle() {
|
||||
#if BUILDFLAG(IS_WIN)
|
||||
return base::PlatformThread::CurrentId();
|
||||
return base::PlatformThread::CurrentId().raw();
|
||||
#else
|
||||
return base::PlatformThread::CurrentHandle().platform_handle();
|
||||
#endif
|
||||
@@ -240,5 +241,7 @@ CEF_EXPORT int cef_dump_without_crashing(long long mseconds_between_dumps,
|
||||
}
|
||||
|
||||
CEF_EXPORT int cef_dump_without_crashing_unthrottled() {
|
||||
return base::debug::DumpWithoutCrashingUnthrottled();
|
||||
CEF_API_REQUIRE_REMOVED(CEF_NEXT);
|
||||
NOTIMPLEMENTED();
|
||||
return 0;
|
||||
}
|
||||
|
@@ -62,7 +62,7 @@ bool CefCreateTempDirectoryInDirectory(const CefString& base_dir,
|
||||
base::FilePath result;
|
||||
base::FilePath::StringType prefix_str = prefix;
|
||||
if (base::CreateTemporaryDirInDir(
|
||||
base_dir, base::FilePath::StringPieceType(prefix_str), &result)) {
|
||||
base_dir, base::FilePath::StringViewType(prefix_str), &result)) {
|
||||
new_dir = result.value();
|
||||
return true;
|
||||
}
|
||||
|
@@ -114,7 +114,7 @@ bool CefThreadImpl::Create(const CefString& display_name,
|
||||
}
|
||||
|
||||
thread_task_runner_ = new CefTaskRunnerImpl(thread_->task_runner());
|
||||
thread_id_ = thread_->GetThreadId();
|
||||
thread_id_ = thread_->GetThreadId().raw();
|
||||
return true;
|
||||
}
|
||||
|
||||
|
@@ -159,7 +159,7 @@ class CefValueControllerThreadSafe : public CefValueController {
|
||||
locked_thread_id_ = base::PlatformThread::CurrentId();
|
||||
}
|
||||
void unlock() override NO_THREAD_SAFETY_ANALYSIS {
|
||||
locked_thread_id_ = 0;
|
||||
locked_thread_id_ = base::PlatformThreadId();
|
||||
lock_.Release();
|
||||
}
|
||||
bool locked() override {
|
||||
@@ -169,7 +169,7 @@ class CefValueControllerThreadSafe : public CefValueController {
|
||||
|
||||
private:
|
||||
base::Lock lock_;
|
||||
base::PlatformThreadId locked_thread_id_ = 0;
|
||||
base::PlatformThreadId locked_thread_id_;
|
||||
};
|
||||
|
||||
// Non-thread-safe access control implementation.
|
||||
|
Reference in New Issue
Block a user