2015-08-07 22:04:03 +02:00
|
|
|
// Copyright 2014 The Chromium Embedded Framework Authors. Portions copyright
|
|
|
|
// 2011 the Chromium Authors. All rights reserved. Use of this source code is
|
|
|
|
// governed by a BSD-style license that can be found in the LICENSE file.
|
|
|
|
|
|
|
|
#include "include/base/cef_build.h"
|
|
|
|
|
2014-07-11 22:10:05 +02:00
|
|
|
#include "include/internal/cef_logging_internal.h"
|
2014-07-15 00:18:51 +02:00
|
|
|
#include "include/internal/cef_thread_internal.h"
|
2017-05-17 11:29:28 +02:00
|
|
|
#include "include/internal/cef_trace_event_internal.h"
|
2014-07-11 22:10:05 +02:00
|
|
|
|
|
|
|
#include "base/logging.h"
|
2014-07-15 00:18:51 +02:00
|
|
|
#include "base/threading/platform_thread.h"
|
2015-03-04 02:00:13 +01:00
|
|
|
#include "base/trace_event/trace_event.h"
|
2014-07-11 22:10:05 +02:00
|
|
|
|
2022-01-24 18:58:02 +01:00
|
|
|
#if BUILDFLAG(IS_WIN)
|
2018-02-20 23:24:59 +01:00
|
|
|
#include "base/win/win_util.h"
|
|
|
|
#endif
|
2015-08-07 22:04:03 +02:00
|
|
|
|
2018-11-30 23:21:07 +01:00
|
|
|
namespace {
|
|
|
|
|
|
|
|
constexpr const char kCategory[] = "cef.client";
|
|
|
|
|
|
|
|
} // namespace
|
|
|
|
|
|
|
|
CEF_EXPORT void cef_trace_event_instant(const char* /* category */,
|
2014-07-11 22:10:05 +02:00
|
|
|
const char* name,
|
|
|
|
const char* arg1_name,
|
|
|
|
uint64 arg1_val,
|
|
|
|
const char* arg2_name,
|
|
|
|
uint64 arg2_val,
|
|
|
|
int copy) {
|
|
|
|
DCHECK(name);
|
2018-11-30 23:21:07 +01:00
|
|
|
if (!name)
|
2014-07-11 22:10:05 +02:00
|
|
|
return;
|
|
|
|
|
|
|
|
if (copy) {
|
2020-01-15 14:36:24 +01:00
|
|
|
if (arg1_name == nullptr && arg2_name == nullptr) {
|
2018-11-30 23:21:07 +01:00
|
|
|
TRACE_EVENT_COPY_INSTANT0(kCategory, name, TRACE_EVENT_SCOPE_THREAD);
|
2020-01-15 14:36:24 +01:00
|
|
|
} else if (arg2_name == nullptr) {
|
2018-11-30 23:21:07 +01:00
|
|
|
TRACE_EVENT_COPY_INSTANT1(kCategory, name, TRACE_EVENT_SCOPE_THREAD,
|
2014-07-11 22:10:05 +02:00
|
|
|
arg1_name, arg1_val);
|
|
|
|
} else {
|
2018-11-30 23:21:07 +01:00
|
|
|
TRACE_EVENT_COPY_INSTANT2(kCategory, name, TRACE_EVENT_SCOPE_THREAD,
|
2014-07-11 22:10:05 +02:00
|
|
|
arg1_name, arg1_val, arg2_name, arg2_val);
|
|
|
|
}
|
|
|
|
} else {
|
2020-01-15 14:36:24 +01:00
|
|
|
if (arg1_name == nullptr && arg2_name == nullptr) {
|
2018-11-30 23:21:07 +01:00
|
|
|
TRACE_EVENT_INSTANT0(kCategory, name, TRACE_EVENT_SCOPE_THREAD);
|
2020-01-15 14:36:24 +01:00
|
|
|
} else if (arg2_name == nullptr) {
|
2018-11-30 23:21:07 +01:00
|
|
|
TRACE_EVENT_INSTANT1(kCategory, name, TRACE_EVENT_SCOPE_THREAD, arg1_name,
|
2017-05-17 11:29:28 +02:00
|
|
|
arg1_val);
|
2014-07-11 22:10:05 +02:00
|
|
|
} else {
|
2018-11-30 23:21:07 +01:00
|
|
|
TRACE_EVENT_INSTANT2(kCategory, name, TRACE_EVENT_SCOPE_THREAD, arg1_name,
|
2017-05-17 11:29:28 +02:00
|
|
|
arg1_val, arg2_name, arg2_val);
|
2014-07-11 22:10:05 +02:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2018-11-30 23:21:07 +01:00
|
|
|
CEF_EXPORT void cef_trace_event_begin(const char* /* category */,
|
2014-07-11 22:10:05 +02:00
|
|
|
const char* name,
|
|
|
|
const char* arg1_name,
|
|
|
|
uint64 arg1_val,
|
|
|
|
const char* arg2_name,
|
|
|
|
uint64 arg2_val,
|
|
|
|
int copy) {
|
|
|
|
DCHECK(name);
|
2018-11-30 23:21:07 +01:00
|
|
|
if (!name)
|
2014-07-11 22:10:05 +02:00
|
|
|
return;
|
|
|
|
|
|
|
|
if (copy) {
|
2020-01-15 14:36:24 +01:00
|
|
|
if (arg1_name == nullptr && arg2_name == nullptr) {
|
2019-09-04 17:13:32 +02:00
|
|
|
TRACE_EVENT_BEGIN_WITH_FLAGS0(kCategory, name, TRACE_EVENT_FLAG_COPY);
|
2020-01-15 14:36:24 +01:00
|
|
|
} else if (arg2_name == nullptr) {
|
2019-09-04 17:13:32 +02:00
|
|
|
TRACE_EVENT_BEGIN_WITH_FLAGS1(kCategory, name, TRACE_EVENT_FLAG_COPY,
|
|
|
|
arg1_name, arg1_val);
|
2014-07-11 22:10:05 +02:00
|
|
|
} else {
|
2018-11-30 23:21:07 +01:00
|
|
|
TRACE_EVENT_COPY_BEGIN2(kCategory, name, arg1_name, arg1_val, arg2_name,
|
2017-05-17 11:29:28 +02:00
|
|
|
arg2_val);
|
2014-07-11 22:10:05 +02:00
|
|
|
}
|
|
|
|
} else {
|
2020-01-15 14:36:24 +01:00
|
|
|
if (arg1_name == nullptr && arg2_name == nullptr) {
|
2018-11-30 23:21:07 +01:00
|
|
|
TRACE_EVENT_BEGIN0(kCategory, name);
|
2020-01-15 14:36:24 +01:00
|
|
|
} else if (arg2_name == nullptr) {
|
2018-11-30 23:21:07 +01:00
|
|
|
TRACE_EVENT_BEGIN1(kCategory, name, arg1_name, arg1_val);
|
2014-07-11 22:10:05 +02:00
|
|
|
} else {
|
2018-11-30 23:21:07 +01:00
|
|
|
TRACE_EVENT_BEGIN2(kCategory, name, arg1_name, arg1_val, arg2_name,
|
2017-05-17 11:29:28 +02:00
|
|
|
arg2_val);
|
2014-07-11 22:10:05 +02:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2018-11-30 23:21:07 +01:00
|
|
|
CEF_EXPORT void cef_trace_event_end(const char* /* category */,
|
2014-07-11 22:10:05 +02:00
|
|
|
const char* name,
|
|
|
|
const char* arg1_name,
|
|
|
|
uint64 arg1_val,
|
|
|
|
const char* arg2_name,
|
|
|
|
uint64 arg2_val,
|
|
|
|
int copy) {
|
|
|
|
DCHECK(name);
|
2018-11-30 23:21:07 +01:00
|
|
|
if (!name)
|
2014-07-11 22:10:05 +02:00
|
|
|
return;
|
|
|
|
|
|
|
|
if (copy) {
|
2020-01-15 14:36:24 +01:00
|
|
|
if (arg1_name == nullptr && arg2_name == nullptr) {
|
2019-09-04 17:13:32 +02:00
|
|
|
TRACE_EVENT_END_WITH_FLAGS0(kCategory, name, TRACE_EVENT_FLAG_COPY);
|
2020-01-15 14:36:24 +01:00
|
|
|
} else if (arg2_name == nullptr) {
|
2019-09-04 17:13:32 +02:00
|
|
|
TRACE_EVENT_END_WITH_FLAGS1(kCategory, name, TRACE_EVENT_FLAG_COPY,
|
|
|
|
arg1_name, arg1_val);
|
2014-07-11 22:10:05 +02:00
|
|
|
} else {
|
2018-11-30 23:21:07 +01:00
|
|
|
TRACE_EVENT_COPY_END2(kCategory, name, arg1_name, arg1_val, arg2_name,
|
2017-05-17 11:29:28 +02:00
|
|
|
arg2_val);
|
2014-07-11 22:10:05 +02:00
|
|
|
}
|
|
|
|
} else {
|
2020-01-15 14:36:24 +01:00
|
|
|
if (arg1_name == nullptr && arg2_name == nullptr) {
|
2018-11-30 23:21:07 +01:00
|
|
|
TRACE_EVENT_END0(kCategory, name);
|
2020-01-15 14:36:24 +01:00
|
|
|
} else if (arg2_name == nullptr) {
|
2018-11-30 23:21:07 +01:00
|
|
|
TRACE_EVENT_END1(kCategory, name, arg1_name, arg1_val);
|
2014-07-11 22:10:05 +02:00
|
|
|
} else {
|
2018-11-30 23:21:07 +01:00
|
|
|
TRACE_EVENT_END2(kCategory, name, arg1_name, arg1_val, arg2_name,
|
2017-05-17 11:29:28 +02:00
|
|
|
arg2_val);
|
2014-07-11 22:10:05 +02:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2018-11-30 23:21:07 +01:00
|
|
|
CEF_EXPORT void cef_trace_counter(const char* /* category */,
|
2014-07-11 22:10:05 +02:00
|
|
|
const char* name,
|
|
|
|
const char* value1_name,
|
|
|
|
uint64 value1_val,
|
|
|
|
const char* value2_name,
|
|
|
|
uint64 value2_val,
|
|
|
|
int copy) {
|
|
|
|
DCHECK(name);
|
2018-11-30 23:21:07 +01:00
|
|
|
if (!name)
|
2014-07-11 22:10:05 +02:00
|
|
|
return;
|
|
|
|
|
|
|
|
if (copy) {
|
2020-01-15 14:36:24 +01:00
|
|
|
if (value1_name == nullptr && value2_name == nullptr) {
|
2018-11-30 23:21:07 +01:00
|
|
|
TRACE_COPY_COUNTER1(kCategory, name, value1_val);
|
2014-07-11 22:10:05 +02:00
|
|
|
} else {
|
2018-11-30 23:21:07 +01:00
|
|
|
TRACE_COPY_COUNTER2(kCategory, name, value1_name, value1_val, value2_name,
|
2017-05-17 11:29:28 +02:00
|
|
|
value2_val);
|
2014-07-11 22:10:05 +02:00
|
|
|
}
|
|
|
|
} else {
|
2020-01-15 14:36:24 +01:00
|
|
|
if (value1_name == nullptr && value2_name == nullptr) {
|
2018-11-30 23:21:07 +01:00
|
|
|
TRACE_COUNTER1(kCategory, name, value1_val);
|
2014-07-11 22:10:05 +02:00
|
|
|
} else {
|
2018-11-30 23:21:07 +01:00
|
|
|
TRACE_COUNTER2(kCategory, name, value1_name, value1_val, value2_name,
|
2017-05-17 11:29:28 +02:00
|
|
|
value2_val);
|
2014-07-11 22:10:05 +02:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2018-11-30 23:21:07 +01:00
|
|
|
CEF_EXPORT void cef_trace_counter_id(const char* /* category */,
|
2014-07-11 22:10:05 +02:00
|
|
|
const char* name,
|
|
|
|
uint64 id,
|
|
|
|
const char* value1_name,
|
|
|
|
uint64 value1_val,
|
|
|
|
const char* value2_name,
|
|
|
|
uint64 value2_val,
|
|
|
|
int copy) {
|
|
|
|
DCHECK(name);
|
2018-11-30 23:21:07 +01:00
|
|
|
if (!name)
|
2014-07-11 22:10:05 +02:00
|
|
|
return;
|
|
|
|
|
|
|
|
if (copy) {
|
2020-01-15 14:36:24 +01:00
|
|
|
if (value1_name == nullptr && value2_name == nullptr) {
|
2018-11-30 23:21:07 +01:00
|
|
|
TRACE_COPY_COUNTER_ID1(kCategory, name, id, value1_val);
|
2014-07-11 22:10:05 +02:00
|
|
|
} else {
|
2018-11-30 23:21:07 +01:00
|
|
|
TRACE_COPY_COUNTER_ID2(kCategory, name, id, value1_name, value1_val,
|
2017-05-17 11:29:28 +02:00
|
|
|
value2_name, value2_val);
|
2014-07-11 22:10:05 +02:00
|
|
|
}
|
|
|
|
} else {
|
2020-01-15 14:36:24 +01:00
|
|
|
if (value1_name == nullptr && value2_name == nullptr) {
|
2018-11-30 23:21:07 +01:00
|
|
|
TRACE_COUNTER_ID1(kCategory, name, id, value1_val);
|
2014-07-11 22:10:05 +02:00
|
|
|
} else {
|
2018-11-30 23:21:07 +01:00
|
|
|
TRACE_COUNTER_ID2(kCategory, name, id, value1_name, value1_val,
|
2014-07-11 22:10:05 +02:00
|
|
|
value2_name, value2_val);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2018-11-30 23:21:07 +01:00
|
|
|
CEF_EXPORT void cef_trace_event_async_begin(const char* /* category */,
|
2014-07-11 22:10:05 +02:00
|
|
|
const char* name,
|
|
|
|
uint64 id,
|
|
|
|
const char* arg1_name,
|
|
|
|
uint64 arg1_val,
|
|
|
|
const char* arg2_name,
|
|
|
|
uint64 arg2_val,
|
|
|
|
int copy) {
|
|
|
|
DCHECK(name);
|
2018-11-30 23:21:07 +01:00
|
|
|
if (!name)
|
2014-07-11 22:10:05 +02:00
|
|
|
return;
|
|
|
|
|
|
|
|
if (copy) {
|
2020-01-15 14:36:24 +01:00
|
|
|
if (arg1_name == nullptr && arg2_name == nullptr) {
|
2018-11-30 23:21:07 +01:00
|
|
|
TRACE_EVENT_COPY_ASYNC_BEGIN0(kCategory, name, id);
|
2020-01-15 14:36:24 +01:00
|
|
|
} else if (arg2_name == nullptr) {
|
2018-11-30 23:21:07 +01:00
|
|
|
TRACE_EVENT_COPY_ASYNC_BEGIN1(kCategory, name, id, arg1_name, arg1_val);
|
2014-07-11 22:10:05 +02:00
|
|
|
} else {
|
2018-11-30 23:21:07 +01:00
|
|
|
TRACE_EVENT_COPY_ASYNC_BEGIN2(kCategory, name, id, arg1_name, arg1_val,
|
2014-07-11 22:10:05 +02:00
|
|
|
arg2_name, arg2_val);
|
|
|
|
}
|
|
|
|
} else {
|
2020-01-15 14:36:24 +01:00
|
|
|
if (arg1_name == nullptr && arg2_name == nullptr) {
|
2018-11-30 23:21:07 +01:00
|
|
|
TRACE_EVENT_ASYNC_BEGIN0(kCategory, name, id);
|
2020-01-15 14:36:24 +01:00
|
|
|
} else if (arg2_name == nullptr) {
|
2018-11-30 23:21:07 +01:00
|
|
|
TRACE_EVENT_ASYNC_BEGIN1(kCategory, name, id, arg1_name, arg1_val);
|
2014-07-11 22:10:05 +02:00
|
|
|
} else {
|
2018-11-30 23:21:07 +01:00
|
|
|
TRACE_EVENT_ASYNC_BEGIN2(kCategory, name, id, arg1_name, arg1_val,
|
2014-07-11 22:10:05 +02:00
|
|
|
arg2_name, arg2_val);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2018-11-30 23:21:07 +01:00
|
|
|
CEF_EXPORT void cef_trace_event_async_step_into(const char* /* category */,
|
2014-07-11 22:10:05 +02:00
|
|
|
const char* name,
|
|
|
|
uint64 id,
|
|
|
|
uint64 step,
|
|
|
|
const char* arg1_name,
|
|
|
|
uint64 arg1_val,
|
|
|
|
int copy) {
|
|
|
|
DCHECK(name);
|
2018-11-30 23:21:07 +01:00
|
|
|
if (!name)
|
2014-07-11 22:10:05 +02:00
|
|
|
return;
|
|
|
|
|
|
|
|
if (copy) {
|
2020-01-15 14:36:24 +01:00
|
|
|
if (arg1_name == nullptr) {
|
2014-07-11 22:10:05 +02:00
|
|
|
INTERNAL_TRACE_EVENT_ADD_WITH_ID(TRACE_EVENT_PHASE_ASYNC_STEP_INTO,
|
2018-11-30 23:21:07 +01:00
|
|
|
kCategory, name, id,
|
2017-05-17 11:29:28 +02:00
|
|
|
TRACE_EVENT_FLAG_COPY, "step", step);
|
2014-07-11 22:10:05 +02:00
|
|
|
} else {
|
2017-05-17 11:29:28 +02:00
|
|
|
INTERNAL_TRACE_EVENT_ADD_WITH_ID(
|
2018-11-30 23:21:07 +01:00
|
|
|
TRACE_EVENT_PHASE_ASYNC_STEP_INTO, kCategory, name, id,
|
2017-05-17 11:29:28 +02:00
|
|
|
TRACE_EVENT_FLAG_COPY, "step", step, arg1_name, arg1_val);
|
2014-07-11 22:10:05 +02:00
|
|
|
}
|
|
|
|
} else {
|
2020-01-15 14:36:24 +01:00
|
|
|
if (arg1_name == nullptr) {
|
2018-11-30 23:21:07 +01:00
|
|
|
TRACE_EVENT_ASYNC_STEP_INTO0(kCategory, name, id, step);
|
2014-07-11 22:10:05 +02:00
|
|
|
} else {
|
2018-11-30 23:21:07 +01:00
|
|
|
TRACE_EVENT_ASYNC_STEP_INTO1(kCategory, name, id, step, arg1_name,
|
2017-05-17 11:29:28 +02:00
|
|
|
arg1_val);
|
2014-07-11 22:10:05 +02:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2018-11-30 23:21:07 +01:00
|
|
|
CEF_EXPORT void cef_trace_event_async_step_past(const char* /* category */,
|
2014-07-11 22:10:05 +02:00
|
|
|
const char* name,
|
|
|
|
uint64 id,
|
|
|
|
uint64 step,
|
|
|
|
const char* arg1_name,
|
|
|
|
uint64 arg1_val,
|
|
|
|
int copy) {
|
|
|
|
DCHECK(name);
|
2018-11-30 23:21:07 +01:00
|
|
|
if (!name)
|
2014-07-11 22:10:05 +02:00
|
|
|
return;
|
|
|
|
|
|
|
|
if (copy) {
|
2020-01-15 14:36:24 +01:00
|
|
|
if (arg1_name == nullptr) {
|
2014-07-11 22:10:05 +02:00
|
|
|
INTERNAL_TRACE_EVENT_ADD_WITH_ID(TRACE_EVENT_PHASE_ASYNC_STEP_PAST,
|
2018-11-30 23:21:07 +01:00
|
|
|
kCategory, name, id,
|
2017-05-17 11:29:28 +02:00
|
|
|
TRACE_EVENT_FLAG_COPY, "step", step);
|
2014-07-11 22:10:05 +02:00
|
|
|
} else {
|
2017-05-17 11:29:28 +02:00
|
|
|
INTERNAL_TRACE_EVENT_ADD_WITH_ID(
|
2018-11-30 23:21:07 +01:00
|
|
|
TRACE_EVENT_PHASE_ASYNC_STEP_PAST, kCategory, name, id,
|
2017-05-17 11:29:28 +02:00
|
|
|
TRACE_EVENT_FLAG_COPY, "step", step, arg1_name, arg1_val);
|
2014-07-11 22:10:05 +02:00
|
|
|
}
|
|
|
|
} else {
|
2020-01-15 14:36:24 +01:00
|
|
|
if (arg1_name == nullptr) {
|
2018-11-30 23:21:07 +01:00
|
|
|
TRACE_EVENT_ASYNC_STEP_PAST0(kCategory, name, id, step);
|
2014-07-11 22:10:05 +02:00
|
|
|
} else {
|
2018-11-30 23:21:07 +01:00
|
|
|
TRACE_EVENT_ASYNC_STEP_PAST1(kCategory, name, id, step, arg1_name,
|
2017-05-17 11:29:28 +02:00
|
|
|
arg1_val);
|
2014-07-11 22:10:05 +02:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2018-11-30 23:21:07 +01:00
|
|
|
CEF_EXPORT void cef_trace_event_async_end(const char* /* category */,
|
2014-07-11 22:10:05 +02:00
|
|
|
const char* name,
|
|
|
|
uint64 id,
|
|
|
|
const char* arg1_name,
|
|
|
|
uint64 arg1_val,
|
|
|
|
const char* arg2_name,
|
|
|
|
uint64 arg2_val,
|
|
|
|
int copy) {
|
|
|
|
DCHECK(name);
|
2018-11-30 23:21:07 +01:00
|
|
|
if (!name)
|
2014-07-11 22:10:05 +02:00
|
|
|
return;
|
|
|
|
|
|
|
|
if (copy) {
|
2020-01-15 14:36:24 +01:00
|
|
|
if (arg1_name == nullptr && arg2_name == nullptr) {
|
2018-11-30 23:21:07 +01:00
|
|
|
TRACE_EVENT_COPY_ASYNC_END0(kCategory, name, id);
|
2020-01-15 14:36:24 +01:00
|
|
|
} else if (arg2_name == nullptr) {
|
2018-11-30 23:21:07 +01:00
|
|
|
TRACE_EVENT_COPY_ASYNC_END1(kCategory, name, id, arg1_name, arg1_val);
|
2014-07-11 22:10:05 +02:00
|
|
|
} else {
|
2018-11-30 23:21:07 +01:00
|
|
|
TRACE_EVENT_COPY_ASYNC_END2(kCategory, name, id, arg1_name, arg1_val,
|
2017-05-17 11:29:28 +02:00
|
|
|
arg2_name, arg2_val);
|
2014-07-11 22:10:05 +02:00
|
|
|
}
|
|
|
|
} else {
|
2020-01-15 14:36:24 +01:00
|
|
|
if (arg1_name == nullptr && arg2_name == nullptr) {
|
2018-11-30 23:21:07 +01:00
|
|
|
TRACE_EVENT_ASYNC_END0(kCategory, name, id);
|
2020-01-15 14:36:24 +01:00
|
|
|
} else if (arg2_name == nullptr) {
|
2018-11-30 23:21:07 +01:00
|
|
|
TRACE_EVENT_ASYNC_END1(kCategory, name, id, arg1_name, arg1_val);
|
2014-07-11 22:10:05 +02:00
|
|
|
} else {
|
2018-11-30 23:21:07 +01:00
|
|
|
TRACE_EVENT_ASYNC_END2(kCategory, name, id, arg1_name, arg1_val,
|
|
|
|
arg2_name, arg2_val);
|
2014-07-11 22:10:05 +02:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
CEF_EXPORT int cef_get_min_log_level() {
|
|
|
|
return logging::GetMinLogLevel();
|
|
|
|
}
|
|
|
|
|
|
|
|
CEF_EXPORT int cef_get_vlog_level(const char* file_start, size_t N) {
|
|
|
|
return logging::GetVlogLevelHelper(file_start, N);
|
|
|
|
}
|
|
|
|
|
|
|
|
CEF_EXPORT void cef_log(const char* file,
|
|
|
|
int line,
|
|
|
|
int severity,
|
|
|
|
const char* message) {
|
|
|
|
logging::LogMessage(file, line, severity).stream() << message;
|
|
|
|
}
|
2014-07-15 00:18:51 +02:00
|
|
|
|
|
|
|
CEF_EXPORT cef_platform_thread_id_t cef_get_current_platform_thread_id() {
|
|
|
|
return base::PlatformThread::CurrentId();
|
|
|
|
}
|
|
|
|
|
|
|
|
CEF_EXPORT cef_platform_thread_handle_t
|
2017-05-17 11:29:28 +02:00
|
|
|
cef_get_current_platform_thread_handle() {
|
2022-01-24 18:58:02 +01:00
|
|
|
#if BUILDFLAG(IS_WIN)
|
2014-07-15 00:18:51 +02:00
|
|
|
return base::PlatformThread::CurrentId();
|
|
|
|
#else
|
|
|
|
return base::PlatformThread::CurrentHandle().platform_handle();
|
|
|
|
#endif
|
|
|
|
}
|
2015-08-07 22:04:03 +02:00
|
|
|
|
|
|
|
void CefEnableHighDPISupport() {
|
2022-01-24 18:58:02 +01:00
|
|
|
#if BUILDFLAG(IS_WIN)
|
2018-02-20 23:24:59 +01:00
|
|
|
base::win::EnableHighDPISupport();
|
2015-08-07 22:04:03 +02:00
|
|
|
#endif
|
|
|
|
}
|