mirror of
https://bitbucket.org/chromiumembedded/cef
synced 2025-06-05 21:39:12 +02:00
Compare commits
44 Commits
Author | SHA1 | Date | |
---|---|---|---|
|
21130e0144 | ||
|
91e8c06f29 | ||
|
749b4d4340 | ||
|
fcd259c3e0 | ||
|
a61da9b80c | ||
|
9cc8df1534 | ||
|
aa348cb3de | ||
|
75c3bf0480 | ||
|
a8d552a01b | ||
|
89aff51c04 | ||
|
4e9a80a23d | ||
|
557c3ad6e7 | ||
|
521608d3c2 | ||
|
d1d2d6a532 | ||
|
419ffdb122 | ||
|
5dbfe13ac8 | ||
|
061204d5be | ||
|
cf87de98bc | ||
|
ed5af5272d | ||
|
be022e26bc | ||
|
096e3eb30d | ||
|
7bcc232ecf | ||
|
30c8e3634d | ||
|
82da225a9f | ||
|
e43eab3229 | ||
|
6355aaf33b | ||
|
e53bff712a | ||
|
b854992ae6 | ||
|
5042d71408 | ||
|
695ee2a041 | ||
|
cf8b7db4b4 | ||
|
5d8c6799fc | ||
|
bd368f5d3a | ||
|
87a04aba03 | ||
|
df4dddee0b | ||
|
eb63f9e7ae | ||
|
29b5999fd7 | ||
|
5707889555 | ||
|
ecdfd467f8 | ||
|
e5334a5a18 | ||
|
e5c4b27366 | ||
|
c18545a7f5 | ||
|
dc9e64308a | ||
|
b8e1c6a59d |
10
BUILD.gn
10
BUILD.gn
@@ -801,6 +801,7 @@ source_set("libcef_static") {
|
||||
"libcef/browser/views/view_util.cc",
|
||||
"libcef/browser/views/view_util.h",
|
||||
"libcef/browser/views/view_view.h",
|
||||
"libcef/browser/views/widget_destruction_observer.h",
|
||||
"libcef/browser/views/window_impl.cc",
|
||||
"libcef/browser/views/window_impl.h",
|
||||
"libcef/browser/views/window_view.cc",
|
||||
@@ -1156,6 +1157,8 @@ source_set("libcef_static") {
|
||||
"//chrome/app/chrome_main_mac.h",
|
||||
"//chrome/app/chrome_main_mac.mm",
|
||||
]
|
||||
|
||||
configs += [ "//build/config/compiler:enable_arc" ]
|
||||
}
|
||||
|
||||
if (ozone_platform_x11) {
|
||||
@@ -1351,9 +1354,10 @@ make_pack_header("resources") {
|
||||
"$root_gen_dir/content/browser/tracing/grit/tracing_resources.h",
|
||||
"$root_gen_dir/content/browser/webrtc/resources/grit/webrtc_internals_resources.h",
|
||||
"$root_gen_dir/content/grit/content_resources.h",
|
||||
"$root_gen_dir/content/grit/dev_ui_content_resources.h",
|
||||
"$root_gen_dir/content/grit/gpu_resources.h",
|
||||
"$root_gen_dir/content/grit/histograms_resources.h",
|
||||
"$root_gen_dir/content/grit/process_resources.h",
|
||||
"$root_gen_dir/content/grit/service_worker_resources.h",
|
||||
"$root_gen_dir/extensions/grit/extensions_browser_resources.h",
|
||||
"$root_gen_dir/extensions/grit/extensions_renderer_resources.h",
|
||||
"$root_gen_dir/extensions/grit/extensions_resources.h",
|
||||
@@ -1379,10 +1383,11 @@ make_pack_header("resources") {
|
||||
"//content/browser/devtools:devtools_resources",
|
||||
"//content/browser/resources/gpu:resources",
|
||||
"//content/browser/resources/histograms:resources",
|
||||
"//content/browser/resources/process:resources",
|
||||
"//content/browser/resources/service_worker:resources",
|
||||
"//content/browser/tracing:resources",
|
||||
"//content/browser/webrtc/resources",
|
||||
"//content:content_resources",
|
||||
"//content:dev_ui_content_resources",
|
||||
"//extensions:extensions_browser_resources",
|
||||
"//extensions:extensions_renderer_resources",
|
||||
"//extensions:extensions_resources_grd",
|
||||
@@ -1602,6 +1607,7 @@ if (is_mac) {
|
||||
|
||||
configs += [
|
||||
":libcef_autogen_config",
|
||||
"//build/config/compiler:enable_arc",
|
||||
]
|
||||
|
||||
# We don't link the framework so just use the path from the main executable.
|
||||
|
@@ -7,5 +7,6 @@
|
||||
# https://bitbucket.org/chromiumembedded/cef/wiki/BranchesAndBuilding
|
||||
|
||||
{
|
||||
'chromium_checkout': 'refs/tags/114.0.5735.0'
|
||||
'chromium_checkout': 'refs/tags/115.0.5790.173',
|
||||
'depot_tools_checkout': '6d0c235dae'
|
||||
}
|
||||
|
@@ -13,7 +13,7 @@
|
||||
#
|
||||
# Linux: Ninja, GCC 7.5.0+, Unix Makefiles
|
||||
# MacOS: Ninja, Xcode 12.2 to 13.0
|
||||
# Windows: Ninja, Visual Studio 2019+
|
||||
# Windows: Ninja, Visual Studio 2022
|
||||
#
|
||||
# Ninja is a cross-platform open-source tool for running fast builds using
|
||||
# pre-installed platform toolchains (GNU, clang, Xcode or MSVC). It can be
|
||||
@@ -54,9 +54,9 @@
|
||||
# recommended.
|
||||
#
|
||||
# - Windows requirements:
|
||||
# Visual Studio 2019 or newer building on Windows 10 or newer. Windows 10
|
||||
# 64-bit is recommended. Newer versions will likely also work but may not have
|
||||
# been tested.
|
||||
# Visual Studio 2022 building on Windows 10 or newer. Windows 10/11 64-bit is
|
||||
# recommended. Newer versions will likely also work but may not have been
|
||||
# tested.
|
||||
#
|
||||
# BUILD EXAMPLES
|
||||
#
|
||||
@@ -96,35 +96,35 @@
|
||||
# > ninja cefclient cefsimple
|
||||
#
|
||||
# To perform a Windows build using a 32-bit CEF binary distribution:
|
||||
# Using the Visual Studio 2019 IDE:
|
||||
# > cmake -G "Visual Studio 16" -A Win32 ..
|
||||
# Using the Visual Studio 2022 IDE:
|
||||
# > cmake -G "Visual Studio 17" -A Win32 ..
|
||||
# Open build\cef.sln in Visual Studio and select Build > Build Solution.
|
||||
#
|
||||
# Using Ninja with Visual Studio 2019 command-line tools:
|
||||
# Using Ninja with Visual Studio 2022 command-line tools:
|
||||
# (this path may be different depending on your Visual Studio installation)
|
||||
# > "C:\Program Files (x86)\Microsoft Visual Studio\2019\Professional\VC\Auxiliary\Build\vcvars32.bat"
|
||||
# > "C:\Program Files\Microsoft Visual Studio\2022\Professional\VC\Auxiliary\Build\vcvars32.bat"
|
||||
# > cmake -G "Ninja" -DCMAKE_BUILD_TYPE=Debug ..
|
||||
# > ninja cefclient cefsimple
|
||||
#
|
||||
# To perform a Windows build using a 64-bit CEF binary distribution:
|
||||
# Using the Visual Studio 2019 IDE:
|
||||
# > cmake -G "Visual Studio 16" -A x64 ..
|
||||
# Using the Visual Studio 2022 IDE:
|
||||
# > cmake -G "Visual Studio 17" -A x64 ..
|
||||
# Open build\cef.sln in Visual Studio and select Build > Build Solution.
|
||||
#
|
||||
# Using Ninja with Visual Studio 2019 command-line tools:
|
||||
# Using Ninja with Visual Studio 2022 command-line tools:
|
||||
# (this path may be different depending on your Visual Studio installation)
|
||||
# > "C:\Program Files (x86)\Microsoft Visual Studio\2019\Professional\VC\Auxiliary\Build\vcvars64.bat"
|
||||
# > "C:\Program Files\Microsoft Visual Studio\2022\Professional\VC\Auxiliary\Build\vcvars64.bat"
|
||||
# > cmake -G "Ninja" -DCMAKE_BUILD_TYPE=Debug ..
|
||||
# > ninja cefclient cefsimple
|
||||
#
|
||||
# To perform a Windows build using an ARM64 CEF binary distribution:
|
||||
# Using the Visual Studio 2019 IDE:
|
||||
# > cmake -G "Visual Studio 16" -A arm64 ..
|
||||
# Using the Visual Studio 2022 IDE:
|
||||
# > cmake -G "Visual Studio 17" -A arm64 ..
|
||||
# Open build\cef.sln in Visual Studio and select Build > Build Solution.
|
||||
#
|
||||
# Using Ninja with Visual Studio 2019 command-line tools:
|
||||
# Using Ninja with Visual Studio 2022 command-line tools:
|
||||
# (this path may be different depending on your Visual Studio installation)
|
||||
# > "C:\Program Files (x86)\Microsoft Visual Studio\2019\Professional\VC\Auxiliary\Build\vcvarsamd64_arm64.bat"
|
||||
# > "C:\Program Files\Microsoft Visual Studio\2022\Professional\VC\Auxiliary\Build\vcvarsamd64_arm64.bat"
|
||||
# > cmake -G "Ninja" -DCMAKE_BUILD_TYPE=Debug ..
|
||||
# > ninja cefsimple
|
||||
|
||||
@@ -132,8 +132,8 @@
|
||||
# Global setup.
|
||||
#
|
||||
|
||||
# For VS2019 and Xcode 12+ support.
|
||||
cmake_minimum_required(VERSION 3.19)
|
||||
# For VS2022 and Xcode 12+ support.
|
||||
cmake_minimum_required(VERSION 3.21)
|
||||
|
||||
# Only generate Debug and Release configuration types.
|
||||
set(CMAKE_CONFIGURATION_TYPES Debug Release)
|
||||
|
@@ -8,7 +8,6 @@
|
||||
'include/base/cef_atomic_flag.h',
|
||||
'include/base/cef_atomic_ref_count.h',
|
||||
'include/base/cef_auto_reset.h',
|
||||
'include/base/cef_basictypes.h',
|
||||
'include/base/cef_bind.h',
|
||||
'include/base/cef_build.h',
|
||||
'include/base/cef_callback.h',
|
||||
@@ -55,6 +54,7 @@
|
||||
'include/internal/cef_time.h',
|
||||
'include/internal/cef_trace_event_internal.h',
|
||||
'include/internal/cef_types.h',
|
||||
'include/internal/cef_types_content_settings.h',
|
||||
'include/internal/cef_types_geometry.h',
|
||||
],
|
||||
'includes_capi': [
|
||||
|
@@ -493,6 +493,7 @@ if(OS_WINDOWS)
|
||||
# List of CEF binary files.
|
||||
set(CEF_BINARY_FILES
|
||||
chrome_elf.dll
|
||||
d3dcompiler_47.dll
|
||||
libcef.dll
|
||||
libEGL.dll
|
||||
libGLESv2.dll
|
||||
@@ -503,12 +504,6 @@ if(OS_WINDOWS)
|
||||
vulkan-1.dll
|
||||
)
|
||||
|
||||
if(NOT PROJECT_ARCH STREQUAL "arm64")
|
||||
list(APPEND CEF_BINARY_FILES
|
||||
d3dcompiler_47.dll
|
||||
)
|
||||
endif()
|
||||
|
||||
# List of CEF resource files.
|
||||
set(CEF_RESOURCE_FILES
|
||||
chrome_100_percent.pak
|
||||
|
@@ -1,86 +0,0 @@
|
||||
// Copyright (c) 2014 Marshall A. Greenblatt. Portions copyright (c) 2012
|
||||
// Google Inc. All rights reserved.
|
||||
//
|
||||
// Redistribution and use in source and binary forms, with or without
|
||||
// modification, are permitted provided that the following conditions are
|
||||
// met:
|
||||
//
|
||||
// * Redistributions of source code must retain the above copyright
|
||||
// notice, this list of conditions and the following disclaimer.
|
||||
// * Redistributions in binary form must reproduce the above
|
||||
// copyright notice, this list of conditions and the following disclaimer
|
||||
// in the documentation and/or other materials provided with the
|
||||
// distribution.
|
||||
// * Neither the name of Google Inc. nor the name Chromium Embedded
|
||||
// Framework nor the names of its contributors may be used to endorse
|
||||
// or promote products derived from this software without specific prior
|
||||
// written permission.
|
||||
//
|
||||
// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
|
||||
// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
|
||||
// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
|
||||
// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
|
||||
// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
|
||||
// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
||||
// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
||||
// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
||||
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
#ifndef CEF_INCLUDE_BASE_CEF_BASICTYPES_H_
|
||||
#define CEF_INCLUDE_BASE_CEF_BASICTYPES_H_
|
||||
#pragma once
|
||||
|
||||
#include <limits.h> // For UINT_MAX
|
||||
#include <stddef.h> // For size_t
|
||||
|
||||
#include "include/base/cef_build.h"
|
||||
|
||||
// The NSPR system headers define 64-bit as |long| when possible, except on
|
||||
// Mac OS X. In order to not have typedef mismatches, we do the same on LP64.
|
||||
//
|
||||
// On Mac OS X, |long long| is used for 64-bit types for compatibility with
|
||||
// <inttypes.h> format macros even in the LP64 model.
|
||||
#if defined(__LP64__) && !defined(OS_MAC) && !defined(OS_OPENBSD)
|
||||
typedef long int64;
|
||||
typedef unsigned long uint64;
|
||||
#else
|
||||
typedef long long int64;
|
||||
typedef unsigned long long uint64;
|
||||
#endif
|
||||
|
||||
// TODO: Remove these type guards. These are to avoid conflicts with
|
||||
// obsolete/protypes.h in the Gecko SDK.
|
||||
#ifndef _INT32
|
||||
#define _INT32
|
||||
typedef int int32;
|
||||
#endif
|
||||
|
||||
// TODO: Remove these type guards. These are to avoid conflicts with
|
||||
// obsolete/protypes.h in the Gecko SDK.
|
||||
#ifndef _UINT32
|
||||
#define _UINT32
|
||||
typedef unsigned int uint32;
|
||||
#endif
|
||||
|
||||
#ifndef _INT16
|
||||
#define _INT16
|
||||
typedef short int16;
|
||||
#endif
|
||||
|
||||
#ifndef _UINT16
|
||||
#define _UINT16
|
||||
typedef unsigned short uint16;
|
||||
#endif
|
||||
|
||||
// UTF-16 character type.
|
||||
#ifndef char16
|
||||
#if defined(WCHAR_T_IS_UTF16)
|
||||
typedef wchar_t char16;
|
||||
#elif defined(WCHAR_T_IS_UTF32)
|
||||
typedef unsigned short char16;
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#endif // CEF_INCLUDE_BASE_CEF_BASICTYPES_H_
|
@@ -253,7 +253,7 @@
|
||||
// The compiler thinks std::string::const_iterator and "const char*" are
|
||||
// equivalent types.
|
||||
#define STD_STRING_ITERATOR_IS_CHAR_POINTER
|
||||
// The compiler thinks std::u16string::const_iterator and "char16*" are
|
||||
// The compiler thinks std::u16string::const_iterator and "char16_t*" are
|
||||
// equivalent types.
|
||||
#define BASE_STRING16_ITERATOR_IS_CHAR16_POINTER
|
||||
#endif
|
||||
|
@@ -723,6 +723,13 @@ std::ostream& operator<<(std::ostream& out, const wchar_t* wstr);
|
||||
inline std::ostream& operator<<(std::ostream& out, const std::wstring& wstr) {
|
||||
return out << wstr.c_str();
|
||||
}
|
||||
#if defined(WCHAR_T_IS_UTF32)
|
||||
std::ostream& operator<<(std::ostream& out, const char16_t* wstr);
|
||||
#elif defined(WCHAR_T_IS_UTF16)
|
||||
inline std::ostream& operator<<(std::ostream& out, const char16_t* wstr) {
|
||||
return operator<<(out, reinterpret_cast<const wchar_t*>(wstr));
|
||||
}
|
||||
#endif
|
||||
|
||||
// The NOTIMPLEMENTED() macro annotates codepaths which have
|
||||
// not been implemented yet.
|
||||
|
@@ -43,7 +43,6 @@
|
||||
// If the Chromium implementation diverges the below implementation should be
|
||||
// updated to match.
|
||||
|
||||
#include "include/base/cef_basictypes.h"
|
||||
#include "include/base/cef_build.h"
|
||||
#include "include/internal/cef_thread_internal.h"
|
||||
|
||||
|
@@ -145,14 +145,6 @@
|
||||
/// free(str); // Trace system now has dangling pointer
|
||||
/// </pre>
|
||||
///
|
||||
/// To avoid this issue with the |name| and |arg_name| parameters, use the
|
||||
/// TRACE_EVENT_COPY_XXX overloads of the macros at additional runtime
|
||||
/// overhead.
|
||||
///
|
||||
/// Notes: The category must always be in a long-lived char* (i.e. static
|
||||
/// const). The |arg_values|, when used, are always deep copied with
|
||||
/// the _COPY macros.
|
||||
///
|
||||
///
|
||||
/// Thread Safety:
|
||||
/// All macros are thread safe and can be used from any process.
|
||||
@@ -179,15 +171,15 @@
|
||||
/// - category and name strings must have application lifetime (statics or
|
||||
/// literals). They may not include " chars.
|
||||
///
|
||||
#define TRACE_EVENT0(category, name) \
|
||||
cef_trace_event_begin(category, name, NULL, 0, NULL, 0, false); \
|
||||
#define TRACE_EVENT0(category, name) \
|
||||
cef_trace_event_begin(category, name, NULL, 0, NULL, 0); \
|
||||
CEF_INTERNAL_TRACE_END_ON_SCOPE_CLOSE(category, name)
|
||||
#define TRACE_EVENT1(category, name, arg1_name, arg1_val) \
|
||||
cef_trace_event_begin(category, name, arg1_name, arg1_val, NULL, 0, false); \
|
||||
#define TRACE_EVENT1(category, name, arg1_name, arg1_val) \
|
||||
cef_trace_event_begin(category, name, arg1_name, arg1_val, NULL, 0); \
|
||||
CEF_INTERNAL_TRACE_END_ON_SCOPE_CLOSE(category, name)
|
||||
#define TRACE_EVENT2(category, name, arg1_name, arg1_val, arg2_name, arg2_val) \
|
||||
cef_trace_event_begin(category, name, arg1_name, arg1_val, arg2_name, \
|
||||
arg2_val, false); \
|
||||
arg2_val); \
|
||||
CEF_INTERNAL_TRACE_END_ON_SCOPE_CLOSE(category, name)
|
||||
|
||||
// Implementation detail: trace event macros create temporary variable names.
|
||||
@@ -211,21 +203,13 @@
|
||||
/// literals). They may not include " chars.
|
||||
///
|
||||
#define TRACE_EVENT_INSTANT0(category, name) \
|
||||
cef_trace_event_instant(category, name, NULL, 0, NULL, 0, false)
|
||||
cef_trace_event_instant(category, name, NULL, 0, NULL, 0)
|
||||
#define TRACE_EVENT_INSTANT1(category, name, arg1_name, arg1_val) \
|
||||
cef_trace_event_instant(category, name, arg1_name, arg1_val, NULL, 0, false)
|
||||
cef_trace_event_instant(category, name, arg1_name, arg1_val, NULL, 0)
|
||||
#define TRACE_EVENT_INSTANT2(category, name, arg1_name, arg1_val, arg2_name, \
|
||||
arg2_val) \
|
||||
cef_trace_event_instant(category, name, arg1_name, arg1_val, arg2_name, \
|
||||
arg2_val, false)
|
||||
#define TRACE_EVENT_COPY_INSTANT0(category, name) \
|
||||
cef_trace_event_instant(category, name, NULL, 0, NULL, 0, true)
|
||||
#define TRACE_EVENT_COPY_INSTANT1(category, name, arg1_name, arg1_val) \
|
||||
cef_trace_event_instant(category, name, arg1_name, arg1_val, NULL, 0, true)
|
||||
#define TRACE_EVENT_COPY_INSTANT2(category, name, arg1_name, arg1_val, \
|
||||
arg2_name, arg2_val) \
|
||||
cef_trace_event_instant(category, name, arg1_name, arg1_val, arg2_name, \
|
||||
arg2_val, true)
|
||||
arg2_val)
|
||||
|
||||
///
|
||||
/// Records a single BEGIN event called "name" immediately, with 0, 1 or 2
|
||||
@@ -235,21 +219,13 @@
|
||||
/// literals). They may not include " chars.
|
||||
///
|
||||
#define TRACE_EVENT_BEGIN0(category, name) \
|
||||
cef_trace_event_begin(category, name, NULL, 0, NULL, 0, false)
|
||||
cef_trace_event_begin(category, name, NULL, 0, NULL, 0)
|
||||
#define TRACE_EVENT_BEGIN1(category, name, arg1_name, arg1_val) \
|
||||
cef_trace_event_begin(category, name, arg1_name, arg1_val, NULL, 0, false)
|
||||
cef_trace_event_begin(category, name, arg1_name, arg1_val, NULL, 0)
|
||||
#define TRACE_EVENT_BEGIN2(category, name, arg1_name, arg1_val, arg2_name, \
|
||||
arg2_val) \
|
||||
cef_trace_event_begin(category, name, arg1_name, arg1_val, arg2_name, \
|
||||
arg2_val, false)
|
||||
#define TRACE_EVENT_COPY_BEGIN0(category, name) \
|
||||
cef_trace_event_begin(category, name, NULL, 0, NULL, 0, true)
|
||||
#define TRACE_EVENT_COPY_BEGIN1(category, name, arg1_name, arg1_val) \
|
||||
cef_trace_event_begin(category, name, arg1_name, arg1_val, NULL, 0, true)
|
||||
#define TRACE_EVENT_COPY_BEGIN2(category, name, arg1_name, arg1_val, \
|
||||
arg2_name, arg2_val) \
|
||||
cef_trace_event_begin(category, name, arg1_name, arg1_val, arg2_name, \
|
||||
arg2_val, true)
|
||||
arg2_val)
|
||||
|
||||
///
|
||||
/// Records a single END event for "name" immediately. If the category
|
||||
@@ -258,21 +234,12 @@
|
||||
/// literals). They may not include " chars.
|
||||
///
|
||||
#define TRACE_EVENT_END0(category, name) \
|
||||
cef_trace_event_end(category, name, NULL, 0, NULL, 0, false)
|
||||
cef_trace_event_end(category, name, NULL, 0, NULL, 0)
|
||||
#define TRACE_EVENT_END1(category, name, arg1_name, arg1_val) \
|
||||
cef_trace_event_end(category, name, arg1_name, arg1_val, NULL, 0, false)
|
||||
cef_trace_event_end(category, name, arg1_name, arg1_val, NULL, 0)
|
||||
#define TRACE_EVENT_END2(category, name, arg1_name, arg1_val, arg2_name, \
|
||||
arg2_val) \
|
||||
cef_trace_event_end(category, name, arg1_name, arg1_val, arg2_name, \
|
||||
arg2_val, false)
|
||||
#define TRACE_EVENT_COPY_END0(category, name) \
|
||||
cef_trace_event_end(category, name, NULL, 0, NULL, 0, true)
|
||||
#define TRACE_EVENT_COPY_END1(category, name, arg1_name, arg1_val) \
|
||||
cef_trace_event_end(category, name, arg1_name, arg1_val, NULL, 0, true)
|
||||
#define TRACE_EVENT_COPY_END2(category, name, arg1_name, arg1_val, arg2_name, \
|
||||
arg2_val) \
|
||||
cef_trace_event_end(category, name, arg1_name, arg1_val, arg2_name, \
|
||||
arg2_val, true)
|
||||
cef_trace_event_end(category, name, arg1_name, arg1_val, arg2_name, arg2_val)
|
||||
|
||||
///
|
||||
/// Records the value of a counter called "name" immediately. Value
|
||||
@@ -281,9 +248,7 @@
|
||||
/// literals). They may not include " chars.
|
||||
///
|
||||
#define TRACE_COUNTER1(category, name, value) \
|
||||
cef_trace_counter(category, name, NULL, value, NULL, 0, false)
|
||||
#define TRACE_COPY_COUNTER1(category, name, value) \
|
||||
cef_trace_counter(category, name, NULL, value, NULL, 0, true)
|
||||
cef_trace_counter(category, name, NULL, value, NULL, 0)
|
||||
|
||||
///
|
||||
/// Records the values of a multi-parted counter called "name" immediately.
|
||||
@@ -295,11 +260,7 @@
|
||||
#define TRACE_COUNTER2(category, name, value1_name, value1_val, value2_name, \
|
||||
value2_val) \
|
||||
cef_trace_counter(category, name, value1_name, value1_val, value2_name, \
|
||||
value2_val, false)
|
||||
#define TRACE_COPY_COUNTER2(category, name, value1_name, value1_val, \
|
||||
value2_name, value2_val) \
|
||||
cef_trace_counter(category, name, value1_name, value1_val, value2_name, \
|
||||
value2_val, true)
|
||||
value2_val)
|
||||
|
||||
///
|
||||
/// Records the value of a counter called "name" immediately. Value
|
||||
@@ -312,9 +273,7 @@
|
||||
/// on two different processes will not collide.
|
||||
///
|
||||
#define TRACE_COUNTER_ID1(category, name, id, value) \
|
||||
cef_trace_counter_id(category, name, id, NULL, value, NULL, 0, false)
|
||||
#define TRACE_COPY_COUNTER_ID1(category, name, id, value) \
|
||||
cef_trace_counter_id(category, name, id, NULL, value, NULL, 0, true)
|
||||
cef_trace_counter_id(category, name, id, NULL, value, NULL, 0)
|
||||
|
||||
///
|
||||
/// Records the values of a multi-parted counter called "name" immediately.
|
||||
@@ -330,11 +289,7 @@
|
||||
#define TRACE_COUNTER_ID2(category, name, id, value1_name, value1_val, \
|
||||
value2_name, value2_val) \
|
||||
cef_trace_counter_id(category, name, id, value1_name, value1_val, \
|
||||
value2_name, value2_val, false)
|
||||
#define TRACE_COPY_COUNTER_ID2(category, name, id, value1_name, value1_val, \
|
||||
value2_name, value2_val) \
|
||||
cef_trace_counter_id(category, name, id, value1_name, value1_val, \
|
||||
value2_name, value2_val, true)
|
||||
value2_name, value2_val)
|
||||
|
||||
///
|
||||
/// Records a single ASYNC_BEGIN event called "name" immediately, with 0, 1 or 2
|
||||
@@ -355,23 +310,13 @@
|
||||
/// args.
|
||||
///
|
||||
#define TRACE_EVENT_ASYNC_BEGIN0(category, name, id) \
|
||||
cef_trace_event_async_begin(category, name, id, NULL, 0, NULL, 0, false)
|
||||
#define TRACE_EVENT_ASYNC_BEGIN1(category, name, id, arg1_name, arg1_val) \
|
||||
cef_trace_event_async_begin(category, name, id, arg1_name, arg1_val, NULL, \
|
||||
0, false)
|
||||
cef_trace_event_async_begin(category, name, id, NULL, 0, NULL, 0)
|
||||
#define TRACE_EVENT_ASYNC_BEGIN1(category, name, id, arg1_name, arg1_val) \
|
||||
cef_trace_event_async_begin(category, name, id, arg1_name, arg1_val, NULL, 0)
|
||||
#define TRACE_EVENT_ASYNC_BEGIN2(category, name, id, arg1_name, arg1_val, \
|
||||
arg2_name, arg2_val) \
|
||||
cef_trace_event_async_begin(category, name, id, arg1_name, arg1_val, \
|
||||
arg2_name, arg2_val, false)
|
||||
#define TRACE_EVENT_COPY_ASYNC_BEGIN0(category, name, id) \
|
||||
cef_trace_event_async_begin(category, name, id, NULL, 0, NULL, 0, true)
|
||||
#define TRACE_EVENT_COPY_ASYNC_BEGIN1(category, name, id, arg1_name, arg1_val) \
|
||||
cef_trace_event_async_begin(category, name, id, arg1_name, arg1_val, NULL, \
|
||||
0, true)
|
||||
#define TRACE_EVENT_COPY_ASYNC_BEGIN2(category, name, id, arg1_name, arg1_val, \
|
||||
arg2_name, arg2_val) \
|
||||
cef_trace_event_async_begin(category, name, id, arg1_name, arg1_val, \
|
||||
arg2_name, arg2_val, true)
|
||||
arg2_name, arg2_val)
|
||||
|
||||
///
|
||||
/// Records a single ASYNC_STEP_INTO event for |step| immediately. If the
|
||||
@@ -382,17 +327,10 @@
|
||||
/// ASYNC_STEP_PAST events.
|
||||
///
|
||||
#define TRACE_EVENT_ASYNC_STEP_INTO0(category, name, id, step) \
|
||||
cef_trace_event_async_step_into(category, name, id, step, NULL, 0, false)
|
||||
cef_trace_event_async_step_into(category, name, id, step, NULL, 0)
|
||||
#define TRACE_EVENT_ASYNC_STEP_INTO1(category, name, id, step, arg1_name, \
|
||||
arg1_val) \
|
||||
cef_trace_event_async_step_into(category, name, id, step, arg1_name, \
|
||||
arg1_val, false)
|
||||
#define TRACE_EVENT_COPY_ASYNC_STEP_INTO0(category, name, id, step) \
|
||||
cef_trace_event_async_step_into(category, name, id, step, NULL, 0, true)
|
||||
#define TRACE_EVENT_COPY_ASYNC_STEP_INTO1(category, name, id, step, arg1_name, \
|
||||
arg1_val) \
|
||||
cef_trace_event_async_step_into(category, name, id, step, arg1_name, \
|
||||
arg1_val, true)
|
||||
cef_trace_event_async_step_into(category, name, id, step, arg1_name, arg1_val)
|
||||
|
||||
///
|
||||
/// Records a single ASYNC_STEP_PAST event for |step| immediately. If the
|
||||
@@ -403,40 +341,23 @@
|
||||
/// ASYNC_STEP_INTO events.
|
||||
///
|
||||
#define TRACE_EVENT_ASYNC_STEP_PAST0(category, name, id, step) \
|
||||
cef_trace_event_async_step_past(category, name, id, step, NULL, 0, false)
|
||||
cef_trace_event_async_step_past(category, name, id, step, NULL, 0)
|
||||
#define TRACE_EVENT_ASYNC_STEP_PAST1(category, name, id, step, arg1_name, \
|
||||
arg1_val) \
|
||||
cef_trace_event_async_step_past(category, name, id, step, arg1_name, \
|
||||
arg1_val, false)
|
||||
#define TRACE_EVENT_COPY_ASYNC_STEP_PAST0(category, name, id, step) \
|
||||
cef_trace_event_async_step_past(category, name, id, step, NULL, 0, true)
|
||||
#define TRACE_EVENT_COPY_ASYNC_STEP_PAST1(category, name, id, step, arg1_name, \
|
||||
arg1_val) \
|
||||
cef_trace_event_async_step_past(category, name, id, step, arg1_name, \
|
||||
arg1_val, true)
|
||||
cef_trace_event_async_step_past(category, name, id, step, arg1_name, arg1_val)
|
||||
|
||||
///
|
||||
/// Records a single ASYNC_END event for "name" immediately. If the category
|
||||
/// is not enabled, then this does nothing.
|
||||
///
|
||||
#define TRACE_EVENT_ASYNC_END0(category, name, id) \
|
||||
cef_trace_event_async_end(category, name, id, NULL, 0, NULL, 0, false)
|
||||
#define TRACE_EVENT_ASYNC_END1(category, name, id, arg1_name, arg1_val) \
|
||||
cef_trace_event_async_end(category, name, id, arg1_name, arg1_val, NULL, 0, \
|
||||
false)
|
||||
cef_trace_event_async_end(category, name, id, NULL, 0, NULL, 0)
|
||||
#define TRACE_EVENT_ASYNC_END1(category, name, id, arg1_name, arg1_val) \
|
||||
cef_trace_event_async_end(category, name, id, arg1_name, arg1_val, NULL, 0)
|
||||
#define TRACE_EVENT_ASYNC_END2(category, name, id, arg1_name, arg1_val, \
|
||||
arg2_name, arg2_val) \
|
||||
cef_trace_event_async_end(category, name, id, arg1_name, arg1_val, \
|
||||
arg2_name, arg2_val, false)
|
||||
#define TRACE_EVENT_COPY_ASYNC_END0(category, name, id) \
|
||||
cef_trace_event_async_end(category, name, id, NULL, 0, NULL, 0, true)
|
||||
#define TRACE_EVENT_COPY_ASYNC_END1(category, name, id, arg1_name, arg1_val) \
|
||||
cef_trace_event_async_end(category, name, id, arg1_name, arg1_val, NULL, 0, \
|
||||
true)
|
||||
#define TRACE_EVENT_COPY_ASYNC_END2(category, name, id, arg1_name, arg1_val, \
|
||||
arg2_name, arg2_val) \
|
||||
cef_trace_event_async_end(category, name, id, arg1_name, arg1_val, \
|
||||
arg2_name, arg2_val, true)
|
||||
arg2_name, arg2_val)
|
||||
|
||||
namespace cef_trace_event {
|
||||
|
||||
@@ -448,7 +369,7 @@ class CefTraceEndOnScopeClose {
|
||||
CefTraceEndOnScopeClose(const char* category, const char* name)
|
||||
: category_(category), name_(name) {}
|
||||
~CefTraceEndOnScopeClose() {
|
||||
cef_trace_event_end(category_, name_, NULL, 0, NULL, 0, false);
|
||||
cef_trace_event_end(category_, name_, NULL, 0, NULL, 0);
|
||||
}
|
||||
|
||||
private:
|
||||
|
@@ -33,7 +33,7 @@
|
||||
// by hand. See the translator.README.txt file in the tools directory for
|
||||
// more information.
|
||||
//
|
||||
// $hash=936274d5539f225ff7adb7e0acba517fd9a8e2f8$
|
||||
// $hash=932c3ecb22fd26322d96d0e01459122aadafd302$
|
||||
//
|
||||
|
||||
#ifndef CEF_INCLUDE_CAPI_CEF_AUDIO_HANDLER_CAPI_H_
|
||||
@@ -93,7 +93,7 @@ typedef struct _cef_audio_handler_t {
|
||||
struct _cef_browser_t* browser,
|
||||
const float** data,
|
||||
int frames,
|
||||
int64 pts);
|
||||
int64_t pts);
|
||||
|
||||
///
|
||||
/// Called on the UI thread when the stream has stopped. OnAudioSteamStopped
|
||||
|
@@ -33,7 +33,7 @@
|
||||
// by hand. See the translator.README.txt file in the tools directory for
|
||||
// more information.
|
||||
//
|
||||
// $hash=7254c050cd7db2ff7d40a1f54c99e941dc592692$
|
||||
// $hash=683d7bff8da04826eee83c7e23cf9c5a701ae265$
|
||||
//
|
||||
|
||||
#ifndef CEF_INCLUDE_CAPI_CEF_BROWSER_CAPI_H_
|
||||
@@ -167,7 +167,7 @@ typedef struct _cef_browser_t {
|
||||
///
|
||||
struct _cef_frame_t*(CEF_CALLBACK* get_frame_byident)(
|
||||
struct _cef_browser_t* self,
|
||||
int64 identifier);
|
||||
int64_t identifier);
|
||||
|
||||
///
|
||||
/// Returns the frame with the specified name, or NULL if not found.
|
||||
@@ -185,7 +185,7 @@ typedef struct _cef_browser_t {
|
||||
///
|
||||
void(CEF_CALLBACK* get_frame_identifiers)(struct _cef_browser_t* self,
|
||||
size_t* identifiersCount,
|
||||
int64* identifiers);
|
||||
int64_t* identifiers);
|
||||
|
||||
///
|
||||
/// Returns the names of all existing frames.
|
||||
@@ -424,7 +424,7 @@ typedef struct _cef_browser_host_t {
|
||||
struct _cef_browser_host_t* self,
|
||||
const cef_string_t* image_url,
|
||||
int is_favicon,
|
||||
uint32 max_image_size,
|
||||
uint32_t max_image_size,
|
||||
int bypass_cache,
|
||||
struct _cef_download_image_callback_t* callback);
|
||||
|
||||
|
@@ -33,7 +33,7 @@
|
||||
// by hand. See the translator.README.txt file in the tools directory for
|
||||
// more information.
|
||||
//
|
||||
// $hash=4ef8b73a5218531b370fdd76c23153a1f83b7f7b$
|
||||
// $hash=a146316e075450f0a6f37cb45d14e15e0ac7be08$
|
||||
//
|
||||
|
||||
#ifndef CEF_INCLUDE_CAPI_CEF_BROWSER_PROCESS_HANDLER_CAPI_H_
|
||||
@@ -121,7 +121,7 @@ typedef struct _cef_browser_process_handler_t {
|
||||
///
|
||||
void(CEF_CALLBACK* on_schedule_message_pump_work)(
|
||||
struct _cef_browser_process_handler_t* self,
|
||||
int64 delay_ms);
|
||||
int64_t delay_ms);
|
||||
|
||||
///
|
||||
/// Return the default client for use with a newly created browser window. If
|
||||
|
@@ -33,7 +33,7 @@
|
||||
// by hand. See the translator.README.txt file in the tools directory for
|
||||
// more information.
|
||||
//
|
||||
// $hash=5c6e0b9e37b8103a182f200fccdf5973104fcd70$
|
||||
// $hash=22cfd717df9032a01214d9abfe3e0e51949b3319$
|
||||
//
|
||||
|
||||
#ifndef CEF_INCLUDE_CAPI_CEF_CRASH_UTIL_CAPI_H_
|
||||
@@ -90,7 +90,7 @@ extern "C" {
|
||||
/// If "AppName" is set on Windows then crash report information (metrics,
|
||||
/// database and dumps) will be stored locally on disk under the
|
||||
/// "C:\Users\[CurrentUser]\AppData\Local\[AppName]\User Data" folder. On other
|
||||
/// platforms the cef_settings_t.user_data_path value will be used.
|
||||
/// platforms the cef_settings_t.root_cache_path value will be used.
|
||||
///
|
||||
/// If "ExternalHandler" is set on Windows then the specified exe will be
|
||||
/// launched as the crashpad-handler instead of re-launching the main process
|
||||
|
@@ -33,7 +33,7 @@
|
||||
// by hand. See the translator.README.txt file in the tools directory for
|
||||
// more information.
|
||||
//
|
||||
// $hash=d9e9f4b914ae2d3b1ed83ae0d9e2e46e9e736af5$
|
||||
// $hash=c4ecfde5d6791400c4b3fd466e7d3676d51cf8d8$
|
||||
//
|
||||
|
||||
#ifndef CEF_INCLUDE_CAPI_CEF_DOWNLOAD_ITEM_CAPI_H_
|
||||
@@ -90,7 +90,7 @@ typedef struct _cef_download_item_t {
|
||||
///
|
||||
/// Returns a simple speed estimate in bytes/s.
|
||||
///
|
||||
int64(CEF_CALLBACK* get_current_speed)(struct _cef_download_item_t* self);
|
||||
int64_t(CEF_CALLBACK* get_current_speed)(struct _cef_download_item_t* self);
|
||||
|
||||
///
|
||||
/// Returns the rough percent complete or -1 if the receive total size is
|
||||
@@ -101,12 +101,12 @@ typedef struct _cef_download_item_t {
|
||||
///
|
||||
/// Returns the total number of bytes.
|
||||
///
|
||||
int64(CEF_CALLBACK* get_total_bytes)(struct _cef_download_item_t* self);
|
||||
int64_t(CEF_CALLBACK* get_total_bytes)(struct _cef_download_item_t* self);
|
||||
|
||||
///
|
||||
/// Returns the number of received bytes.
|
||||
///
|
||||
int64(CEF_CALLBACK* get_received_bytes)(struct _cef_download_item_t* self);
|
||||
int64_t(CEF_CALLBACK* get_received_bytes)(struct _cef_download_item_t* self);
|
||||
|
||||
///
|
||||
/// Returns the time that the download started.
|
||||
@@ -129,7 +129,7 @@ typedef struct _cef_download_item_t {
|
||||
///
|
||||
/// Returns the unique identifier for this download.
|
||||
///
|
||||
uint32(CEF_CALLBACK* get_id)(struct _cef_download_item_t* self);
|
||||
uint32_t(CEF_CALLBACK* get_id)(struct _cef_download_item_t* self);
|
||||
|
||||
///
|
||||
/// Returns the URL.
|
||||
|
@@ -33,7 +33,7 @@
|
||||
// by hand. See the translator.README.txt file in the tools directory for
|
||||
// more information.
|
||||
//
|
||||
// $hash=5bed8359f09a821f4b5ec8ebfad0aa5720bf39f9$
|
||||
// $hash=1ad87e4addc2f05497671bc59dc7fd315e0603f3$
|
||||
//
|
||||
|
||||
#ifndef CEF_INCLUDE_CAPI_CEF_FRAME_CAPI_H_
|
||||
@@ -181,7 +181,7 @@ typedef struct _cef_frame_t {
|
||||
/// Returns the globally unique identifier for this frame or < 0 if the
|
||||
/// underlying frame does not yet exist.
|
||||
///
|
||||
int64(CEF_CALLBACK* get_identifier)(struct _cef_frame_t* self);
|
||||
int64_t(CEF_CALLBACK* get_identifier)(struct _cef_frame_t* self);
|
||||
|
||||
///
|
||||
/// Returns the parent of this frame or NULL if this is the main (top-level)
|
||||
|
@@ -33,7 +33,7 @@
|
||||
// by hand. See the translator.README.txt file in the tools directory for
|
||||
// more information.
|
||||
//
|
||||
// $hash=b564dfe24017a0805e393854d12791a71c46c454$
|
||||
// $hash=9330c709713a10c1e6b55278428e65c07f4c9dfb$
|
||||
//
|
||||
|
||||
#ifndef CEF_INCLUDE_CAPI_CEF_ORIGIN_WHITELIST_CAPI_H_
|
||||
|
@@ -33,7 +33,7 @@
|
||||
// by hand. See the translator.README.txt file in the tools directory for
|
||||
// more information.
|
||||
//
|
||||
// $hash=bc44eb70b7f0b48e0646825e919cb9996ac99781$
|
||||
// $hash=012d76416d19b590f29c013c44ceec1674593022$
|
||||
//
|
||||
|
||||
#ifndef CEF_INCLUDE_CAPI_CEF_PERMISSION_HANDLER_CAPI_H_
|
||||
@@ -66,7 +66,7 @@ typedef struct _cef_media_access_callback_t {
|
||||
/// OnRequestMediaAccessPermission.
|
||||
///
|
||||
void(CEF_CALLBACK* cont)(struct _cef_media_access_callback_t* self,
|
||||
uint32 allowed_permissions);
|
||||
uint32_t allowed_permissions);
|
||||
|
||||
///
|
||||
/// Cancel the media access request.
|
||||
@@ -119,7 +119,7 @@ typedef struct _cef_permission_handler_t {
|
||||
struct _cef_browser_t* browser,
|
||||
struct _cef_frame_t* frame,
|
||||
const cef_string_t* requesting_origin,
|
||||
uint32 requested_permissions,
|
||||
uint32_t requested_permissions,
|
||||
struct _cef_media_access_callback_t* callback);
|
||||
|
||||
///
|
||||
@@ -136,9 +136,9 @@ typedef struct _cef_permission_handler_t {
|
||||
int(CEF_CALLBACK* on_show_permission_prompt)(
|
||||
struct _cef_permission_handler_t* self,
|
||||
struct _cef_browser_t* browser,
|
||||
uint64 prompt_id,
|
||||
uint64_t prompt_id,
|
||||
const cef_string_t* requesting_origin,
|
||||
uint32 requested_permissions,
|
||||
uint32_t requested_permissions,
|
||||
struct _cef_permission_prompt_callback_t* callback);
|
||||
|
||||
///
|
||||
@@ -153,7 +153,7 @@ typedef struct _cef_permission_handler_t {
|
||||
void(CEF_CALLBACK* on_dismiss_permission_prompt)(
|
||||
struct _cef_permission_handler_t* self,
|
||||
struct _cef_browser_t* browser,
|
||||
uint64 prompt_id,
|
||||
uint64_t prompt_id,
|
||||
cef_permission_request_result_t result);
|
||||
} cef_permission_handler_t;
|
||||
|
||||
|
@@ -33,7 +33,7 @@
|
||||
// by hand. See the translator.README.txt file in the tools directory for
|
||||
// more information.
|
||||
//
|
||||
// $hash=3339290cad3a77c8b0b07d422f0faf902a047838$
|
||||
// $hash=241f8b8ba0a4555f8ad8ed1d60345ae83d4d62f4$
|
||||
//
|
||||
|
||||
#ifndef CEF_INCLUDE_CAPI_CEF_REQUEST_CAPI_H_
|
||||
@@ -214,7 +214,7 @@ typedef struct _cef_request_t {
|
||||
/// in the browser process to track a single request across multiple
|
||||
/// callbacks.
|
||||
///
|
||||
uint64(CEF_CALLBACK* get_identifier)(struct _cef_request_t* self);
|
||||
uint64_t(CEF_CALLBACK* get_identifier)(struct _cef_request_t* self);
|
||||
} cef_request_t;
|
||||
|
||||
///
|
||||
|
@@ -33,7 +33,7 @@
|
||||
// by hand. See the translator.README.txt file in the tools directory for
|
||||
// more information.
|
||||
//
|
||||
// $hash=c2a6265e8e9acce475a8b5755a8c58b97b495207$
|
||||
// $hash=1c3c3dfb4bde6cd45278c6a80fbc53f624017c44$
|
||||
//
|
||||
|
||||
#ifndef CEF_INCLUDE_CAPI_CEF_REQUEST_CONTEXT_CAPI_H_
|
||||
@@ -46,6 +46,7 @@
|
||||
#include "include/capi/cef_extension_handler_capi.h"
|
||||
#include "include/capi/cef_media_router_capi.h"
|
||||
#include "include/capi/cef_preference_capi.h"
|
||||
#include "include/capi/cef_values_capi.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
@@ -301,6 +302,72 @@ typedef struct _cef_request_context_t {
|
||||
struct _cef_media_router_t*(CEF_CALLBACK* get_media_router)(
|
||||
struct _cef_request_context_t* self,
|
||||
struct _cef_completion_callback_t* callback);
|
||||
|
||||
///
|
||||
/// Returns the current value for |content_type| that applies for the
|
||||
/// specified URLs. If both URLs are NULL the default value will be returned.
|
||||
/// Returns nullptr if no value is configured. Must be called on the browser
|
||||
/// process UI thread.
|
||||
///
|
||||
struct _cef_value_t*(CEF_CALLBACK* get_website_setting)(
|
||||
struct _cef_request_context_t* self,
|
||||
const cef_string_t* requesting_url,
|
||||
const cef_string_t* top_level_url,
|
||||
cef_content_setting_types_t content_type);
|
||||
|
||||
///
|
||||
/// Sets the current value for |content_type| for the specified URLs in the
|
||||
/// default scope. If both URLs are NULL, and the context is not incognito,
|
||||
/// the default value will be set. Pass nullptr for |value| to remove the
|
||||
/// default value for this content type.
|
||||
///
|
||||
/// WARNING: Incorrect usage of this function may cause instability or
|
||||
/// security issues in Chromium. Make sure that you first understand the
|
||||
/// potential impact of any changes to |content_type| by reviewing the related
|
||||
/// source code in Chromium. For example, if you plan to modify
|
||||
/// CEF_CONTENT_SETTING_TYPE_POPUPS, first review and understand the usage of
|
||||
/// ContentSettingsType::POPUPS in Chromium:
|
||||
/// https://source.chromium.org/search?q=ContentSettingsType::POPUPS
|
||||
///
|
||||
void(CEF_CALLBACK* set_website_setting)(
|
||||
struct _cef_request_context_t* self,
|
||||
const cef_string_t* requesting_url,
|
||||
const cef_string_t* top_level_url,
|
||||
cef_content_setting_types_t content_type,
|
||||
struct _cef_value_t* value);
|
||||
|
||||
///
|
||||
/// Returns the current value for |content_type| that applies for the
|
||||
/// specified URLs. If both URLs are NULL the default value will be returned.
|
||||
/// Returns CEF_CONTENT_SETTING_VALUE_DEFAULT if no value is configured. Must
|
||||
/// be called on the browser process UI thread.
|
||||
///
|
||||
cef_content_setting_values_t(CEF_CALLBACK* get_content_setting)(
|
||||
struct _cef_request_context_t* self,
|
||||
const cef_string_t* requesting_url,
|
||||
const cef_string_t* top_level_url,
|
||||
cef_content_setting_types_t content_type);
|
||||
|
||||
///
|
||||
/// Sets the current value for |content_type| for the specified URLs in the
|
||||
/// default scope. If both URLs are NULL, and the context is not incognito,
|
||||
/// the default value will be set. Pass CEF_CONTENT_SETTING_VALUE_DEFAULT for
|
||||
/// |value| to use the default value for this content type.
|
||||
///
|
||||
/// WARNING: Incorrect usage of this function may cause instability or
|
||||
/// security issues in Chromium. Make sure that you first understand the
|
||||
/// potential impact of any changes to |content_type| by reviewing the related
|
||||
/// source code in Chromium. For example, if you plan to modify
|
||||
/// CEF_CONTENT_SETTING_TYPE_POPUPS, first review and understand the usage of
|
||||
/// ContentSettingsType::POPUPS in Chromium:
|
||||
/// https://source.chromium.org/search?q=ContentSettingsType::POPUPS
|
||||
///
|
||||
void(CEF_CALLBACK* set_content_setting)(
|
||||
struct _cef_request_context_t* self,
|
||||
const cef_string_t* requesting_url,
|
||||
const cef_string_t* top_level_url,
|
||||
cef_content_setting_types_t content_type,
|
||||
cef_content_setting_values_t value);
|
||||
} cef_request_context_t;
|
||||
|
||||
///
|
||||
|
@@ -33,7 +33,7 @@
|
||||
// by hand. See the translator.README.txt file in the tools directory for
|
||||
// more information.
|
||||
//
|
||||
// $hash=93e5c4f5e93f56b63b5944208300669dcecba972$
|
||||
// $hash=ca5c224b373452158904b0f859f126f36c927f93$
|
||||
//
|
||||
|
||||
#ifndef CEF_INCLUDE_CAPI_CEF_RESOURCE_HANDLER_CAPI_H_
|
||||
@@ -67,7 +67,7 @@ typedef struct _cef_resource_skip_callback_t {
|
||||
/// 0 the request will fail with ERR_REQUEST_RANGE_NOT_SATISFIABLE.
|
||||
///
|
||||
void(CEF_CALLBACK* cont)(struct _cef_resource_skip_callback_t* self,
|
||||
int64 bytes_skipped);
|
||||
int64_t bytes_skipped);
|
||||
} cef_resource_skip_callback_t;
|
||||
|
||||
///
|
||||
@@ -146,7 +146,7 @@ typedef struct _cef_resource_handler_t {
|
||||
///
|
||||
void(CEF_CALLBACK* get_response_headers)(struct _cef_resource_handler_t* self,
|
||||
struct _cef_response_t* response,
|
||||
int64* response_length,
|
||||
int64_t* response_length,
|
||||
cef_string_t* redirectUrl);
|
||||
|
||||
///
|
||||
@@ -159,8 +159,8 @@ typedef struct _cef_resource_handler_t {
|
||||
/// function will be called in sequence but not from a dedicated thread.
|
||||
///
|
||||
int(CEF_CALLBACK* skip)(struct _cef_resource_handler_t* self,
|
||||
int64 bytes_to_skip,
|
||||
int64* bytes_skipped,
|
||||
int64_t bytes_to_skip,
|
||||
int64_t* bytes_skipped,
|
||||
struct _cef_resource_skip_callback_t* callback);
|
||||
|
||||
///
|
||||
|
@@ -33,7 +33,7 @@
|
||||
// by hand. See the translator.README.txt file in the tools directory for
|
||||
// more information.
|
||||
//
|
||||
// $hash=70d6b393cbdc96a75864911d7ca3568cc8dcdebf$
|
||||
// $hash=757155e6dbceef47938fd562f7f5f48a609ce288$
|
||||
//
|
||||
|
||||
#ifndef CEF_INCLUDE_CAPI_CEF_RESOURCE_REQUEST_HANDLER_CAPI_H_
|
||||
@@ -188,7 +188,7 @@ typedef struct _cef_resource_request_handler_t {
|
||||
struct _cef_request_t* request,
|
||||
struct _cef_response_t* response,
|
||||
cef_urlrequest_status_t status,
|
||||
int64 received_content_length);
|
||||
int64_t received_content_length);
|
||||
|
||||
///
|
||||
/// Called on the IO thread to handle requests for URLs with an unknown
|
||||
|
@@ -33,7 +33,7 @@
|
||||
// by hand. See the translator.README.txt file in the tools directory for
|
||||
// more information.
|
||||
//
|
||||
// $hash=64e9ebc0e01acca0333ca3419e379d4053892270$
|
||||
// $hash=d0563a0850f6118c850ab01c553142d2e890703e$
|
||||
//
|
||||
|
||||
#ifndef CEF_INCLUDE_CAPI_CEF_SERVER_CAPI_H_
|
||||
@@ -153,7 +153,7 @@ typedef struct _cef_server_t {
|
||||
int connection_id,
|
||||
int response_code,
|
||||
const cef_string_t* content_type,
|
||||
int64 content_length,
|
||||
int64_t content_length,
|
||||
cef_string_multimap_t extra_headers);
|
||||
|
||||
///
|
||||
@@ -203,7 +203,7 @@ typedef struct _cef_server_t {
|
||||
/// server lifespan.
|
||||
///
|
||||
CEF_EXPORT void cef_server_create(const cef_string_t* address,
|
||||
uint16 port,
|
||||
uint16_t port,
|
||||
int backlog,
|
||||
struct _cef_server_handler_t* handler);
|
||||
|
||||
|
@@ -33,7 +33,7 @@
|
||||
// by hand. See the translator.README.txt file in the tools directory for
|
||||
// more information.
|
||||
//
|
||||
// $hash=bbb4153d5d7325ac9a410d7f85a8d47eadcfaf6e$
|
||||
// $hash=5632e62f83aac60e62db9d7f308563fed3285c65$
|
||||
//
|
||||
|
||||
#ifndef CEF_INCLUDE_CAPI_CEF_STREAM_CAPI_H_
|
||||
@@ -70,13 +70,13 @@ typedef struct _cef_read_handler_t {
|
||||
/// failure.
|
||||
///
|
||||
int(CEF_CALLBACK* seek)(struct _cef_read_handler_t* self,
|
||||
int64 offset,
|
||||
int64_t offset,
|
||||
int whence);
|
||||
|
||||
///
|
||||
/// Return the current offset position.
|
||||
///
|
||||
int64(CEF_CALLBACK* tell)(struct _cef_read_handler_t* self);
|
||||
int64_t(CEF_CALLBACK* tell)(struct _cef_read_handler_t* self);
|
||||
|
||||
///
|
||||
/// Return non-zero if at end of file.
|
||||
@@ -115,13 +115,13 @@ typedef struct _cef_stream_reader_t {
|
||||
/// failure.
|
||||
///
|
||||
int(CEF_CALLBACK* seek)(struct _cef_stream_reader_t* self,
|
||||
int64 offset,
|
||||
int64_t offset,
|
||||
int whence);
|
||||
|
||||
///
|
||||
/// Return the current offset position.
|
||||
///
|
||||
int64(CEF_CALLBACK* tell)(struct _cef_stream_reader_t* self);
|
||||
int64_t(CEF_CALLBACK* tell)(struct _cef_stream_reader_t* self);
|
||||
|
||||
///
|
||||
/// Return non-zero if at end of file.
|
||||
@@ -178,13 +178,13 @@ typedef struct _cef_write_handler_t {
|
||||
/// failure.
|
||||
///
|
||||
int(CEF_CALLBACK* seek)(struct _cef_write_handler_t* self,
|
||||
int64 offset,
|
||||
int64_t offset,
|
||||
int whence);
|
||||
|
||||
///
|
||||
/// Return the current offset position.
|
||||
///
|
||||
int64(CEF_CALLBACK* tell)(struct _cef_write_handler_t* self);
|
||||
int64_t(CEF_CALLBACK* tell)(struct _cef_write_handler_t* self);
|
||||
|
||||
///
|
||||
/// Flush the stream.
|
||||
@@ -223,13 +223,13 @@ typedef struct _cef_stream_writer_t {
|
||||
/// failure.
|
||||
///
|
||||
int(CEF_CALLBACK* seek)(struct _cef_stream_writer_t* self,
|
||||
int64 offset,
|
||||
int64_t offset,
|
||||
int whence);
|
||||
|
||||
///
|
||||
/// Return the current offset position.
|
||||
///
|
||||
int64(CEF_CALLBACK* tell)(struct _cef_stream_writer_t* self);
|
||||
int64_t(CEF_CALLBACK* tell)(struct _cef_stream_writer_t* self);
|
||||
|
||||
///
|
||||
/// Flush the stream.
|
||||
|
@@ -33,7 +33,7 @@
|
||||
// by hand. See the translator.README.txt file in the tools directory for
|
||||
// more information.
|
||||
//
|
||||
// $hash=273a6abfd4ac030701be00c45811c19e74e128bd$
|
||||
// $hash=fc609ce5aa3bc51e5cef1f9174dbfc5cff0a0689$
|
||||
//
|
||||
|
||||
#ifndef CEF_INCLUDE_CAPI_CEF_TASK_CAPI_H_
|
||||
@@ -114,7 +114,7 @@ typedef struct _cef_task_runner_t {
|
||||
///
|
||||
int(CEF_CALLBACK* post_delayed_task)(struct _cef_task_runner_t* self,
|
||||
struct _cef_task_t* task,
|
||||
int64 delay_ms);
|
||||
int64_t delay_ms);
|
||||
} cef_task_runner_t;
|
||||
|
||||
///
|
||||
@@ -149,7 +149,7 @@ CEF_EXPORT int cef_post_task(cef_thread_id_t threadId, cef_task_t* task);
|
||||
///
|
||||
CEF_EXPORT int cef_post_delayed_task(cef_thread_id_t threadId,
|
||||
cef_task_t* task,
|
||||
int64 delay_ms);
|
||||
int64_t delay_ms);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
|
@@ -33,7 +33,7 @@
|
||||
// by hand. See the translator.README.txt file in the tools directory for
|
||||
// more information.
|
||||
//
|
||||
// $hash=8d275bd73854b2b8d5a7a5bc55fa737e020705ee$
|
||||
// $hash=28e2d2d86dffdfdad0f275a444656a0638b44d0e$
|
||||
//
|
||||
|
||||
#ifndef CEF_INCLUDE_CAPI_CEF_TRACE_CAPI_H_
|
||||
@@ -109,7 +109,7 @@ CEF_EXPORT int cef_end_tracing(const cef_string_t* tracing_file,
|
||||
/// high-res time. Can be used by clients to synchronize with the time
|
||||
/// information in trace events.
|
||||
///
|
||||
CEF_EXPORT int64 cef_now_from_system_trace_time(void);
|
||||
CEF_EXPORT int64_t cef_now_from_system_trace_time(void);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
|
@@ -33,7 +33,7 @@
|
||||
// by hand. See the translator.README.txt file in the tools directory for
|
||||
// more information.
|
||||
//
|
||||
// $hash=91c121d4353a80d7fff3ef582c5a56ac86e0a34c$
|
||||
// $hash=b038ad859f1dad2d8ba63589da118898350b309c$
|
||||
//
|
||||
|
||||
#ifndef CEF_INCLUDE_CAPI_CEF_URLREQUEST_CAPI_H_
|
||||
@@ -158,8 +158,8 @@ typedef struct _cef_urlrequest_client_t {
|
||||
///
|
||||
void(CEF_CALLBACK* on_upload_progress)(struct _cef_urlrequest_client_t* self,
|
||||
struct _cef_urlrequest_t* request,
|
||||
int64 current,
|
||||
int64 total);
|
||||
int64_t current,
|
||||
int64_t total);
|
||||
|
||||
///
|
||||
/// Notifies the client of download progress. |current| denotes the number of
|
||||
@@ -169,8 +169,8 @@ typedef struct _cef_urlrequest_client_t {
|
||||
void(CEF_CALLBACK* on_download_progress)(
|
||||
struct _cef_urlrequest_client_t* self,
|
||||
struct _cef_urlrequest_t* request,
|
||||
int64 current,
|
||||
int64 total);
|
||||
int64_t current,
|
||||
int64_t total);
|
||||
|
||||
///
|
||||
/// Called when some part of the response is read. |data| contains the current
|
||||
|
@@ -33,7 +33,7 @@
|
||||
// by hand. See the translator.README.txt file in the tools directory for
|
||||
// more information.
|
||||
//
|
||||
// $hash=0d787ac7676ba90d3a1fe68d5e2494b985b1db0e$
|
||||
// $hash=42de7c0e6f5ec529d9182fe4cbf2c1edfacd7392$
|
||||
//
|
||||
|
||||
#ifndef CEF_INCLUDE_CAPI_CEF_V8_CAPI_H_
|
||||
@@ -474,12 +474,12 @@ typedef struct _cef_v8value_t {
|
||||
///
|
||||
/// Return an int value.
|
||||
///
|
||||
int32(CEF_CALLBACK* get_int_value)(struct _cef_v8value_t* self);
|
||||
int32_t(CEF_CALLBACK* get_int_value)(struct _cef_v8value_t* self);
|
||||
|
||||
///
|
||||
/// Return an unsigned int value.
|
||||
///
|
||||
uint32(CEF_CALLBACK* get_uint_value)(struct _cef_v8value_t* self);
|
||||
uint32_t(CEF_CALLBACK* get_uint_value)(struct _cef_v8value_t* self);
|
||||
|
||||
///
|
||||
/// Return a double value.
|
||||
@@ -764,12 +764,12 @@ CEF_EXPORT cef_v8value_t* cef_v8value_create_bool(int value);
|
||||
///
|
||||
/// Create a new cef_v8value_t object of type int.
|
||||
///
|
||||
CEF_EXPORT cef_v8value_t* cef_v8value_create_int(int32 value);
|
||||
CEF_EXPORT cef_v8value_t* cef_v8value_create_int(int32_t value);
|
||||
|
||||
///
|
||||
/// Create a new cef_v8value_t object of type unsigned int.
|
||||
///
|
||||
CEF_EXPORT cef_v8value_t* cef_v8value_create_uint(uint32 value);
|
||||
CEF_EXPORT cef_v8value_t* cef_v8value_create_uint(uint32_t value);
|
||||
|
||||
///
|
||||
/// Create a new cef_v8value_t object of type double.
|
||||
|
@@ -33,7 +33,7 @@
|
||||
// by hand. See the translator.README.txt file in the tools directory for
|
||||
// more information.
|
||||
//
|
||||
// $hash=683d592a2405ada0a9c46c004f003d640a3298ad$
|
||||
// $hash=be3741396459ccf1337f319965ba1dc509142536$
|
||||
//
|
||||
|
||||
#ifndef CEF_INCLUDE_CAPI_CEF_WAITABLE_EVENT_CAPI_H_
|
||||
@@ -96,7 +96,7 @@ typedef struct _cef_waitable_event_t {
|
||||
/// called on the browser process UI or IO threads.
|
||||
///
|
||||
int(CEF_CALLBACK* timed_wait)(struct _cef_waitable_event_t* self,
|
||||
int64 max_ms);
|
||||
int64_t max_ms);
|
||||
} cef_waitable_event_t;
|
||||
|
||||
///
|
||||
|
@@ -33,7 +33,7 @@
|
||||
// by hand. See the translator.README.txt file in the tools directory for
|
||||
// more information.
|
||||
//
|
||||
// $hash=7a541729b4ac664b22cdea625f19f1dba1b6a685$
|
||||
// $hash=a4b62b20f30552fef5d522bdd00ebf9a8f12464c$
|
||||
//
|
||||
|
||||
#ifndef CEF_INCLUDE_CAPI_CEF_X509_CERTIFICATE_CAPI_H_
|
||||
@@ -93,13 +93,6 @@ typedef struct _cef_x509cert_principal_t {
|
||||
cef_string_userfree_t(CEF_CALLBACK* get_country_name)(
|
||||
struct _cef_x509cert_principal_t* self);
|
||||
|
||||
///
|
||||
/// Retrieve the list of street addresses.
|
||||
///
|
||||
void(CEF_CALLBACK* get_street_addresses)(
|
||||
struct _cef_x509cert_principal_t* self,
|
||||
cef_string_list_t addresses);
|
||||
|
||||
///
|
||||
/// Retrieve the list of organization names.
|
||||
///
|
||||
@@ -113,13 +106,6 @@ typedef struct _cef_x509cert_principal_t {
|
||||
void(CEF_CALLBACK* get_organization_unit_names)(
|
||||
struct _cef_x509cert_principal_t* self,
|
||||
cef_string_list_t names);
|
||||
|
||||
///
|
||||
/// Retrieve the list of domain components.
|
||||
///
|
||||
void(CEF_CALLBACK* get_domain_components)(
|
||||
struct _cef_x509cert_principal_t* self,
|
||||
cef_string_list_t components);
|
||||
} cef_x509cert_principal_t;
|
||||
|
||||
///
|
||||
|
@@ -33,7 +33,7 @@
|
||||
// by hand. See the translator.README.txt file in the tools directory for
|
||||
// more information.
|
||||
//
|
||||
// $hash=83debac545c04a630270665b391f52b15484b5d3$
|
||||
// $hash=d082d724164cb0b1da12d49b080c599934f08b9d$
|
||||
//
|
||||
|
||||
#ifndef CEF_INCLUDE_CAPI_CEF_ZIP_READER_CAPI_H_
|
||||
@@ -95,7 +95,7 @@ typedef struct _cef_zip_reader_t {
|
||||
///
|
||||
/// Returns the uncompressed size of the file.
|
||||
///
|
||||
int64(CEF_CALLBACK* get_file_size)(struct _cef_zip_reader_t* self);
|
||||
int64_t(CEF_CALLBACK* get_file_size)(struct _cef_zip_reader_t* self);
|
||||
|
||||
///
|
||||
/// Returns the last modified timestamp for the file.
|
||||
@@ -126,7 +126,7 @@ typedef struct _cef_zip_reader_t {
|
||||
///
|
||||
/// Returns the current offset in the uncompressed file contents.
|
||||
///
|
||||
int64(CEF_CALLBACK* tell)(struct _cef_zip_reader_t* self);
|
||||
int64_t(CEF_CALLBACK* tell)(struct _cef_zip_reader_t* self);
|
||||
|
||||
///
|
||||
/// Returns true (1) if at end of the file contents.
|
||||
|
@@ -33,7 +33,7 @@
|
||||
// by hand. See the translator.README.txt file in the tools directory for
|
||||
// more information.
|
||||
//
|
||||
// $hash=df532eb91caf9de44b077abdf00620dd2508402b$
|
||||
// $hash=f5731d0fffb953f1269b63b478a89bb6b842ac94$
|
||||
//
|
||||
|
||||
#ifndef CEF_INCLUDE_CAPI_TEST_CEF_TEST_SERVER_CAPI_H_
|
||||
@@ -104,7 +104,7 @@ typedef struct _cef_test_server_t {
|
||||
/// started. The server will continue running until Stop is called.
|
||||
///
|
||||
CEF_EXPORT cef_test_server_t* cef_test_server_create_and_start(
|
||||
uint16 port,
|
||||
uint16_t port,
|
||||
int https_server,
|
||||
cef_test_cert_type_t https_cert_type,
|
||||
struct _cef_test_server_handler_t* handler);
|
||||
|
@@ -33,7 +33,7 @@
|
||||
// by hand. See the translator.README.txt file in the tools directory for
|
||||
// more information.
|
||||
//
|
||||
// $hash=e38c41a553d518abcd1b912d32281e99b93c4fd7$
|
||||
// $hash=94e93810316b74e54eb315d97c6fc6f1cc0c9cc5$
|
||||
//
|
||||
|
||||
#ifndef CEF_INCLUDE_CAPI_VIEWS_CEF_BROWSER_VIEW_DELEGATE_CAPI_H_
|
||||
@@ -120,6 +120,18 @@ typedef struct _cef_browser_view_delegate_t {
|
||||
///
|
||||
cef_chrome_toolbar_type_t(CEF_CALLBACK* get_chrome_toolbar_type)(
|
||||
struct _cef_browser_view_delegate_t* self);
|
||||
|
||||
///
|
||||
/// Called when |browser_view| receives a gesture command. Return true (1) to
|
||||
/// handle (or disable) a |gesture_command| or false (0) to propagate the
|
||||
/// gesture to the browser for default handling. This function will only be
|
||||
/// called with the Alloy runtime. To handle these commands with the Chrome
|
||||
/// runtime implement cef_command_handler_t::OnChromeCommand instead.
|
||||
///
|
||||
int(CEF_CALLBACK* on_gesture_command)(
|
||||
struct _cef_browser_view_delegate_t* self,
|
||||
struct _cef_browser_view_t* browser_view,
|
||||
cef_gesture_command_t gesture_command);
|
||||
} cef_browser_view_delegate_t;
|
||||
|
||||
#ifdef __cplusplus
|
||||
|
@@ -33,7 +33,7 @@
|
||||
// by hand. See the translator.README.txt file in the tools directory for
|
||||
// more information.
|
||||
//
|
||||
// $hash=7674d3af52dd4272b454b2028e7a4ee72fb3c9ff$
|
||||
// $hash=2e9acfffaf1dbc70f0c76fcf58a5190326b131ba$
|
||||
//
|
||||
|
||||
#ifndef CEF_INCLUDE_CAPI_VIEWS_CEF_DISPLAY_CAPI_H_
|
||||
@@ -63,7 +63,7 @@ typedef struct _cef_display_t {
|
||||
///
|
||||
/// Returns the unique identifier for this Display.
|
||||
///
|
||||
int64(CEF_CALLBACK* get_id)(struct _cef_display_t* self);
|
||||
int64_t(CEF_CALLBACK* get_id)(struct _cef_display_t* self);
|
||||
|
||||
///
|
||||
/// Returns this Display's device pixel scale factor. This specifies how much
|
||||
|
@@ -33,7 +33,7 @@
|
||||
// by hand. See the translator.README.txt file in the tools directory for
|
||||
// more information.
|
||||
//
|
||||
// $hash=04aa6e193cc5d5658c0ef28a42c0777c0a955409$
|
||||
// $hash=d53c4a0a7e731a56a0edcb9d705c76b0a2770155$
|
||||
//
|
||||
|
||||
#ifndef CEF_INCLUDE_CAPI_VIEWS_CEF_WINDOW_CAPI_H_
|
||||
@@ -51,6 +51,8 @@
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
struct _cef_browser_view_t;
|
||||
|
||||
///
|
||||
/// A Window is a top-level Window/widget in the Views hierarchy. By default it
|
||||
/// will have a non-client area with title bar, icon and buttons that supports
|
||||
@@ -69,6 +71,21 @@ typedef struct _cef_window_t {
|
||||
///
|
||||
void(CEF_CALLBACK* show)(struct _cef_window_t* self);
|
||||
|
||||
///
|
||||
/// Show the Window as a browser modal dialog relative to |browser_view|. A
|
||||
/// parent Window must be returned via
|
||||
/// cef_window_delegate_t::get_parent_window() and |browser_view| must belong
|
||||
/// to that parent Window. While this Window is visible, |browser_view| will
|
||||
/// be disabled while other controls in the parent Window remain enabled.
|
||||
/// Navigating or destroying the |browser_view| will close this Window
|
||||
/// automatically. Alternately, use show() and return true (1) from
|
||||
/// cef_window_delegate_t::is_window_modal_dialog() for a window modal dialog
|
||||
/// where all controls in the parent Window are disabled.
|
||||
///
|
||||
void(CEF_CALLBACK* show_as_browser_modal_dialog)(
|
||||
struct _cef_window_t* self,
|
||||
struct _cef_browser_view_t* browser_view);
|
||||
|
||||
///
|
||||
/// Hide the Window.
|
||||
///
|
||||
@@ -286,7 +303,7 @@ typedef struct _cef_window_t {
|
||||
///
|
||||
void(CEF_CALLBACK* send_key_press)(struct _cef_window_t* self,
|
||||
int key_code,
|
||||
uint32 event_flags);
|
||||
uint32_t event_flags);
|
||||
|
||||
///
|
||||
/// Simulate a mouse move. The mouse cursor will be moved to the specified
|
||||
|
@@ -33,7 +33,7 @@
|
||||
// by hand. See the translator.README.txt file in the tools directory for
|
||||
// more information.
|
||||
//
|
||||
// $hash=7201d268e16fc89f255b6ccd00d043f34fe77584$
|
||||
// $hash=61099a1ba8b16a5e46f5a80d326d1f9bfc99317d$
|
||||
//
|
||||
|
||||
#ifndef CEF_INCLUDE_CAPI_VIEWS_CEF_WINDOW_DELEGATE_CAPI_H_
|
||||
@@ -110,6 +110,18 @@ typedef struct _cef_window_delegate_t {
|
||||
int* is_menu,
|
||||
int* can_activate_menu);
|
||||
|
||||
///
|
||||
/// Return true (1) if |window| should be created as a window modal dialog.
|
||||
/// Only called when a Window is returned via get_parent_window() with
|
||||
/// |is_menu| set to false (0). All controls in the parent Window will be
|
||||
/// disabled while |window| is visible. This functionality is not supported by
|
||||
/// all Linux window managers. Alternately, use
|
||||
/// cef_window_t::show_as_browser_modal_dialog() for a browser modal dialog
|
||||
/// that works on all platforms.
|
||||
///
|
||||
int(CEF_CALLBACK* is_window_modal_dialog)(struct _cef_window_delegate_t* self,
|
||||
struct _cef_window_t* window);
|
||||
|
||||
///
|
||||
/// Return the initial bounds for |window| in density independent pixel (DIP)
|
||||
/// coordinates. If this function returns an NULL CefRect then
|
||||
|
@@ -42,13 +42,13 @@
|
||||
// way that may cause binary incompatibility with other builds. The universal
|
||||
// hash value will change if any platform is affected whereas the platform hash
|
||||
// values will change only if that particular platform is affected.
|
||||
#define CEF_API_HASH_UNIVERSAL "defb610a3c797b3636da085bd008fb24c46c8242"
|
||||
#define CEF_API_HASH_UNIVERSAL "9c9fbc9d59a544c8e0c2f0cbed4b6622f2786f1c"
|
||||
#if defined(OS_WIN)
|
||||
#define CEF_API_HASH_PLATFORM "b47966e88841b7aa5546ead8a2021892d51886b1"
|
||||
#define CEF_API_HASH_PLATFORM "240e06747f2ea2d7d4a3071042d45cf80d170420"
|
||||
#elif defined(OS_MAC)
|
||||
#define CEF_API_HASH_PLATFORM "da69054d32deecf2476aeb30607036e074413730"
|
||||
#define CEF_API_HASH_PLATFORM "cd4a815153a919ad30b95c659688b564823d92fc"
|
||||
#elif defined(OS_LINUX)
|
||||
#define CEF_API_HASH_PLATFORM "00ed1b02f30b01ed1c841e1ef515f1b77f9832e6"
|
||||
#define CEF_API_HASH_PLATFORM "4c372cb13e3446b2a54aaaea51b0d47ba7766152"
|
||||
#endif
|
||||
|
||||
#ifdef __cplusplus
|
||||
|
@@ -87,7 +87,7 @@ class CefAudioHandler : public virtual CefBaseRefCounted {
|
||||
virtual void OnAudioStreamPacket(CefRefPtr<CefBrowser> browser,
|
||||
const float** data,
|
||||
int frames,
|
||||
int64 pts) = 0;
|
||||
int64_t pts) = 0;
|
||||
|
||||
///
|
||||
/// Called on the UI thread when the stream has stopped. OnAudioSteamStopped
|
||||
|
@@ -170,7 +170,7 @@ class CefBrowser : public virtual CefBaseRefCounted {
|
||||
/// Returns the frame with the specified identifier, or NULL if not found.
|
||||
///
|
||||
/*--cef(capi_name=get_frame_byident)--*/
|
||||
virtual CefRefPtr<CefFrame> GetFrame(int64 identifier) = 0;
|
||||
virtual CefRefPtr<CefFrame> GetFrame(int64_t identifier) = 0;
|
||||
|
||||
///
|
||||
/// Returns the frame with the specified name, or NULL if not found.
|
||||
@@ -188,7 +188,7 @@ class CefBrowser : public virtual CefBaseRefCounted {
|
||||
/// Returns the identifiers of all existing frames.
|
||||
///
|
||||
/*--cef(count_func=identifiers:GetFrameCount)--*/
|
||||
virtual void GetFrameIdentifiers(std::vector<int64>& identifiers) = 0;
|
||||
virtual void GetFrameIdentifiers(std::vector<int64_t>& identifiers) = 0;
|
||||
|
||||
///
|
||||
/// Returns the names of all existing frames.
|
||||
@@ -456,7 +456,7 @@ class CefBrowserHost : public virtual CefBaseRefCounted {
|
||||
/*--cef()--*/
|
||||
virtual void DownloadImage(const CefString& image_url,
|
||||
bool is_favicon,
|
||||
uint32 max_image_size,
|
||||
uint32_t max_image_size,
|
||||
bool bypass_cache,
|
||||
CefRefPtr<CefDownloadImageCallback> callback) = 0;
|
||||
|
||||
|
@@ -111,7 +111,7 @@ class CefBrowserProcessHandler : public virtual CefBaseRefCounted {
|
||||
/// pending scheduled call should be cancelled.
|
||||
///
|
||||
/*--cef()--*/
|
||||
virtual void OnScheduleMessagePumpWork(int64 delay_ms) {}
|
||||
virtual void OnScheduleMessagePumpWork(int64_t delay_ms) {}
|
||||
|
||||
///
|
||||
/// Return the default client for use with a newly created browser window. If
|
||||
|
@@ -82,7 +82,7 @@
|
||||
/// If "AppName" is set on Windows then crash report information (metrics,
|
||||
/// database and dumps) will be stored locally on disk under the
|
||||
/// "C:\Users\[CurrentUser]\AppData\Local\[AppName]\User Data" folder. On other
|
||||
/// platforms the cef_settings_t.user_data_path value will be used.
|
||||
/// platforms the cef_settings_t.root_cache_path value will be used.
|
||||
///
|
||||
/// If "ExternalHandler" is set on Windows then the specified exe will be
|
||||
/// launched as the crashpad-handler instead of re-launching the main process
|
||||
|
@@ -87,7 +87,7 @@ class CefDownloadItem : public virtual CefBaseRefCounted {
|
||||
/// Returns a simple speed estimate in bytes/s.
|
||||
///
|
||||
/*--cef()--*/
|
||||
virtual int64 GetCurrentSpeed() = 0;
|
||||
virtual int64_t GetCurrentSpeed() = 0;
|
||||
|
||||
///
|
||||
/// Returns the rough percent complete or -1 if the receive total size is
|
||||
@@ -100,13 +100,13 @@ class CefDownloadItem : public virtual CefBaseRefCounted {
|
||||
/// Returns the total number of bytes.
|
||||
///
|
||||
/*--cef()--*/
|
||||
virtual int64 GetTotalBytes() = 0;
|
||||
virtual int64_t GetTotalBytes() = 0;
|
||||
|
||||
///
|
||||
/// Returns the number of received bytes.
|
||||
///
|
||||
/*--cef()--*/
|
||||
virtual int64 GetReceivedBytes() = 0;
|
||||
virtual int64_t GetReceivedBytes() = 0;
|
||||
|
||||
///
|
||||
/// Returns the time that the download started.
|
||||
@@ -130,7 +130,7 @@ class CefDownloadItem : public virtual CefBaseRefCounted {
|
||||
/// Returns the unique identifier for this download.
|
||||
///
|
||||
/*--cef()--*/
|
||||
virtual uint32 GetId() = 0;
|
||||
virtual uint32_t GetId() = 0;
|
||||
|
||||
///
|
||||
/// Returns the URL.
|
||||
|
@@ -184,7 +184,7 @@ class CefFrame : public virtual CefBaseRefCounted {
|
||||
/// underlying frame does not yet exist.
|
||||
///
|
||||
/*--cef()--*/
|
||||
virtual int64 GetIdentifier() = 0;
|
||||
virtual int64_t GetIdentifier() = 0;
|
||||
|
||||
///
|
||||
/// Returns the parent of this frame or NULL if this is the main (top-level)
|
||||
|
@@ -57,7 +57,7 @@ class CefMediaAccessCallback : public virtual CefBaseRefCounted {
|
||||
/// OnRequestMediaAccessPermission.
|
||||
///
|
||||
/*--cef(capi_name=cont)--*/
|
||||
virtual void Continue(uint32 allowed_permissions) = 0;
|
||||
virtual void Continue(uint32_t allowed_permissions) = 0;
|
||||
|
||||
///
|
||||
/// Cancel the media access request.
|
||||
@@ -104,7 +104,7 @@ class CefPermissionHandler : public virtual CefBaseRefCounted {
|
||||
CefRefPtr<CefBrowser> browser,
|
||||
CefRefPtr<CefFrame> frame,
|
||||
const CefString& requesting_origin,
|
||||
uint32 requested_permissions,
|
||||
uint32_t requested_permissions,
|
||||
CefRefPtr<CefMediaAccessCallback> callback) {
|
||||
return false;
|
||||
}
|
||||
@@ -123,9 +123,9 @@ class CefPermissionHandler : public virtual CefBaseRefCounted {
|
||||
/*--cef()--*/
|
||||
virtual bool OnShowPermissionPrompt(
|
||||
CefRefPtr<CefBrowser> browser,
|
||||
uint64 prompt_id,
|
||||
uint64_t prompt_id,
|
||||
const CefString& requesting_origin,
|
||||
uint32 requested_permissions,
|
||||
uint32_t requested_permissions,
|
||||
CefRefPtr<CefPermissionPromptCallback> callback) {
|
||||
return false;
|
||||
}
|
||||
@@ -142,7 +142,7 @@ class CefPermissionHandler : public virtual CefBaseRefCounted {
|
||||
/*--cef()--*/
|
||||
virtual void OnDismissPermissionPrompt(
|
||||
CefRefPtr<CefBrowser> browser,
|
||||
uint64 prompt_id,
|
||||
uint64_t prompt_id,
|
||||
cef_permission_request_result_t result) {}
|
||||
};
|
||||
|
||||
|
@@ -217,7 +217,7 @@ class CefRequest : public virtual CefBaseRefCounted {
|
||||
/// browser process to track a single request across multiple callbacks.
|
||||
///
|
||||
/*--cef()--*/
|
||||
virtual uint64 GetIdentifier() = 0;
|
||||
virtual uint64_t GetIdentifier() = 0;
|
||||
};
|
||||
|
||||
///
|
||||
|
@@ -46,6 +46,7 @@
|
||||
#include "include/cef_extension_handler.h"
|
||||
#include "include/cef_media_router.h"
|
||||
#include "include/cef_preference.h"
|
||||
#include "include/cef_values.h"
|
||||
|
||||
class CefRequestContextHandler;
|
||||
class CefSchemeHandlerFactory;
|
||||
@@ -314,6 +315,72 @@ class CefRequestContext : public CefPreferenceManager {
|
||||
/*--cef(optional_param=callback)--*/
|
||||
virtual CefRefPtr<CefMediaRouter> GetMediaRouter(
|
||||
CefRefPtr<CefCompletionCallback> callback) = 0;
|
||||
|
||||
///
|
||||
/// Returns the current value for |content_type| that applies for the
|
||||
/// specified URLs. If both URLs are empty the default value will be returned.
|
||||
/// Returns nullptr if no value is configured. Must be called on the browser
|
||||
/// process UI thread.
|
||||
///
|
||||
/*--cef(optional_param=requesting_url,optional_param=top_level_url)--*/
|
||||
virtual CefRefPtr<CefValue> GetWebsiteSetting(
|
||||
const CefString& requesting_url,
|
||||
const CefString& top_level_url,
|
||||
cef_content_setting_types_t content_type) = 0;
|
||||
|
||||
///
|
||||
/// Sets the current value for |content_type| for the specified URLs in the
|
||||
/// default scope. If both URLs are empty, and the context is not incognito,
|
||||
/// the default value will be set. Pass nullptr for |value| to remove the
|
||||
/// default value for this content type.
|
||||
///
|
||||
/// WARNING: Incorrect usage of this method may cause instability or security
|
||||
/// issues in Chromium. Make sure that you first understand the potential
|
||||
/// impact of any changes to |content_type| by reviewing the related source
|
||||
/// code in Chromium. For example, if you plan to modify
|
||||
/// CEF_CONTENT_SETTING_TYPE_POPUPS, first review and understand the usage of
|
||||
/// ContentSettingsType::POPUPS in Chromium:
|
||||
/// https://source.chromium.org/search?q=ContentSettingsType::POPUPS
|
||||
///
|
||||
/*--cef(optional_param=requesting_url,optional_param=top_level_url,
|
||||
optional_param=value)--*/
|
||||
virtual void SetWebsiteSetting(const CefString& requesting_url,
|
||||
const CefString& top_level_url,
|
||||
cef_content_setting_types_t content_type,
|
||||
CefRefPtr<CefValue> value) = 0;
|
||||
|
||||
///
|
||||
/// Returns the current value for |content_type| that applies for the
|
||||
/// specified URLs. If both URLs are empty the default value will be returned.
|
||||
/// Returns CEF_CONTENT_SETTING_VALUE_DEFAULT if no value is configured. Must
|
||||
/// be called on the browser process UI thread.
|
||||
///
|
||||
/*--cef(optional_param=requesting_url,optional_param=top_level_url,
|
||||
default_retval=CEF_CONTENT_SETTING_VALUE_DEFAULT)--*/
|
||||
virtual cef_content_setting_values_t GetContentSetting(
|
||||
const CefString& requesting_url,
|
||||
const CefString& top_level_url,
|
||||
cef_content_setting_types_t content_type) = 0;
|
||||
|
||||
///
|
||||
/// Sets the current value for |content_type| for the specified URLs in the
|
||||
/// default scope. If both URLs are empty, and the context is not incognito,
|
||||
/// the default value will be set. Pass CEF_CONTENT_SETTING_VALUE_DEFAULT for
|
||||
/// |value| to use the default value for this content type.
|
||||
///
|
||||
/// WARNING: Incorrect usage of this method may cause instability or security
|
||||
/// issues in Chromium. Make sure that you first understand the potential
|
||||
/// impact of any changes to |content_type| by reviewing the related source
|
||||
/// code in Chromium. For example, if you plan to modify
|
||||
/// CEF_CONTENT_SETTING_TYPE_POPUPS, first review and understand the usage of
|
||||
/// ContentSettingsType::POPUPS in Chromium:
|
||||
/// https://source.chromium.org/search?q=ContentSettingsType::POPUPS
|
||||
///
|
||||
/*--cef(optional_param=requesting_url,optional_param=top_level_url)--*/
|
||||
virtual void SetContentSetting(const CefString& requesting_url,
|
||||
const CefString& top_level_url,
|
||||
cef_content_setting_types_t content_type,
|
||||
cef_content_setting_values_t value) = 0;
|
||||
};
|
||||
|
||||
#endif // CEF_INCLUDE_CEF_REQUEST_CONTEXT_H_
|
||||
|
@@ -58,7 +58,7 @@ class CefResourceSkipCallback : public virtual CefBaseRefCounted {
|
||||
/// <= 0 the request will fail with ERR_REQUEST_RANGE_NOT_SATISFIABLE.
|
||||
///
|
||||
/*--cef(capi_name=cont)--*/
|
||||
virtual void Continue(int64 bytes_skipped) = 0;
|
||||
virtual void Continue(int64_t bytes_skipped) = 0;
|
||||
};
|
||||
|
||||
///
|
||||
@@ -136,7 +136,7 @@ class CefResourceHandler : public virtual CefBaseRefCounted {
|
||||
///
|
||||
/*--cef()--*/
|
||||
virtual void GetResponseHeaders(CefRefPtr<CefResponse> response,
|
||||
int64& response_length,
|
||||
int64_t& response_length,
|
||||
CefString& redirectUrl) = 0;
|
||||
|
||||
///
|
||||
@@ -149,8 +149,8 @@ class CefResourceHandler : public virtual CefBaseRefCounted {
|
||||
/// method will be called in sequence but not from a dedicated thread.
|
||||
///
|
||||
/*--cef()--*/
|
||||
virtual bool Skip(int64 bytes_to_skip,
|
||||
int64& bytes_skipped,
|
||||
virtual bool Skip(int64_t bytes_to_skip,
|
||||
int64_t& bytes_skipped,
|
||||
CefRefPtr<CefResourceSkipCallback> callback) {
|
||||
bytes_skipped = -2;
|
||||
return false;
|
||||
|
@@ -187,7 +187,7 @@ class CefResourceRequestHandler : public virtual CefBaseRefCounted {
|
||||
CefRefPtr<CefRequest> request,
|
||||
CefRefPtr<CefResponse> response,
|
||||
URLRequestStatus status,
|
||||
int64 received_content_length) {}
|
||||
int64_t received_content_length) {}
|
||||
|
||||
///
|
||||
/// Called on the IO thread to handle requests for URLs with an unknown
|
||||
|
@@ -74,7 +74,7 @@ class CefServer : public CefBaseRefCounted {
|
||||
///
|
||||
/*--cef()--*/
|
||||
static void CreateServer(const CefString& address,
|
||||
uint16 port,
|
||||
uint16_t port,
|
||||
int backlog,
|
||||
CefRefPtr<CefServerHandler> handler);
|
||||
|
||||
@@ -170,7 +170,7 @@ class CefServer : public CefBaseRefCounted {
|
||||
virtual void SendHttpResponse(int connection_id,
|
||||
int response_code,
|
||||
const CefString& content_type,
|
||||
int64 content_length,
|
||||
int64_t content_length,
|
||||
const HeaderMap& extra_headers) = 0;
|
||||
|
||||
///
|
||||
|
@@ -58,13 +58,13 @@ class CefReadHandler : public virtual CefBaseRefCounted {
|
||||
/// failure.
|
||||
///
|
||||
/*--cef()--*/
|
||||
virtual int Seek(int64 offset, int whence) = 0;
|
||||
virtual int Seek(int64_t offset, int whence) = 0;
|
||||
|
||||
///
|
||||
/// Return the current offset position.
|
||||
///
|
||||
/*--cef()--*/
|
||||
virtual int64 Tell() = 0;
|
||||
virtual int64_t Tell() = 0;
|
||||
|
||||
///
|
||||
/// Return non-zero if at end of file.
|
||||
@@ -119,13 +119,13 @@ class CefStreamReader : public virtual CefBaseRefCounted {
|
||||
/// failure.
|
||||
///
|
||||
/*--cef()--*/
|
||||
virtual int Seek(int64 offset, int whence) = 0;
|
||||
virtual int Seek(int64_t offset, int whence) = 0;
|
||||
|
||||
///
|
||||
/// Return the current offset position.
|
||||
///
|
||||
/*--cef()--*/
|
||||
virtual int64 Tell() = 0;
|
||||
virtual int64_t Tell() = 0;
|
||||
|
||||
///
|
||||
/// Return non-zero if at end of file.
|
||||
@@ -161,13 +161,13 @@ class CefWriteHandler : public virtual CefBaseRefCounted {
|
||||
/// failure.
|
||||
///
|
||||
/*--cef()--*/
|
||||
virtual int Seek(int64 offset, int whence) = 0;
|
||||
virtual int Seek(int64_t offset, int whence) = 0;
|
||||
|
||||
///
|
||||
/// Return the current offset position.
|
||||
///
|
||||
/*--cef()--*/
|
||||
virtual int64 Tell() = 0;
|
||||
virtual int64_t Tell() = 0;
|
||||
|
||||
///
|
||||
/// Flush the stream.
|
||||
@@ -215,13 +215,13 @@ class CefStreamWriter : public virtual CefBaseRefCounted {
|
||||
/// failure.
|
||||
///
|
||||
/*--cef()--*/
|
||||
virtual int Seek(int64 offset, int whence) = 0;
|
||||
virtual int Seek(int64_t offset, int whence) = 0;
|
||||
|
||||
///
|
||||
/// Return the current offset position.
|
||||
///
|
||||
/*--cef()--*/
|
||||
virtual int64 Tell() = 0;
|
||||
virtual int64_t Tell() = 0;
|
||||
|
||||
///
|
||||
/// Flush the stream.
|
||||
|
@@ -118,7 +118,7 @@ class CefTaskRunner : public virtual CefBaseRefCounted {
|
||||
/// specified delay.
|
||||
///
|
||||
/*--cef()--*/
|
||||
virtual bool PostDelayedTask(CefRefPtr<CefTask> task, int64 delay_ms) = 0;
|
||||
virtual bool PostDelayedTask(CefRefPtr<CefTask> task, int64_t delay_ms) = 0;
|
||||
};
|
||||
|
||||
///
|
||||
@@ -143,6 +143,6 @@ bool CefPostTask(CefThreadId threadId, CefRefPtr<CefTask> task);
|
||||
/*--cef()--*/
|
||||
bool CefPostDelayedTask(CefThreadId threadId,
|
||||
CefRefPtr<CefTask> task,
|
||||
int64 delay_ms);
|
||||
int64_t delay_ms);
|
||||
|
||||
#endif // CEF_INCLUDE_CEF_TASK_H_
|
||||
|
@@ -106,6 +106,6 @@ bool CefEndTracing(const CefString& tracing_file,
|
||||
/// information in trace events.
|
||||
///
|
||||
/*--cef()--*/
|
||||
int64 CefNowFromSystemTraceTime();
|
||||
int64_t CefNowFromSystemTraceTime();
|
||||
|
||||
#endif // CEF_INCLUDE_CEF_TRACE_H_
|
||||
|
@@ -152,8 +152,8 @@ class CefURLRequestClient : public virtual CefBaseRefCounted {
|
||||
///
|
||||
/*--cef()--*/
|
||||
virtual void OnUploadProgress(CefRefPtr<CefURLRequest> request,
|
||||
int64 current,
|
||||
int64 total) = 0;
|
||||
int64_t current,
|
||||
int64_t total) = 0;
|
||||
|
||||
///
|
||||
/// Notifies the client of download progress. |current| denotes the number of
|
||||
@@ -162,8 +162,8 @@ class CefURLRequestClient : public virtual CefBaseRefCounted {
|
||||
///
|
||||
/*--cef()--*/
|
||||
virtual void OnDownloadProgress(CefRefPtr<CefURLRequest> request,
|
||||
int64 current,
|
||||
int64 total) = 0;
|
||||
int64_t current,
|
||||
int64_t total) = 0;
|
||||
|
||||
///
|
||||
/// Called when some part of the response is read. |data| contains the current
|
||||
|
@@ -459,13 +459,13 @@ class CefV8Value : public virtual CefBaseRefCounted {
|
||||
/// Create a new CefV8Value object of type int.
|
||||
///
|
||||
/*--cef()--*/
|
||||
static CefRefPtr<CefV8Value> CreateInt(int32 value);
|
||||
static CefRefPtr<CefV8Value> CreateInt(int32_t value);
|
||||
|
||||
///
|
||||
/// Create a new CefV8Value object of type unsigned int.
|
||||
///
|
||||
/*--cef()--*/
|
||||
static CefRefPtr<CefV8Value> CreateUInt(uint32 value);
|
||||
static CefRefPtr<CefV8Value> CreateUInt(uint32_t value);
|
||||
|
||||
///
|
||||
/// Create a new CefV8Value object of type double.
|
||||
@@ -648,13 +648,13 @@ class CefV8Value : public virtual CefBaseRefCounted {
|
||||
/// Return an int value.
|
||||
///
|
||||
/*--cef()--*/
|
||||
virtual int32 GetIntValue() = 0;
|
||||
virtual int32_t GetIntValue() = 0;
|
||||
|
||||
///
|
||||
/// Return an unsigned int value.
|
||||
///
|
||||
/*--cef()--*/
|
||||
virtual uint32 GetUIntValue() = 0;
|
||||
virtual uint32_t GetUIntValue() = 0;
|
||||
|
||||
///
|
||||
/// Return a double value.
|
||||
|
@@ -103,7 +103,7 @@ class CefWaitableEvent : public CefBaseRefCounted {
|
||||
/// called on the browser process UI or IO threads.
|
||||
///
|
||||
/*--cef()--*/
|
||||
virtual bool TimedWait(int64 max_ms) = 0;
|
||||
virtual bool TimedWait(int64_t max_ms) = 0;
|
||||
};
|
||||
|
||||
#endif // CEF_INCLUDE_CEF_WAITABLE_EVENT_H_
|
||||
|
@@ -81,12 +81,6 @@ class CefX509CertPrincipal : public virtual CefBaseRefCounted {
|
||||
/*--cef()--*/
|
||||
virtual CefString GetCountryName() = 0;
|
||||
|
||||
///
|
||||
/// Retrieve the list of street addresses.
|
||||
///
|
||||
/*--cef()--*/
|
||||
virtual void GetStreetAddresses(std::vector<CefString>& addresses) = 0;
|
||||
|
||||
///
|
||||
/// Retrieve the list of organization names.
|
||||
///
|
||||
@@ -98,12 +92,6 @@ class CefX509CertPrincipal : public virtual CefBaseRefCounted {
|
||||
///
|
||||
/*--cef()--*/
|
||||
virtual void GetOrganizationUnitNames(std::vector<CefString>& names) = 0;
|
||||
|
||||
///
|
||||
/// Retrieve the list of domain components.
|
||||
///
|
||||
/*--cef()--*/
|
||||
virtual void GetDomainComponents(std::vector<CefString>& components) = 0;
|
||||
};
|
||||
|
||||
///
|
||||
|
@@ -96,7 +96,7 @@ class CefZipReader : public virtual CefBaseRefCounted {
|
||||
/// Returns the uncompressed size of the file.
|
||||
///
|
||||
/*--cef()--*/
|
||||
virtual int64 GetFileSize() = 0;
|
||||
virtual int64_t GetFileSize() = 0;
|
||||
|
||||
///
|
||||
/// Returns the last modified timestamp for the file.
|
||||
@@ -128,7 +128,7 @@ class CefZipReader : public virtual CefBaseRefCounted {
|
||||
/// Returns the current offset in the uncompressed file contents.
|
||||
///
|
||||
/*--cef()--*/
|
||||
virtual int64 Tell() = 0;
|
||||
virtual int64_t Tell() = 0;
|
||||
|
||||
///
|
||||
/// Returns true if at end of the file contents.
|
||||
|
@@ -74,7 +74,7 @@ typedef cef_string_userfree_utf8_t cef_string_userfree_t;
|
||||
#define cef_string_to_wide cef_string_utf8_to_wide
|
||||
#define cef_string_from_wide cef_string_wide_to_utf8
|
||||
#elif defined(CEF_STRING_TYPE_UTF16)
|
||||
typedef char16 cef_char_t;
|
||||
typedef char16_t cef_char_t;
|
||||
typedef cef_string_userfree_utf16_t cef_string_userfree_t;
|
||||
typedef cef_string_utf16_t cef_string_t;
|
||||
#define cef_string_set cef_string_utf16_set
|
||||
|
@@ -33,7 +33,18 @@
|
||||
|
||||
#include <stddef.h>
|
||||
|
||||
#include "include/base/cef_basictypes.h"
|
||||
#ifdef __clang__
|
||||
// On macOS, <uchar.h> is only available with Xcode 14.3+.
|
||||
#if __has_include(<uchar.h>)
|
||||
#include <uchar.h>
|
||||
#elif !defined(__cplusplus)
|
||||
#include <stdint.h>
|
||||
typedef uint_least16_t char16_t;
|
||||
#endif
|
||||
#else
|
||||
#include <uchar.h>
|
||||
#endif
|
||||
|
||||
#include "include/internal/cef_export.h"
|
||||
|
||||
///
|
||||
@@ -70,9 +81,9 @@ typedef struct _cef_string_utf8_t {
|
||||
} cef_string_utf8_t;
|
||||
|
||||
typedef struct _cef_string_utf16_t {
|
||||
char16* str;
|
||||
char16_t* str;
|
||||
size_t length;
|
||||
void (*dtor)(char16* str);
|
||||
void (*dtor)(char16_t* str);
|
||||
} cef_string_utf16_t;
|
||||
|
||||
///
|
||||
@@ -89,7 +100,7 @@ CEF_EXPORT int cef_string_utf8_set(const char* src,
|
||||
size_t src_len,
|
||||
cef_string_utf8_t* output,
|
||||
int copy);
|
||||
CEF_EXPORT int cef_string_utf16_set(const char16* src,
|
||||
CEF_EXPORT int cef_string_utf16_set(const char16_t* src,
|
||||
size_t src_len,
|
||||
cef_string_utf16_t* output,
|
||||
int copy);
|
||||
@@ -141,14 +152,14 @@ CEF_EXPORT int cef_string_utf8_to_wide(const char* src,
|
||||
CEF_EXPORT int cef_string_wide_to_utf16(const wchar_t* src,
|
||||
size_t src_len,
|
||||
cef_string_utf16_t* output);
|
||||
CEF_EXPORT int cef_string_utf16_to_wide(const char16* src,
|
||||
CEF_EXPORT int cef_string_utf16_to_wide(const char16_t* src,
|
||||
size_t src_len,
|
||||
cef_string_wide_t* output);
|
||||
|
||||
CEF_EXPORT int cef_string_utf8_to_utf16(const char* src,
|
||||
size_t src_len,
|
||||
cef_string_utf16_t* output);
|
||||
CEF_EXPORT int cef_string_utf16_to_utf8(const char16* src,
|
||||
CEF_EXPORT int cef_string_utf16_to_utf8(const char16_t* src,
|
||||
size_t src_len,
|
||||
cef_string_utf8_t* output);
|
||||
|
||||
@@ -198,10 +209,10 @@ CEF_EXPORT void cef_string_userfree_utf16_free(cef_string_userfree_utf16_t str);
|
||||
/// may change the length of the string in some cases.
|
||||
///
|
||||
|
||||
CEF_EXPORT int cef_string_utf16_to_lower(const char16* src,
|
||||
CEF_EXPORT int cef_string_utf16_to_lower(const char16_t* src,
|
||||
size_t src_len,
|
||||
cef_string_utf16_t* output);
|
||||
CEF_EXPORT int cef_string_utf16_to_upper(const char16* src,
|
||||
CEF_EXPORT int cef_string_utf16_to_upper(const char16_t* src,
|
||||
size_t src_len,
|
||||
cef_string_utf16_t* output);
|
||||
|
||||
|
@@ -115,7 +115,7 @@ struct CefStringTraitsWide {
|
||||
static inline bool from_string16(const std::u16string::value_type* data,
|
||||
size_t length,
|
||||
struct_type* s) {
|
||||
return cef_string_utf16_to_wide(reinterpret_cast<const char16*>(data),
|
||||
return cef_string_utf16_to_wide(reinterpret_cast<const char16_t*>(data),
|
||||
length, s)
|
||||
? true
|
||||
: false;
|
||||
@@ -213,7 +213,7 @@ struct CefStringTraitsUTF8 {
|
||||
static inline bool from_string16(const std::u16string::value_type* data,
|
||||
size_t length,
|
||||
struct_type* s) {
|
||||
return cef_string_utf16_to_utf8(reinterpret_cast<const char16*>(data),
|
||||
return cef_string_utf16_to_utf8(reinterpret_cast<const char16_t*>(data),
|
||||
length, s)
|
||||
? true
|
||||
: false;
|
||||
@@ -227,7 +227,7 @@ struct CefStringTraitsUTF8 {
|
||||
/// Traits implementation for utf16 character strings.
|
||||
///
|
||||
struct CefStringTraitsUTF16 {
|
||||
typedef char16 char_type;
|
||||
typedef char16_t char_type;
|
||||
typedef cef_string_utf16_t struct_type;
|
||||
typedef cef_string_userfree_utf16_t userfree_struct_type;
|
||||
|
||||
@@ -290,12 +290,15 @@ struct CefStringTraitsUTF16 {
|
||||
}
|
||||
#else // WCHAR_T_IS_UTF32
|
||||
static inline std::wstring to_wstring(const struct_type* s) {
|
||||
return std::wstring(s->str, s->length);
|
||||
return std::wstring(reinterpret_cast<wchar_t*>(s->str), s->length);
|
||||
}
|
||||
static inline bool from_wstring(const std::wstring::value_type* data,
|
||||
size_t length,
|
||||
struct_type* s) {
|
||||
return cef_string_utf16_set(data, length, s, true) ? true : false;
|
||||
return cef_string_utf16_set(reinterpret_cast<const char16_t*>(data), length,
|
||||
s, true)
|
||||
? true
|
||||
: false;
|
||||
}
|
||||
#endif // WCHAR_T_IS_UTF32
|
||||
static inline bool from_wstring(const std::wstring& str, struct_type* s) {
|
||||
@@ -308,7 +311,7 @@ struct CefStringTraitsUTF16 {
|
||||
static inline bool from_string16(const std::u16string::value_type* data,
|
||||
size_t length,
|
||||
struct_type* s) {
|
||||
return cef_string_utf16_set(reinterpret_cast<const char16*>(data), length,
|
||||
return cef_string_utf16_set(reinterpret_cast<const char16_t*>(data), length,
|
||||
s, true)
|
||||
? true
|
||||
: false;
|
||||
@@ -412,15 +415,6 @@ class CefStringBase {
|
||||
FromString16(src, length);
|
||||
}
|
||||
}
|
||||
#if defined(WCHAR_T_IS_UTF32)
|
||||
CefStringBase(const char16* src, size_t length = 0)
|
||||
: string_(NULL), owner_(false) {
|
||||
if (src) {
|
||||
FromString16(reinterpret_cast<const std::u16string::value_type*>(src),
|
||||
length);
|
||||
}
|
||||
}
|
||||
#endif // WCHAR_T_IS_UTF32
|
||||
|
||||
///
|
||||
/// Create a new string from an existing character array. If |copy| is true
|
||||
@@ -826,12 +820,6 @@ class CefStringBase {
|
||||
FromString16(str);
|
||||
return *this;
|
||||
}
|
||||
#if defined(WCHAR_T_IS_UTF32)
|
||||
CefStringBase& operator=(const char16* str) {
|
||||
FromString16(reinterpret_cast<const std::u16string::value_type*>(str));
|
||||
return *this;
|
||||
}
|
||||
#endif // WCHAR_T_IS_UTF32
|
||||
#if defined(USING_CHROMIUM_INCLUDES)
|
||||
// The base::FilePath constructor is marked as explicit so provide the
|
||||
// conversion here for convenience.
|
||||
|
@@ -35,8 +35,9 @@
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#include <stdint.h>
|
||||
#include <time.h>
|
||||
#include "include/base/cef_basictypes.h"
|
||||
|
||||
#include "include/internal/cef_export.h"
|
||||
|
||||
///
|
||||
@@ -47,7 +48,7 @@ extern "C" {
|
||||
/// This is equivalent of Chromium `base::Time` (see base/time/time.h).
|
||||
///
|
||||
typedef struct _cef_basetime_t {
|
||||
int64 val;
|
||||
int64_t val;
|
||||
} cef_basetime_t;
|
||||
|
||||
///
|
||||
|
@@ -45,77 +45,66 @@ extern "C" {
|
||||
// may not include "(quotes) chars.
|
||||
// - |argX_name|, |argX_val|, |valueX_name|, |valeX_val| are optional parameters
|
||||
// and represent pairs of name and values of arguments
|
||||
// - |copy| is used to avoid memory scoping issues with the |name| and
|
||||
// |arg_name| parameters by copying them
|
||||
// - |id| is used to disambiguate counters with the same name, or match async
|
||||
// trace events
|
||||
|
||||
CEF_EXPORT void cef_trace_event_instant(const char* category,
|
||||
const char* name,
|
||||
const char* arg1_name,
|
||||
uint64 arg1_val,
|
||||
uint64_t arg1_val,
|
||||
const char* arg2_name,
|
||||
uint64 arg2_val,
|
||||
int copy);
|
||||
uint64_t arg2_val);
|
||||
CEF_EXPORT void cef_trace_event_begin(const char* category,
|
||||
const char* name,
|
||||
const char* arg1_name,
|
||||
uint64 arg1_val,
|
||||
uint64_t arg1_val,
|
||||
const char* arg2_name,
|
||||
uint64 arg2_val,
|
||||
int copy);
|
||||
uint64_t arg2_val);
|
||||
CEF_EXPORT void cef_trace_event_end(const char* category,
|
||||
const char* name,
|
||||
const char* arg1_name,
|
||||
uint64 arg1_val,
|
||||
uint64_t arg1_val,
|
||||
const char* arg2_name,
|
||||
uint64 arg2_val,
|
||||
int copy);
|
||||
uint64_t arg2_val);
|
||||
CEF_EXPORT void cef_trace_counter(const char* category,
|
||||
const char* name,
|
||||
const char* value1_name,
|
||||
uint64 value1_val,
|
||||
uint64_t value1_val,
|
||||
const char* value2_name,
|
||||
uint64 value2_val,
|
||||
int copy);
|
||||
uint64_t value2_val);
|
||||
CEF_EXPORT void cef_trace_counter_id(const char* category,
|
||||
const char* name,
|
||||
uint64 id,
|
||||
uint64_t id,
|
||||
const char* value1_name,
|
||||
uint64 value1_val,
|
||||
uint64_t value1_val,
|
||||
const char* value2_name,
|
||||
uint64 value2_val,
|
||||
int copy);
|
||||
uint64_t value2_val);
|
||||
CEF_EXPORT void cef_trace_event_async_begin(const char* category,
|
||||
const char* name,
|
||||
uint64 id,
|
||||
uint64_t id,
|
||||
const char* arg1_name,
|
||||
uint64 arg1_val,
|
||||
uint64_t arg1_val,
|
||||
const char* arg2_name,
|
||||
uint64 arg2_val,
|
||||
int copy);
|
||||
uint64_t arg2_val);
|
||||
CEF_EXPORT void cef_trace_event_async_step_into(const char* category,
|
||||
const char* name,
|
||||
uint64 id,
|
||||
uint64 step,
|
||||
uint64_t id,
|
||||
uint64_t step,
|
||||
const char* arg1_name,
|
||||
uint64 arg1_val,
|
||||
int copy);
|
||||
uint64_t arg1_val);
|
||||
CEF_EXPORT void cef_trace_event_async_step_past(const char* category,
|
||||
const char* name,
|
||||
uint64 id,
|
||||
uint64 step,
|
||||
uint64_t id,
|
||||
uint64_t step,
|
||||
const char* arg1_name,
|
||||
uint64 arg1_val,
|
||||
int copy);
|
||||
uint64_t arg1_val);
|
||||
CEF_EXPORT void cef_trace_event_async_end(const char* category,
|
||||
const char* name,
|
||||
uint64 id,
|
||||
uint64_t id,
|
||||
const char* arg1_name,
|
||||
uint64 arg1_val,
|
||||
uint64_t arg1_val,
|
||||
const char* arg2_name,
|
||||
uint64 arg2_val,
|
||||
int copy);
|
||||
uint64_t arg2_val);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
|
@@ -31,10 +31,14 @@
|
||||
#define CEF_INCLUDE_INTERNAL_CEF_TYPES_H_
|
||||
#pragma once
|
||||
|
||||
#include "include/base/cef_basictypes.h"
|
||||
#include <limits.h>
|
||||
#include <stddef.h>
|
||||
#include <stdint.h>
|
||||
|
||||
#include "include/internal/cef_string.h"
|
||||
#include "include/internal/cef_string_list.h"
|
||||
#include "include/internal/cef_time.h"
|
||||
#include "include/internal/cef_types_content_settings.h"
|
||||
#include "include/internal/cef_types_geometry.h"
|
||||
|
||||
// Bring in platform-specific definitions.
|
||||
@@ -48,7 +52,7 @@
|
||||
|
||||
// 32-bit ARGB color value, not premultiplied. The color components are always
|
||||
// in a known order. Equivalent to the SkColor type.
|
||||
typedef uint32 cef_color_t;
|
||||
typedef uint32_t cef_color_t;
|
||||
|
||||
// Return the alpha byte from a cef_color_t value.
|
||||
#define CefColorGetA(color) (((color) >> 24) & 0xFF)
|
||||
@@ -65,17 +69,18 @@ typedef uint32 cef_color_t;
|
||||
(static_cast<unsigned>(a) << 24) | (static_cast<unsigned>(r) << 16) | \
|
||||
(static_cast<unsigned>(g) << 8) | (static_cast<unsigned>(b) << 0))
|
||||
|
||||
// Return an int64 value with the specified low and high int32 component values.
|
||||
#define CefInt64Set(int32_low, int32_high) \
|
||||
static_cast<int64>((static_cast<uint32>(int32_low)) | \
|
||||
(static_cast<int64>(static_cast<int32>(int32_high))) \
|
||||
<< 32)
|
||||
// Return an int64_t value with the specified low and high int32_t component
|
||||
// values.
|
||||
#define CefInt64Set(int32_low, int32_high) \
|
||||
static_cast<int64_t>( \
|
||||
(static_cast<uint32_t>(int32_low)) | \
|
||||
(static_cast<int64_t>(static_cast<int32_t>(int32_high))) << 32)
|
||||
|
||||
// Return the low int32 value from an int64 value.
|
||||
#define CefInt64GetLow(int64_val) static_cast<int32>(int64_val)
|
||||
// Return the high int32 value from an int64 value.
|
||||
// Return the low int32_t value from an int64_t value.
|
||||
#define CefInt64GetLow(int64_val) static_cast<int32_t>(int64_val)
|
||||
// Return the high int32_t value from an int64_t value.
|
||||
#define CefInt64GetHigh(int64_val) \
|
||||
static_cast<int32>((static_cast<int64>(int64_val) >> 32) & 0xFFFFFFFFL)
|
||||
static_cast<int32_t>((static_cast<int64_t>(int64_val) >> 32) & 0xFFFFFFFFL)
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
@@ -255,24 +260,16 @@ typedef struct _cef_settings_t {
|
||||
/// The root directory that all CefSettings.cache_path and
|
||||
/// CefRequestContextSettings.cache_path values must have in common. If this
|
||||
/// value is empty and CefSettings.cache_path is non-empty then it will
|
||||
/// default to the CefSettings.cache_path value. If this value is non-empty
|
||||
/// then it must be an absolute path. Failure to set this value correctly may
|
||||
/// result in the sandbox blocking read/write access to the cache_path
|
||||
/// directory.
|
||||
///
|
||||
cef_string_t root_cache_path;
|
||||
|
||||
///
|
||||
/// The location where user data such as the Widevine CDM module and spell
|
||||
/// checking dictionary files will be stored on disk. If this value is empty
|
||||
/// then the default platform-specific user data directory will be used
|
||||
/// default to the CefSettings.cache_path value. If both values are empty
|
||||
/// then the default platform-specific directory will be used
|
||||
/// ("~/.config/cef_user_data" directory on Linux, "~/Library/Application
|
||||
/// Support/CEF/User Data" directory on MacOS, "AppData\Local\CEF\User Data"
|
||||
/// directory under the user profile directory on Windows). If this value is
|
||||
/// non-empty then it must be an absolute path. When using the Chrome runtime
|
||||
/// this value will be ignored in favor of the |root_cache_path| value.
|
||||
/// non-empty then it must be an absolute path. Failure to set this value
|
||||
/// correctly may result in the sandbox blocking read/write access to certain
|
||||
/// files.
|
||||
///
|
||||
cef_string_t user_data_path;
|
||||
cef_string_t root_cache_path;
|
||||
|
||||
///
|
||||
/// To persist session cookies (cookies without an expiry date or validity
|
||||
@@ -1778,7 +1775,7 @@ typedef struct _cef_mouse_event_t {
|
||||
/// Bit flags describing any pressed modifier keys. See
|
||||
/// cef_event_flags_t for values.
|
||||
///
|
||||
uint32 modifiers;
|
||||
uint32_t modifiers;
|
||||
} cef_mouse_event_t;
|
||||
|
||||
///
|
||||
@@ -1856,7 +1853,7 @@ typedef struct _cef_touch_event_t {
|
||||
/// Bit flags describing any pressed modifier keys. See
|
||||
/// cef_event_flags_t for values.
|
||||
///
|
||||
uint32 modifiers;
|
||||
uint32_t modifiers;
|
||||
|
||||
///
|
||||
/// The device type that caused the event.
|
||||
@@ -2069,7 +2066,7 @@ typedef struct _cef_key_event_t {
|
||||
/// Bit flags describing any pressed modifier keys. See
|
||||
/// cef_event_flags_t for values.
|
||||
///
|
||||
uint32 modifiers;
|
||||
uint32_t modifiers;
|
||||
|
||||
///
|
||||
/// The Windows key code for the key event. This value is used by the DOM
|
||||
@@ -2094,13 +2091,13 @@ typedef struct _cef_key_event_t {
|
||||
///
|
||||
/// The character generated by the keystroke.
|
||||
///
|
||||
char16 character;
|
||||
char16_t character;
|
||||
|
||||
///
|
||||
/// Same as |character| but unmodified by any concurrently-held modifiers
|
||||
/// (except shift). This is useful for working out shortcut keys.
|
||||
///
|
||||
char16 unmodified_character;
|
||||
char16_t unmodified_character;
|
||||
|
||||
///
|
||||
/// True if the focus is currently on an editable field on the page. This is
|
||||
@@ -3000,8 +2997,8 @@ typedef enum {
|
||||
/// Structure representing a range.
|
||||
///
|
||||
typedef struct _cef_range_t {
|
||||
int from;
|
||||
int to;
|
||||
uint32_t from;
|
||||
uint32_t to;
|
||||
} cef_range_t;
|
||||
|
||||
///
|
||||
@@ -3289,7 +3286,8 @@ typedef enum {
|
||||
CEF_CPAIT_VIRTUAL_CARD_MANUAL_FALLBACK,
|
||||
CEF_CPAIT_ZOOM,
|
||||
CEF_CPAIT_SAVE_IBAN,
|
||||
CEF_CPAIT_MAX_VALUE = CEF_CPAIT_SAVE_IBAN,
|
||||
CEF_CPAIT_MANDATORY_REAUTH,
|
||||
CEF_CPAIT_MAX_VALUE = CEF_CPAIT_MANDATORY_REAUTH,
|
||||
} cef_chrome_page_action_icon_type_t;
|
||||
|
||||
///
|
||||
@@ -3346,7 +3344,7 @@ typedef struct _cef_touch_handle_state_t {
|
||||
/// Combination of cef_touch_handle_state_flags_t values indicating what state
|
||||
/// is set.
|
||||
///
|
||||
uint32 flags;
|
||||
uint32_t flags;
|
||||
|
||||
///
|
||||
/// Enabled state. Only set if |flags| contains CEF_THS_FLAG_ENABLED.
|
||||
@@ -3605,6 +3603,14 @@ typedef enum {
|
||||
CEF_DOWNLOAD_INTERRUPT_REASON_CRASH = 50,
|
||||
} cef_download_interrupt_reason_t;
|
||||
|
||||
///
|
||||
/// Specifies the gesture commands.
|
||||
///
|
||||
typedef enum {
|
||||
CEF_GESTURE_COMMAND_BACK,
|
||||
CEF_GESTURE_COMMAND_FORWARD,
|
||||
} cef_gesture_command_t;
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
368
include/internal/cef_types_content_settings.h
Normal file
368
include/internal/cef_types_content_settings.h
Normal file
@@ -0,0 +1,368 @@
|
||||
// Copyright (c) 2023 Marshall A. Greenblatt. All rights reserved.
|
||||
//
|
||||
// Redistribution and use in source and binary forms, with or without
|
||||
// modification, are permitted provided that the following conditions are
|
||||
// met:
|
||||
//
|
||||
// * Redistributions of source code must retain the above copyright
|
||||
// notice, this list of conditions and the following disclaimer.
|
||||
// * Redistributions in binary form must reproduce the above
|
||||
// copyright notice, this list of conditions and the following disclaimer
|
||||
// in the documentation and/or other materials provided with the
|
||||
// distribution.
|
||||
// * Neither the name of Google Inc. nor the name Chromium Embedded
|
||||
// Framework nor the names of its contributors may be used to endorse
|
||||
// or promote products derived from this software without specific prior
|
||||
// written permission.
|
||||
//
|
||||
// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
|
||||
// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
|
||||
// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
|
||||
// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
|
||||
// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
|
||||
// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
||||
// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
||||
// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
||||
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
#ifndef CEF_INCLUDE_INTERNAL_CEF_TYPES_CONTENT_SETTINGS_H_
|
||||
#define CEF_INCLUDE_INTERNAL_CEF_TYPES_CONTENT_SETTINGS_H_
|
||||
#pragma once
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
///
|
||||
/// Supported content setting types. Some types are platform-specific or only
|
||||
/// supported with the Chrome runtime. Should be kept in sync with Chromium's
|
||||
/// ContentSettingsType type.
|
||||
///
|
||||
typedef enum {
|
||||
CEF_CONTENT_SETTING_TYPE_COOKIES = 0,
|
||||
CEF_CONTENT_SETTING_TYPE_IMAGES,
|
||||
CEF_CONTENT_SETTING_TYPE_JAVASCRIPT,
|
||||
|
||||
/// This setting governs both popups and unwanted redirects like tab-unders
|
||||
/// and framebusting.
|
||||
CEF_CONTENT_SETTING_TYPE_POPUPS,
|
||||
|
||||
CEF_CONTENT_SETTING_TYPE_GEOLOCATION,
|
||||
CEF_CONTENT_SETTING_TYPE_NOTIFICATIONS,
|
||||
CEF_CONTENT_SETTING_TYPE_AUTO_SELECT_CERTIFICATE,
|
||||
CEF_CONTENT_SETTING_TYPE_MIXEDSCRIPT,
|
||||
CEF_CONTENT_SETTING_TYPE_MEDIASTREAM_MIC,
|
||||
CEF_CONTENT_SETTING_TYPE_MEDIASTREAM_CAMERA,
|
||||
CEF_CONTENT_SETTING_TYPE_PROTOCOL_HANDLERS,
|
||||
CEF_CONTENT_SETTING_TYPE_DEPRECATED_PPAPI_BROKER,
|
||||
CEF_CONTENT_SETTING_TYPE_AUTOMATIC_DOWNLOADS,
|
||||
CEF_CONTENT_SETTING_TYPE_MIDI_SYSEX,
|
||||
CEF_CONTENT_SETTING_TYPE_SSL_CERT_DECISIONS,
|
||||
CEF_CONTENT_SETTING_TYPE_PROTECTED_MEDIA_IDENTIFIER,
|
||||
CEF_CONTENT_SETTING_TYPE_APP_BANNER,
|
||||
CEF_CONTENT_SETTING_TYPE_SITE_ENGAGEMENT,
|
||||
CEF_CONTENT_SETTING_TYPE_DURABLE_STORAGE,
|
||||
CEF_CONTENT_SETTING_TYPE_USB_CHOOSER_DATA,
|
||||
CEF_CONTENT_SETTING_TYPE_BLUETOOTH_GUARD,
|
||||
CEF_CONTENT_SETTING_TYPE_BACKGROUND_SYNC,
|
||||
CEF_CONTENT_SETTING_TYPE_AUTOPLAY,
|
||||
CEF_CONTENT_SETTING_TYPE_IMPORTANT_SITE_INFO,
|
||||
CEF_CONTENT_SETTING_TYPE_PERMISSION_AUTOBLOCKER_DATA,
|
||||
CEF_CONTENT_SETTING_TYPE_ADS,
|
||||
|
||||
/// Website setting which stores metadata for the subresource filter to aid in
|
||||
/// decisions for whether or not to show the UI.
|
||||
CEF_CONTENT_SETTING_TYPE_ADS_DATA,
|
||||
|
||||
/// This is special-cased in the permissions layer to always allow, and as
|
||||
/// such doesn't have associated prefs data.
|
||||
CEF_CONTENT_SETTING_TYPE_MIDI,
|
||||
|
||||
/// This content setting type is for caching password protection service's
|
||||
/// verdicts of each origin.
|
||||
CEF_CONTENT_SETTING_TYPE_PASSWORD_PROTECTION,
|
||||
|
||||
/// Website setting which stores engagement data for media related to a
|
||||
/// specific origin.
|
||||
CEF_CONTENT_SETTING_TYPE_MEDIA_ENGAGEMENT,
|
||||
|
||||
/// Content setting which stores whether or not the site can play audible
|
||||
/// sound. This will not block playback but instead the user will not hear it.
|
||||
CEF_CONTENT_SETTING_TYPE_SOUND,
|
||||
|
||||
/// Website setting which stores the list of client hints that the origin
|
||||
/// requested the browser to remember. The browser is expected to send all
|
||||
/// client hints in the HTTP request headers for every resource requested
|
||||
/// from that origin.
|
||||
CEF_CONTENT_SETTING_TYPE_CLIENT_HINTS,
|
||||
|
||||
/// Generic Sensor API covering ambient-light-sensor, accelerometer, gyroscope
|
||||
/// and magnetometer are all mapped to a single content_settings_type.
|
||||
/// Setting for the Generic Sensor API covering ambient-light-sensor,
|
||||
/// accelerometer, gyroscope and magnetometer. These are all mapped to a
|
||||
/// single ContentSettingsType.
|
||||
CEF_CONTENT_SETTING_TYPE_SENSORS,
|
||||
|
||||
/// Content setting which stores whether or not the user has granted the site
|
||||
/// permission to respond to accessibility events, which can be used to
|
||||
/// provide a custom accessibility experience. Requires explicit user consent
|
||||
/// because some users may not want sites to know they're using assistive
|
||||
/// technology.
|
||||
CEF_CONTENT_SETTING_TYPE_ACCESSIBILITY_EVENTS,
|
||||
|
||||
/// Used to store whether to allow a website to install a payment handler.
|
||||
CEF_CONTENT_SETTING_TYPE_PAYMENT_HANDLER,
|
||||
|
||||
/// Content setting which stores whether to allow sites to ask for permission
|
||||
/// to access USB devices. If this is allowed specific device permissions are
|
||||
/// stored under USB_CHOOSER_DATA.
|
||||
CEF_CONTENT_SETTING_TYPE_USB_GUARD,
|
||||
|
||||
/// Nothing is stored in this setting at present. Please refer to
|
||||
/// BackgroundFetchPermissionContext for details on how this permission
|
||||
/// is ascertained.
|
||||
CEF_CONTENT_SETTING_TYPE_BACKGROUND_FETCH,
|
||||
|
||||
/// Website setting which stores the amount of times the user has dismissed
|
||||
/// intent picker UI without explicitly choosing an option.
|
||||
CEF_CONTENT_SETTING_TYPE_INTENT_PICKER_DISPLAY,
|
||||
|
||||
/// Used to store whether to allow a website to detect user active/idle state.
|
||||
CEF_CONTENT_SETTING_TYPE_IDLE_DETECTION,
|
||||
|
||||
/// Setting for enabling auto-select of all screens for getDisplayMediaSet.
|
||||
CEF_CONTENT_SETTING_TYPE_GET_DISPLAY_MEDIA_SET_SELECT_ALL_SCREENS,
|
||||
|
||||
/// Content settings for access to serial ports. The "guard" content setting
|
||||
/// stores whether to allow sites to ask for permission to access a port. The
|
||||
/// permissions granted to access particular ports are stored in the "chooser
|
||||
/// data" website setting.
|
||||
CEF_CONTENT_SETTING_TYPE_SERIAL_GUARD,
|
||||
CEF_CONTENT_SETTING_TYPE_SERIAL_CHOOSER_DATA,
|
||||
|
||||
/// Nothing is stored in this setting at present. Please refer to
|
||||
/// PeriodicBackgroundSyncPermissionContext for details on how this permission
|
||||
/// is ascertained.
|
||||
/// This content setting is not registered because it does not require access
|
||||
/// to any existing providers.
|
||||
CEF_CONTENT_SETTING_TYPE_PERIODIC_BACKGROUND_SYNC,
|
||||
|
||||
/// Content setting which stores whether to allow sites to ask for permission
|
||||
/// to do Bluetooth scanning.
|
||||
CEF_CONTENT_SETTING_TYPE_BLUETOOTH_SCANNING,
|
||||
|
||||
/// Content settings for access to HID devices. The "guard" content setting
|
||||
/// stores whether to allow sites to ask for permission to access a device.
|
||||
/// The permissions granted to access particular devices are stored in the
|
||||
/// "chooser data" website setting.
|
||||
CEF_CONTENT_SETTING_TYPE_HID_GUARD,
|
||||
CEF_CONTENT_SETTING_TYPE_HID_CHOOSER_DATA,
|
||||
|
||||
/// Wake Lock API, which has two lock types: screen and system locks.
|
||||
/// Currently, screen locks do not need any additional permission, and system
|
||||
/// locks are always denied while the right UI is worked out.
|
||||
CEF_CONTENT_SETTING_TYPE_WAKE_LOCK_SCREEN,
|
||||
CEF_CONTENT_SETTING_TYPE_WAKE_LOCK_SYSTEM,
|
||||
|
||||
/// Legacy SameSite cookie behavior. This disables SameSite=Lax-by-default,
|
||||
/// SameSite=None requires Secure, and Schemeful Same-Site, forcing the
|
||||
/// legacy behavior wherein 1) cookies that don't specify SameSite are treated
|
||||
/// as SameSite=None, 2) SameSite=None cookies are not required to be Secure,
|
||||
/// and 3) schemeful same-site is not active.
|
||||
///
|
||||
/// This will also be used to revert to legacy behavior when future changes
|
||||
/// in cookie handling are introduced.
|
||||
CEF_CONTENT_SETTING_TYPE_LEGACY_COOKIE_ACCESS,
|
||||
|
||||
/// Content settings which stores whether to allow sites to ask for permission
|
||||
/// to save changes to an original file selected by the user through the
|
||||
/// File System Access API.
|
||||
CEF_CONTENT_SETTING_TYPE_FILE_SYSTEM_WRITE_GUARD,
|
||||
|
||||
/// Used to store whether to allow a website to exchange data with NFC
|
||||
/// devices.
|
||||
CEF_CONTENT_SETTING_TYPE_NFC,
|
||||
|
||||
/// Website setting to store permissions granted to access particular
|
||||
/// Bluetooth devices.
|
||||
CEF_CONTENT_SETTING_TYPE_BLUETOOTH_CHOOSER_DATA,
|
||||
|
||||
/// Full access to the system clipboard (sanitized read without user gesture,
|
||||
/// and unsanitized read and write with user gesture).
|
||||
CEF_CONTENT_SETTING_TYPE_CLIPBOARD_READ_WRITE,
|
||||
|
||||
/// This is special-cased in the permissions layer to always allow, and as
|
||||
/// such doesn't have associated prefs data.
|
||||
CEF_CONTENT_SETTING_TYPE_CLIPBOARD_SANITIZED_WRITE,
|
||||
|
||||
/// This content setting type is for caching safe browsing real time url
|
||||
/// check's verdicts of each origin.
|
||||
CEF_CONTENT_SETTING_TYPE_SAFE_BROWSING_URL_CHECK_DATA,
|
||||
|
||||
/// Used to store whether a site is allowed to request AR or VR sessions with
|
||||
/// the WebXr Device API.
|
||||
CEF_CONTENT_SETTING_TYPE_VR,
|
||||
CEF_CONTENT_SETTING_TYPE_AR,
|
||||
|
||||
/// Content setting which stores whether to allow site to open and read files
|
||||
/// and directories selected through the File System Access API.
|
||||
CEF_CONTENT_SETTING_TYPE_FILE_SYSTEM_READ_GUARD,
|
||||
|
||||
/// Access to first party storage in a third-party context. Exceptions are
|
||||
/// scoped to the combination of requesting/top-level origin, and are managed
|
||||
/// through the Storage Access API. For the time being, this content setting
|
||||
/// exists in parallel to third-party cookie rules stored in COOKIES.
|
||||
CEF_CONTENT_SETTING_TYPE_STORAGE_ACCESS,
|
||||
|
||||
/// Content setting which stores whether to allow a site to control camera
|
||||
/// movements. It does not give access to camera.
|
||||
CEF_CONTENT_SETTING_TYPE_CAMERA_PAN_TILT_ZOOM,
|
||||
|
||||
/// Content setting for Screen Enumeration and Screen Detail functionality.
|
||||
/// Permits access to detailed multi-screen information, like size and
|
||||
/// position. Permits placing fullscreen and windowed content on specific
|
||||
/// screens. See also: https://w3c.github.io/window-placement
|
||||
CEF_CONTENT_SETTING_TYPE_WINDOW_MANAGEMENT,
|
||||
|
||||
/// Stores whether to allow insecure websites to make local network requests.
|
||||
/// See also: https://wicg.github.io/local-network-access
|
||||
/// Set through enterprise policies only.
|
||||
CEF_CONTENT_SETTING_TYPE_INSECURE_LOCAL_NETWORK,
|
||||
|
||||
/// Content setting which stores whether or not a site can access low-level
|
||||
/// locally installed font data using the Local Fonts Access API.
|
||||
CEF_CONTENT_SETTING_TYPE_LOCAL_FONTS,
|
||||
|
||||
/// Stores per-origin state for permission auto-revocation (for all permission
|
||||
/// types).
|
||||
CEF_CONTENT_SETTING_TYPE_PERMISSION_AUTOREVOCATION_DATA,
|
||||
|
||||
/// Stores per-origin state of the most recently selected directory for the
|
||||
/// use by the File System Access API.
|
||||
CEF_CONTENT_SETTING_TYPE_FILE_SYSTEM_LAST_PICKED_DIRECTORY,
|
||||
|
||||
/// Controls access to the getDisplayMedia API when {preferCurrentTab: true}
|
||||
/// is specified.
|
||||
CEF_CONTENT_SETTING_TYPE_DISPLAY_CAPTURE,
|
||||
|
||||
/// Website setting to store permissions metadata granted to paths on the
|
||||
/// local file system via the File System Access API.
|
||||
/// |FILE_SYSTEM_WRITE_GUARD| is the corresponding "guard" setting.
|
||||
CEF_CONTENT_SETTING_TYPE_FILE_SYSTEM_ACCESS_CHOOSER_DATA,
|
||||
|
||||
/// Stores a grant that allows a relying party to send a request for identity
|
||||
/// information to specified identity providers, potentially through any
|
||||
/// anti-tracking measures that would otherwise prevent it. This setting is
|
||||
/// associated with the relying party's origin.
|
||||
CEF_CONTENT_SETTING_TYPE_FEDERATED_IDENTITY_SHARING,
|
||||
|
||||
/// Whether to use the v8 optimized JIT for running JavaScript on the page.
|
||||
CEF_CONTENT_SETTING_TYPE_JAVASCRIPT_JIT,
|
||||
|
||||
/// Content setting which stores user decisions to allow loading a site over
|
||||
/// HTTP. Entries are added by hostname when a user bypasses the HTTPS-First
|
||||
/// Mode interstitial warning when a site does not support HTTPS. Allowed
|
||||
/// hosts are exact hostname matches -- subdomains of a host on the allowlist
|
||||
/// must be separately allowlisted.
|
||||
CEF_CONTENT_SETTING_TYPE_HTTP_ALLOWED,
|
||||
|
||||
/// Stores metadata related to form fill, such as e.g. whether user data was
|
||||
/// autofilled on a specific website.
|
||||
CEF_CONTENT_SETTING_TYPE_FORMFILL_METADATA,
|
||||
|
||||
/// Setting to indicate that there is an active federated sign-in session
|
||||
/// between a specified relying party and a specified identity provider for
|
||||
/// a specified account. When this is present it allows access to session
|
||||
/// management capabilities between the sites. This setting is associated
|
||||
/// with the relying party's origin.
|
||||
CEF_CONTENT_SETTING_TYPE_FEDERATED_IDENTITY_ACTIVE_SESSION,
|
||||
|
||||
/// Setting to indicate whether Chrome should automatically apply darkening to
|
||||
/// web content.
|
||||
CEF_CONTENT_SETTING_TYPE_AUTO_DARK_WEB_CONTENT,
|
||||
|
||||
/// Setting to indicate whether Chrome should request the desktop view of a
|
||||
/// site instead of the mobile one.
|
||||
CEF_CONTENT_SETTING_TYPE_REQUEST_DESKTOP_SITE,
|
||||
|
||||
/// Setting to indicate whether browser should allow signing into a website
|
||||
/// via the browser FedCM API.
|
||||
CEF_CONTENT_SETTING_TYPE_FEDERATED_IDENTITY_API,
|
||||
|
||||
/// Stores notification interactions per origin for the past 90 days.
|
||||
/// Interactions per origin are pre-aggregated over seven-day windows: A
|
||||
/// notification interaction or display is assigned to the last Monday
|
||||
/// midnight in local time.
|
||||
CEF_CONTENT_SETTING_TYPE_NOTIFICATION_INTERACTIONS,
|
||||
|
||||
/// Website setting which stores the last reduced accept language negotiated
|
||||
/// for a given origin, to be used on future visits to the origin.
|
||||
CEF_CONTENT_SETTING_TYPE_REDUCED_ACCEPT_LANGUAGE,
|
||||
|
||||
/// Website setting which is used for NotificationPermissionReviewService to
|
||||
/// store origin blocklist from review notification permissions feature.
|
||||
CEF_CONTENT_SETTING_TYPE_NOTIFICATION_PERMISSION_REVIEW,
|
||||
|
||||
/// Website setting to store permissions granted to access particular devices
|
||||
/// in private network.
|
||||
CEF_CONTENT_SETTING_TYPE_PRIVATE_NETWORK_GUARD,
|
||||
CEF_CONTENT_SETTING_TYPE_PRIVATE_NETWORK_CHOOSER_DATA,
|
||||
|
||||
/// Website setting which stores whether the browser has observed the user
|
||||
/// signing into an identity-provider based on observing the IdP-SignIn-Status
|
||||
/// HTTP header.
|
||||
CEF_CONTENT_SETTING_TYPE_FEDERATED_IDENTITY_IDENTITY_PROVIDER_SIGNIN_STATUS,
|
||||
|
||||
/// Website setting which is used for UnusedSitePermissionsService to
|
||||
/// store revoked permissions of unused sites from unused site permissions
|
||||
/// feature.
|
||||
CEF_CONTENT_SETTING_TYPE_REVOKED_UNUSED_SITE_PERMISSIONS,
|
||||
|
||||
/// Similar to STORAGE_ACCESS, but applicable at the page-level rather than
|
||||
/// being specific to a frame.
|
||||
CEF_CONTENT_SETTING_TYPE_TOP_LEVEL_STORAGE_ACCESS,
|
||||
|
||||
/// Setting to indicate whether user has opted in to allowing auto re-authn
|
||||
/// via the FedCM API.
|
||||
CEF_CONTENT_SETTING_TYPE_FEDERATED_IDENTITY_AUTO_REAUTHN_PERMISSION,
|
||||
|
||||
/// Website setting which stores whether the user has explicitly registered
|
||||
/// a website as an identity-provider.
|
||||
CEF_CONTENT_SETTING_TYPE_FEDERATED_IDENTITY_IDENTITY_PROVIDER_REGISTRATION,
|
||||
|
||||
/// Content setting which is used to indicate whether anti-abuse functionality
|
||||
/// should be enabled.
|
||||
CEF_CONTENT_SETTING_TYPE_ANTI_ABUSE,
|
||||
|
||||
/// Content setting used to indicate whether third-party storage partitioning
|
||||
/// should be enabled.
|
||||
CEF_CONTENT_SETTING_TYPE_THIRD_PARTY_STORAGE_PARTITIONING,
|
||||
|
||||
/// Used to indicate whether HTTPS-First Mode is enabled on the hostname.
|
||||
CEF_CONTENT_SETTING_TYPE_HTTPS_ENFORCED,
|
||||
|
||||
CEF_CONTENT_SETTING_TYPE_NUM_TYPES,
|
||||
} cef_content_setting_types_t;
|
||||
|
||||
///
|
||||
/// Supported content setting values. Should be kept in sync with Chromium's
|
||||
/// ContentSetting type.
|
||||
///
|
||||
typedef enum {
|
||||
CEF_CONTENT_SETTING_VALUE_DEFAULT = 0,
|
||||
CEF_CONTENT_SETTING_VALUE_ALLOW,
|
||||
CEF_CONTENT_SETTING_VALUE_BLOCK,
|
||||
CEF_CONTENT_SETTING_VALUE_ASK,
|
||||
CEF_CONTENT_SETTING_VALUE_SESSION_ONLY,
|
||||
CEF_CONTENT_SETTING_VALUE_DETECT_IMPORTANT_CONTENT,
|
||||
|
||||
CEF_CONTENT_SETTING_VALUE_NUM_VALUES
|
||||
} cef_content_setting_values_t;
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif // CEF_INCLUDE_INTERNAL_CEF_TYPES_CONTENT_SETTINGS_H_
|
@@ -31,6 +31,8 @@
|
||||
#define CEF_INCLUDE_INTERNAL_CEF_TYPES_WRAPPERS_H_
|
||||
#pragma once
|
||||
|
||||
#include <limits>
|
||||
|
||||
#include "include/internal/cef_string.h"
|
||||
#include "include/internal/cef_string_list.h"
|
||||
#include "include/internal/cef_types.h"
|
||||
@@ -215,7 +217,12 @@ class CefRange : public cef_range_t {
|
||||
public:
|
||||
CefRange() : cef_range_t{} {}
|
||||
CefRange(const cef_range_t& r) : cef_range_t(r) {}
|
||||
CefRange(int from, int to) : cef_range_t{from, to} {}
|
||||
CefRange(uint32_t from, uint32_t to) : cef_range_t{from, to} {}
|
||||
|
||||
static CefRange InvalidRange() {
|
||||
return CefRange((std::numeric_limits<uint32_t>::max)(),
|
||||
(std::numeric_limits<uint32_t>::max)());
|
||||
}
|
||||
|
||||
void Set(int from_val, int to_val) { from = from_val, to = to_val; }
|
||||
};
|
||||
@@ -357,7 +364,6 @@ struct CefSettingsTraits {
|
||||
cef_string_clear(&s->main_bundle_path);
|
||||
cef_string_clear(&s->cache_path);
|
||||
cef_string_clear(&s->root_cache_path);
|
||||
cef_string_clear(&s->user_data_path);
|
||||
cef_string_clear(&s->user_agent);
|
||||
cef_string_clear(&s->user_agent_product);
|
||||
cef_string_clear(&s->locale);
|
||||
@@ -390,8 +396,6 @@ struct CefSettingsTraits {
|
||||
&target->cache_path, copy);
|
||||
cef_string_set(src->root_cache_path.str, src->root_cache_path.length,
|
||||
&target->root_cache_path, copy);
|
||||
cef_string_set(src->user_data_path.str, src->user_data_path.length,
|
||||
&target->user_data_path, copy);
|
||||
target->persist_session_cookies = src->persist_session_cookies;
|
||||
target->persist_user_preferences = src->persist_user_preferences;
|
||||
|
||||
|
@@ -86,7 +86,7 @@ class CefTestServer : public CefBaseRefCounted {
|
||||
///
|
||||
/*--cef()--*/
|
||||
static CefRefPtr<CefTestServer> CreateAndStart(
|
||||
uint16 port,
|
||||
uint16_t port,
|
||||
bool https_server,
|
||||
cef_test_cert_type_t https_cert_type,
|
||||
CefRefPtr<CefTestServerHandler> handler);
|
||||
|
@@ -114,6 +114,19 @@ class CefBrowserViewDelegate : public CefViewDelegate {
|
||||
///
|
||||
/*--cef(default_retval=CEF_CTT_NONE)--*/
|
||||
virtual ChromeToolbarType GetChromeToolbarType() { return CEF_CTT_NONE; }
|
||||
|
||||
///
|
||||
/// Called when |browser_view| receives a gesture command. Return true to
|
||||
/// handle (or disable) a |gesture_command| or false to propagate the gesture
|
||||
/// to the browser for default handling. This method will only be called with
|
||||
/// the Alloy runtime. To handle these commands with the Chrome runtime
|
||||
/// implement CefCommandHandler::OnChromeCommand instead.
|
||||
///
|
||||
/*--cef()--*/
|
||||
virtual bool OnGestureCommand(CefRefPtr<CefBrowserView> browser_view,
|
||||
cef_gesture_command_t gesture_command) {
|
||||
return false;
|
||||
}
|
||||
};
|
||||
|
||||
#endif // CEF_INCLUDE_VIEWS_CEF_BROWSER_VIEW_DELEGATE_H_
|
||||
|
@@ -123,7 +123,7 @@ class CefDisplay : public CefBaseRefCounted {
|
||||
/// Returns the unique identifier for this Display.
|
||||
///
|
||||
/*--cef()--*/
|
||||
virtual int64 GetID() = 0;
|
||||
virtual int64_t GetID() = 0;
|
||||
|
||||
///
|
||||
/// Returns this Display's device pixel scale factor. This specifies how much
|
||||
|
@@ -45,6 +45,8 @@
|
||||
#include "include/views/cef_panel.h"
|
||||
#include "include/views/cef_window_delegate.h"
|
||||
|
||||
class CefBrowserView;
|
||||
|
||||
///
|
||||
/// A Window is a top-level Window/widget in the Views hierarchy. By default it
|
||||
/// will have a non-client area with title bar, icon and buttons that supports
|
||||
@@ -68,6 +70,20 @@ class CefWindow : public CefPanel {
|
||||
/*--cef()--*/
|
||||
virtual void Show() = 0;
|
||||
|
||||
///
|
||||
/// Show the Window as a browser modal dialog relative to |browser_view|. A
|
||||
/// parent Window must be returned via CefWindowDelegate::GetParentWindow()
|
||||
/// and |browser_view| must belong to that parent Window. While this Window is
|
||||
/// visible, |browser_view| will be disabled while other controls in the
|
||||
/// parent Window remain enabled. Navigating or destroying the |browser_view|
|
||||
/// will close this Window automatically. Alternately, use Show() and return
|
||||
/// true from CefWindowDelegate::IsWindowModalDialog() for a window modal
|
||||
/// dialog where all controls in the parent Window are disabled.
|
||||
///
|
||||
/*--cef()--*/
|
||||
virtual void ShowAsBrowserModalDialog(
|
||||
CefRefPtr<CefBrowserView> browser_view) = 0;
|
||||
|
||||
///
|
||||
/// Hide the Window.
|
||||
///
|
||||
@@ -300,7 +316,7 @@ class CefWindow : public CefPanel {
|
||||
/// primarily for testing purposes.
|
||||
///
|
||||
/*--cef()--*/
|
||||
virtual void SendKeyPress(int key_code, uint32 event_flags) = 0;
|
||||
virtual void SendKeyPress(int key_code, uint32_t event_flags) = 0;
|
||||
|
||||
///
|
||||
/// Simulate a mouse move. The mouse cursor will be moved to the specified
|
||||
|
@@ -99,6 +99,19 @@ class CefWindowDelegate : public CefPanelDelegate {
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
///
|
||||
/// Return true if |window| should be created as a window modal dialog. Only
|
||||
/// called when a Window is returned via GetParentWindow() with |is_menu| set
|
||||
/// to false. All controls in the parent Window will be disabled while
|
||||
/// |window| is visible. This functionality is not supported by all Linux
|
||||
/// window managers. Alternately, use CefWindow::ShowAsBrowserModalDialog()
|
||||
/// for a browser modal dialog that works on all platforms.
|
||||
///
|
||||
/*--cef()--*/
|
||||
virtual bool IsWindowModalDialog(CefRefPtr<CefWindow> window) {
|
||||
return false;
|
||||
}
|
||||
|
||||
///
|
||||
/// Return the initial bounds for |window| in density independent pixel (DIP)
|
||||
/// coordinates. If this method returns an empty CefRect then
|
||||
|
@@ -61,15 +61,15 @@ class CefByteReadHandler : public CefReadHandler {
|
||||
|
||||
// CefReadHandler methods.
|
||||
virtual size_t Read(void* ptr, size_t size, size_t n) override;
|
||||
virtual int Seek(int64 offset, int whence) override;
|
||||
virtual int64 Tell() override;
|
||||
virtual int Seek(int64_t offset, int whence) override;
|
||||
virtual int64_t Tell() override;
|
||||
virtual int Eof() override;
|
||||
virtual bool MayBlock() override { return false; }
|
||||
|
||||
private:
|
||||
const unsigned char* bytes_;
|
||||
int64 size_;
|
||||
int64 offset_;
|
||||
int64_t size_;
|
||||
int64_t offset_;
|
||||
CefRefPtr<CefBaseRefCounted> source_;
|
||||
|
||||
base::Lock lock_;
|
||||
|
@@ -109,9 +109,9 @@ bool CefPostTask(CefThreadId threadId, const base::RepeatingClosure& closure);
|
||||
///
|
||||
bool CefPostDelayedTask(CefThreadId threadId,
|
||||
base::OnceClosure closure,
|
||||
int64 delay_ms);
|
||||
int64_t delay_ms);
|
||||
bool CefPostDelayedTask(CefThreadId threadId,
|
||||
const base::RepeatingClosure& closure,
|
||||
int64 delay_ms);
|
||||
int64_t delay_ms);
|
||||
|
||||
#endif // CEF_INCLUDE_WRAPPER_CEF_CLOSURE_TASK_H_
|
||||
|
@@ -177,7 +177,7 @@
|
||||
// 8. Handle the query in your Handler::OnQuery implementation and execute the
|
||||
// appropriate callback either immediately or asynchronously.
|
||||
//
|
||||
// void MyHandler::OnQuery(int64 query_id,
|
||||
// void MyHandler::OnQuery(int64_t query_id,
|
||||
// CefRefPtr<CefBrowser> browser,
|
||||
// CefRefPtr<CefFrame> frame,
|
||||
// const CefString& request,
|
||||
@@ -269,7 +269,7 @@ class CefMessageRouterBrowserSide
|
||||
///
|
||||
virtual bool OnQuery(CefRefPtr<CefBrowser> browser,
|
||||
CefRefPtr<CefFrame> frame,
|
||||
int64 query_id,
|
||||
int64_t query_id,
|
||||
const CefString& request,
|
||||
bool persistent,
|
||||
CefRefPtr<Callback> callback) {
|
||||
@@ -287,7 +287,7 @@ class CefMessageRouterBrowserSide
|
||||
///
|
||||
virtual void OnQueryCanceled(CefRefPtr<CefBrowser> browser,
|
||||
CefRefPtr<CefFrame> frame,
|
||||
int64 query_id) {}
|
||||
int64_t query_id) {}
|
||||
|
||||
virtual ~Handler() {}
|
||||
};
|
||||
|
@@ -361,7 +361,7 @@ class CefResourceManager
|
||||
ProviderEntryList providers_;
|
||||
|
||||
// Map of response ID to pending CefResourceHandler object.
|
||||
using PendingHandlersMap = std::map<uint64, CefRefPtr<CefResourceHandler>>;
|
||||
using PendingHandlersMap = std::map<uint64_t, CefRefPtr<CefResourceHandler>>;
|
||||
PendingHandlersMap pending_handlers_;
|
||||
|
||||
UrlFilter url_filter_;
|
||||
|
@@ -68,7 +68,7 @@ class CefStreamResourceHandler : public CefResourceHandler {
|
||||
bool& handle_request,
|
||||
CefRefPtr<CefCallback> callback) override;
|
||||
void GetResponseHeaders(CefRefPtr<CefResponse> response,
|
||||
int64& response_length,
|
||||
int64_t& response_length,
|
||||
CefString& redirectUrl) override;
|
||||
bool Read(void* data_out,
|
||||
int bytes_to_read,
|
||||
|
@@ -440,36 +440,36 @@ ProfileKey* AlloyBrowserContext::GetProfileKey() const {
|
||||
|
||||
policy::SchemaRegistryService*
|
||||
AlloyBrowserContext::GetPolicySchemaRegistryService() {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
policy::UserCloudPolicyManager*
|
||||
AlloyBrowserContext::GetUserCloudPolicyManager() {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
policy::ProfileCloudPolicyManager*
|
||||
AlloyBrowserContext::GetProfileCloudPolicyManager() {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
policy::ProfilePolicyConnector*
|
||||
AlloyBrowserContext::GetProfilePolicyConnector() {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
const policy::ProfilePolicyConnector*
|
||||
AlloyBrowserContext::GetProfilePolicyConnector() const {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
bool AlloyBrowserContext::IsNewProfile() const {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return false;
|
||||
}
|
||||
|
||||
|
@@ -296,7 +296,7 @@ void AlloyBrowserHostImpl::CloseBrowser(bool force_close) {
|
||||
|
||||
bool AlloyBrowserHostImpl::TryCloseBrowser() {
|
||||
if (!CEF_CURRENTLY_ON_UIT()) {
|
||||
NOTREACHED() << "called on invalid thread";
|
||||
DCHECK(false) << "called on invalid thread";
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -333,7 +333,7 @@ CefWindowHandle AlloyBrowserHostImpl::GetOpenerWindowHandle() {
|
||||
double AlloyBrowserHostImpl::GetZoomLevel() {
|
||||
// Verify that this method is being called on the UI thread.
|
||||
if (!CEF_CURRENTLY_ON_UIT()) {
|
||||
NOTREACHED() << "called on invalid thread";
|
||||
DCHECK(false) << "called on invalid thread";
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -416,7 +416,7 @@ void AlloyBrowserHostImpl::CloseDevTools() {
|
||||
|
||||
bool AlloyBrowserHostImpl::HasDevTools() {
|
||||
if (!CEF_CURRENTLY_ON_UIT()) {
|
||||
NOTREACHED() << "called on invalid thread";
|
||||
DCHECK(false) << "called on invalid thread";
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -481,7 +481,7 @@ void AlloyBrowserHostImpl::WasResized() {
|
||||
|
||||
void AlloyBrowserHostImpl::WasHidden(bool hidden) {
|
||||
if (!IsWindowless()) {
|
||||
NOTREACHED() << "Window rendering is not disabled";
|
||||
DCHECK(false) << "Window rendering is not disabled";
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -498,7 +498,7 @@ void AlloyBrowserHostImpl::WasHidden(bool hidden) {
|
||||
|
||||
void AlloyBrowserHostImpl::NotifyScreenInfoChanged() {
|
||||
if (!IsWindowless()) {
|
||||
NOTREACHED() << "Window rendering is not disabled";
|
||||
DCHECK(false) << "Window rendering is not disabled";
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -516,7 +516,7 @@ void AlloyBrowserHostImpl::NotifyScreenInfoChanged() {
|
||||
|
||||
void AlloyBrowserHostImpl::Invalidate(PaintElementType type) {
|
||||
if (!IsWindowless()) {
|
||||
NOTREACHED() << "Window rendering is not disabled";
|
||||
DCHECK(false) << "Window rendering is not disabled";
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -533,7 +533,7 @@ void AlloyBrowserHostImpl::Invalidate(PaintElementType type) {
|
||||
|
||||
void AlloyBrowserHostImpl::SendExternalBeginFrame() {
|
||||
if (!IsWindowless()) {
|
||||
NOTREACHED() << "Window rendering is not disabled";
|
||||
DCHECK(false) << "Window rendering is not disabled";
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -551,7 +551,7 @@ void AlloyBrowserHostImpl::SendExternalBeginFrame() {
|
||||
|
||||
void AlloyBrowserHostImpl::SendTouchEvent(const CefTouchEvent& event) {
|
||||
if (!IsWindowless()) {
|
||||
NOTREACHED() << "Window rendering is not disabled";
|
||||
DCHECK(false) << "Window rendering is not disabled";
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -582,7 +582,7 @@ void AlloyBrowserHostImpl::SendCaptureLostEvent() {
|
||||
int AlloyBrowserHostImpl::GetWindowlessFrameRate() {
|
||||
// Verify that this method is being called on the UI thread.
|
||||
if (!CEF_CURRENTLY_ON_UIT()) {
|
||||
NOTREACHED() << "called on invalid thread";
|
||||
DCHECK(false) << "called on invalid thread";
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -795,7 +795,7 @@ void AlloyBrowserHostImpl::ImeSetComposition(
|
||||
const CefRange& replacement_range,
|
||||
const CefRange& selection_range) {
|
||||
if (!IsWindowless()) {
|
||||
NOTREACHED() << "Window rendering is not disabled";
|
||||
DCHECK(false) << "Window rendering is not disabled";
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -817,7 +817,7 @@ void AlloyBrowserHostImpl::ImeCommitText(const CefString& text,
|
||||
const CefRange& replacement_range,
|
||||
int relative_cursor_pos) {
|
||||
if (!IsWindowless()) {
|
||||
NOTREACHED() << "Window rendering is not disabled";
|
||||
DCHECK(false) << "Window rendering is not disabled";
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -836,7 +836,7 @@ void AlloyBrowserHostImpl::ImeCommitText(const CefString& text,
|
||||
|
||||
void AlloyBrowserHostImpl::ImeFinishComposingText(bool keep_selection) {
|
||||
if (!IsWindowless()) {
|
||||
NOTREACHED() << "Window rendering is not disabled";
|
||||
DCHECK(false) << "Window rendering is not disabled";
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -854,7 +854,7 @@ void AlloyBrowserHostImpl::ImeFinishComposingText(bool keep_selection) {
|
||||
|
||||
void AlloyBrowserHostImpl::ImeCancelComposition() {
|
||||
if (!IsWindowless()) {
|
||||
NOTREACHED() << "Window rendering is not disabled";
|
||||
DCHECK(false) << "Window rendering is not disabled";
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -875,7 +875,7 @@ void AlloyBrowserHostImpl::DragTargetDragEnter(
|
||||
const CefMouseEvent& event,
|
||||
CefBrowserHost::DragOperationsMask allowed_ops) {
|
||||
if (!IsWindowless()) {
|
||||
NOTREACHED() << "Window rendering is not disabled";
|
||||
DCHECK(false) << "Window rendering is not disabled";
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -887,7 +887,7 @@ void AlloyBrowserHostImpl::DragTargetDragEnter(
|
||||
}
|
||||
|
||||
if (!drag_data.get()) {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -900,7 +900,7 @@ void AlloyBrowserHostImpl::DragTargetDragOver(
|
||||
const CefMouseEvent& event,
|
||||
CefBrowserHost::DragOperationsMask allowed_ops) {
|
||||
if (!IsWindowless()) {
|
||||
NOTREACHED() << "Window rendering is not disabled";
|
||||
DCHECK(false) << "Window rendering is not disabled";
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -918,7 +918,7 @@ void AlloyBrowserHostImpl::DragTargetDragOver(
|
||||
|
||||
void AlloyBrowserHostImpl::DragTargetDragLeave() {
|
||||
if (!IsWindowless()) {
|
||||
NOTREACHED() << "Window rendering is not disabled";
|
||||
DCHECK(false) << "Window rendering is not disabled";
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -936,7 +936,7 @@ void AlloyBrowserHostImpl::DragTargetDragLeave() {
|
||||
|
||||
void AlloyBrowserHostImpl::DragTargetDrop(const CefMouseEvent& event) {
|
||||
if (!IsWindowless()) {
|
||||
NOTREACHED() << "Window rendering is not disabled";
|
||||
DCHECK(false) << "Window rendering is not disabled";
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -953,7 +953,7 @@ void AlloyBrowserHostImpl::DragTargetDrop(const CefMouseEvent& event) {
|
||||
|
||||
void AlloyBrowserHostImpl::DragSourceSystemDragEnded() {
|
||||
if (!IsWindowless()) {
|
||||
NOTREACHED() << "Window rendering is not disabled";
|
||||
DCHECK(false) << "Window rendering is not disabled";
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -974,7 +974,7 @@ void AlloyBrowserHostImpl::DragSourceEndedAt(
|
||||
int y,
|
||||
CefBrowserHost::DragOperationsMask op) {
|
||||
if (!IsWindowless()) {
|
||||
NOTREACHED() << "Window rendering is not disabled";
|
||||
DCHECK(false) << "Window rendering is not disabled";
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -1004,7 +1004,7 @@ void AlloyBrowserHostImpl::SetAudioMuted(bool mute) {
|
||||
|
||||
bool AlloyBrowserHostImpl::IsAudioMuted() {
|
||||
if (!CEF_CURRENTLY_ON_UIT()) {
|
||||
NOTREACHED() << "called on invalid thread";
|
||||
DCHECK(false) << "called on invalid thread";
|
||||
return false;
|
||||
}
|
||||
if (!web_contents()) {
|
||||
|
@@ -32,6 +32,7 @@
|
||||
#include "chrome/browser/ui/color/chrome_color_mixers.h"
|
||||
#include "chrome/browser/ui/javascript_dialogs/chrome_javascript_app_modal_dialog_view_factory.h"
|
||||
#include "chrome/browser/ui/ui_features.h"
|
||||
#include "chrome/common/chrome_paths.h"
|
||||
#include "chrome/common/chrome_switches.h"
|
||||
#include "components/constrained_window/constrained_window_views.h"
|
||||
#include "content/public/browser/gpu_data_manager.h"
|
||||
@@ -58,6 +59,7 @@
|
||||
|
||||
#if BUILDFLAG(IS_WIN)
|
||||
#include "base/enterprise_util.h"
|
||||
#include "base/files/file_util.h"
|
||||
#include "chrome/browser/chrome_browser_main_win.h"
|
||||
#include "chrome/browser/win/parental_controls.h"
|
||||
#endif
|
||||
@@ -82,7 +84,6 @@
|
||||
#include "base/path_service.h"
|
||||
#include "chrome/browser/themes/theme_service_aura_linux.h"
|
||||
#include "chrome/browser/ui/views/theme_profile_key.h"
|
||||
#include "chrome/common/chrome_paths.h"
|
||||
#include "chrome/grit/chromium_strings.h"
|
||||
#include "components/os_crypt/sync/key_storage_config_linux.h"
|
||||
#include "libcef/browser/printing/print_dialog_linux.h"
|
||||
@@ -241,6 +242,10 @@ void AlloyBrowserMainParts::PostCreateMainMessageLoop() {
|
||||
DCHECK(!config->user_data_path.empty());
|
||||
OSCrypt::SetConfig(std::move(config));
|
||||
#endif // BUILDFLAG(IS_LINUX)
|
||||
|
||||
#if BUILDFLAG(IS_WIN)
|
||||
base::SetExtraNoExecuteAllowedPath(chrome::DIR_USER_DATA);
|
||||
#endif
|
||||
}
|
||||
|
||||
int AlloyBrowserMainParts::PreCreateThreads() {
|
||||
|
@@ -300,11 +300,11 @@ void BindNetworkHintsHandler(
|
||||
predictors::NetworkHintsHandlerImpl::Create(frame_host, std::move(receiver));
|
||||
}
|
||||
|
||||
base::FilePath GetRootCachePath() {
|
||||
// The CefContext::ValidateCachePath method enforces the requirement that all
|
||||
// cache_path values be either equal to or a child of root_cache_path.
|
||||
return base::FilePath(
|
||||
CefString(&CefContext::Get()->settings().root_cache_path));
|
||||
base::FilePath GetUserDataPath() {
|
||||
base::FilePath user_data_path;
|
||||
base::PathService::Get(chrome::DIR_USER_DATA, &user_data_path);
|
||||
DCHECK(!user_data_path.empty());
|
||||
return user_data_path;
|
||||
}
|
||||
|
||||
const extensions::Extension* GetEnabledExtensionFromSiteURL(
|
||||
@@ -506,35 +506,7 @@ void AlloyContentBrowserClient::SiteInstanceGotProcess(
|
||||
}
|
||||
|
||||
extensions::ProcessMap::Get(context)->Insert(
|
||||
extension->id(), site_instance->GetProcess()->GetID(),
|
||||
site_instance->GetId());
|
||||
}
|
||||
|
||||
void AlloyContentBrowserClient::SiteInstanceDeleting(
|
||||
content::SiteInstance* site_instance) {
|
||||
if (!extensions::ExtensionsEnabled()) {
|
||||
return;
|
||||
}
|
||||
|
||||
if (!site_instance->HasProcess()) {
|
||||
return;
|
||||
}
|
||||
|
||||
auto context = site_instance->GetBrowserContext();
|
||||
auto registry = extensions::ExtensionRegistry::Get(context);
|
||||
if (!registry) {
|
||||
return;
|
||||
}
|
||||
|
||||
auto extension = registry->enabled_extensions().GetExtensionOrAppByURL(
|
||||
site_instance->GetSiteURL());
|
||||
if (!extension) {
|
||||
return;
|
||||
}
|
||||
|
||||
extensions::ProcessMap::Get(context)->Remove(
|
||||
extension->id(), site_instance->GetProcess()->GetID(),
|
||||
site_instance->GetId());
|
||||
extension->id(), site_instance->GetProcess()->GetID());
|
||||
}
|
||||
|
||||
void AlloyContentBrowserClient::BindHostReceiverForRenderer(
|
||||
@@ -1176,9 +1148,9 @@ bool AlloyContentBrowserClient::ConfigureNetworkContextParams(
|
||||
network_context_params->cookieable_schemes =
|
||||
cef_context->GetCookieableSchemes();
|
||||
|
||||
// TODO(cef): Remove this and add required NetworkIsolationKeys,
|
||||
// TODO(cef): Remove this and add required NetworkAnonymizationKey,
|
||||
// this is currently not the case and this was not required pre M84.
|
||||
network_context_params->require_network_isolation_key = false;
|
||||
network_context_params->require_network_anonymization_key = false;
|
||||
|
||||
return true;
|
||||
}
|
||||
@@ -1187,19 +1159,7 @@ bool AlloyContentBrowserClient::ConfigureNetworkContextParams(
|
||||
// directories that are not returned by this method.
|
||||
std::vector<base::FilePath>
|
||||
AlloyContentBrowserClient::GetNetworkContextsParentDirectory() {
|
||||
base::FilePath user_data_path;
|
||||
base::PathService::Get(chrome::DIR_USER_DATA, &user_data_path);
|
||||
DCHECK(!user_data_path.empty());
|
||||
|
||||
const auto& root_cache_path = GetRootCachePath();
|
||||
|
||||
// root_cache_path may sometimes be empty or a child of user_data_path, so
|
||||
// only return the one path in that case.
|
||||
if (root_cache_path.empty() || user_data_path.IsParent(root_cache_path)) {
|
||||
return {user_data_path};
|
||||
}
|
||||
|
||||
return {user_data_path, root_cache_path};
|
||||
return {GetUserDataPath()};
|
||||
}
|
||||
|
||||
bool AlloyContentBrowserClient::HandleExternalProtocol(
|
||||
@@ -1310,7 +1270,7 @@ void AlloyContentBrowserClient::RegisterBrowserInterfaceBindersForServiceWorker(
|
||||
|
||||
base::FilePath
|
||||
AlloyContentBrowserClient::GetSandboxedStorageServiceDataDirectory() {
|
||||
return GetRootCachePath();
|
||||
return GetUserDataPath();
|
||||
}
|
||||
|
||||
std::string AlloyContentBrowserClient::GetProduct() {
|
||||
@@ -1318,7 +1278,7 @@ std::string AlloyContentBrowserClient::GetProduct() {
|
||||
}
|
||||
|
||||
std::string AlloyContentBrowserClient::GetChromeProduct() {
|
||||
return version_info::GetProductNameAndVersionForUserAgent();
|
||||
return std::string(version_info::GetProductNameAndVersionForUserAgent());
|
||||
}
|
||||
|
||||
std::string AlloyContentBrowserClient::GetUserAgent() {
|
||||
@@ -1340,18 +1300,8 @@ AlloyContentBrowserClient::GetWebContentsViewDelegate(
|
||||
}
|
||||
|
||||
blink::UserAgentMetadata AlloyContentBrowserClient::GetUserAgentMetadata() {
|
||||
blink::UserAgentMetadata metadata;
|
||||
|
||||
metadata.brand_version_list = {blink::UserAgentBrandVersion{
|
||||
version_info::GetProductName(), version_info::GetMajorVersionNumber()}};
|
||||
metadata.full_version = version_info::GetVersionNumber();
|
||||
metadata.platform = version_info::GetOSType();
|
||||
|
||||
// TODO(mkwst): Poke at BuildUserAgentFromProduct to split out these pieces.
|
||||
metadata.architecture = "";
|
||||
metadata.model = "";
|
||||
|
||||
return metadata;
|
||||
return embedder_support::GetUserAgentMetadata(
|
||||
g_browser_process->local_state());
|
||||
}
|
||||
|
||||
base::flat_set<std::string>
|
||||
|
@@ -65,7 +65,6 @@ class AlloyContentBrowserClient : public content::ContentBrowserClient {
|
||||
bool IsWebUIAllowedToMakeNetworkRequests(const url::Origin& origin) override;
|
||||
bool IsHandledURL(const GURL& url) override;
|
||||
void SiteInstanceGotProcess(content::SiteInstance* site_instance) override;
|
||||
void SiteInstanceDeleting(content::SiteInstance* site_instance) override;
|
||||
void BindHostReceiverForRenderer(
|
||||
content::RenderProcessHost* render_process_host,
|
||||
mojo::GenericPendingReceiver receiver) override;
|
||||
|
@@ -219,7 +219,7 @@ void CefBrowserPlatformDelegateAlloy::CreateExtensionHost(
|
||||
extension, web_contents_, url, host_type);
|
||||
// Load will be triggered by ProcessManager::CreateBackgroundHost.
|
||||
} else {
|
||||
NOTREACHED() << " Unsupported extension host type: " << host_type;
|
||||
DCHECK(false) << " Unsupported extension host type: " << host_type;
|
||||
}
|
||||
}
|
||||
|
||||
|
@@ -16,6 +16,7 @@
|
||||
#include "libcef/common/extensions/extensions_util.h"
|
||||
|
||||
#include "base/command_line.h"
|
||||
#include "base/path_service.h"
|
||||
#include "chrome/browser/component_updater/chrome_component_updater_configurator.h"
|
||||
#include "chrome/browser/net/system_network_context_manager.h"
|
||||
#include "chrome/browser/permissions/chrome_permissions_client.h"
|
||||
@@ -24,6 +25,7 @@
|
||||
#include "chrome/browser/printing/print_job_manager.h"
|
||||
#include "chrome/browser/printing/print_preview_dialog_controller.h"
|
||||
#include "chrome/browser/ui/prefs/pref_watcher.h"
|
||||
#include "chrome/common/chrome_paths.h"
|
||||
#include "components/component_updater/component_updater_service.h"
|
||||
#include "components/component_updater/timer_update_scheduler.h"
|
||||
#include "components/net_log/chrome_net_log.h"
|
||||
@@ -136,27 +138,27 @@ void ChromeBrowserProcessAlloy::CleanupOnUIThread() {
|
||||
}
|
||||
|
||||
void ChromeBrowserProcessAlloy::EndSession() {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
}
|
||||
|
||||
void ChromeBrowserProcessAlloy::FlushLocalStateAndReply(
|
||||
base::OnceClosure reply) {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
}
|
||||
|
||||
device::GeolocationManager* ChromeBrowserProcessAlloy::geolocation_manager() {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
metrics_services_manager::MetricsServicesManager*
|
||||
ChromeBrowserProcessAlloy::GetMetricsServicesManager() {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
metrics::MetricsService* ChromeBrowserProcessAlloy::metrics_service() {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
@@ -168,7 +170,13 @@ ChromeBrowserProcessAlloy::system_network_context_manager() {
|
||||
|
||||
network::NetworkQualityTracker*
|
||||
ChromeBrowserProcessAlloy::network_quality_tracker() {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
embedder_support::OriginTrialsSettingsStorage*
|
||||
ChromeBrowserProcessAlloy::GetOriginTrialsSettingsStorage() {
|
||||
DCHECK(false);
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
@@ -180,16 +188,15 @@ ProfileManager* ChromeBrowserProcessAlloy::profile_manager() {
|
||||
PrefService* ChromeBrowserProcessAlloy::local_state() {
|
||||
DCHECK(initialized_);
|
||||
if (!local_state_) {
|
||||
// Use a location that is shared by all request contexts.
|
||||
const CefSettings& settings = CefContext::Get()->settings();
|
||||
const base::FilePath& root_cache_path =
|
||||
base::FilePath(CefString(&settings.root_cache_path));
|
||||
base::FilePath user_data_path;
|
||||
base::PathService::Get(chrome::DIR_USER_DATA, &user_data_path);
|
||||
DCHECK(!user_data_path.empty());
|
||||
|
||||
// Used for very early NetworkService initialization.
|
||||
// Always persist preferences for this PrefService if possible because it
|
||||
// contains the cookie encryption key on Windows.
|
||||
local_state_ =
|
||||
browser_prefs::CreatePrefService(nullptr /* profile */, root_cache_path,
|
||||
browser_prefs::CreatePrefService(nullptr /* profile */, user_data_path,
|
||||
true /* persist_user_preferences */);
|
||||
}
|
||||
return local_state_.get();
|
||||
@@ -197,17 +204,17 @@ PrefService* ChromeBrowserProcessAlloy::local_state() {
|
||||
|
||||
scoped_refptr<network::SharedURLLoaderFactory>
|
||||
ChromeBrowserProcessAlloy::shared_url_loader_factory() {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
variations::VariationsService* ChromeBrowserProcessAlloy::variations_service() {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
BrowserProcessPlatformPart* ChromeBrowserProcessAlloy::platform_part() {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
@@ -218,19 +225,19 @@ ChromeBrowserProcessAlloy::extension_event_router_forwarder() {
|
||||
}
|
||||
|
||||
NotificationUIManager* ChromeBrowserProcessAlloy::notification_ui_manager() {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
NotificationPlatformBridge*
|
||||
ChromeBrowserProcessAlloy::notification_platform_bridge() {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
void ChromeBrowserProcessAlloy::SetGeolocationManager(
|
||||
std::unique_ptr<device::GeolocationManager> geolocation_manager) {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
}
|
||||
|
||||
policy::ChromeBrowserPolicyConnector*
|
||||
@@ -247,25 +254,25 @@ policy::PolicyService* ChromeBrowserProcessAlloy::policy_service() {
|
||||
}
|
||||
|
||||
IconManager* ChromeBrowserProcessAlloy::icon_manager() {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
GpuModeManager* ChromeBrowserProcessAlloy::gpu_mode_manager() {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
void ChromeBrowserProcessAlloy::CreateDevToolsProtocolHandler() {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
}
|
||||
|
||||
void ChromeBrowserProcessAlloy::CreateDevToolsAutoOpener() {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
}
|
||||
|
||||
bool ChromeBrowserProcessAlloy::IsShuttingDown() {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -294,7 +301,7 @@ ChromeBrowserProcessAlloy::background_printing_manager() {
|
||||
|
||||
IntranetRedirectDetector*
|
||||
ChromeBrowserProcessAlloy::intranet_redirect_detector() {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
@@ -309,29 +316,29 @@ void ChromeBrowserProcessAlloy::SetApplicationLocale(
|
||||
}
|
||||
|
||||
DownloadStatusUpdater* ChromeBrowserProcessAlloy::download_status_updater() {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
DownloadRequestLimiter* ChromeBrowserProcessAlloy::download_request_limiter() {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
#if BUILDFLAG(ENABLE_BACKGROUND_MODE)
|
||||
BackgroundModeManager* ChromeBrowserProcessAlloy::background_mode_manager() {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
void ChromeBrowserProcessAlloy::set_background_mode_manager_for_test(
|
||||
std::unique_ptr<BackgroundModeManager> manager) {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
}
|
||||
#endif
|
||||
|
||||
StatusTray* ChromeBrowserProcessAlloy::status_tray() {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
@@ -342,12 +349,12 @@ ChromeBrowserProcessAlloy::safe_browsing_service() {
|
||||
|
||||
subresource_filter::RulesetService*
|
||||
ChromeBrowserProcessAlloy::subresource_filter_ruleset_service() {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
StartupData* ChromeBrowserProcessAlloy::startup_data() {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
@@ -379,55 +386,55 @@ ChromeBrowserProcessAlloy::component_updater() {
|
||||
|
||||
MediaFileSystemRegistry*
|
||||
ChromeBrowserProcessAlloy::media_file_system_registry() {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
WebRtcLogUploader* ChromeBrowserProcessAlloy::webrtc_log_uploader() {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
network_time::NetworkTimeTracker*
|
||||
ChromeBrowserProcessAlloy::network_time_tracker() {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
gcm::GCMDriver* ChromeBrowserProcessAlloy::gcm_driver() {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
resource_coordinator::TabManager* ChromeBrowserProcessAlloy::GetTabManager() {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
resource_coordinator::ResourceCoordinatorParts*
|
||||
ChromeBrowserProcessAlloy::resource_coordinator_parts() {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
BuildState* ChromeBrowserProcessAlloy::GetBuildState() {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
SerialPolicyAllowedPorts*
|
||||
ChromeBrowserProcessAlloy::serial_policy_allowed_ports() {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
HidPolicyAllowedDevices*
|
||||
ChromeBrowserProcessAlloy::hid_policy_allowed_devices() {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
HidSystemTrayIcon* ChromeBrowserProcessAlloy::hid_system_tray_icon() {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return nullptr;
|
||||
}
|
||||
|
@@ -57,6 +57,8 @@ class ChromeBrowserProcessAlloy : public BrowserProcess {
|
||||
metrics::MetricsService* metrics_service() override;
|
||||
SystemNetworkContextManager* system_network_context_manager() override;
|
||||
network::NetworkQualityTracker* network_quality_tracker() override;
|
||||
embedder_support::OriginTrialsSettingsStorage*
|
||||
GetOriginTrialsSettingsStorage() override;
|
||||
ProfileManager* profile_manager() override;
|
||||
PrefService* local_state() override;
|
||||
scoped_refptr<network::SharedURLLoaderFactory> shared_url_loader_factory()
|
||||
|
@@ -54,7 +54,7 @@ bool ChromeProfileAlloy::IsOffTheRecord() const {
|
||||
}
|
||||
|
||||
const Profile::OTRProfileID& ChromeProfileAlloy::GetOTRProfileID() const {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
static base::NoDestructor<Profile::OTRProfileID> otr_profile_id(
|
||||
Profile::OTRProfileID::PrimaryID());
|
||||
return *otr_profile_id;
|
||||
@@ -68,19 +68,19 @@ variations::VariationsClient* ChromeProfileAlloy::GetVariationsClient() {
|
||||
}
|
||||
|
||||
scoped_refptr<base::SequencedTaskRunner> ChromeProfileAlloy::GetIOTaskRunner() {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return scoped_refptr<base::SequencedTaskRunner>();
|
||||
}
|
||||
|
||||
std::string ChromeProfileAlloy::GetProfileUserName() const {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return std::string();
|
||||
}
|
||||
|
||||
Profile* ChromeProfileAlloy::GetOffTheRecordProfile(
|
||||
const Profile::OTRProfileID& otr_profile_id,
|
||||
bool create_if_needed) {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
@@ -89,7 +89,7 @@ std::vector<Profile*> ChromeProfileAlloy::GetAllOffTheRecordProfiles() {
|
||||
}
|
||||
|
||||
void ChromeProfileAlloy::DestroyOffTheRecordProfile(Profile* otr_profile) {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
}
|
||||
|
||||
bool ChromeProfileAlloy::HasOffTheRecordProfile(
|
||||
@@ -115,17 +115,17 @@ bool ChromeProfileAlloy::IsChild() const {
|
||||
|
||||
ExtensionSpecialStoragePolicy*
|
||||
ChromeProfileAlloy::GetExtensionSpecialStoragePolicy() {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
bool ChromeProfileAlloy::IsSameOrParent(Profile* profile) {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return false;
|
||||
}
|
||||
|
||||
base::Time ChromeProfileAlloy::GetStartTime() const {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return base::Time();
|
||||
}
|
||||
|
||||
@@ -139,30 +139,30 @@ void ChromeProfileAlloy::set_last_selected_directory(
|
||||
}
|
||||
|
||||
GURL ChromeProfileAlloy::GetHomePage() {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return GURL();
|
||||
}
|
||||
|
||||
bool ChromeProfileAlloy::WasCreatedByVersionOrLater(
|
||||
const std::string& version) {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return false;
|
||||
}
|
||||
|
||||
base::Time ChromeProfileAlloy::GetCreationTime() const {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return base::Time();
|
||||
}
|
||||
|
||||
void ChromeProfileAlloy::SetCreationTimeForTesting(base::Time creation_time) {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
}
|
||||
|
||||
void ChromeProfileAlloy::RecordPrimaryMainFrameNavigation() {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
}
|
||||
|
||||
bool ChromeProfileAlloy::IsSignedIn() {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return false;
|
||||
}
|
||||
|
@@ -29,7 +29,7 @@ class AlloyConstrainedWindowViewsClient
|
||||
if (auto browser = GetPreferredBrowser(parent)) {
|
||||
return browser->platform_delegate()->GetWebContentsModalDialogHost();
|
||||
}
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
@@ -73,4 +73,4 @@ class AlloyConstrainedWindowViewsClient
|
||||
std::unique_ptr<constrained_window::ConstrainedWindowViewsClient>
|
||||
CreateAlloyConstrainedWindowViewsClient() {
|
||||
return std::make_unique<AlloyConstrainedWindowViewsClient>();
|
||||
}
|
||||
}
|
||||
|
@@ -33,7 +33,7 @@ bool AlloyWebContentsDialogHelper::IsWebContentsVisible(
|
||||
} else if (auto native_view = web_contents->GetNativeView()) {
|
||||
return platform_util::IsVisible(native_view);
|
||||
}
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -51,7 +51,7 @@ gfx::NativeView AlloyWebContentsDialogHelper::GetHostView() const {
|
||||
if (auto widget = browser_delegate_->GetWindowWidget()) {
|
||||
return widget->GetNativeView();
|
||||
}
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return gfx::NativeView();
|
||||
}
|
||||
|
||||
@@ -66,7 +66,7 @@ gfx::AcceleratedWidget AlloyWebContentsDialogHelper::GetHostWidget() const {
|
||||
return parent_widget;
|
||||
}
|
||||
#endif // defined(USE_AURA)
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return gfx::kNullAcceleratedWidget;
|
||||
}
|
||||
|
||||
|
@@ -77,6 +77,6 @@ CefRefPtr<CefFrameHostImpl> CefBrowserFrame::GetFrameHost(
|
||||
return browser->browser_info()->GetFrameForHost(rfh, nullptr,
|
||||
prefer_speculative);
|
||||
}
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return nullptr;
|
||||
}
|
||||
|
@@ -28,6 +28,7 @@
|
||||
#include "content/public/browser/download_request_utils.h"
|
||||
#include "content/public/browser/file_select_listener.h"
|
||||
#include "content/public/browser/navigation_entry.h"
|
||||
#include "ui/base/resource/resource_scale_factor.h"
|
||||
#include "ui/gfx/image/image_skia.h"
|
||||
#include "ui/shell_dialogs/select_file_policy.h"
|
||||
|
||||
@@ -315,7 +316,7 @@ void CefBrowserHostBase::StartDownload(const CefString& url) {
|
||||
void CefBrowserHostBase::DownloadImage(
|
||||
const CefString& image_url,
|
||||
bool is_favicon,
|
||||
uint32 max_image_size,
|
||||
uint32_t max_image_size,
|
||||
bool bypass_cache,
|
||||
CefRefPtr<CefDownloadImageCallback> callback) {
|
||||
if (!CEF_CURRENTLY_ON_UIT()) {
|
||||
@@ -340,11 +341,12 @@ void CefBrowserHostBase::DownloadImage(
|
||||
return;
|
||||
}
|
||||
|
||||
const float scale = ui::GetScaleForMaxSupportedResourceScaleFactor();
|
||||
web_contents->DownloadImage(
|
||||
gurl, is_favicon, gfx::Size(max_image_size, max_image_size),
|
||||
max_image_size * gfx::ImageSkia::GetMaxSupportedScale(), bypass_cache,
|
||||
max_image_size * scale, bypass_cache,
|
||||
base::BindOnce(
|
||||
[](uint32 max_image_size,
|
||||
[](uint32_t max_image_size,
|
||||
CefRefPtr<CefDownloadImageCallback> callback, int id,
|
||||
int http_status_code, const GURL& image_url,
|
||||
const std::vector<SkBitmap>& bitmaps,
|
||||
@@ -493,7 +495,7 @@ void CefBrowserHostBase::GetNavigationEntries(
|
||||
|
||||
CefRefPtr<CefNavigationEntry> CefBrowserHostBase::GetVisibleNavigationEntry() {
|
||||
if (!CEF_CURRENTLY_ON_UIT()) {
|
||||
NOTREACHED() << "called on invalid thread";
|
||||
DCHECK(false) << "called on invalid thread";
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
@@ -763,7 +765,7 @@ CefRefPtr<CefFrame> CefBrowserHostBase::GetFocusedFrame() {
|
||||
return GetFrame(CefFrameHostImpl::kFocusedFrameId);
|
||||
}
|
||||
|
||||
CefRefPtr<CefFrame> CefBrowserHostBase::GetFrame(int64 identifier) {
|
||||
CefRefPtr<CefFrame> CefBrowserHostBase::GetFrame(int64_t identifier) {
|
||||
if (identifier == CefFrameHostImpl::kInvalidFrameId) {
|
||||
return nullptr;
|
||||
} else if (identifier == CefFrameHostImpl::kMainFrameId) {
|
||||
@@ -794,7 +796,8 @@ size_t CefBrowserHostBase::GetFrameCount() {
|
||||
return browser_info_->GetAllFrames().size();
|
||||
}
|
||||
|
||||
void CefBrowserHostBase::GetFrameIdentifiers(std::vector<int64>& identifiers) {
|
||||
void CefBrowserHostBase::GetFrameIdentifiers(
|
||||
std::vector<int64_t>& identifiers) {
|
||||
if (identifiers.size() > 0) {
|
||||
identifiers.clear();
|
||||
}
|
||||
|
@@ -179,7 +179,7 @@ class CefBrowserHostBase : public CefBrowserHost,
|
||||
void StartDownload(const CefString& url) override;
|
||||
void DownloadImage(const CefString& image_url,
|
||||
bool is_favicon,
|
||||
uint32 max_image_size,
|
||||
uint32_t max_image_size,
|
||||
bool bypass_cache,
|
||||
CefRefPtr<CefDownloadImageCallback> callback) override;
|
||||
void Print() override;
|
||||
@@ -225,10 +225,10 @@ class CefBrowserHostBase : public CefBrowserHost,
|
||||
bool IsPopup() override;
|
||||
CefRefPtr<CefFrame> GetMainFrame() override;
|
||||
CefRefPtr<CefFrame> GetFocusedFrame() override;
|
||||
CefRefPtr<CefFrame> GetFrame(int64 identifier) override;
|
||||
CefRefPtr<CefFrame> GetFrame(int64_t identifier) override;
|
||||
CefRefPtr<CefFrame> GetFrame(const CefString& name) override;
|
||||
size_t GetFrameCount() override;
|
||||
void GetFrameIdentifiers(std::vector<int64>& identifiers) override;
|
||||
void GetFrameIdentifiers(std::vector<int64_t>& identifiers) override;
|
||||
void GetFrameNames(std::vector<CefString>& names) override;
|
||||
|
||||
// CefBrowserContentsDelegate::Observer methods:
|
||||
|
@@ -53,20 +53,20 @@ bool CefBrowserHost::CreateBrowser(
|
||||
CefRefPtr<CefRequestContext> request_context) {
|
||||
// Verify that the context is in a valid state.
|
||||
if (!CONTEXT_STATE_VALID()) {
|
||||
NOTREACHED() << "context not valid";
|
||||
DCHECK(false) << "context not valid";
|
||||
return false;
|
||||
}
|
||||
|
||||
// Verify that the settings structure is a valid size.
|
||||
if (settings.size != sizeof(cef_browser_settings_t)) {
|
||||
NOTREACHED() << "invalid CefBrowserSettings structure size";
|
||||
DCHECK(false) << "invalid CefBrowserSettings structure size";
|
||||
return false;
|
||||
}
|
||||
|
||||
// Verify windowless rendering requirements.
|
||||
if (windowInfo.windowless_rendering_enabled &&
|
||||
!client->GetRenderHandler().get()) {
|
||||
NOTREACHED() << "CefRenderHandler implementation is required";
|
||||
DCHECK(false) << "CefRenderHandler implementation is required";
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -110,13 +110,13 @@ CefRefPtr<CefBrowser> CefBrowserHost::CreateBrowserSync(
|
||||
CefRefPtr<CefRequestContext> request_context) {
|
||||
// Verify that the context is in a valid state.
|
||||
if (!CONTEXT_STATE_VALID()) {
|
||||
NOTREACHED() << "context not valid";
|
||||
DCHECK(false) << "context not valid";
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
// Verify that the settings structure is a valid size.
|
||||
if (settings.size != sizeof(cef_browser_settings_t)) {
|
||||
NOTREACHED() << "invalid CefBrowserSettings structure size";
|
||||
DCHECK(false) << "invalid CefBrowserSettings structure size";
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
@@ -134,7 +134,7 @@ CefRefPtr<CefBrowser> CefBrowserHost::CreateBrowserSync(
|
||||
// Verify windowless rendering requirements.
|
||||
if (windowInfo.windowless_rendering_enabled &&
|
||||
!client->GetRenderHandler().get()) {
|
||||
NOTREACHED() << "CefRenderHandler implementation is required";
|
||||
DCHECK(false) << "CefRenderHandler implementation is required";
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
|
@@ -358,7 +358,7 @@ void CefBrowserInfoManager::RemoveBrowserInfo(
|
||||
}
|
||||
}
|
||||
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
}
|
||||
|
||||
void CefBrowserInfoManager::DestroyAllBrowsers() {
|
||||
|
@@ -20,14 +20,14 @@ CefBrowserPlatformDelegate::~CefBrowserPlatformDelegate() {
|
||||
content::WebContents* CefBrowserPlatformDelegate::CreateWebContents(
|
||||
CefBrowserCreateParams& create_params,
|
||||
bool& own_web_contents) {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
void CefBrowserPlatformDelegate::CreateViewForWebContents(
|
||||
content::WebContentsView** view,
|
||||
content::RenderViewHostDelegateView** delegate_view) {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
}
|
||||
|
||||
void CefBrowserPlatformDelegate::WebContentsCreated(
|
||||
@@ -48,7 +48,7 @@ void CefBrowserPlatformDelegate::AddNewContents(
|
||||
const blink::mojom::WindowFeatures& window_features,
|
||||
bool user_gesture,
|
||||
bool* was_blocked) {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
}
|
||||
|
||||
void CefBrowserPlatformDelegate::WebContentsDestroyed(
|
||||
@@ -87,12 +87,12 @@ void CefBrowserPlatformDelegate::CreateExtensionHost(
|
||||
const extensions::Extension* extension,
|
||||
const GURL& url,
|
||||
extensions::mojom::ViewType host_type) {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
}
|
||||
|
||||
extensions::ExtensionHost* CefBrowserPlatformDelegate::GetExtensionHost()
|
||||
const {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
@@ -109,32 +109,32 @@ void CefBrowserPlatformDelegate::BrowserDestroyed(CefBrowserHostBase* browser) {
|
||||
}
|
||||
|
||||
bool CefBrowserPlatformDelegate::CreateHostWindow() {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return true;
|
||||
}
|
||||
|
||||
void CefBrowserPlatformDelegate::CloseHostWindow() {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
}
|
||||
|
||||
CefWindowHandle CefBrowserPlatformDelegate::GetHostWindowHandle() const {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return kNullWindowHandle;
|
||||
}
|
||||
|
||||
views::Widget* CefBrowserPlatformDelegate::GetWindowWidget() const {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
CefRefPtr<CefBrowserView> CefBrowserPlatformDelegate::GetBrowserView() const {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
web_modal::WebContentsModalDialogHost*
|
||||
CefBrowserPlatformDelegate::GetWebContentsModalDialogHost() const {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
@@ -150,12 +150,12 @@ void CefBrowserPlatformDelegate::PopupBrowserCreated(
|
||||
bool is_devtools) {}
|
||||
|
||||
SkColor CefBrowserPlatformDelegate::GetBackgroundColor() const {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return SkColor();
|
||||
}
|
||||
|
||||
void CefBrowserPlatformDelegate::WasResized() {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
}
|
||||
|
||||
void CefBrowserPlatformDelegate::SendKeyEvent(const CefKeyEvent& event) {
|
||||
@@ -200,7 +200,7 @@ void CefBrowserPlatformDelegate::SizeTo(int width, int height) {}
|
||||
gfx::Point CefBrowserPlatformDelegate::GetScreenPoint(
|
||||
const gfx::Point& view,
|
||||
bool want_dip_coords) const {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return gfx::Point();
|
||||
}
|
||||
|
||||
@@ -210,7 +210,7 @@ void CefBrowserPlatformDelegate::ViewText(const std::string& text) {
|
||||
|
||||
bool CefBrowserPlatformDelegate::HandleKeyboardEvent(
|
||||
const content::NativeWebKeyboardEvent& event) {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -227,7 +227,7 @@ bool CefBrowserPlatformDelegate::IsNeverComposited(
|
||||
|
||||
CefEventHandle CefBrowserPlatformDelegate::GetEventHandle(
|
||||
const content::NativeWebKeyboardEvent& event) const {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return kNullEventHandle;
|
||||
}
|
||||
|
||||
@@ -259,28 +259,28 @@ bool CefBrowserPlatformDelegate::HasExternalParent() const {
|
||||
}
|
||||
|
||||
void CefBrowserPlatformDelegate::WasHidden(bool hidden) {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
}
|
||||
|
||||
bool CefBrowserPlatformDelegate::IsHidden() const {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return false;
|
||||
}
|
||||
|
||||
void CefBrowserPlatformDelegate::NotifyScreenInfoChanged() {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
}
|
||||
|
||||
void CefBrowserPlatformDelegate::Invalidate(cef_paint_element_type_t type) {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
}
|
||||
|
||||
void CefBrowserPlatformDelegate::SendExternalBeginFrame() {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
}
|
||||
|
||||
void CefBrowserPlatformDelegate::SetWindowlessFrameRate(int frame_rate) {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
}
|
||||
|
||||
void CefBrowserPlatformDelegate::ImeSetComposition(
|
||||
@@ -288,43 +288,43 @@ void CefBrowserPlatformDelegate::ImeSetComposition(
|
||||
const std::vector<CefCompositionUnderline>& underlines,
|
||||
const CefRange& replacement_range,
|
||||
const CefRange& selection_range) {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
}
|
||||
|
||||
void CefBrowserPlatformDelegate::ImeCommitText(
|
||||
const CefString& text,
|
||||
const CefRange& replacement_range,
|
||||
int relative_cursor_pos) {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
}
|
||||
|
||||
void CefBrowserPlatformDelegate::ImeFinishComposingText(bool keep_selection) {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
}
|
||||
|
||||
void CefBrowserPlatformDelegate::ImeCancelComposition() {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
}
|
||||
|
||||
void CefBrowserPlatformDelegate::DragTargetDragEnter(
|
||||
CefRefPtr<CefDragData> drag_data,
|
||||
const CefMouseEvent& event,
|
||||
cef_drag_operations_mask_t allowed_ops) {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
}
|
||||
|
||||
void CefBrowserPlatformDelegate::DragTargetDragOver(
|
||||
const CefMouseEvent& event,
|
||||
cef_drag_operations_mask_t allowed_ops) {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
}
|
||||
|
||||
void CefBrowserPlatformDelegate::DragTargetDragLeave() {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
}
|
||||
|
||||
void CefBrowserPlatformDelegate::DragTargetDrop(const CefMouseEvent& event) {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
}
|
||||
|
||||
void CefBrowserPlatformDelegate::StartDragging(
|
||||
@@ -334,33 +334,33 @@ void CefBrowserPlatformDelegate::StartDragging(
|
||||
const gfx::Vector2d& image_offset,
|
||||
const blink::mojom::DragEventSourceInfo& event_info,
|
||||
content::RenderWidgetHostImpl* source_rwh) {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
}
|
||||
|
||||
void CefBrowserPlatformDelegate::UpdateDragCursor(
|
||||
ui::mojom::DragOperation operation) {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
}
|
||||
|
||||
void CefBrowserPlatformDelegate::DragSourceEndedAt(
|
||||
int x,
|
||||
int y,
|
||||
cef_drag_operations_mask_t op) {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
}
|
||||
|
||||
void CefBrowserPlatformDelegate::DragSourceSystemDragEnded() {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
}
|
||||
|
||||
void CefBrowserPlatformDelegate::AccessibilityEventReceived(
|
||||
const content::AXEventNotificationDetails& eventData) {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
}
|
||||
|
||||
void CefBrowserPlatformDelegate::AccessibilityLocationChangesReceived(
|
||||
const std::vector<content::AXLocationChangeNotificationDetails>& locData) {
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
}
|
||||
|
||||
gfx::Point CefBrowserPlatformDelegate::GetDialogPosition(
|
||||
@@ -408,7 +408,7 @@ void CefBrowserPlatformDelegate::StopFinding(bool clearSelection) {
|
||||
|
||||
// static
|
||||
int CefBrowserPlatformDelegate::TranslateWebEventModifiers(
|
||||
uint32 cef_modifiers) {
|
||||
uint32_t cef_modifiers) {
|
||||
int result = 0;
|
||||
// Set modifiers based on key state.
|
||||
if (cef_modifiers & EVENTFLAG_CAPS_LOCK_ON) {
|
||||
|
@@ -379,7 +379,7 @@ class CefBrowserPlatformDelegate {
|
||||
CefBrowserPlatformDelegate();
|
||||
virtual ~CefBrowserPlatformDelegate();
|
||||
|
||||
static int TranslateWebEventModifiers(uint32 cef_modifiers);
|
||||
static int TranslateWebEventModifiers(uint32_t cef_modifiers);
|
||||
|
||||
// Not owned by this object.
|
||||
content::WebContents* web_contents_ = nullptr;
|
||||
|
@@ -138,6 +138,6 @@ std::unique_ptr<CefBrowserPlatformDelegate> CefBrowserPlatformDelegate::Create(
|
||||
return std::move(native_delegate);
|
||||
}
|
||||
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return nullptr;
|
||||
}
|
||||
|
@@ -56,7 +56,7 @@ CefBrowserPlatformDelegateChrome::GetWebContentsModalDialogHost() const {
|
||||
ChromeWebModalDialogManagerDelegate* manager = chrome_browser_;
|
||||
return manager->GetWebContentsModalDialogHost();
|
||||
}
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
@@ -143,6 +143,6 @@ gfx::NativeWindow CefBrowserPlatformDelegateChrome::GetNativeWindow() const {
|
||||
if (chrome_browser_ && chrome_browser_->window()) {
|
||||
return chrome_browser_->window()->GetNativeWindow();
|
||||
}
|
||||
NOTREACHED();
|
||||
DCHECK(false);
|
||||
return gfx::NativeWindow();
|
||||
}
|
||||
|
@@ -299,7 +299,7 @@ bool CefInitialize(const CefMainArgs& args,
|
||||
}
|
||||
|
||||
if (settings.size != sizeof(cef_settings_t)) {
|
||||
NOTREACHED() << "invalid CefSettings structure size";
|
||||
DCHECK(false) << "invalid CefSettings structure size";
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -314,13 +314,13 @@ bool CefInitialize(const CefMainArgs& args,
|
||||
void CefShutdown() {
|
||||
// Verify that the context is in a valid state.
|
||||
if (!CONTEXT_STATE_VALID()) {
|
||||
NOTREACHED() << "context not valid";
|
||||
DCHECK(false) << "context not valid";
|
||||
return;
|
||||
}
|
||||
|
||||
// Must always be called on the same thread as Initialize.
|
||||
if (!g_context->OnInitThread()) {
|
||||
NOTREACHED() << "called on invalid thread";
|
||||
DCHECK(false) << "called on invalid thread";
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -335,13 +335,13 @@ void CefShutdown() {
|
||||
void CefDoMessageLoopWork() {
|
||||
// Verify that the context is in a valid state.
|
||||
if (!CONTEXT_STATE_VALID()) {
|
||||
NOTREACHED() << "context not valid";
|
||||
DCHECK(false) << "context not valid";
|
||||
return;
|
||||
}
|
||||
|
||||
// Must always be called on the same thread as Initialize.
|
||||
if (!g_context->OnInitThread()) {
|
||||
NOTREACHED() << "called on invalid thread";
|
||||
DCHECK(false) << "called on invalid thread";
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -352,13 +352,13 @@ void CefDoMessageLoopWork() {
|
||||
void CefRunMessageLoop() {
|
||||
// Verify that the context is in a valid state.
|
||||
if (!CONTEXT_STATE_VALID()) {
|
||||
NOTREACHED() << "context not valid";
|
||||
DCHECK(false) << "context not valid";
|
||||
return;
|
||||
}
|
||||
|
||||
// Must always be called on the same thread as Initialize.
|
||||
if (!g_context->OnInitThread()) {
|
||||
NOTREACHED() << "called on invalid thread";
|
||||
DCHECK(false) << "called on invalid thread";
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -368,13 +368,13 @@ void CefRunMessageLoop() {
|
||||
void CefQuitMessageLoop() {
|
||||
// Verify that the context is in a valid state.
|
||||
if (!CONTEXT_STATE_VALID()) {
|
||||
NOTREACHED() << "context not valid";
|
||||
DCHECK(false) << "context not valid";
|
||||
return;
|
||||
}
|
||||
|
||||
// Must always be called on the same thread as Initialize.
|
||||
if (!g_context->OnInitThread()) {
|
||||
NOTREACHED() << "called on invalid thread";
|
||||
DCHECK(false) << "called on invalid thread";
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -403,7 +403,7 @@ int CefRunMainWithPreferredStackSize(mainPtr main, int argc, char* argv[]) {
|
||||
void CefSetOSModalLoop(bool osModalLoop) {
|
||||
// Verify that the context is in a valid state.
|
||||
if (!CONTEXT_STATE_VALID()) {
|
||||
NOTREACHED() << "context not valid";
|
||||
DCHECK(false) << "context not valid";
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -462,7 +462,6 @@ bool CefContext::Initialize(const CefMainArgs& args,
|
||||
"browser_subprocess_path");
|
||||
NormalizePathAndSet(settings_.framework_dir_path, "framework_dir_path");
|
||||
NormalizePathAndSet(settings_.main_bundle_path, "main_bundle_path");
|
||||
NormalizePathAndSet(settings_.user_data_path, "user_data_path");
|
||||
NormalizePathAndSet(settings_.resources_dir_path, "resources_dir_path");
|
||||
NormalizePathAndSet(settings_.locales_dir_path, "locales_dir_path");
|
||||
|
||||
|
@@ -227,7 +227,7 @@ class CefDevToolsFrontend::NetworkResourceLoader
|
||||
bindings_->loaders_.erase(bindings_->loaders_.find(this));
|
||||
}
|
||||
|
||||
void OnRetry(base::OnceClosure start_retry) override { NOTREACHED(); }
|
||||
void OnRetry(base::OnceClosure start_retry) override { DCHECK(false); }
|
||||
|
||||
const int stream_id_;
|
||||
CefDevToolsFrontend* const bindings_;
|
||||
|
@@ -50,7 +50,7 @@ cef_download_interrupt_reason_t CefDownloadItemImpl::GetInterruptReason() {
|
||||
const_value().GetLastReason());
|
||||
}
|
||||
|
||||
int64 CefDownloadItemImpl::GetCurrentSpeed() {
|
||||
int64_t CefDownloadItemImpl::GetCurrentSpeed() {
|
||||
CEF_VALUE_VERIFY_RETURN(false, 0);
|
||||
return const_value().CurrentSpeed();
|
||||
}
|
||||
@@ -60,12 +60,12 @@ int CefDownloadItemImpl::GetPercentComplete() {
|
||||
return const_value().PercentComplete();
|
||||
}
|
||||
|
||||
int64 CefDownloadItemImpl::GetTotalBytes() {
|
||||
int64_t CefDownloadItemImpl::GetTotalBytes() {
|
||||
CEF_VALUE_VERIFY_RETURN(false, 0);
|
||||
return const_value().GetTotalBytes();
|
||||
}
|
||||
|
||||
int64 CefDownloadItemImpl::GetReceivedBytes() {
|
||||
int64_t CefDownloadItemImpl::GetReceivedBytes() {
|
||||
CEF_VALUE_VERIFY_RETURN(false, 0);
|
||||
return const_value().GetReceivedBytes();
|
||||
}
|
||||
@@ -85,7 +85,7 @@ CefString CefDownloadItemImpl::GetFullPath() {
|
||||
return const_value().GetFullPath().value();
|
||||
}
|
||||
|
||||
uint32 CefDownloadItemImpl::GetId() {
|
||||
uint32_t CefDownloadItemImpl::GetId() {
|
||||
CEF_VALUE_VERIFY_RETURN(false, 0);
|
||||
return const_value().GetId();
|
||||
}
|
||||
|
@@ -29,14 +29,14 @@ class CefDownloadItemImpl
|
||||
bool IsCanceled() override;
|
||||
bool IsInterrupted() override;
|
||||
cef_download_interrupt_reason_t GetInterruptReason() override;
|
||||
int64 GetCurrentSpeed() override;
|
||||
int64_t GetCurrentSpeed() override;
|
||||
int GetPercentComplete() override;
|
||||
int64 GetTotalBytes() override;
|
||||
int64 GetReceivedBytes() override;
|
||||
int64_t GetTotalBytes() override;
|
||||
int64_t GetReceivedBytes() override;
|
||||
CefBaseTime GetStartTime() override;
|
||||
CefBaseTime GetEndTime() override;
|
||||
CefString GetFullPath() override;
|
||||
uint32 GetId() override;
|
||||
uint32_t GetId() override;
|
||||
CefString GetURL() override;
|
||||
CefString GetOriginalUrl() override;
|
||||
CefString GetSuggestedFileName() override;
|
||||
|
@@ -45,7 +45,7 @@ CefRefPtr<CefDownloadHandler> GetDownloadHandler(
|
||||
class CefBeforeDownloadCallbackImpl : public CefBeforeDownloadCallback {
|
||||
public:
|
||||
CefBeforeDownloadCallbackImpl(const base::WeakPtr<DownloadManager>& manager,
|
||||
uint32 download_id,
|
||||
uint32_t download_id,
|
||||
const base::FilePath& suggested_name,
|
||||
content::DownloadTargetCallback callback)
|
||||
: manager_(manager),
|
||||
@@ -81,7 +81,7 @@ class CefBeforeDownloadCallbackImpl : public CefBeforeDownloadCallback {
|
||||
|
||||
private:
|
||||
static void GenerateFilename(base::WeakPtr<DownloadManager> manager,
|
||||
uint32 download_id,
|
||||
uint32_t download_id,
|
||||
const base::FilePath& suggested_name,
|
||||
const base::FilePath& download_path,
|
||||
bool show_dialog,
|
||||
@@ -94,7 +94,7 @@ class CefBeforeDownloadCallbackImpl : public CefBeforeDownloadCallback {
|
||||
base::FilePath dir_path = suggested_path.DirName();
|
||||
if (!base::DirectoryExists(dir_path) &&
|
||||
!base::CreateDirectory(dir_path)) {
|
||||
NOTREACHED() << "failed to create the download directory";
|
||||
DCHECK(false) << "failed to create the download directory";
|
||||
suggested_path.clear();
|
||||
}
|
||||
}
|
||||
@@ -117,7 +117,7 @@ class CefBeforeDownloadCallbackImpl : public CefBeforeDownloadCallback {
|
||||
}
|
||||
|
||||
static void ChooseDownloadPath(base::WeakPtr<DownloadManager> manager,
|
||||
uint32 download_id,
|
||||
uint32_t download_id,
|
||||
const base::FilePath& suggested_path,
|
||||
bool show_dialog,
|
||||
content::DownloadTargetCallback callback) {
|
||||
@@ -188,7 +188,7 @@ class CefBeforeDownloadCallbackImpl : public CefBeforeDownloadCallback {
|
||||
}
|
||||
|
||||
base::WeakPtr<DownloadManager> manager_;
|
||||
uint32 download_id_;
|
||||
uint32_t download_id_;
|
||||
base::FilePath suggested_name_;
|
||||
content::DownloadTargetCallback callback_;
|
||||
|
||||
@@ -200,7 +200,7 @@ class CefDownloadItemCallbackImpl : public CefDownloadItemCallback {
|
||||
public:
|
||||
explicit CefDownloadItemCallbackImpl(
|
||||
const base::WeakPtr<DownloadManager>& manager,
|
||||
uint32 download_id)
|
||||
uint32_t download_id)
|
||||
: manager_(manager), download_id_(download_id) {}
|
||||
|
||||
CefDownloadItemCallbackImpl(const CefDownloadItemCallbackImpl&) = delete;
|
||||
@@ -265,7 +265,7 @@ class CefDownloadItemCallbackImpl : public CefDownloadItemCallback {
|
||||
}
|
||||
|
||||
base::WeakPtr<DownloadManager> manager_;
|
||||
uint32 download_id_;
|
||||
uint32_t download_id_;
|
||||
|
||||
IMPLEMENT_REFCOUNTING(CefDownloadItemCallbackImpl);
|
||||
};
|
||||
@@ -416,7 +416,7 @@ bool CefDownloadManagerDelegate::DetermineDownloadTarget(
|
||||
|
||||
void CefDownloadManagerDelegate::GetNextId(
|
||||
content::DownloadIdCallback callback) {
|
||||
static uint32 next_id = DownloadItem::kInvalidId + 1;
|
||||
static uint32_t next_id = DownloadItem::kInvalidId + 1;
|
||||
std::move(callback).Run(next_id++);
|
||||
}
|
||||
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user