mirror of
https://github.com/browseros-ai/BrowserOS.git
synced 2026-05-13 23:53:25 +00:00
feat: chromium 145 upgrade (#362)
* feat: new apply --force * chore: update chromium version * feat: chromium 145 updated patches * fix: disable series patches for nwo * chore: bump offset + version --------- Co-authored-by: Nikhil <shadowfax@mac.local.meter>
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
MAJOR=142
|
||||
MAJOR=145
|
||||
MINOR=0
|
||||
BUILD=7444
|
||||
PATCH=49
|
||||
BUILD=7632
|
||||
PATCH=46
|
||||
|
||||
31
packages/browseros/build/cli/dev.py
generated
31
packages/browseros/build/cli/dev.py
generated
@@ -364,6 +364,37 @@ def apply_patch_cmd(
|
||||
log_success(f"Successfully applied patch for: {chromium_path}")
|
||||
|
||||
|
||||
@apply_app.command(name="force")
|
||||
def apply_force(
|
||||
reset_to: Optional[str] = Option(
|
||||
None, "--reset-to", "-r", help="Reset files to this commit before applying patches"
|
||||
),
|
||||
):
|
||||
"""Apply all patches non-interactively, writing .rej files for conflicts.
|
||||
|
||||
Applies every patch without prompting. When a patch conflicts, uses
|
||||
git apply --reject to apply what it can and write .rej files for
|
||||
failed hunks, then continues to the next patch.
|
||||
|
||||
Examples:
|
||||
browseros dev apply force -S /chromium
|
||||
browseros dev apply force --reset-to base -S /chromium
|
||||
"""
|
||||
ctx = create_build_context(state.chromium_src)
|
||||
if not ctx:
|
||||
raise typer.Exit(1)
|
||||
|
||||
from ..modules.apply import ApplyForceModule
|
||||
|
||||
module = ApplyForceModule()
|
||||
try:
|
||||
module.validate(ctx)
|
||||
module.execute(ctx, reset_to=reset_to)
|
||||
except Exception as e:
|
||||
log_error(f"Failed to apply patches: {e}")
|
||||
raise typer.Exit(1)
|
||||
|
||||
|
||||
@apply_app.command(name="changed")
|
||||
def apply_changed(
|
||||
commit: Optional[str] = Option(
|
||||
|
||||
@@ -1 +1 @@
|
||||
121
|
||||
122
|
||||
|
||||
@@ -12,6 +12,7 @@ from .apply_all import apply_all_patches, ApplyAllModule
|
||||
from .apply_feature import apply_feature_patches, ApplyFeatureModule
|
||||
from .apply_patch import apply_single_file_patch
|
||||
from .apply_changed import apply_changed_patches, ApplyChangedModule
|
||||
from .apply_force import apply_all_force, ApplyForceModule
|
||||
|
||||
__all__ = [
|
||||
"apply_all_patches",
|
||||
@@ -21,4 +22,6 @@ __all__ = [
|
||||
"apply_single_file_patch",
|
||||
"apply_changed_patches",
|
||||
"ApplyChangedModule",
|
||||
"apply_all_force",
|
||||
"ApplyForceModule",
|
||||
]
|
||||
|
||||
196
packages/browseros/build/modules/apply/apply_force.py
generated
Normal file
196
packages/browseros/build/modules/apply/apply_force.py
generated
Normal file
@@ -0,0 +1,196 @@
|
||||
"""
|
||||
Apply Force - Non-interactive apply that uses --reject for conflicts.
|
||||
|
||||
When a patch fails to apply cleanly, falls back to `git apply --reject`
|
||||
which applies what it can and writes .rej files for failed hunks.
|
||||
Always continues to the next patch regardless of failures.
|
||||
"""
|
||||
|
||||
from pathlib import Path
|
||||
from typing import List, Tuple, Optional
|
||||
|
||||
from ...common.context import Context
|
||||
from ...common.module import CommandModule, ValidationError
|
||||
from ...common.utils import log_info, log_error, log_warning, log_success
|
||||
from .common import find_patch_files
|
||||
from .utils import run_git_command, file_exists_in_commit, reset_file_to_commit
|
||||
|
||||
|
||||
def apply_patch_with_reject(
|
||||
patch_path: Path,
|
||||
chromium_src: Path,
|
||||
relative_to: Optional[Path] = None,
|
||||
reset_to: Optional[str] = None,
|
||||
) -> Tuple[str, Optional[str]]:
|
||||
"""Apply a single patch, falling back to --reject on conflict.
|
||||
|
||||
Args:
|
||||
patch_path: Path to the patch file
|
||||
chromium_src: Chromium source directory
|
||||
relative_to: Base path for displaying relative paths
|
||||
reset_to: Commit to reset file to before applying
|
||||
|
||||
Returns:
|
||||
Tuple of (status, rej_files) where status is one of:
|
||||
- "applied": patch applied cleanly (rej_files is [])
|
||||
- "rejected": patch had conflicts, .rej files written (rej_files has full paths)
|
||||
- "failed": patch could not be applied at all
|
||||
"""
|
||||
display_path = patch_path.relative_to(relative_to) if relative_to else patch_path
|
||||
|
||||
# Reset file to base commit if requested
|
||||
if reset_to:
|
||||
file_path = str(display_path)
|
||||
if file_exists_in_commit(file_path, reset_to, chromium_src):
|
||||
reset_file_to_commit(file_path, reset_to, chromium_src)
|
||||
else:
|
||||
target_file = chromium_src / file_path
|
||||
if target_file.exists():
|
||||
target_file.unlink()
|
||||
|
||||
# Try clean apply first (same strategy as common.apply_single_patch)
|
||||
result = run_git_command(
|
||||
[
|
||||
"git", "apply",
|
||||
"--ignore-whitespace", "--whitespace=nowarn",
|
||||
"-p1", str(patch_path),
|
||||
],
|
||||
cwd=chromium_src,
|
||||
)
|
||||
|
||||
if result.returncode == 0:
|
||||
log_success(f" Applied: {display_path}")
|
||||
return "applied", []
|
||||
|
||||
# Try 3-way merge
|
||||
result = run_git_command(
|
||||
[
|
||||
"git", "apply",
|
||||
"--ignore-whitespace", "--whitespace=nowarn",
|
||||
"-p1", "--3way",
|
||||
str(patch_path),
|
||||
],
|
||||
cwd=chromium_src,
|
||||
)
|
||||
|
||||
if result.returncode == 0:
|
||||
log_success(f" Applied (3way): {display_path}")
|
||||
return "applied", []
|
||||
|
||||
# Fall back to --reject: applies what it can, writes .rej for the rest
|
||||
result = run_git_command(
|
||||
[
|
||||
"git", "apply",
|
||||
"--ignore-whitespace", "--whitespace=nowarn",
|
||||
"-p1", "--reject",
|
||||
str(patch_path),
|
||||
],
|
||||
cwd=chromium_src,
|
||||
)
|
||||
|
||||
if result.returncode == 0:
|
||||
# --reject returned 0 means it applied (possibly with warnings)
|
||||
log_success(f" Applied (reject): {display_path}")
|
||||
return "applied", []
|
||||
else:
|
||||
# Some hunks failed - .rej files were written
|
||||
log_warning(f" Conflict: {display_path}")
|
||||
# Find .rej files created for this patch
|
||||
rej_path = chromium_src / f"{display_path}.rej"
|
||||
rej_files = []
|
||||
if rej_path.exists():
|
||||
rej_files.append(str(rej_path))
|
||||
log_warning(f" .rej: {rej_path}")
|
||||
return "rejected", rej_files
|
||||
|
||||
|
||||
def apply_all_force(
|
||||
build_ctx: Context,
|
||||
reset_to: Optional[str] = None,
|
||||
) -> Tuple[int, int, List[str]]:
|
||||
"""Apply all patches non-interactively, using --reject for conflicts.
|
||||
|
||||
Args:
|
||||
build_ctx: Build context
|
||||
reset_to: Commit to reset files to before applying
|
||||
|
||||
Returns:
|
||||
Tuple of (applied_count, rejected_count, failed_list)
|
||||
"""
|
||||
patches_dir = build_ctx.get_patches_dir()
|
||||
|
||||
if not patches_dir.exists():
|
||||
log_warning(f"Patches directory does not exist: {patches_dir}")
|
||||
return 0, 0, []
|
||||
|
||||
patch_files = find_patch_files(patches_dir)
|
||||
|
||||
if not patch_files:
|
||||
log_warning("No patch files found")
|
||||
return 0, 0, []
|
||||
|
||||
log_info(f"Found {len(patch_files)} patches (non-interactive, --reject on conflict)")
|
||||
|
||||
applied = 0
|
||||
rejected = 0
|
||||
failed = []
|
||||
all_rej_files: List[str] = []
|
||||
|
||||
for patch_path in patch_files:
|
||||
display_name = str(patch_path.relative_to(patches_dir))
|
||||
|
||||
if not patch_path.exists():
|
||||
log_warning(f" Patch not found: {display_name}")
|
||||
failed.append(display_name)
|
||||
continue
|
||||
|
||||
status, rej_files = apply_patch_with_reject(
|
||||
patch_path, build_ctx.chromium_src, patches_dir, reset_to
|
||||
)
|
||||
|
||||
if status == "applied":
|
||||
applied += 1
|
||||
elif status == "rejected":
|
||||
rejected += 1
|
||||
failed.append(display_name)
|
||||
all_rej_files.extend(rej_files)
|
||||
else:
|
||||
failed.append(display_name)
|
||||
|
||||
# Summary
|
||||
log_info(f"\nSummary: {applied} applied, {rejected} rejected (.rej), {len(failed)} total failed")
|
||||
|
||||
if all_rej_files:
|
||||
log_warning("Reject files:")
|
||||
for rej in all_rej_files:
|
||||
log_warning(f" {rej}")
|
||||
|
||||
return applied, rejected, failed
|
||||
|
||||
|
||||
class ApplyForceModule(CommandModule):
|
||||
"""Non-interactive apply with --reject for conflicts"""
|
||||
|
||||
produces = []
|
||||
requires = []
|
||||
description = "Apply all patches non-interactively, writing .rej files for conflicts"
|
||||
|
||||
def validate(self, ctx: Context) -> None:
|
||||
import shutil
|
||||
|
||||
if not shutil.which("git"):
|
||||
raise ValidationError("Git is not available in PATH")
|
||||
if not ctx.chromium_src.exists():
|
||||
raise ValidationError(f"Chromium source not found: {ctx.chromium_src}")
|
||||
|
||||
def execute(
|
||||
self,
|
||||
ctx: Context,
|
||||
reset_to: Optional[str] = None,
|
||||
**kwargs,
|
||||
) -> None:
|
||||
applied, rejected, failed = apply_all_force(ctx, reset_to=reset_to)
|
||||
if rejected > 0:
|
||||
log_warning(
|
||||
f"{rejected} patch(es) had conflicts. Review .rej files in chromium source."
|
||||
)
|
||||
@@ -1,15 +1,16 @@
|
||||
diff --git a/chrome/app/chrome_command_ids.h b/chrome/app/chrome_command_ids.h
|
||||
index d32aa215bc900..237fd55fe2aaf 100644
|
||||
index 650fa7987ac19..d685c16726d1c 100644
|
||||
--- a/chrome/app/chrome_command_ids.h
|
||||
+++ b/chrome/app/chrome_command_ids.h
|
||||
@@ -298,6 +298,10 @@
|
||||
#define IDC_SHOW_SEARCH_TOOLS 40296
|
||||
@@ -304,6 +304,11 @@
|
||||
#define IDC_SHOW_COMMENTS_SIDE_PANEL 40297
|
||||
#define IDC_RECENT_TABS_SEE_DEVICE_TABS 40298
|
||||
+#define IDC_SHOW_THIRD_PARTY_LLM_SIDE_PANEL 40299
|
||||
+#define IDC_CYCLE_THIRD_PARTY_LLM_PROVIDER 40300
|
||||
+#define IDC_OPEN_CLASH_OF_GPTS 40301
|
||||
+#define IDC_TOGGLE_BROWSEROS_AGENT 40302
|
||||
#define IDC_SHOW_AI_MODE_OMNIBOX_BUTTON 40299
|
||||
+// BrowserOS: custom command IDs
|
||||
+#define IDC_SHOW_THIRD_PARTY_LLM_SIDE_PANEL 40300
|
||||
+#define IDC_CYCLE_THIRD_PARTY_LLM_PROVIDER 40301
|
||||
+#define IDC_OPEN_CLASH_OF_GPTS 40302
|
||||
+#define IDC_TOGGLE_BROWSEROS_AGENT 40303
|
||||
|
||||
// Spell-check
|
||||
// Insert any additional suggestions before _LAST; these have to be consecutive.
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
diff --git a/chrome/browser/browseros/core/browseros_constants.h b/chrome/browser/browseros/core/browseros_constants.h
|
||||
new file mode 100644
|
||||
index 0000000000000..476d761245673
|
||||
index 0000000000000..adc52f61b9771
|
||||
--- /dev/null
|
||||
+++ b/chrome/browser/browseros/core/browseros_constants.h
|
||||
@@ -0,0 +1,222 @@
|
||||
@@ -0,0 +1,223 @@
|
||||
+// Copyright 2024 The Chromium Authors
|
||||
+// Use of this source code is governed by a BSD-style license that can be
|
||||
+// found in the LICENSE file.
|
||||
@@ -13,6 +13,7 @@ index 0000000000000..476d761245673
|
||||
+
|
||||
+#include <cstddef>
|
||||
+#include <string>
|
||||
+#include <string_view>
|
||||
+#include <vector>
|
||||
+
|
||||
+#include "base/command_line.h"
|
||||
@@ -81,7 +82,7 @@ index 0000000000000..476d761245673
|
||||
+
|
||||
+// Find a route for a given virtual path (e.g., "/ai")
|
||||
+// Returns nullptr if no matching route found
|
||||
+inline const BrowserOSURLRoute* FindBrowserOSRoute(const std::string& path) {
|
||||
+inline const BrowserOSURLRoute* FindBrowserOSRoute(std::string_view path) {
|
||||
+ for (const auto& route : kBrowserOSURLRoutes) {
|
||||
+ if (path == route.virtual_path) {
|
||||
+ return &route;
|
||||
@@ -93,7 +94,7 @@ index 0000000000000..476d761245673
|
||||
+// Get the extension URL for a chrome://browseros/* path
|
||||
+// Returns empty string if no matching route or if URL overrides are disabled
|
||||
+// Example: "/ai" -> "chrome-extension://bflp.../options.html#ai"
|
||||
+inline std::string GetBrowserOSExtensionURL(const std::string& virtual_path) {
|
||||
+inline std::string GetBrowserOSExtensionURL(std::string_view virtual_path) {
|
||||
+ if (IsURLOverridesDisabled()) {
|
||||
+ return std::string();
|
||||
+ }
|
||||
@@ -118,15 +119,15 @@ index 0000000000000..476d761245673
|
||||
+// extension_path: from url.path(), e.g., "/options.html"
|
||||
+// extension_ref: from url.ref(), e.g., "ai" or "/ai" (normalized internally)
|
||||
+// Fallback: If no exact hash match, falls back to route with empty hash for same page
|
||||
+inline std::string GetBrowserOSVirtualURL(const std::string& extension_id,
|
||||
+ const std::string& extension_path,
|
||||
+ const std::string& extension_ref) {
|
||||
+inline std::string GetBrowserOSVirtualURL(std::string_view extension_id,
|
||||
+ std::string_view extension_path,
|
||||
+ std::string_view extension_ref) {
|
||||
+ if (IsURLOverridesDisabled()) {
|
||||
+ return std::string();
|
||||
+ }
|
||||
+
|
||||
+ // Normalize ref - strip leading slash if present (handles both #ai and #/ai)
|
||||
+ std::string normalized_ref = extension_ref;
|
||||
+ std::string normalized_ref(extension_ref);
|
||||
+ if (!normalized_ref.empty() && normalized_ref[0] == '/') {
|
||||
+ normalized_ref = normalized_ref.substr(1);
|
||||
+ }
|
||||
|
||||
@@ -1,15 +1,16 @@
|
||||
diff --git a/chrome/browser/browseros/extensions/browseros_extension_installer.cc b/chrome/browser/browseros/extensions/browseros_extension_installer.cc
|
||||
new file mode 100644
|
||||
index 0000000000000..e84ab10537ec4
|
||||
index 0000000000000..27fadedbd37ef
|
||||
--- /dev/null
|
||||
+++ b/chrome/browser/browseros/extensions/browseros_extension_installer.cc
|
||||
@@ -0,0 +1,338 @@
|
||||
@@ -0,0 +1,341 @@
|
||||
+// Copyright 2024 The Chromium Authors
|
||||
+// Use of this source code is governed by a BSD-style license that can be
|
||||
+// found in the LICENSE file.
|
||||
+
|
||||
+#include "chrome/browser/browseros/extensions/browseros_extension_installer.h"
|
||||
+
|
||||
+#include <optional>
|
||||
+#include <utility>
|
||||
+
|
||||
+#include "base/feature_list.h"
|
||||
@@ -124,7 +125,8 @@ index 0000000000000..e84ab10537ec4
|
||||
+ return base::Value::Dict();
|
||||
+ }
|
||||
+
|
||||
+ std::optional<base::Value> parsed = base::JSONReader::Read(json_content);
|
||||
+ std::optional<base::Value> parsed =
|
||||
+ base::JSONReader::Read(json_content, base::JSON_PARSE_RFC);
|
||||
+ if (!parsed || !parsed->is_dict()) {
|
||||
+ LOG(ERROR) << "browseros: Invalid bundled manifest JSON";
|
||||
+ return base::Value::Dict();
|
||||
@@ -234,8 +236,8 @@ index 0000000000000..e84ab10537ec4
|
||||
+}
|
||||
+
|
||||
+void BrowserOSExtensionInstaller::OnRemoteFetchComplete(
|
||||
+ std::unique_ptr<std::string> response_body) {
|
||||
+ if (!response_body) {
|
||||
+ std::optional<std::string> response_body) {
|
||||
+ if (!response_body.has_value()) {
|
||||
+ LOG(ERROR) << "browseros: Failed to fetch config";
|
||||
+ Complete(InstallResult());
|
||||
+ return;
|
||||
@@ -317,7 +319,8 @@ index 0000000000000..e84ab10537ec4
|
||||
+
|
||||
+base::Value::Dict BrowserOSExtensionInstaller::ParseConfigJson(
|
||||
+ const std::string& json_content) {
|
||||
+ std::optional<base::Value> parsed = base::JSONReader::Read(json_content);
|
||||
+ std::optional<base::Value> parsed =
|
||||
+ base::JSONReader::Read(json_content, base::JSON_PARSE_RFC);
|
||||
+
|
||||
+ if (!parsed || !parsed->is_dict()) {
|
||||
+ LOG(ERROR) << "browseros: Invalid config JSON";
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
diff --git a/chrome/browser/browseros/extensions/browseros_extension_installer.h b/chrome/browser/browseros/extensions/browseros_extension_installer.h
|
||||
new file mode 100644
|
||||
index 0000000000000..7502da6d31ff5
|
||||
index 0000000000000..9a3c2000ed05a
|
||||
--- /dev/null
|
||||
+++ b/chrome/browser/browseros/extensions/browseros_extension_installer.h
|
||||
@@ -0,0 +1,99 @@
|
||||
@@ -0,0 +1,100 @@
|
||||
+// Copyright 2024 The Chromium Authors
|
||||
+// Use of this source code is governed by a BSD-style license that can be
|
||||
+// found in the LICENSE file.
|
||||
@@ -12,6 +12,7 @@ index 0000000000000..7502da6d31ff5
|
||||
+#define CHROME_BROWSER_BROWSEROS_EXTENSIONS_BROWSEROS_EXTENSION_INSTALLER_H_
|
||||
+
|
||||
+#include <memory>
|
||||
+#include <optional>
|
||||
+#include <set>
|
||||
+#include <string>
|
||||
+
|
||||
@@ -81,7 +82,7 @@ index 0000000000000..7502da6d31ff5
|
||||
+ void FetchFromRemote();
|
||||
+
|
||||
+ // Called when remote fetch completes.
|
||||
+ void OnRemoteFetchComplete(std::unique_ptr<std::string> response_body);
|
||||
+ void OnRemoteFetchComplete(std::optional<std::string> response_body);
|
||||
+
|
||||
+ // Parses config JSON and returns extensions dict.
|
||||
+ base::Value::Dict ParseConfigJson(const std::string& json_content);
|
||||
|
||||
@@ -1,15 +1,16 @@
|
||||
diff --git a/chrome/browser/browseros/extensions/browseros_extension_maintainer.cc b/chrome/browser/browseros/extensions/browseros_extension_maintainer.cc
|
||||
new file mode 100644
|
||||
index 0000000000000..fec50b08b130c
|
||||
index 0000000000000..404fb31de4e55
|
||||
--- /dev/null
|
||||
+++ b/chrome/browser/browseros/extensions/browseros_extension_maintainer.cc
|
||||
@@ -0,0 +1,381 @@
|
||||
@@ -0,0 +1,383 @@
|
||||
+// Copyright 2024 The Chromium Authors
|
||||
+// Use of this source code is governed by a BSD-style license that can be
|
||||
+// found in the LICENSE file.
|
||||
+
|
||||
+#include "chrome/browser/browseros/extensions/browseros_extension_maintainer.h"
|
||||
+
|
||||
+#include <optional>
|
||||
+#include <utility>
|
||||
+
|
||||
+#include "base/json/json_reader.h"
|
||||
@@ -124,8 +125,8 @@ index 0000000000000..fec50b08b130c
|
||||
+
|
||||
+void BrowserOSExtensionMaintainer::OnConfigFetched(
|
||||
+ std::unique_ptr<network::SimpleURLLoader> loader,
|
||||
+ std::unique_ptr<std::string> response_body) {
|
||||
+ if (response_body) {
|
||||
+ std::optional<std::string> response_body) {
|
||||
+ if (response_body.has_value()) {
|
||||
+ base::Value::Dict config = ParseConfigJson(*response_body);
|
||||
+ if (!config.empty()) {
|
||||
+ last_config_ = std::move(config);
|
||||
@@ -147,7 +148,8 @@ index 0000000000000..fec50b08b130c
|
||||
+
|
||||
+base::Value::Dict BrowserOSExtensionMaintainer::ParseConfigJson(
|
||||
+ const std::string& json_content) {
|
||||
+ std::optional<base::Value> parsed = base::JSONReader::Read(json_content);
|
||||
+ std::optional<base::Value> parsed =
|
||||
+ base::JSONReader::Read(json_content, base::JSON_PARSE_RFC);
|
||||
+
|
||||
+ if (!parsed || !parsed->is_dict()) {
|
||||
+ LOG(ERROR) << "browseros: Invalid config JSON";
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
diff --git a/chrome/browser/browseros/extensions/browseros_extension_maintainer.h b/chrome/browser/browseros/extensions/browseros_extension_maintainer.h
|
||||
new file mode 100644
|
||||
index 0000000000000..e7e228e6fd71e
|
||||
index 0000000000000..eb68969a4163f
|
||||
--- /dev/null
|
||||
+++ b/chrome/browser/browseros/extensions/browseros_extension_maintainer.h
|
||||
@@ -0,0 +1,83 @@
|
||||
@@ -0,0 +1,84 @@
|
||||
+// Copyright 2024 The Chromium Authors
|
||||
+// Use of this source code is governed by a BSD-style license that can be
|
||||
+// found in the LICENSE file.
|
||||
@@ -12,6 +12,7 @@ index 0000000000000..e7e228e6fd71e
|
||||
+#define CHROME_BROWSER_BROWSEROS_EXTENSIONS_BROWSEROS_EXTENSION_MAINTAINER_H_
|
||||
+
|
||||
+#include <memory>
|
||||
+#include <optional>
|
||||
+#include <set>
|
||||
+#include <string>
|
||||
+
|
||||
@@ -56,7 +57,7 @@ index 0000000000000..e7e228e6fd71e
|
||||
+
|
||||
+ // Called when config fetch completes.
|
||||
+ void OnConfigFetched(std::unique_ptr<network::SimpleURLLoader> loader,
|
||||
+ std::unique_ptr<std::string> response_body);
|
||||
+ std::optional<std::string> response_body);
|
||||
+
|
||||
+ // Parses config JSON and returns extensions dict.
|
||||
+ base::Value::Dict ParseConfigJson(const std::string& json_content);
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
diff --git a/chrome/browser/browseros/metrics/browseros_metrics_service.cc b/chrome/browser/browseros/metrics/browseros_metrics_service.cc
|
||||
new file mode 100644
|
||||
index 0000000000000..8c8c588df4481
|
||||
index 0000000000000..cbc1f29e5d407
|
||||
--- /dev/null
|
||||
+++ b/chrome/browser/browseros/metrics/browseros_metrics_service.cc
|
||||
@@ -0,0 +1,231 @@
|
||||
@@ -198,7 +198,7 @@ index 0000000000000..8c8c588df4481
|
||||
+
|
||||
+void BrowserOSMetricsService::OnPostHogResponse(
|
||||
+ std::unique_ptr<network::SimpleURLLoader> loader,
|
||||
+ std::unique_ptr<std::string> response_body) {
|
||||
+ std::optional<std::string> response_body) {
|
||||
+ int response_code = 0;
|
||||
+ if (loader->ResponseInfo() && loader->ResponseInfo()->headers) {
|
||||
+ response_code = loader->ResponseInfo()->headers->response_code();
|
||||
@@ -209,7 +209,7 @@ index 0000000000000..8c8c588df4481
|
||||
+ } else {
|
||||
+ LOG(WARNING) << "browseros: Failed to send metrics event. Response code: "
|
||||
+ << response_code;
|
||||
+ if (response_body && !response_body->empty()) {
|
||||
+ if (response_body.has_value() && !response_body->empty()) {
|
||||
+ LOG(WARNING) << "browseros: Error response: " << *response_body;
|
||||
+ }
|
||||
+ }
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
diff --git a/chrome/browser/browseros/metrics/browseros_metrics_service.h b/chrome/browser/browseros/metrics/browseros_metrics_service.h
|
||||
new file mode 100644
|
||||
index 0000000000000..2157d1eb1698e
|
||||
index 0000000000000..beadbcfd183e0
|
||||
--- /dev/null
|
||||
+++ b/chrome/browser/browseros/metrics/browseros_metrics_service.h
|
||||
@@ -0,0 +1,95 @@
|
||||
@@ -0,0 +1,96 @@
|
||||
+// Copyright 2025 The Chromium Authors
|
||||
+// Use of this source code is governed by a BSD-style license that can be
|
||||
+// found in the LICENSE file.
|
||||
@@ -12,6 +12,7 @@ index 0000000000000..2157d1eb1698e
|
||||
+#define CHROME_BROWSER_BROWSEROS_METRICS_BROWSEROS_METRICS_SERVICE_H_
|
||||
+
|
||||
+#include <memory>
|
||||
+#include <optional>
|
||||
+#include <string>
|
||||
+
|
||||
+#include "base/functional/callback.h"
|
||||
@@ -72,7 +73,7 @@ index 0000000000000..2157d1eb1698e
|
||||
+
|
||||
+ // Handles the response from PostHog API.
|
||||
+ void OnPostHogResponse(std::unique_ptr<network::SimpleURLLoader> loader,
|
||||
+ std::unique_ptr<std::string> response_body);
|
||||
+ std::optional<std::string> response_body);
|
||||
+
|
||||
+ // Adds default properties to the event.
|
||||
+ void AddDefaultProperties(base::Value::Dict& properties);
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
diff --git a/chrome/browser/browseros/server/browseros_server_manager.cc b/chrome/browser/browseros/server/browseros_server_manager.cc
|
||||
new file mode 100644
|
||||
index 0000000000000..6d44b32b78ce8
|
||||
index 0000000000000..87a0c20a2c67e
|
||||
--- /dev/null
|
||||
+++ b/chrome/browser/browseros/server/browseros_server_manager.cc
|
||||
@@ -0,0 +1,1061 @@
|
||||
@@ -0,0 +1,1062 @@
|
||||
+// Copyright 2024 The Chromium Authors
|
||||
+// Use of this source code is governed by a BSD-style license that can be
|
||||
+// found in the LICENSE file.
|
||||
@@ -14,6 +14,7 @@ index 0000000000000..6d44b32b78ce8
|
||||
+#include <set>
|
||||
+
|
||||
+#include "base/command_line.h"
|
||||
+#include "base/functional/callback_helpers.h"
|
||||
+#include "base/files/file_path.h"
|
||||
+#include "base/files/file_util.h"
|
||||
+#include "base/logging.h"
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
diff --git a/chrome/browser/browseros/server/browseros_server_proxy.cc b/chrome/browser/browseros/server/browseros_server_proxy.cc
|
||||
new file mode 100644
|
||||
index 0000000000000..7ffdb8f011b08
|
||||
index 0000000000000..17560c9a2c55a
|
||||
--- /dev/null
|
||||
+++ b/chrome/browser/browseros/server/browseros_server_proxy.cc
|
||||
@@ -0,0 +1,225 @@
|
||||
@@ -193,7 +193,7 @@ index 0000000000000..7ffdb8f011b08
|
||||
+
|
||||
+void BrowserOSServerProxy::OnBackendResponse(
|
||||
+ int connection_id,
|
||||
+ std::unique_ptr<std::string> response_body) {
|
||||
+ std::optional<std::string> response_body) {
|
||||
+ auto it = pending_loaders_.find(connection_id);
|
||||
+ if (it == pending_loaders_.end() || !server_) {
|
||||
+ return;
|
||||
@@ -208,7 +208,7 @@ index 0000000000000..7ffdb8f011b08
|
||||
+ response_code = response_info->headers->response_code();
|
||||
+ }
|
||||
+
|
||||
+ if (!response_body || response_code == 0) {
|
||||
+ if (!response_body.has_value() || response_code == 0) {
|
||||
+ Send503(server_.get(), connection_id);
|
||||
+ return;
|
||||
+ }
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
diff --git a/chrome/browser/browseros/server/browseros_server_proxy.h b/chrome/browser/browseros/server/browseros_server_proxy.h
|
||||
new file mode 100644
|
||||
index 0000000000000..30474fa5001df
|
||||
index 0000000000000..586296d473849
|
||||
--- /dev/null
|
||||
+++ b/chrome/browser/browseros/server/browseros_server_proxy.h
|
||||
@@ -0,0 +1,78 @@
|
||||
@@ -0,0 +1,79 @@
|
||||
+// Copyright 2024 The Chromium Authors
|
||||
+// Use of this source code is governed by a BSD-style license that can be
|
||||
+// found in the LICENSE file.
|
||||
@@ -12,6 +12,7 @@ index 0000000000000..30474fa5001df
|
||||
+#define CHROME_BROWSER_BROWSEROS_SERVER_BROWSEROS_SERVER_PROXY_H_
|
||||
+
|
||||
+#include <memory>
|
||||
+#include <optional>
|
||||
+#include <string>
|
||||
+
|
||||
+#include "base/containers/flat_map.h"
|
||||
@@ -68,7 +69,7 @@ index 0000000000000..30474fa5001df
|
||||
+ void ForwardRequest(int connection_id,
|
||||
+ const net::HttpServerRequestInfo& info);
|
||||
+ void OnBackendResponse(int connection_id,
|
||||
+ std::unique_ptr<std::string> response_body);
|
||||
+ std::optional<std::string> response_body);
|
||||
+
|
||||
+ std::unique_ptr<net::HttpServer> server_;
|
||||
+ base::flat_map<int, std::unique_ptr<network::SimpleURLLoader>>
|
||||
|
||||
@@ -1,15 +1,17 @@
|
||||
diff --git a/chrome/browser/browseros/server/browseros_server_updater.cc b/chrome/browser/browseros/server/browseros_server_updater.cc
|
||||
new file mode 100644
|
||||
index 0000000000000..ced363ffbabc2
|
||||
index 0000000000000..9050130727fc8
|
||||
--- /dev/null
|
||||
+++ b/chrome/browser/browseros/server/browseros_server_updater.cc
|
||||
@@ -0,0 +1,1075 @@
|
||||
@@ -0,0 +1,1078 @@
|
||||
+// Copyright 2024 The Chromium Authors
|
||||
+// Use of this source code is governed by a BSD-style license that can be
|
||||
+// found in the LICENSE file.
|
||||
+
|
||||
+#include "chrome/browser/browseros/server/browseros_server_updater.h"
|
||||
+
|
||||
+#include <optional>
|
||||
+
|
||||
+#include "base/base64.h"
|
||||
+#include "base/command_line.h"
|
||||
+#include "base/feature_list.h"
|
||||
@@ -452,8 +454,8 @@ index 0000000000000..ced363ffbabc2
|
||||
+}
|
||||
+
|
||||
+void BrowserOSServerUpdater::OnAppcastFetched(
|
||||
+ std::unique_ptr<std::string> response) {
|
||||
+ if (!response) {
|
||||
+ std::optional<std::string> response) {
|
||||
+ if (!response.has_value()) {
|
||||
+ int net_error = appcast_loader_->NetError();
|
||||
+ OnError("check",
|
||||
+ "Failed to fetch appcast: " + net::ErrorToString(net_error));
|
||||
@@ -726,8 +728,8 @@ index 0000000000000..ced363ffbabc2
|
||||
+}
|
||||
+
|
||||
+void BrowserOSServerUpdater::OnStatusFetched(
|
||||
+ std::unique_ptr<std::string> response) {
|
||||
+ if (!response) {
|
||||
+ std::optional<std::string> response) {
|
||||
+ if (!response.has_value()) {
|
||||
+ int net_error = status_loader_->NetError();
|
||||
+ LOG(WARNING) << "browseros: Failed to fetch server status: "
|
||||
+ << net::ErrorToString(net_error)
|
||||
@@ -736,7 +738,8 @@ index 0000000000000..ced363ffbabc2
|
||||
+ return;
|
||||
+ }
|
||||
+
|
||||
+ std::optional<base::Value> json = base::JSONReader::Read(*response);
|
||||
+ std::optional<base::Value> json =
|
||||
+ base::JSONReader::Read(*response, base::JSON_PARSE_RFC);
|
||||
+ if (!json || !json->is_dict()) {
|
||||
+ LOG(WARNING)
|
||||
+ << "browseros: Invalid status response, proceeding with update";
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
diff --git a/chrome/browser/browseros/server/browseros_server_updater.h b/chrome/browser/browseros/server/browseros_server_updater.h
|
||||
new file mode 100644
|
||||
index 0000000000000..022b703a32e8d
|
||||
index 0000000000000..a7edcdd9d98ee
|
||||
--- /dev/null
|
||||
+++ b/chrome/browser/browseros/server/browseros_server_updater.h
|
||||
@@ -0,0 +1,164 @@
|
||||
@@ -0,0 +1,165 @@
|
||||
+// Copyright 2024 The Chromium Authors
|
||||
+// Use of this source code is governed by a BSD-style license that can be
|
||||
+// found in the LICENSE file.
|
||||
@@ -12,6 +12,7 @@ index 0000000000000..022b703a32e8d
|
||||
+#define CHROME_BROWSER_BROWSEROS_SERVER_BROWSEROS_SERVER_UPDATER_H_
|
||||
+
|
||||
+#include <memory>
|
||||
+#include <optional>
|
||||
+#include <string>
|
||||
+
|
||||
+#include "base/files/file_path.h"
|
||||
@@ -76,7 +77,7 @@ index 0000000000000..022b703a32e8d
|
||||
+
|
||||
+ // Appcast flow
|
||||
+ void FetchAppcast();
|
||||
+ void OnAppcastFetched(std::unique_ptr<std::string> response);
|
||||
+ void OnAppcastFetched(std::optional<std::string> response);
|
||||
+
|
||||
+ // Download flow
|
||||
+ void CheckVersionAlreadyDownloaded(const AppcastEnclosure& enclosure,
|
||||
@@ -105,7 +106,7 @@ index 0000000000000..022b703a32e8d
|
||||
+
|
||||
+ // Hot-swap flow
|
||||
+ void CheckServerStatus();
|
||||
+ void OnStatusFetched(std::unique_ptr<std::string> response);
|
||||
+ void OnStatusFetched(std::optional<std::string> response);
|
||||
+ void OnServerStatusChecked(bool can_update);
|
||||
+ void PerformHotSwap(const base::Version& version);
|
||||
+ void OnHotSwapComplete(const base::Version& old_version,
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
diff --git a/chrome/browser/browseros/server/browseros_server_utils.cc b/chrome/browser/browseros/server/browseros_server_utils.cc
|
||||
new file mode 100644
|
||||
index 0000000000000..9aca12ed05475
|
||||
index 0000000000000..867dbf4699f17
|
||||
--- /dev/null
|
||||
+++ b/chrome/browser/browseros/server/browseros_server_utils.cc
|
||||
@@ -0,0 +1,517 @@
|
||||
@@ -0,0 +1,518 @@
|
||||
+// Copyright 2024 The Chromium Authors
|
||||
+// Use of this source code is governed by a BSD-style license that can be
|
||||
+// found in the LICENSE file.
|
||||
@@ -275,7 +275,8 @@ index 0000000000000..9aca12ed05475
|
||||
+ return std::nullopt;
|
||||
+ }
|
||||
+
|
||||
+ std::optional<base::Value> parsed = base::JSONReader::Read(contents);
|
||||
+ std::optional<base::Value> parsed =
|
||||
+ base::JSONReader::Read(contents, base::JSON_PARSE_RFC);
|
||||
+ if (!parsed || !parsed->is_dict()) {
|
||||
+ LOG(WARNING) << "browseros: Invalid state file format";
|
||||
+ return std::nullopt;
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
diff --git a/chrome/browser/chrome_content_browser_client.cc b/chrome/browser/chrome_content_browser_client.cc
|
||||
index 0ab10486a183c..e25fbac661e4d 100644
|
||||
index 90eec90d4ef45..da7beb4a4547e 100644
|
||||
--- a/chrome/browser/chrome_content_browser_client.cc
|
||||
+++ b/chrome/browser/chrome_content_browser_client.cc
|
||||
@@ -613,6 +613,7 @@
|
||||
@@ -598,6 +598,7 @@
|
||||
#endif
|
||||
|
||||
#if BUILDFLAG(ENABLE_EXTENSIONS_CORE)
|
||||
@@ -10,7 +10,7 @@ index 0ab10486a183c..e25fbac661e4d 100644
|
||||
#include "chrome/browser/extensions/chrome_content_browser_client_extensions_part.h"
|
||||
#include "chrome/browser/extensions/chrome_extension_cookies.h"
|
||||
#include "extensions/browser/api/web_request/web_request_api.h"
|
||||
@@ -1439,7 +1440,7 @@ void ChromeContentBrowserClient::RegisterLocalStatePrefs(
|
||||
@@ -1421,7 +1422,7 @@ void ChromeContentBrowserClient::RegisterLocalStatePrefs(
|
||||
void ChromeContentBrowserClient::RegisterProfilePrefs(
|
||||
user_prefs::PrefRegistrySyncable* registry) {
|
||||
registry->RegisterBooleanPref(prefs::kDisable3DAPIs, false);
|
||||
@@ -19,7 +19,7 @@ index 0ab10486a183c..e25fbac661e4d 100644
|
||||
// Register user prefs for mapping SitePerProcess and IsolateOrigins in
|
||||
// user policy in addition to the same named ones in Local State (which are
|
||||
// used for mapping the command-line flags).
|
||||
@@ -4975,6 +4976,43 @@ bool ChromeContentBrowserClient::
|
||||
@@ -4884,6 +4885,43 @@ bool ChromeContentBrowserClient::
|
||||
prefs.root_scrollbar_theme_color;
|
||||
}
|
||||
|
||||
@@ -63,7 +63,7 @@ index 0ab10486a183c..e25fbac661e4d 100644
|
||||
void ChromeContentBrowserClient::BrowserURLHandlerCreated(
|
||||
BrowserURLHandler* handler) {
|
||||
// The group policy NTP URL handler must be registered before the other NTP
|
||||
@@ -4991,6 +5029,13 @@ void ChromeContentBrowserClient::BrowserURLHandlerCreated(
|
||||
@@ -4900,6 +4938,13 @@ void ChromeContentBrowserClient::BrowserURLHandlerCreated(
|
||||
handler->AddHandlerPair(&HandleChromeAboutAndChromeSyncRewrite,
|
||||
BrowserURLHandler::null_handler());
|
||||
|
||||
@@ -77,7 +77,7 @@ index 0ab10486a183c..e25fbac661e4d 100644
|
||||
#if BUILDFLAG(IS_ANDROID)
|
||||
// Handler to rewrite chrome://newtab on Android.
|
||||
handler->AddHandlerPair(&chrome::android::HandleAndroidNativePageURL,
|
||||
@@ -7741,6 +7786,15 @@ content::ContentBrowserClient::PrivateNetworkRequestPolicyOverride
|
||||
@@ -7693,6 +7738,15 @@ content::ContentBrowserClient::PrivateNetworkRequestPolicyOverride
|
||||
ChromeContentBrowserClient::ShouldOverridePrivateNetworkRequestPolicy(
|
||||
content::BrowserContext* browser_context,
|
||||
const url::Origin& origin) {
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
diff --git a/chrome/browser/extensions/BUILD.gn b/chrome/browser/extensions/BUILD.gn
|
||||
index a8e054baadb1f..870b10ddd4eaa 100644
|
||||
index 5d5af07b158c0..f32c7889de5be 100644
|
||||
--- a/chrome/browser/extensions/BUILD.gn
|
||||
+++ b/chrome/browser/extensions/BUILD.gn
|
||||
@@ -351,6 +351,12 @@ source_set("extensions") {
|
||||
@@ -357,6 +357,12 @@ source_set("extensions") {
|
||||
"external_install_manager.h",
|
||||
"external_install_manager_factory.cc",
|
||||
"external_install_manager_factory.h",
|
||||
@@ -12,10 +12,10 @@ index a8e054baadb1f..870b10ddd4eaa 100644
|
||||
+ "//chrome/browser/browseros/extensions/browseros_extension_loader.h",
|
||||
+ "//chrome/browser/browseros/extensions/browseros_extension_maintainer.cc",
|
||||
+ "//chrome/browser/browseros/extensions/browseros_extension_maintainer.h",
|
||||
"external_loader.cc",
|
||||
"external_loader.h",
|
||||
"external_policy_loader.cc",
|
||||
@@ -677,6 +683,18 @@ source_set("extensions") {
|
||||
"external_policy_loader.h",
|
||||
"external_pref_loader.cc",
|
||||
@@ -690,6 +696,18 @@ source_set("extensions") {
|
||||
"api/automation_internal/chrome_automation_internal_api_delegate.h",
|
||||
"api/bookmark_manager_private/bookmark_manager_private_api.cc",
|
||||
"api/bookmark_manager_private/bookmark_manager_private_api.h",
|
||||
@@ -32,9 +32,9 @@ index a8e054baadb1f..870b10ddd4eaa 100644
|
||||
+ "api/browser_os/browser_os_snapshot_processor.cc",
|
||||
+ "api/browser_os/browser_os_snapshot_processor.h",
|
||||
"api/chrome_device_permissions_prompt.h",
|
||||
"api/developer_private/developer_private_event_router_desktop.cc",
|
||||
"api/developer_private/developer_private_event_router_desktop.h",
|
||||
@@ -1006,6 +1024,8 @@ source_set("extensions") {
|
||||
"api/enterprise_reporting_private/conversion_utils.cc",
|
||||
"api/enterprise_reporting_private/conversion_utils.h",
|
||||
@@ -997,6 +1015,8 @@ source_set("extensions") {
|
||||
"//components/language/core/common",
|
||||
"//components/language/core/language_model",
|
||||
"//components/live_caption:constants",
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
diff --git a/chrome/browser/extensions/api/browser_os/browser_os_api.cc b/chrome/browser/extensions/api/browser_os/browser_os_api.cc
|
||||
new file mode 100644
|
||||
index 0000000000000..c08b705ef6869
|
||||
index 0000000000000..832e8d5471a78
|
||||
--- /dev/null
|
||||
+++ b/chrome/browser/extensions/api/browser_os/browser_os_api.cc
|
||||
@@ -0,0 +1,1437 @@
|
||||
@@ -0,0 +1,1445 @@
|
||||
+// Copyright 2024 The Chromium Authors
|
||||
+// Use of this source code is governed by a BSD-style license that can be
|
||||
+// found in the LICENSE file.
|
||||
@@ -21,6 +21,7 @@ index 0000000000000..c08b705ef6869
|
||||
+#include <utility>
|
||||
+#include <vector>
|
||||
+
|
||||
+#include "components/viz/common/frame_sinks/copy_output_result.h"
|
||||
+#include "base/functional/bind.h"
|
||||
+#include "base/threading/platform_thread.h"
|
||||
+#include "chrome/browser/browser_process.h"
|
||||
@@ -148,9 +149,9 @@ index 0000000000000..c08b705ef6869
|
||||
+ }
|
||||
+
|
||||
+ // Bool attributes map
|
||||
+ if (node.bool_attributes && node.bool_attributes->Size() > 0) {
|
||||
+ if (node.bool_attributes.Size() > 0) {
|
||||
+ base::Value::Dict attrs;
|
||||
+ node.bool_attributes->ForEach([&attrs](ax::mojom::BoolAttribute key, bool value) {
|
||||
+ node.bool_attributes.ForEach([&attrs](ax::mojom::BoolAttribute key, bool value) {
|
||||
+ attrs.Set(ui::ToString(key), value);
|
||||
+ });
|
||||
+ dict.Set("boolAttributes", std::move(attrs));
|
||||
@@ -982,17 +983,24 @@ index 0000000000000..c08b705ef6869
|
||||
+ view->CopyFromSurface(
|
||||
+ gfx::Rect(), // Empty rect means copy entire surface
|
||||
+ target_size_,
|
||||
+ base::TimeDelta(), // No timeout
|
||||
+ base::BindOnce(&BrowserOSCaptureScreenshotFunction::OnScreenshotCaptured,
|
||||
+ this));
|
||||
+}
|
||||
+
|
||||
+void BrowserOSCaptureScreenshotFunction::OnScreenshotCaptured(
|
||||
+ const SkBitmap& bitmap) {
|
||||
+ const content::CopyFromSurfaceResult& result) {
|
||||
+ // Clean up the highlights immediately after capture (only if we added them)
|
||||
+ if (show_highlights_ && web_contents_) {
|
||||
+ RemoveHighlights(web_contents_.get());
|
||||
+ }
|
||||
+
|
||||
+
|
||||
+ if (!result.has_value()) {
|
||||
+ Respond(Error("Failed to capture screenshot"));
|
||||
+ return;
|
||||
+ }
|
||||
+
|
||||
+ const SkBitmap& bitmap = result->bitmap;
|
||||
+ if (bitmap.empty()) {
|
||||
+ Respond(Error("Failed to capture screenshot"));
|
||||
+ return;
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
diff --git a/chrome/browser/extensions/api/browser_os/browser_os_api.h b/chrome/browser/extensions/api/browser_os/browser_os_api.h
|
||||
new file mode 100644
|
||||
index 0000000000000..2e2f5f0253f86
|
||||
index 0000000000000..53ece24723da0
|
||||
--- /dev/null
|
||||
+++ b/chrome/browser/extensions/api/browser_os/browser_os_api.h
|
||||
@@ -0,0 +1,369 @@
|
||||
@@ -0,0 +1,371 @@
|
||||
+// Copyright 2024 The Chromium Authors
|
||||
+// Use of this source code is governed by a BSD-style license that can be
|
||||
+// found in the LICENSE file.
|
||||
@@ -18,6 +18,8 @@ index 0000000000000..2e2f5f0253f86
|
||||
+#include "chrome/browser/extensions/api/browser_os/browser_os_api_utils.h"
|
||||
+#include "chrome/browser/extensions/api/browser_os/browser_os_content_processor.h"
|
||||
+#include "chrome/browser/extensions/api/browser_os/browser_os_snapshot_processor.h"
|
||||
+#include "components/viz/common/frame_sinks/copy_output_result.h"
|
||||
+#include "content/public/browser/render_widget_host_view.h"
|
||||
+#include "extensions/browser/extension_function.h"
|
||||
+#include "third_party/skia/include/core/SkBitmap.h"
|
||||
+#include "ui/shell_dialogs/select_file_dialog.h"
|
||||
@@ -198,7 +200,7 @@ index 0000000000000..2e2f5f0253f86
|
||||
+ private:
|
||||
+ void DrawHighlightsAndCapture();
|
||||
+ void CaptureScreenshotNow();
|
||||
+ void OnScreenshotCaptured(const SkBitmap& bitmap);
|
||||
+ void OnScreenshotCaptured(const content::CopyFromSurfaceResult& result);
|
||||
+
|
||||
+ // Store web contents and tab id for highlight operations
|
||||
+ base::WeakPtr<content::WebContents> web_contents_;
|
||||
|
||||
@@ -1,19 +1,20 @@
|
||||
diff --git a/chrome/browser/extensions/api/side_panel/side_panel_service.cc b/chrome/browser/extensions/api/side_panel/side_panel_service.cc
|
||||
index 0582cf9b5141a..d3ec91af0f140 100644
|
||||
index b4e8c1ce7316c..c6ba8b2fc1ca6 100644
|
||||
--- a/chrome/browser/extensions/api/side_panel/side_panel_service.cc
|
||||
+++ b/chrome/browser/extensions/api/side_panel/side_panel_service.cc
|
||||
@@ -8,8 +8,10 @@
|
||||
@@ -8,9 +8,11 @@
|
||||
#include <memory>
|
||||
#include <optional>
|
||||
|
||||
+#include "base/logging.h"
|
||||
#include "base/no_destructor.h"
|
||||
#include "base/strings/stringprintf.h"
|
||||
#include "base/strings/to_string.h"
|
||||
+#include "chrome/browser/browseros/core/browseros_constants.h"
|
||||
#include "chrome/browser/extensions/extension_tab_util.h"
|
||||
#include "chrome/browser/profiles/profile.h"
|
||||
#include "chrome/browser/ui/browser_window/public/browser_window_interface.h"
|
||||
@@ -464,6 +466,139 @@ void SidePanelService::OnExtensionUninstalled(
|
||||
@@ -471,6 +473,139 @@ void SidePanelService::OnExtensionUninstalled(
|
||||
RemoveExtensionOptions(extension->id());
|
||||
}
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
diff --git a/chrome/browser/extensions/chrome_extensions_browser_api_provider.cc b/chrome/browser/extensions/chrome_extensions_browser_api_provider.cc
|
||||
index f64f81b90b4fb..73c22ae9e77f8 100644
|
||||
index a251aaaa53378..25b5989cedf15 100644
|
||||
--- a/chrome/browser/extensions/chrome_extensions_browser_api_provider.cc
|
||||
+++ b/chrome/browser/extensions/chrome_extensions_browser_api_provider.cc
|
||||
@@ -4,6 +4,7 @@
|
||||
@@ -7,14 +7,14 @@ index f64f81b90b4fb..73c22ae9e77f8 100644
|
||||
#include "chrome/browser/extensions/chrome_extensions_browser_api_provider.h"
|
||||
|
||||
+#include "chrome/browser/extensions/api/browser_os/browser_os_api.h"
|
||||
#include "chrome/browser/extensions/api/commands/commands.h"
|
||||
#include "chrome/browser/extensions/api/generated_api_registration.h"
|
||||
#include "extensions/browser/extension_function_registry.h"
|
||||
@@ -23,6 +24,14 @@ void ChromeExtensionsBrowserAPIProvider::RegisterExtensionFunctions(
|
||||
// Commands
|
||||
registry->RegisterFunction<GetAllCommandsFunction>();
|
||||
#include "extensions/buildflags/buildflags.h"
|
||||
@@ -19,6 +20,14 @@ ChromeExtensionsBrowserAPIProvider::~ChromeExtensionsBrowserAPIProvider() =
|
||||
|
||||
+ // Browser OS API
|
||||
void ChromeExtensionsBrowserAPIProvider::RegisterExtensionFunctions(
|
||||
ExtensionFunctionRegistry* registry) {
|
||||
+ // BrowserOS API
|
||||
+ registry->RegisterFunction<api::BrowserOSGetAccessibilityTreeFunction>();
|
||||
+ registry->RegisterFunction<api::BrowserOSGetInteractiveSnapshotFunction>();
|
||||
+ registry->RegisterFunction<api::BrowserOSClickFunction>();
|
||||
|
||||
@@ -1,16 +1,16 @@
|
||||
diff --git a/chrome/browser/extensions/extension_context_menu_model.cc b/chrome/browser/extensions/extension_context_menu_model.cc
|
||||
index 39b916751757d..25b504181aeb6 100644
|
||||
index 7d8d30399b256..bd3356e448d51 100644
|
||||
--- a/chrome/browser/extensions/extension_context_menu_model.cc
|
||||
+++ b/chrome/browser/extensions/extension_context_menu_model.cc
|
||||
@@ -7,6 +7,7 @@
|
||||
@@ -6,6 +6,7 @@
|
||||
|
||||
#include <memory>
|
||||
|
||||
#include "base/containers/contains.h"
|
||||
+#include "chrome/browser/browseros/core/browseros_constants.h"
|
||||
#include "base/feature_list.h"
|
||||
#include "base/functional/bind.h"
|
||||
#include "base/metrics/histogram_macros.h"
|
||||
@@ -800,7 +801,8 @@ void ExtensionContextMenuModel::InitMenuWithFeature(
|
||||
@@ -806,7 +807,8 @@ void ExtensionContextMenuModel::InitMenuWithFeature(
|
||||
|
||||
// Controls section.
|
||||
bool has_options_page = OptionsPageInfo::HasOptionsPage(extension);
|
||||
|
||||
@@ -1,24 +0,0 @@
|
||||
diff --git a/chrome/browser/flag_descriptions.cc b/chrome/browser/flag_descriptions.cc
|
||||
index f9088ac701027..f3f892d69791b 100644
|
||||
--- a/chrome/browser/flag_descriptions.cc
|
||||
+++ b/chrome/browser/flag_descriptions.cc
|
||||
@@ -270,6 +270,19 @@ const char kBookmarksTreeViewName[] = "Top Chrome Bookmarks Tree View";
|
||||
const char kBookmarksTreeViewDescription[] =
|
||||
"Show the bookmarks side panel in a tree view while in compact mode.";
|
||||
|
||||
+const char kBrowserOsAlphaFeaturesName[] = "BrowserOS Alpha Features";
|
||||
+const char kBrowserOsAlphaFeaturesDescription[] =
|
||||
+ "Enables BrowserOS alpha features.";
|
||||
+
|
||||
+const char kBrowserOsClawdbotName[] = "BrowserOS Clawdbot";
|
||||
+const char kBrowserOsClawdbotDescription[] =
|
||||
+ "Enables Clawdbot Browser Relay extension.";
|
||||
+
|
||||
+const char kBrowserOsKeyboardShortcutsName[] = "BrowserOS Keyboard Shortcuts";
|
||||
+const char kBrowserOsKeyboardShortcutsDescription[] =
|
||||
+ "Enables BrowserOS keyboard shortcuts (Cmd+Shift+K, Cmd+Shift+L, Option+A). "
|
||||
+ "Disable if these conflict with your keyboard layout.";
|
||||
+
|
||||
const char kBrowsingHistoryActorIntegrationM1Name[] =
|
||||
"Browsing History Actor Integration M1";
|
||||
const char kBrowsingHistoryActorIntegrationM1Description[] =
|
||||
@@ -1,20 +1,27 @@
|
||||
diff --git a/chrome/browser/flag_descriptions.h b/chrome/browser/flag_descriptions.h
|
||||
index fea522351cd1b..cc466bdbf03a3 100644
|
||||
index d73e9a053eb63..e22ef4d7024af 100644
|
||||
--- a/chrome/browser/flag_descriptions.h
|
||||
+++ b/chrome/browser/flag_descriptions.h
|
||||
@@ -188,6 +188,15 @@ extern const char kByDateHistoryInSidePanelDescription[];
|
||||
extern const char kBookmarksTreeViewName[];
|
||||
extern const char kBookmarksTreeViewDescription[];
|
||||
@@ -284,6 +284,22 @@ inline constexpr char kBookmarksTreeViewName[] =
|
||||
inline constexpr char kBookmarksTreeViewDescription[] =
|
||||
"Show the bookmarks side panel in a tree view while in compact mode.";
|
||||
|
||||
+extern const char kBrowserOsAlphaFeaturesName[];
|
||||
+extern const char kBrowserOsAlphaFeaturesDescription[];
|
||||
+// BrowserOS: feature flags
|
||||
+inline constexpr char kBrowserOsAlphaFeaturesName[] =
|
||||
+ "BrowserOS Alpha Features";
|
||||
+inline constexpr char kBrowserOsAlphaFeaturesDescription[] =
|
||||
+ "Enables BrowserOS alpha features.";
|
||||
+
|
||||
+extern const char kBrowserOsClawdbotName[];
|
||||
+extern const char kBrowserOsClawdbotDescription[];
|
||||
+inline constexpr char kBrowserOsClawdbotName[] = "BrowserOS Clawdbot";
|
||||
+inline constexpr char kBrowserOsClawdbotDescription[] =
|
||||
+ "Enables Clawdbot Browser Relay extension.";
|
||||
+
|
||||
+extern const char kBrowserOsKeyboardShortcutsName[];
|
||||
+extern const char kBrowserOsKeyboardShortcutsDescription[];
|
||||
+inline constexpr char kBrowserOsKeyboardShortcutsName[] =
|
||||
+ "BrowserOS Keyboard Shortcuts";
|
||||
+inline constexpr char kBrowserOsKeyboardShortcutsDescription[] =
|
||||
+ "Enables BrowserOS keyboard shortcuts (Cmd+Shift+K, Cmd+Shift+L, "
|
||||
+ "Option+A). Disable if these conflict with your keyboard layout.";
|
||||
+
|
||||
extern const char kBrowsingHistoryActorIntegrationM1Name[];
|
||||
extern const char kBrowsingHistoryActorIntegrationM1Description[];
|
||||
#endif
|
||||
inline constexpr char kBrowsingHistoryActorIntegrationM1Name[] =
|
||||
"Browsing History Actor Integration M1";
|
||||
inline constexpr char kBrowsingHistoryActorIntegrationM1Description[] =
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
diff --git a/chrome/browser/importer/profile_writer.cc b/chrome/browser/importer/profile_writer.cc
|
||||
index 6edb974687c07..738d8ca61a9b4 100644
|
||||
index 08859f9d1fa91..3f542543e6437 100644
|
||||
--- a/chrome/browser/importer/profile_writer.cc
|
||||
+++ b/chrome/browser/importer/profile_writer.cc
|
||||
@@ -11,6 +11,7 @@
|
||||
@@ -10,7 +10,7 @@ index 6edb974687c07..738d8ca61a9b4 100644
|
||||
#include "base/strings/string_number_conversions.h"
|
||||
#include "base/strings/string_util.h"
|
||||
#include "base/strings/utf_string_conversions.h"
|
||||
@@ -36,7 +37,25 @@
|
||||
@@ -36,7 +37,24 @@
|
||||
#include "components/prefs/pref_service.h"
|
||||
#include "components/search_engines/template_url.h"
|
||||
#include "components/search_engines/template_url_service.h"
|
||||
@@ -25,7 +25,6 @@ index 6edb974687c07..738d8ca61a9b4 100644
|
||||
+#include "extensions/browser/extension_system.h"
|
||||
+#include "extensions/common/extension.h"
|
||||
+#include "chrome/browser/extensions/webstore_installer.h"
|
||||
+#include "chrome/browser/extensions/install_approval.h"
|
||||
+#include "extensions/browser/extension_registry.h"
|
||||
+#include "chrome/browser/extensions/extension_install_prompt.h"
|
||||
+#include "chrome/browser/extensions/webstore_install_with_prompt.h"
|
||||
@@ -36,7 +35,7 @@ index 6edb974687c07..738d8ca61a9b4 100644
|
||||
|
||||
using bookmarks::BookmarkModel;
|
||||
using bookmarks::BookmarkNode;
|
||||
@@ -75,6 +94,22 @@ void ShowBookmarkBar(Profile* profile) {
|
||||
@@ -75,6 +93,22 @@ void ShowBookmarkBar(Profile* profile) {
|
||||
profile->GetPrefs()->SetBoolean(bookmarks::prefs::kShowBookmarkBar, true);
|
||||
}
|
||||
|
||||
@@ -59,7 +58,7 @@ index 6edb974687c07..738d8ca61a9b4 100644
|
||||
} // namespace
|
||||
|
||||
ProfileWriter::ProfileWriter(Profile* profile) : profile_(profile) {}
|
||||
@@ -99,6 +134,73 @@ void ProfileWriter::AddPasswordForm(
|
||||
@@ -99,6 +133,73 @@ void ProfileWriter::AddPasswordForm(
|
||||
}
|
||||
}
|
||||
|
||||
@@ -133,7 +132,7 @@ index 6edb974687c07..738d8ca61a9b4 100644
|
||||
void ProfileWriter::AddHistoryPage(const history::URLRows& page,
|
||||
history::VisitSource visit_source) {
|
||||
if (!page.empty()) {
|
||||
@@ -338,3 +440,119 @@ void ProfileWriter::AddAutocompleteFormDataEntries(
|
||||
@@ -338,3 +439,119 @@ void ProfileWriter::AddAutocompleteFormDataEntries(
|
||||
}
|
||||
|
||||
ProfileWriter::~ProfileWriter() = default;
|
||||
|
||||
@@ -1,17 +1,18 @@
|
||||
diff --git a/chrome/browser/sync/prefs/chrome_syncable_prefs_database.cc b/chrome/browser/sync/prefs/chrome_syncable_prefs_database.cc
|
||||
index b4ff6805bf506..fdce0d4e90463 100644
|
||||
index cb73087d9476d..14a8d978660dc 100644
|
||||
--- a/chrome/browser/sync/prefs/chrome_syncable_prefs_database.cc
|
||||
+++ b/chrome/browser/sync/prefs/chrome_syncable_prefs_database.cc
|
||||
@@ -402,6 +402,8 @@ enum {
|
||||
kDesktopToiOSLensPromoLastImpressionTimestamp = 100335,
|
||||
kDesktopToiOSLensPromoImpressionsCounter = 100336,
|
||||
kDesktopToiOSLensPromoOptOut = 100337,
|
||||
+ kPinnedThirdPartyLlmMigrationComplete = 100338,
|
||||
+ kPinnedClashOfGptsMigrationComplete = 100339,
|
||||
@@ -436,6 +436,9 @@ enum {
|
||||
kPinContextualTaskButton = 100369,
|
||||
kAccessibilityReadAnythingOmniboxChipIgnoredCount = 100370,
|
||||
kAccessibilityReadAnythingLineFocus = 100371,
|
||||
+ // BrowserOS: sync pref IDs
|
||||
+ kPinnedThirdPartyLlmMigrationComplete = 100372,
|
||||
+ kPinnedClashOfGptsMigrationComplete = 100373,
|
||||
// See components/sync_preferences/README.md about adding new entries here.
|
||||
// vvvvv IMPORTANT! vvvvv
|
||||
// Note to the reviewer: IT IS YOUR RESPONSIBILITY to ensure that new syncable
|
||||
@@ -590,6 +592,14 @@ constexpr auto kChromeSyncablePrefsAllowlist = base::MakeFixedFlatMap<
|
||||
@@ -636,6 +639,14 @@ constexpr auto kChromeSyncablePrefsAllowlist = base::MakeFixedFlatMap<
|
||||
{syncable_prefs_ids::kVerticalTabsEnabled, syncer::PREFERENCES,
|
||||
sync_preferences::PrefSensitivity::kNone,
|
||||
sync_preferences::MergeBehavior::kNone}},
|
||||
|
||||
@@ -1,18 +1,18 @@
|
||||
diff --git a/chrome/browser/ui/BUILD.gn b/chrome/browser/ui/BUILD.gn
|
||||
index f4531197ae5e1..027e77f1536c6 100644
|
||||
index 2ec7c847678a0..66767940651d2 100644
|
||||
--- a/chrome/browser/ui/BUILD.gn
|
||||
+++ b/chrome/browser/ui/BUILD.gn
|
||||
@@ -1275,6 +1275,8 @@ static_library("ui") {
|
||||
"webui/settings/reset_settings_handler.h",
|
||||
"webui/settings/search_engines_handler.cc",
|
||||
@@ -1297,6 +1297,8 @@ static_library("ui") {
|
||||
"webui/settings/search_engines_handler.h",
|
||||
"webui/settings/security_settings_provider.cc",
|
||||
"webui/settings/security_settings_provider.h",
|
||||
+ "webui/settings/browseros_metrics_handler.cc",
|
||||
+ "webui/settings/browseros_metrics_handler.h",
|
||||
"webui/settings/settings_clear_browsing_data_handler.cc",
|
||||
"webui/settings/settings_clear_browsing_data_handler.h",
|
||||
"webui/settings/settings_localized_strings_privacy_sandbox_provider.cc",
|
||||
@@ -3168,6 +3170,8 @@ static_library("ui") {
|
||||
"views/frame/immersive_mode_controller_mac.mm",
|
||||
@@ -3225,6 +3227,8 @@ static_library("ui") {
|
||||
"views/frame/immersive_mode_overlay_views_mac.mm",
|
||||
"views/tab_contents/chrome_web_contents_view_delegate_views_mac.h",
|
||||
"views/tab_contents/chrome_web_contents_view_delegate_views_mac.mm",
|
||||
+ "webui/help/sparkle_version_updater_mac.h",
|
||||
|
||||
@@ -1,16 +1,16 @@
|
||||
diff --git a/chrome/browser/ui/browser_actions.cc b/chrome/browser/ui/browser_actions.cc
|
||||
index fb3dba200be8c..9b7941ff32407 100644
|
||||
index 96ccc8d0a6acc..9c446a5e041a9 100644
|
||||
--- a/chrome/browser/ui/browser_actions.cc
|
||||
+++ b/chrome/browser/ui/browser_actions.cc
|
||||
@@ -12,6 +12,7 @@
|
||||
#include "base/check_op.h"
|
||||
@@ -14,6 +14,7 @@
|
||||
#include "base/functional/bind.h"
|
||||
#include "base/functional/callback_helpers.h"
|
||||
#include "chrome/app/chrome_command_ids.h"
|
||||
+#include "chrome/grit/theme_resources.h"
|
||||
#include "chrome/app/vector_icons/vector_icons.h"
|
||||
#include "chrome/browser/contextual_tasks/contextual_tasks_side_panel_coordinator.h"
|
||||
#include "chrome/browser/devtools/devtools_window.h"
|
||||
#include "chrome/browser/prefs/incognito_mode_prefs.h"
|
||||
@@ -20,6 +21,13 @@
|
||||
@@ -23,6 +24,13 @@
|
||||
#include "chrome/browser/sharing_hub/sharing_hub_features.h"
|
||||
#include "chrome/browser/ui/actions/chrome_action_id.h"
|
||||
#include "chrome/browser/ui/actions/chrome_actions.h"
|
||||
@@ -23,8 +23,8 @@ index fb3dba200be8c..9b7941ff32407 100644
|
||||
+#include "extensions/browser/extension_registry.h"
|
||||
#include "chrome/browser/ui/autofill/address_bubbles_icon_controller.h"
|
||||
#include "chrome/browser/ui/autofill/autofill_bubble_base.h"
|
||||
#include "chrome/browser/ui/autofill/payments/mandatory_reauth_bubble_controller_impl.h"
|
||||
@@ -253,6 +261,110 @@ void BrowserActions::InitializeBrowserActions() {
|
||||
#include "chrome/browser/ui/autofill/payments/filled_card_information_bubble_controller_impl.h"
|
||||
@@ -272,6 +280,110 @@ void BrowserActions::InitializeBrowserActions() {
|
||||
.Build());
|
||||
}
|
||||
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
diff --git a/chrome/browser/ui/browser_commands.cc b/chrome/browser/ui/browser_commands.cc
|
||||
index 94593b999f490..d7f12d90b1577 100644
|
||||
index 43e2b81f9903f..9944e94ba22ef 100644
|
||||
--- a/chrome/browser/ui/browser_commands.cc
|
||||
+++ b/chrome/browser/ui/browser_commands.cc
|
||||
@@ -121,6 +121,7 @@
|
||||
@@ -122,6 +122,7 @@
|
||||
#include "chrome/browser/web_applications/web_app_helpers.h"
|
||||
#include "chrome/browser/web_applications/web_app_provider.h"
|
||||
#include "chrome/browser/web_applications/web_app_registrar.h"
|
||||
@@ -10,7 +10,7 @@ index 94593b999f490..d7f12d90b1577 100644
|
||||
#include "chrome/common/chrome_features.h"
|
||||
#include "chrome/common/content_restriction.h"
|
||||
#include "chrome/common/pref_names.h"
|
||||
@@ -2392,7 +2393,20 @@ bool IsDebuggerAttachedToCurrentTab(Browser* browser) {
|
||||
@@ -2484,7 +2485,20 @@ bool IsDebuggerAttachedToCurrentTab(Browser* browser) {
|
||||
|
||||
void CopyURL(BrowserWindowInterface* bwi, content::WebContents* web_contents) {
|
||||
ui::ScopedClipboardWriter scw(ui::ClipboardBuffer::kCopyPaste);
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
diff --git a/chrome/browser/ui/browser_ui_prefs.cc b/chrome/browser/ui/browser_ui_prefs.cc
|
||||
index 7a2f76324af50..d87b0e71d9a98 100644
|
||||
index e94568b1c7542..25e7e791009a0 100644
|
||||
--- a/chrome/browser/ui/browser_ui_prefs.cc
|
||||
+++ b/chrome/browser/ui/browser_ui_prefs.cc
|
||||
@@ -65,7 +65,7 @@ void RegisterBrowserPrefs(PrefRegistrySimple* registry) {
|
||||
@@ -68,7 +68,7 @@ void RegisterBrowserPrefs(PrefRegistrySimple* registry) {
|
||||
|
||||
registry->RegisterBooleanPref(prefs::kHoverCardImagesEnabled, true);
|
||||
|
||||
@@ -11,7 +11,7 @@ index 7a2f76324af50..d87b0e71d9a98 100644
|
||||
|
||||
#if defined(USE_AURA)
|
||||
registry->RegisterBooleanPref(prefs::kOverscrollHistoryNavigationEnabled,
|
||||
@@ -109,7 +109,7 @@ void RegisterBrowserUserPrefs(user_prefs::PrefRegistrySyncable* registry) {
|
||||
@@ -112,7 +112,7 @@ void RegisterBrowserUserPrefs(user_prefs::PrefRegistrySyncable* registry) {
|
||||
|
||||
registry->RegisterBooleanPref(prefs::kHomePageIsNewTabPage, true,
|
||||
pref_registration_flags);
|
||||
@@ -20,11 +20,12 @@ index 7a2f76324af50..d87b0e71d9a98 100644
|
||||
pref_registration_flags);
|
||||
registry->RegisterBooleanPref(prefs::kSplitViewDragAndDropEnabled, true,
|
||||
pref_registration_flags);
|
||||
@@ -117,7 +117,7 @@ void RegisterBrowserUserPrefs(user_prefs::PrefRegistrySyncable* registry) {
|
||||
registry->RegisterBooleanPref(prefs::kShowForwardButton, true,
|
||||
@@ -121,7 +121,8 @@ void RegisterBrowserUserPrefs(user_prefs::PrefRegistrySyncable* registry) {
|
||||
pref_registration_flags);
|
||||
registry->RegisterBooleanPref(prefs::kPinContextualTaskButton, true,
|
||||
pref_registration_flags);
|
||||
|
||||
- registry->RegisterBooleanPref(prefs::kPinSplitTabButton, false,
|
||||
+ // BrowserOS: default split tab button to pinned
|
||||
+ registry->RegisterBooleanPref(prefs::kPinSplitTabButton, true,
|
||||
pref_registration_flags);
|
||||
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
diff --git a/chrome/browser/ui/browser_window/internal/browser_window_features.cc b/chrome/browser/ui/browser_window/internal/browser_window_features.cc
|
||||
index 8c4ecc7069f8f..ab415e928c23d 100644
|
||||
index cecb7ad2b1147..901f87635a63e 100644
|
||||
--- a/chrome/browser/ui/browser_window/internal/browser_window_features.cc
|
||||
+++ b/chrome/browser/ui/browser_window/internal/browser_window_features.cc
|
||||
@@ -88,12 +88,14 @@
|
||||
@@ -103,6 +103,7 @@
|
||||
#include "chrome/browser/ui/views/profiles/profile_menu_coordinator.h"
|
||||
#include "chrome/browser/ui/views/send_tab_to_self/send_tab_to_self_toolbar_bubble_controller.h"
|
||||
#include "chrome/browser/ui/views/side_panel/bookmarks/bookmarks_side_panel_coordinator.h"
|
||||
@@ -10,14 +10,16 @@ index 8c4ecc7069f8f..ab415e928c23d 100644
|
||||
#include "chrome/browser/ui/views/side_panel/comments/comments_side_panel_coordinator.h"
|
||||
#include "chrome/browser/ui/views/side_panel/extensions/extension_side_panel_manager.h"
|
||||
#include "chrome/browser/ui/views/side_panel/history/history_side_panel_coordinator.h"
|
||||
#include "chrome/browser/ui/views/side_panel/history_clusters/history_clusters_side_panel_coordinator.h"
|
||||
@@ -110,6 +111,8 @@
|
||||
#include "chrome/browser/ui/views/side_panel/reading_list/reading_list_side_panel_coordinator.h"
|
||||
#include "chrome/browser/ui/views/side_panel/side_panel_coordinator.h"
|
||||
#include "chrome/browser/ui/views/side_panel/side_panel_registry.h"
|
||||
+#include "chrome/browser/ui/views/side_panel/clash_of_gpts/clash_of_gpts_coordinator.h"
|
||||
+#include "chrome/browser/ui/views/side_panel/third_party_llm/third_party_llm_panel_coordinator.h"
|
||||
#include "chrome/browser/ui/views/tabs/recent_activity_bubble_dialog_view.h"
|
||||
#include "chrome/browser/ui/views/tabs/tab_strip_action_container.h"
|
||||
#include "chrome/browser/ui/views/toolbar/chrome_labs/chrome_labs_coordinator.h"
|
||||
@@ -322,6 +324,12 @@ void BrowserWindowFeatures::Init(BrowserWindowInterface* browser) {
|
||||
@@ -381,6 +384,12 @@ void BrowserWindowFeatures::Init(BrowserWindowInterface* browser) {
|
||||
bookmarks_side_panel_coordinator_ =
|
||||
std::make_unique<BookmarksSidePanelCoordinator>();
|
||||
|
||||
@@ -30,15 +32,16 @@ index 8c4ecc7069f8f..ab415e928c23d 100644
|
||||
signin_view_controller_ = std::make_unique<SigninViewController>(
|
||||
browser, profile, tab_strip_model_);
|
||||
|
||||
@@ -527,6 +535,11 @@ void BrowserWindowFeatures::InitPostWindowConstruction(Browser* browser) {
|
||||
@@ -603,6 +612,12 @@ void BrowserWindowFeatures::InitPostWindowConstruction(Browser* browser) {
|
||||
incognito_clear_browsing_data_dialog_coordinator_ =
|
||||
std::make_unique<IncognitoClearBrowsingDataDialogCoordinator>(profile);
|
||||
|
||||
+ // BrowserOS: Clash of GPTs coordinator
|
||||
+ if (base::FeatureList::IsEnabled(features::kClashOfGpts)) {
|
||||
+ clash_of_gpts_coordinator_ =
|
||||
+ std::make_unique<ClashOfGptsCoordinator>(browser);
|
||||
+ }
|
||||
+
|
||||
if (auto* browser_view = BrowserView::GetBrowserViewForBrowser(browser)) {
|
||||
if (browser_view) {
|
||||
color_provider_browser_helper_ =
|
||||
std::make_unique<ColorProviderBrowserHelper>(
|
||||
|
||||
@@ -1,16 +1,16 @@
|
||||
diff --git a/chrome/browser/ui/browser_window/public/browser_window_features.h b/chrome/browser/ui/browser_window/public/browser_window_features.h
|
||||
index 19048c9478592..cc3c846cac900 100644
|
||||
index f1fc1743c6b4b..1d36a9bde9e7c 100644
|
||||
--- a/chrome/browser/ui/browser_window/public/browser_window_features.h
|
||||
+++ b/chrome/browser/ui/browser_window/public/browser_window_features.h
|
||||
@@ -42,6 +42,7 @@ class BrowserUserEducationInterface;
|
||||
@@ -43,6 +43,7 @@ class BrowserUserEducationInterface;
|
||||
class BrowserView;
|
||||
class BrowserWindowInterface;
|
||||
class ChromeLabsCoordinator;
|
||||
+class ClashOfGptsCoordinator;
|
||||
class ColorProviderBrowserHelper;
|
||||
class LocationBar;
|
||||
class CommentsSidePanelCoordinator;
|
||||
class ContentsBorderController;
|
||||
@@ -75,6 +76,7 @@ class TabSearchToolbarButtonController;
|
||||
@@ -86,6 +87,7 @@ class TabSearchToolbarButtonController;
|
||||
class TabListBridge;
|
||||
class TabStripModel;
|
||||
class TabStripServiceFeature;
|
||||
@@ -18,8 +18,8 @@ index 19048c9478592..cc3c846cac900 100644
|
||||
class ToastController;
|
||||
class ToastService;
|
||||
class TranslateBubbleController;
|
||||
@@ -253,6 +255,14 @@ class BrowserWindowFeatures {
|
||||
return comments_side_panel_coordinator_.get();
|
||||
@@ -277,6 +279,14 @@ class BrowserWindowFeatures {
|
||||
return extension_installed_watcher_.get();
|
||||
}
|
||||
|
||||
+ ThirdPartyLlmPanelCoordinator* third_party_llm_panel_coordinator() {
|
||||
@@ -33,7 +33,7 @@ index 19048c9478592..cc3c846cac900 100644
|
||||
#if BUILDFLAG(ENABLE_GLIC)
|
||||
glic::GlicLegacySidePanelCoordinator* glic_side_panel_coordinator() {
|
||||
return glic_side_panel_coordinator_.get();
|
||||
@@ -546,6 +556,11 @@ class BrowserWindowFeatures {
|
||||
@@ -590,6 +600,11 @@ class BrowserWindowFeatures {
|
||||
std::unique_ptr<CommentsSidePanelCoordinator>
|
||||
comments_side_panel_coordinator_;
|
||||
|
||||
|
||||
@@ -1,16 +1,16 @@
|
||||
diff --git a/chrome/browser/ui/omnibox/chrome_omnibox_client.cc b/chrome/browser/ui/omnibox/chrome_omnibox_client.cc
|
||||
index 89857e5f1bc3e..476b0f0f6a9d2 100644
|
||||
index 37cb48b9b7c9f..90d2d430f41a5 100644
|
||||
--- a/chrome/browser/ui/omnibox/chrome_omnibox_client.cc
|
||||
+++ b/chrome/browser/ui/omnibox/chrome_omnibox_client.cc
|
||||
@@ -115,6 +115,7 @@
|
||||
@@ -123,6 +123,7 @@
|
||||
#include "url/gurl.h"
|
||||
|
||||
#if BUILDFLAG(ENABLE_EXTENSIONS)
|
||||
+#include "chrome/browser/browseros/core/browseros_constants.h"
|
||||
#include "chrome/browser/safe_browsing/extension_telemetry/extension_telemetry_service.h"
|
||||
#include "chrome/browser/ui/extensions/settings_api_bubble_helpers.h"
|
||||
#endif
|
||||
@@ -301,15 +302,50 @@ gfx::Image ChromeOmniboxClient::GetSizedIcon(const gfx::Image& icon) const {
|
||||
|
||||
@@ -323,15 +324,50 @@ gfx::Image ChromeOmniboxClient::GetSizedIcon(const gfx::Image& icon) const {
|
||||
}
|
||||
|
||||
std::u16string ChromeOmniboxClient::GetFormattedFullURL() const {
|
||||
|
||||
@@ -1,14 +1,15 @@
|
||||
diff --git a/chrome/browser/ui/toolbar/app_menu_icon_controller.cc b/chrome/browser/ui/toolbar/app_menu_icon_controller.cc
|
||||
index 93b96091cf8b8..58820e2807d5c 100644
|
||||
index 62486948bce84..fbe9b650fd29e 100644
|
||||
--- a/chrome/browser/ui/toolbar/app_menu_icon_controller.cc
|
||||
+++ b/chrome/browser/ui/toolbar/app_menu_icon_controller.cc
|
||||
@@ -45,8 +45,7 @@ AppMenuIconController::Severity SeverityFromUpgradeLevel(
|
||||
@@ -45,8 +45,8 @@ AppMenuIconController::Severity SeverityFromUpgradeLevel(
|
||||
case UpgradeDetector::UPGRADE_ANNOYANCE_NONE:
|
||||
break;
|
||||
case UpgradeDetector::UPGRADE_ANNOYANCE_VERY_LOW:
|
||||
- // kVeryLow is meaningless for stable channels.
|
||||
- return AppMenuIconController::Severity::NONE;
|
||||
+ return AppMenuIconController::Severity::MEDIUM;
|
||||
- return AppMenuIconController::Severity::kNone;
|
||||
+ // BrowserOS: show update indicator sooner
|
||||
+ return AppMenuIconController::Severity::kMedium;
|
||||
case UpgradeDetector::UPGRADE_ANNOYANCE_LOW:
|
||||
return AppMenuIconController::Severity::LOW;
|
||||
return AppMenuIconController::Severity::kLow;
|
||||
case UpgradeDetector::UPGRADE_ANNOYANCE_ELEVATED:
|
||||
|
||||
@@ -1,45 +1,10 @@
|
||||
diff --git a/chrome/browser/ui/ui_features.cc b/chrome/browser/ui/ui_features.cc
|
||||
index c03c8ac6f6e00..0c0b83dfe9fef 100644
|
||||
index 8e70b4d6c09a8..f63de4c04083c 100644
|
||||
--- a/chrome/browser/ui/ui_features.cc
|
||||
+++ b/chrome/browser/ui/ui_features.cc
|
||||
@@ -106,14 +106,14 @@ BASE_FEATURE(kReloadSelectionModel, base::FEATURE_DISABLED_BY_DEFAULT);
|
||||
// Enforces close tab hotkey to only close the active view of a split tab,
|
||||
// when it is the only tab in selection model.
|
||||
BASE_FEATURE(kCloseActiveTabInSplitViewViaHotkey,
|
||||
- base::FEATURE_DISABLED_BY_DEFAULT);
|
||||
+ base::FEATURE_ENABLED_BY_DEFAULT);
|
||||
@@ -115,6 +115,14 @@ BASE_FEATURE(kPopupBrowserUseNewLayout, base::FEATURE_ENABLED_BY_DEFAULT);
|
||||
|
||||
#if BUILDFLAG(IS_MAC)
|
||||
// Add tab group colours when viewing tab groups using the top mac OS menu bar.
|
||||
BASE_FEATURE(kShowTabGroupsMacSystemMenu, base::FEATURE_DISABLED_BY_DEFAULT);
|
||||
#endif // BUILDFLAG(IS_MAC)
|
||||
|
||||
-BASE_FEATURE(kSideBySide, base::FEATURE_DISABLED_BY_DEFAULT);
|
||||
+BASE_FEATURE(kSideBySide, base::FEATURE_ENABLED_BY_DEFAULT);
|
||||
|
||||
// The delay before showing the drop target for the side-by-side drag-and-drop
|
||||
// entrypoint.
|
||||
@@ -242,7 +242,7 @@ BASE_FEATURE_PARAM(int,
|
||||
|
||||
// When enabled along with SideBySide flag, split tabs will be restored on
|
||||
// startup.
|
||||
-BASE_FEATURE(kSideBySideSessionRestore, base::FEATURE_DISABLED_BY_DEFAULT);
|
||||
+BASE_FEATURE(kSideBySideSessionRestore, base::FEATURE_ENABLED_BY_DEFAULT);
|
||||
|
||||
bool IsRestoringSplitViewEnabled() {
|
||||
return base::FeatureList::IsEnabled(features::kSideBySide) &&
|
||||
@@ -251,7 +251,7 @@ bool IsRestoringSplitViewEnabled() {
|
||||
|
||||
BASE_FEATURE(kSideBySideLinkMenuNewBadge, base::FEATURE_DISABLED_BY_DEFAULT);
|
||||
|
||||
-BASE_FEATURE(kSideBySideKeyboardShortcut, base::FEATURE_DISABLED_BY_DEFAULT);
|
||||
+BASE_FEATURE(kSideBySideKeyboardShortcut, base::FEATURE_ENABLED_BY_DEFAULT);
|
||||
|
||||
bool IsSideBySideKeyboardShortcutEnabled() {
|
||||
return base::FeatureList::IsEnabled(features::kSideBySide) &&
|
||||
@@ -260,6 +260,14 @@ bool IsSideBySideKeyboardShortcutEnabled() {
|
||||
|
||||
BASE_FEATURE(kSidePanelResizing, base::FEATURE_ENABLED_BY_DEFAULT);
|
||||
BASE_FEATURE(kTabbedBrowserUseNewLayout, base::FEATURE_ENABLED_BY_DEFAULT);
|
||||
|
||||
+BASE_FEATURE(kThirdPartyLlmPanel,
|
||||
+ "ThirdPartyLlmPanel",
|
||||
@@ -51,4 +16,4 @@ index c03c8ac6f6e00..0c0b83dfe9fef 100644
|
||||
+
|
||||
BASE_FEATURE(kTabDuplicateMetrics, base::FEATURE_ENABLED_BY_DEFAULT);
|
||||
|
||||
// Enables buttons when scrolling the tabstrip https://crbug.com/951078
|
||||
// Enables tabs to be frozen when collapsed.
|
||||
|
||||
@@ -1,13 +1,15 @@
|
||||
diff --git a/chrome/browser/ui/ui_features.h b/chrome/browser/ui/ui_features.h
|
||||
index 24bf81e4b6e3c..1056daae1f563 100644
|
||||
index 2bedb1e230459..f779499960910 100644
|
||||
--- a/chrome/browser/ui/ui_features.h
|
||||
+++ b/chrome/browser/ui/ui_features.h
|
||||
@@ -225,6 +225,8 @@ inline constexpr char kTabScrollingButtonPositionParameterName[] =
|
||||
@@ -161,6 +161,10 @@ BASE_DECLARE_FEATURE(kPopupBrowserUseNewLayout);
|
||||
|
||||
BASE_DECLARE_FEATURE(kSidePanelResizing);
|
||||
BASE_DECLARE_FEATURE(kSidePanelSearchCompanion);
|
||||
BASE_DECLARE_FEATURE(kTabbedBrowserUseNewLayout);
|
||||
|
||||
+// BrowserOS: feature declarations
|
||||
+BASE_DECLARE_FEATURE(kThirdPartyLlmPanel);
|
||||
+BASE_DECLARE_FEATURE(kClashOfGpts);
|
||||
+
|
||||
BASE_DECLARE_FEATURE(kTabDuplicateMetrics);
|
||||
|
||||
BASE_DECLARE_FEATURE(kTabGroupsCollapseFreezing);
|
||||
BASE_DECLARE_FEATURE(kTabGroupHoverCards);
|
||||
|
||||
@@ -1,13 +1,16 @@
|
||||
diff --git a/chrome/browser/ui/views/chrome_layout_provider.cc b/chrome/browser/ui/views/chrome_layout_provider.cc
|
||||
index 0f1e5c46255a1..9d5c67a26e001 100644
|
||||
index 77be8f6e709d3..5f0dd9b1960d7 100644
|
||||
--- a/chrome/browser/ui/views/chrome_layout_provider.cc
|
||||
+++ b/chrome/browser/ui/views/chrome_layout_provider.cc
|
||||
@@ -160,7 +160,7 @@ int ChromeLayoutProvider::GetDistanceMetric(int metric) const {
|
||||
case DISTANCE_INFOBAR_HEIGHT:
|
||||
// Spec says height of button should be 36dp, vertical padding on both
|
||||
@@ -167,9 +167,10 @@ int ChromeLayoutProvider::GetDistanceMetric(int metric) const {
|
||||
// top and bottom should be 8dp.
|
||||
- return 36 + 2 * 8;
|
||||
+ return 36 + 2 * 3;
|
||||
// The new refreshed button height is 20 + (2 * 6) = 32dp.
|
||||
// Therefore, the total infobar height is 32dp + 2 * 12.
|
||||
+ // BrowserOS: reduced padding for non-refresh infobars (2*3 instead of 2*8)
|
||||
return base::FeatureList::IsEnabled(features::kInfobarRefresh)
|
||||
? 32 + 2 * 12
|
||||
- : 36 + 2 * 8;
|
||||
+ : 36 + 2 * 3;
|
||||
case DISTANCE_PERMISSION_PROMPT_HORIZONTAL_ICON_LABEL_PADDING:
|
||||
return 8;
|
||||
case DISTANCE_RICH_HOVER_BUTTON_ICON_HORIZONTAL:
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
diff --git a/chrome/browser/ui/views/side_panel/extensions/extension_side_panel_utils.cc b/chrome/browser/ui/views/side_panel/extensions/extension_side_panel_utils.cc
|
||||
index ff61e95a7bba9..312c019f68442 100644
|
||||
index 539677d6bb9ac..bc32fcec8788c 100644
|
||||
--- a/chrome/browser/ui/views/side_panel/extensions/extension_side_panel_utils.cc
|
||||
+++ b/chrome/browser/ui/views/side_panel/extensions/extension_side_panel_utils.cc
|
||||
@@ -4,6 +4,7 @@
|
||||
@@ -10,8 +10,8 @@ index ff61e95a7bba9..312c019f68442 100644
|
||||
#include "chrome/browser/profiles/profile.h"
|
||||
#include "chrome/browser/ui/browser_window/public/browser_window_features.h"
|
||||
#include "chrome/browser/ui/browser_window/public/browser_window_interface.h"
|
||||
@@ -216,4 +217,127 @@ void CloseContextualExtensionSidePanel(BrowserWindowInterface* browser_window,
|
||||
}
|
||||
@@ -212,4 +213,127 @@ void CloseContextualExtensionSidePanel(BrowserWindowInterface* browser_window,
|
||||
ExtensionSidePanelCoordinator::GetPanelType());
|
||||
}
|
||||
|
||||
+bool IsContextualExtensionSidePanelOpen(BrowserWindowInterface* browser_window,
|
||||
@@ -38,7 +38,7 @@ index ff61e95a7bba9..312c019f68442 100644
|
||||
+ // this extension's entry.
|
||||
+ if (is_active_tab) {
|
||||
+ SidePanelUI* side_panel_ui = browser_window->GetFeatures().side_panel_ui();
|
||||
+ bool is_showing = side_panel_ui->IsSidePanelShowing();
|
||||
+ bool is_showing = side_panel_ui->IsSidePanelShowing(SidePanelEntry::PanelType::kContent);
|
||||
+ LOG(INFO) << "browseros: side_panel is_showing=" << is_showing;
|
||||
+ if (!is_showing) {
|
||||
+ return false;
|
||||
@@ -84,7 +84,7 @@ index ff61e95a7bba9..312c019f68442 100644
|
||||
+
|
||||
+ // Check if this extension's contextual panel is currently showing.
|
||||
+ bool is_currently_open = false;
|
||||
+ if (is_active_tab && side_panel_ui->IsSidePanelShowing()) {
|
||||
+ if (is_active_tab && side_panel_ui->IsSidePanelShowing(SidePanelEntry::PanelType::kContent)) {
|
||||
+ is_currently_open = IsKeyActiveInRegistry(contextual_registry, extension_key);
|
||||
+ }
|
||||
+
|
||||
@@ -110,7 +110,7 @@ index ff61e95a7bba9..312c019f68442 100644
|
||||
+
|
||||
+ if (!should_open) {
|
||||
+ LOG(INFO) << "browseros: Closing contextual panel";
|
||||
+ side_panel_ui->Close();
|
||||
+ side_panel_ui->Close(SidePanelEntry::PanelType::kContent);
|
||||
+ contextual_registry->ResetActiveEntryFor(SidePanelEntry::PanelType::kContent);
|
||||
+ return false;
|
||||
+ } else {
|
||||
|
||||
@@ -1,13 +1,16 @@
|
||||
diff --git a/chrome/browser/ui/views/side_panel/side_panel.cc b/chrome/browser/ui/views/side_panel/side_panel.cc
|
||||
index d98e373f9b359..14e1dbb3ca4d4 100644
|
||||
index 56a63f28ca526..773d4ff107c9a 100644
|
||||
--- a/chrome/browser/ui/views/side_panel/side_panel.cc
|
||||
+++ b/chrome/browser/ui/views/side_panel/side_panel.cc
|
||||
@@ -677,7 +677,7 @@ void SidePanel::UpdateVisibility(bool should_be_open, bool animate_transition) {
|
||||
|
||||
bool SidePanel::ShouldShowAnimation() const {
|
||||
return lens::features::IsLensOverlayEnabled() &&
|
||||
- gfx::Animation::ShouldRenderRichAnimation() && !animations_disabled_;
|
||||
+ gfx::Animation::ShouldRenderRichAnimation() && !animations_disabled_ && animations_disabled_browseros_;
|
||||
@@ -879,8 +879,10 @@ double SidePanel::GetAnimationValueFor(
|
||||
}
|
||||
|
||||
void SidePanel::AnnounceResize() {
|
||||
bool SidePanel::ShouldShowAnimation() const {
|
||||
+ // BrowserOS: animations_disabled_browseros_ used to control animation
|
||||
bool should_show_animations =
|
||||
- gfx::Animation::ShouldRenderRichAnimation() && !animations_disabled_;
|
||||
+ gfx::Animation::ShouldRenderRichAnimation() && !animations_disabled_ &&
|
||||
+ animations_disabled_browseros_;
|
||||
#if BUILDFLAG(IS_WIN)
|
||||
// Don't show open/close animations for the toolbar height panel on Windows
|
||||
// due to jank. The "show from" animation should still run which is the only
|
||||
|
||||
@@ -1,13 +1,14 @@
|
||||
diff --git a/chrome/browser/ui/views/side_panel/side_panel.h b/chrome/browser/ui/views/side_panel/side_panel.h
|
||||
index 617d8674a4ead..e711565394814 100644
|
||||
index 340d36f59e278..32dac5e143fbd 100644
|
||||
--- a/chrome/browser/ui/views/side_panel/side_panel.h
|
||||
+++ b/chrome/browser/ui/views/side_panel/side_panel.h
|
||||
@@ -128,6 +128,8 @@ class SidePanel : public views::AccessiblePaneView,
|
||||
@@ -170,6 +170,9 @@ class SidePanel : public views::AccessiblePaneView,
|
||||
|
||||
bool animations_disabled_ = false;
|
||||
|
||||
+ // BrowserOS: flag to control animations
|
||||
+ bool animations_disabled_browseros_ = true;
|
||||
+
|
||||
// Animation controlling showing and hiding of the side panel.
|
||||
gfx::SlideAnimation animation_{this};
|
||||
|
||||
// Starting bounds for the side panel content if kOpenWithContentTransition
|
||||
// animation is shown.
|
||||
std::optional<gfx::Rect> content_starting_bounds_;
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
diff --git a/chrome/browser/ui/views/side_panel/third_party_llm/third_party_llm_panel_coordinator.cc b/chrome/browser/ui/views/side_panel/third_party_llm/third_party_llm_panel_coordinator.cc
|
||||
new file mode 100644
|
||||
index 0000000000000..ea3e4207ee029
|
||||
index 0000000000000..d6a803c592c98
|
||||
--- /dev/null
|
||||
+++ b/chrome/browser/ui/views/side_panel/third_party_llm/third_party_llm_panel_coordinator.cc
|
||||
@@ -0,0 +1,1187 @@
|
||||
@@ -0,0 +1,1192 @@
|
||||
+// Copyright 2024 The Chromium Authors
|
||||
+// Use of this source code is governed by a BSD-style license that can be
|
||||
+// found in the LICENSE file.
|
||||
@@ -66,6 +66,9 @@ index 0000000000000..ea3e4207ee029
|
||||
+#include "base/timer/timer.h"
|
||||
+#include "base/task/sequenced_task_runner.h"
|
||||
+#include "components/input/native_web_keyboard_event.h"
|
||||
+#include "chrome/browser/ui/browser_window/public/browser_window_interface.h"
|
||||
+#include "chrome/browser/ui/browser_window/public/browser_window_interface_iterator.h"
|
||||
+#include "components/viz/common/frame_sinks/copy_output_result.h"
|
||||
+#include "content/public/browser/render_widget_host_view.h"
|
||||
+#include "third_party/skia/include/core/SkBitmap.h"
|
||||
+#include "ui/gfx/codec/png_codec.h"
|
||||
@@ -640,14 +643,15 @@ index 0000000000000..ea3e4207ee029
|
||||
+ view->CopyFromSurface(
|
||||
+ gfx::Rect(), // Empty rect = full visible surface
|
||||
+ gfx::Size(), // Empty size = original size
|
||||
+ base::TimeDelta(), // No timeout
|
||||
+ base::BindOnce([](base::WeakPtr<ThirdPartyLlmPanelCoordinator> coordinator,
|
||||
+ const SkBitmap& bitmap) {
|
||||
+ const content::CopyFromSurfaceResult& result) {
|
||||
+ if (!coordinator) {
|
||||
+ return;
|
||||
+ }
|
||||
+ gfx::Image image;
|
||||
+ if (!bitmap.drawsNothing()) {
|
||||
+ image = gfx::Image::CreateFrom1xBitmap(bitmap);
|
||||
+ if (result.has_value() && !result->bitmap.drawsNothing()) {
|
||||
+ image = gfx::Image::CreateFrom1xBitmap(result->bitmap);
|
||||
+ }
|
||||
+ coordinator->OnScreenshotCaptured(image);
|
||||
+ }, weak_factory_.GetWeakPtr()));
|
||||
@@ -1175,9 +1179,10 @@ index 0000000000000..ea3e4207ee029
|
||||
+ OnOpenInNewTab();
|
||||
+ break;
|
||||
+ case IDC_CLASH_OF_GPTS:
|
||||
+ if (Browser* browser = BrowserList::GetInstance()->GetLastActive()) {
|
||||
+ if (BrowserWindowInterface* window =
|
||||
+ GetLastActiveBrowserWindowInterfaceWithAnyProfile()) {
|
||||
+ if (auto* coordinator =
|
||||
+ browser->browser_window_features()->clash_of_gpts_coordinator()) {
|
||||
+ window->GetFeatures().clash_of_gpts_coordinator()) {
|
||||
+ coordinator->Show();
|
||||
+ }
|
||||
+ }
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
diff --git a/chrome/browser/ui/webui/help/version_updater_mac.mm b/chrome/browser/ui/webui/help/version_updater_mac.mm
|
||||
index ad6be624e5cb0..a0d9043c06fa1 100644
|
||||
index d619a644cef14..a851e42d99acb 100644
|
||||
--- a/chrome/browser/ui/webui/help/version_updater_mac.mm
|
||||
+++ b/chrome/browser/ui/webui/help/version_updater_mac.mm
|
||||
@@ -6,6 +6,15 @@
|
||||
@@ -18,7 +18,7 @@ index ad6be624e5cb0..a0d9043c06fa1 100644
|
||||
#include <algorithm>
|
||||
#include <memory>
|
||||
#include <string>
|
||||
@@ -78,6 +87,8 @@ void UpdateStatus(VersionUpdater::StatusCallback status_callback,
|
||||
@@ -77,6 +86,8 @@ void UpdateStatus(VersionUpdater::StatusCallback status_callback,
|
||||
: VersionUpdater::Status::UPDATED;
|
||||
break;
|
||||
case updater::UpdateService::UpdateState::State::kUpdateError:
|
||||
@@ -27,17 +27,7 @@ index ad6be624e5cb0..a0d9043c06fa1 100644
|
||||
switch (update_state.error_code) {
|
||||
case updater::GOOPDATE_E_APP_UPDATE_DISABLED_BY_POLICY:
|
||||
status = VersionUpdater::Status::DISABLED_BY_ADMIN;
|
||||
@@ -147,12 +158,27 @@ class VersionUpdaterMac : public VersionUpdater {
|
||||
},
|
||||
base::BindRepeating(&UpdateStatus, status_callback)));
|
||||
}
|
||||
- void PromoteUpdater() override { SetupSystemUpdater(); }
|
||||
+ void PromoteUpdater() override {
|
||||
+ SetupSystemUpdater();
|
||||
+ }
|
||||
};
|
||||
|
||||
} // namespace
|
||||
@@ -134,5 +145,18 @@ void CheckForUpdate(StatusCallback status_callback,
|
||||
|
||||
std::unique_ptr<VersionUpdater> VersionUpdater::Create(
|
||||
content::WebContents* /* web_contents */) {
|
||||
|
||||
@@ -1,11 +1,12 @@
|
||||
diff --git a/chrome/browser/ui/webui/side_panel/customize_chrome/customize_toolbar/customize_toolbar.mojom b/chrome/browser/ui/webui/side_panel/customize_chrome/customize_toolbar/customize_toolbar.mojom
|
||||
index 8eec2ead88a8a..c873205ac549a 100644
|
||||
index dc2fed765187a..3ab37408a8488 100644
|
||||
--- a/chrome/browser/ui/webui/side_panel/customize_chrome/customize_toolbar/customize_toolbar.mojom
|
||||
+++ b/chrome/browser/ui/webui/side_panel/customize_chrome/customize_toolbar/customize_toolbar.mojom
|
||||
@@ -33,6 +33,8 @@ enum ActionId {
|
||||
kCopyLink,
|
||||
@@ -34,6 +34,9 @@ enum ActionId {
|
||||
kTabSearch,
|
||||
kSplitTab,
|
||||
kContextualTasks,
|
||||
+ // BrowserOS: custom action IDs
|
||||
+ kShowThirdPartyLlm,
|
||||
+ kShowClashOfGpts,
|
||||
};
|
||||
|
||||
@@ -1,11 +1,12 @@
|
||||
diff --git a/chrome/browser/ui/webui/side_panel/customize_chrome/customize_toolbar/customize_toolbar_handler.cc b/chrome/browser/ui/webui/side_panel/customize_chrome/customize_toolbar/customize_toolbar_handler.cc
|
||||
index 52dddc0ddc518..5be29b2ed54dd 100644
|
||||
index 31b360347f2bc..1192c83265e9a 100644
|
||||
--- a/chrome/browser/ui/webui/side_panel/customize_chrome/customize_toolbar/customize_toolbar_handler.cc
|
||||
+++ b/chrome/browser/ui/webui/side_panel/customize_chrome/customize_toolbar/customize_toolbar_handler.cc
|
||||
@@ -85,6 +85,10 @@ MojoActionForChromeAction(actions::ActionId action_id) {
|
||||
return side_panel::customize_chrome::mojom::ActionId::kTabSearch;
|
||||
case kActionSplitTab:
|
||||
@@ -92,6 +92,11 @@ MojoActionForChromeAction(actions::ActionId action_id) {
|
||||
return side_panel::customize_chrome::mojom::ActionId::kSplitTab;
|
||||
case kActionSidePanelShowContextualTasks:
|
||||
return side_panel::customize_chrome::mojom::ActionId::kContextualTasks;
|
||||
+ // BrowserOS: custom toolbar actions
|
||||
+ case kActionSidePanelShowThirdPartyLlm:
|
||||
+ return side_panel::customize_chrome::mojom::ActionId::kShowThirdPartyLlm;
|
||||
+ case kActionSidePanelShowClashOfGpts:
|
||||
@@ -13,10 +14,11 @@ index 52dddc0ddc518..5be29b2ed54dd 100644
|
||||
default:
|
||||
return std::nullopt;
|
||||
}
|
||||
@@ -143,6 +147,10 @@ std::optional<actions::ActionId> ChromeActionForMojoAction(
|
||||
return kActionTabSearch;
|
||||
case side_panel::customize_chrome::mojom::ActionId::kSplitTab:
|
||||
@@ -152,6 +157,11 @@ std::optional<actions::ActionId> ChromeActionForMojoAction(
|
||||
return kActionSplitTab;
|
||||
case side_panel::customize_chrome::mojom::ActionId::kContextualTasks:
|
||||
return kActionSidePanelShowContextualTasks;
|
||||
+ // BrowserOS: custom toolbar actions
|
||||
+ case side_panel::customize_chrome::mojom::ActionId::kShowThirdPartyLlm:
|
||||
+ return kActionSidePanelShowThirdPartyLlm;
|
||||
+ case side_panel::customize_chrome::mojom::ActionId::kShowClashOfGpts:
|
||||
@@ -24,7 +26,7 @@ index 52dddc0ddc518..5be29b2ed54dd 100644
|
||||
default:
|
||||
return std::nullopt;
|
||||
}
|
||||
@@ -290,6 +298,10 @@ void CustomizeToolbarHandler::ListActions(ListActionsCallback callback) {
|
||||
@@ -342,6 +352,10 @@ void CustomizeToolbarHandler::ListActions(ListActionsCallback callback) {
|
||||
side_panel::customize_chrome::mojom::CategoryId::kYourChrome);
|
||||
add_action(kActionSidePanelShowReadingList,
|
||||
side_panel::customize_chrome::mojom::CategoryId::kYourChrome);
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
diff --git a/chrome/common/pref_names.h b/chrome/common/pref_names.h
|
||||
index 1a4683393ff24..dc1e69f5fc57d 100644
|
||||
index 898e1c48db1e1..3f88b936ccd63 100644
|
||||
--- a/chrome/common/pref_names.h
|
||||
+++ b/chrome/common/pref_names.h
|
||||
@@ -1583,6 +1583,9 @@ inline constexpr char kImportDialogSavedPasswords[] =
|
||||
@@ -1594,6 +1594,9 @@ inline constexpr char kImportDialogSavedPasswords[] =
|
||||
"import_dialog_saved_passwords";
|
||||
inline constexpr char kImportDialogSearchEngine[] =
|
||||
"import_dialog_search_engine";
|
||||
@@ -12,10 +12,11 @@ index 1a4683393ff24..dc1e69f5fc57d 100644
|
||||
|
||||
// Profile avatar and name
|
||||
inline constexpr char kProfileAvatarIndex[] = "profile.avatar_index";
|
||||
@@ -4302,6 +4305,17 @@ inline constexpr char kNonMilestoneUpdateToastVersion[] =
|
||||
"toast.non_milestone_update_toast_version";
|
||||
#endif // !BUILDFLAG(IS_ANDROID)
|
||||
@@ -4336,6 +4339,18 @@ inline constexpr char kAndroidTipNotificationShownBottomOmnibox[] =
|
||||
// LINT.ThenChange(//chrome/android/java/src/org/chromium/chrome/browser/notifications/tips/TipsUtils.java:TipsShownPrefs)
|
||||
#endif // BUILDFLAG(IS_ANDROID)
|
||||
|
||||
+// BrowserOS: metrics prefs
|
||||
+// String containing the stable client ID for BrowserOS metrics
|
||||
+inline constexpr char kBrowserOSMetricsClientId[] =
|
||||
+ "browseros.metrics_client_id";
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
diff --git a/chrome/install_static/chromium_install_modes.h b/chrome/install_static/chromium_install_modes.h
|
||||
index 7de32cf745755..18c95e7046ef1 100644
|
||||
index 0cf937413e08a..a61c438a77379 100644
|
||||
--- a/chrome/install_static/chromium_install_modes.h
|
||||
+++ b/chrome/install_static/chromium_install_modes.h
|
||||
@@ -33,47 +33,47 @@ inline constexpr auto kInstallModes = std::to_array<InstallConstants>({
|
||||
@@ -33,48 +33,49 @@ inline constexpr auto kInstallModes = std::to_array<InstallConstants>({
|
||||
L"", // Empty install_suffix for the primary install mode.
|
||||
.logo_suffix = L"", // No logo suffix for the primary install mode.
|
||||
.app_guid =
|
||||
@@ -15,9 +15,11 @@ index 7de32cf745755..18c95e7046ef1 100644
|
||||
+ .base_app_id = L"BrowserOS", // A distinct base_app_id.
|
||||
+ .browser_prog_id_prefix = L"BOSHTML", // Browser ProgID prefix.
|
||||
.browser_prog_id_description =
|
||||
- L"Chromium HTML Document", // Browser ProgID description.
|
||||
- L"Chromium HTML Document", // Browser ProgID description.
|
||||
- .direct_launch_url_scheme = "chromium",
|
||||
- .pdf_prog_id_prefix = L"ChromiumPDF", // PDF ProgID prefix.
|
||||
+ L"BrowserOS HTML Document", // Browser ProgID description.
|
||||
+ L"BrowserOS HTML Document", // Browser ProgID description.
|
||||
+ .direct_launch_url_scheme = "browseros",
|
||||
+ .pdf_prog_id_prefix = L"BOSPDF", // PDF ProgID prefix.
|
||||
.pdf_prog_id_description =
|
||||
- L"Chromium PDF Document", // PDF ProgID description.
|
||||
@@ -40,12 +42,12 @@ index 7de32cf745755..18c95e7046ef1 100644
|
||||
- 0x4D6B,
|
||||
- {0x8B, 0xFE, 0x83, 0xBF, 0x8C, 0xA1, 0xB1,
|
||||
- 0xB0}}, // Elevator CLSID.
|
||||
- .elevator_iid = {0xb88c45b9,
|
||||
- 0x8825,
|
||||
- 0x4629,
|
||||
- {0xb8, 0x3e, 0x77, 0xcc, 0x67, 0xd9, 0xce,
|
||||
- 0xed}}, // IElevator IID and TypeLib
|
||||
- // {B88C45B9-8825-4629-B83E-77CC67D9CEED}.
|
||||
- .elevator_iid = {0xbb19a0e5,
|
||||
- 0xc6,
|
||||
- 0x4966,
|
||||
- {0x94, 0xb2, 0x5a, 0xfe, 0xc6, 0xfe, 0xd9,
|
||||
- 0x3a}}, // IElevator IID and TypeLib
|
||||
- // {BB19A0E5-00C6-4966-94B2-5AFEC6FED93A}.
|
||||
- .tracing_service_clsid = {0x83f69367,
|
||||
- 0x442d,
|
||||
- 0x447f,
|
||||
@@ -56,6 +58,7 @@ index 7de32cf745755..18c95e7046ef1 100644
|
||||
- 0x4075,
|
||||
- {0x91, 0x74, 0x75, 0xd0, 0xb1, 0x99, 0xd3,
|
||||
- 0xcb}}, // ISystemTraceSessionChromium IID and
|
||||
+ // BrowserOS: custom CLSIDs for Windows integration
|
||||
+ .toast_activator_clsid = {0xE76CCE76,
|
||||
+ 0x27A7,
|
||||
+ 0x46D3,
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
diff --git a/chrome/utility/importer/browseros/chrome_bookmarks_importer.cc b/chrome/utility/importer/browseros/chrome_bookmarks_importer.cc
|
||||
new file mode 100644
|
||||
index 0000000000000..6896bb7ab0f7c
|
||||
index 0000000000000..e631448aa5137
|
||||
--- /dev/null
|
||||
+++ b/chrome/utility/importer/browseros/chrome_bookmarks_importer.cc
|
||||
@@ -0,0 +1,249 @@
|
||||
@@ -0,0 +1,248 @@
|
||||
+// Copyright 2024 AKW Technology Inc
|
||||
+// Chrome bookmarks importer implementation
|
||||
+
|
||||
@@ -151,8 +151,7 @@ index 0000000000000..6896bb7ab0f7c
|
||||
+ continue;
|
||||
+ }
|
||||
+
|
||||
+ std::vector<uint8_t> data;
|
||||
+ statement.ColumnBlobAsVector(1, &data);
|
||||
+ std::vector<uint8_t> data = statement.ColumnBlobAsVector(1);
|
||||
+ if (data.empty()) {
|
||||
+ statement.Reset(true);
|
||||
+ continue;
|
||||
@@ -193,7 +192,7 @@ index 0000000000000..6896bb7ab0f7c
|
||||
+ }
|
||||
+
|
||||
+ std::optional<base::Value> bookmarks_value =
|
||||
+ base::JSONReader::Read(bookmarks_content);
|
||||
+ base::JSONReader::Read(bookmarks_content, base::JSON_PARSE_RFC);
|
||||
+ if (!bookmarks_value || !bookmarks_value->is_dict()) {
|
||||
+ LOG(WARNING) << "browseros: Failed to parse Bookmarks JSON";
|
||||
+ return result;
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
diff --git a/chrome/utility/importer/browseros/chrome_cookie_importer.cc b/chrome/utility/importer/browseros/chrome_cookie_importer.cc
|
||||
new file mode 100644
|
||||
index 0000000000000..4497532338b3f
|
||||
index 0000000000000..da4ba9dd79e93
|
||||
--- /dev/null
|
||||
+++ b/chrome/utility/importer/browseros/chrome_cookie_importer.cc
|
||||
@@ -0,0 +1,229 @@
|
||||
@@ -0,0 +1,228 @@
|
||||
+// Copyright 2024 AKW Technology Inc
|
||||
+// Chrome cookie importer implementation
|
||||
+
|
||||
@@ -184,8 +184,7 @@ index 0000000000000..4497532338b3f
|
||||
+
|
||||
+ // Get both plaintext and encrypted values
|
||||
+ std::string plaintext_value = statement.ColumnString(2);
|
||||
+ std::string encrypted_value;
|
||||
+ statement.ColumnBlobAsString(3, &encrypted_value);
|
||||
+ std::string encrypted_value = statement.ColumnBlobAsString(3);
|
||||
+
|
||||
+ // Prefer encrypted_value if present, otherwise use plaintext
|
||||
+ if (!encrypted_value.empty()) {
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
diff --git a/chrome/utility/importer/browseros/chrome_decryptor_win.cc b/chrome/utility/importer/browseros/chrome_decryptor_win.cc
|
||||
new file mode 100644
|
||||
index 0000000000000..5853c63c5e2d4
|
||||
index 0000000000000..c56a27b698eda
|
||||
--- /dev/null
|
||||
+++ b/chrome/utility/importer/browseros/chrome_decryptor_win.cc
|
||||
@@ -0,0 +1,246 @@
|
||||
@@ -53,7 +53,7 @@ index 0000000000000..5853c63c5e2d4
|
||||
+ return false;
|
||||
+ }
|
||||
+
|
||||
+ auto parsed = base::JSONReader::Read(json_content);
|
||||
+ auto parsed = base::JSONReader::Read(json_content, base::JSON_PARSE_RFC);
|
||||
+ if (!parsed || !parsed->is_dict()) {
|
||||
+ LOG(WARNING) << "browseros: Failed to parse Local State JSON";
|
||||
+ return false;
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
diff --git a/chrome/utility/importer/browseros/chrome_password_importer.cc b/chrome/utility/importer/browseros/chrome_password_importer.cc
|
||||
new file mode 100644
|
||||
index 0000000000000..cbae752f359b5
|
||||
index 0000000000000..1a01e3951aa3f
|
||||
--- /dev/null
|
||||
+++ b/chrome/utility/importer/browseros/chrome_password_importer.cc
|
||||
@@ -0,0 +1,151 @@
|
||||
@@ -0,0 +1,150 @@
|
||||
+// Copyright 2024 AKW Technology Inc
|
||||
+// Chrome password importer implementation
|
||||
+
|
||||
@@ -104,8 +104,7 @@ index 0000000000000..cbae752f359b5
|
||||
+ std::u16string password_element = statement.ColumnString16(4);
|
||||
+
|
||||
+ // password_value is a BLOB - encrypted
|
||||
+ std::string encrypted_password;
|
||||
+ statement.ColumnBlobAsString(5, &encrypted_password);
|
||||
+ std::string encrypted_password = statement.ColumnBlobAsString(5);
|
||||
+
|
||||
+ std::string signon_realm = statement.ColumnString(6);
|
||||
+ bool blacklisted = statement.ColumnBool(7);
|
||||
|
||||
@@ -1,12 +1,13 @@
|
||||
diff --git a/components/infobars/core/infobar_delegate.h b/components/infobars/core/infobar_delegate.h
|
||||
index 20a8371d17c74..0351c5ad4b028 100644
|
||||
index 62247f8d82ca6..5bc23ffd73d95 100644
|
||||
--- a/components/infobars/core/infobar_delegate.h
|
||||
+++ b/components/infobars/core/infobar_delegate.h
|
||||
@@ -195,6 +195,7 @@ class InfoBarDelegate {
|
||||
PIN_INFOBAR_DELEGATE = 127,
|
||||
@@ -212,6 +212,8 @@ class InfoBarDelegate {
|
||||
SESSION_RESTORE_INFOBAR_DELEGATE = 128,
|
||||
ROLL_BACK_MODE_B_INFOBAR_DELEGATE = 129,
|
||||
+ BROWSEROS_AGENT_INSTALLING_INFOBAR_DELEGATE = 130,
|
||||
DEV_TOOLS_REMOTE_DEBUGGING_INFOBAR_DELEGATE = 130,
|
||||
+ // BrowserOS: agent installation infobar
|
||||
+ BROWSEROS_AGENT_INSTALLING_INFOBAR_DELEGATE = 131,
|
||||
};
|
||||
// LINT.ThenChange(//tools/metrics/histograms/metadata/browser/enums.xml:InfoBarIdentifier)
|
||||
|
||||
|
||||
@@ -1,13 +1,14 @@
|
||||
diff --git a/components/os_crypt/sync/keychain_password_mac.mm b/components/os_crypt/sync/keychain_password_mac.mm
|
||||
index 1d4c16a300227..af4b3c4c09eb9 100644
|
||||
--- a/components/os_crypt/sync/keychain_password_mac.mm
|
||||
+++ b/components/os_crypt/sync/keychain_password_mac.mm
|
||||
@@ -35,8 +35,8 @@ namespace {
|
||||
diff --git a/components/os_crypt/common/keychain_password_mac.mm b/components/os_crypt/common/keychain_password_mac.mm
|
||||
index caa0e420956a3..d60a67a8bacb7 100644
|
||||
--- a/components/os_crypt/common/keychain_password_mac.mm
|
||||
+++ b/components/os_crypt/common/keychain_password_mac.mm
|
||||
@@ -35,8 +35,9 @@
|
||||
const char kDefaultServiceName[] = "Chrome Safe Storage";
|
||||
const char kDefaultAccountName[] = "Chrome";
|
||||
#else
|
||||
-const char kDefaultServiceName[] = "Chromium Safe Storage";
|
||||
-const char kDefaultAccountName[] = "Chromium";
|
||||
+// BrowserOS: custom keychain service name
|
||||
+const char kDefaultServiceName[] = "BrowserOS Safe Storage";
|
||||
+const char kDefaultAccountName[] = "BrowserOS";
|
||||
#endif
|
||||
@@ -1,36 +1,37 @@
|
||||
diff --git a/extensions/browser/extension_function_histogram_value.h b/extensions/browser/extension_function_histogram_value.h
|
||||
index 6d9bd29ae220f..f84c951ebeacb 100644
|
||||
index ef1e808e09269..0d8e46d362f80 100644
|
||||
--- a/extensions/browser/extension_function_histogram_value.h
|
||||
+++ b/extensions/browser/extension_function_histogram_value.h
|
||||
@@ -2011,6 +2011,31 @@ enum HistogramValue {
|
||||
DEVELOPERPRIVATE_SHOWSITESETTINGS = 1948,
|
||||
ACCESSIBILITY_PRIVATE_PROCESSPENDINGSPOKENFEEDBACKEVENT = 1949,
|
||||
ACCESSIBILITY_PRIVATE_ENABLESPOKENFEEDBACKMV3KEYHANDLING = 1950,
|
||||
+ BROWSER_OS_GETACCESSIBILITYTREE = 1951,
|
||||
+ BROWSER_OS_GETINTERACTIVESNAPSHOT = 1952,
|
||||
+ BROWSER_OS_CLICK = 1953,
|
||||
+ BROWSER_OS_INPUTTEXT = 1954,
|
||||
+ BROWSER_OS_CLEAR = 1955,
|
||||
+ BROWSER_OS_GETPAGELOADSTATUS = 1956,
|
||||
+ BROWSER_OS_SCROLLUP = 1957,
|
||||
+ BROWSER_OS_SCROLLDOWN = 1958,
|
||||
+ BROWSER_OS_SCROLLTONODE = 1959,
|
||||
+ BROWSER_OS_SENDKEYS = 1960,
|
||||
+ BROWSER_OS_GETPAGESTRUCTURE = 1961,
|
||||
+ BROWSER_OS_CAPTURESCREENSHOT = 1962,
|
||||
+ BROWSER_OS_GETSNAPSHOT = 1963,
|
||||
+ BROWSER_OS_GETPREF = 1964,
|
||||
+ BROWSER_OS_SETPREF = 1965,
|
||||
+ BROWSER_OS_GETALLPREFS = 1966,
|
||||
+ BROWSER_OS_LOGMETRIC = 1967,
|
||||
+ BROWSER_OS_GETVERSIONNUMBER = 1968,
|
||||
+ BROWSER_OS_EXECUTEJAVASCRIPT = 1969,
|
||||
+ BROWSER_OS_CLICKCOORDINATES = 1970,
|
||||
+ BROWSER_OS_TYPEATCOORDINATES = 1971,
|
||||
+ SIDEPANEL_BROWSEROSTOGGLE = 1972,
|
||||
+ SIDEPANEL_BROWSEROSISOPEN = 1973,
|
||||
+ BROWSER_OS_GETBROWSEROSVERSIONNUMBER = 1974,
|
||||
+ BROWSER_OS_CHOOSEPATH = 1975,
|
||||
@@ -2017,6 +2017,32 @@ enum HistogramValue {
|
||||
WEBSTOREPRIVATE_SHOULDSHOWENTERPRISEPROMOTIONBANNER = 1954,
|
||||
WEBSTOREPRIVATE_LOGENTERPRISEPROMOSHOWN = 1955,
|
||||
WEBSTOREPRIVATE_ONENTERPRISEPROMOCLICK = 1956,
|
||||
+ // BrowserOS: extension function histogram values
|
||||
+ BROWSER_OS_GETACCESSIBILITYTREE = 1957,
|
||||
+ BROWSER_OS_GETINTERACTIVESNAPSHOT = 1958,
|
||||
+ BROWSER_OS_CLICK = 1959,
|
||||
+ BROWSER_OS_INPUTTEXT = 1960,
|
||||
+ BROWSER_OS_CLEAR = 1961,
|
||||
+ BROWSER_OS_GETPAGELOADSTATUS = 1962,
|
||||
+ BROWSER_OS_SCROLLUP = 1963,
|
||||
+ BROWSER_OS_SCROLLDOWN = 1964,
|
||||
+ BROWSER_OS_SCROLLTONODE = 1965,
|
||||
+ BROWSER_OS_SENDKEYS = 1966,
|
||||
+ BROWSER_OS_GETPAGESTRUCTURE = 1967,
|
||||
+ BROWSER_OS_CAPTURESCREENSHOT = 1968,
|
||||
+ BROWSER_OS_GETSNAPSHOT = 1969,
|
||||
+ BROWSER_OS_GETPREF = 1970,
|
||||
+ BROWSER_OS_SETPREF = 1971,
|
||||
+ BROWSER_OS_GETALLPREFS = 1972,
|
||||
+ BROWSER_OS_LOGMETRIC = 1973,
|
||||
+ BROWSER_OS_GETVERSIONNUMBER = 1974,
|
||||
+ BROWSER_OS_EXECUTEJAVASCRIPT = 1975,
|
||||
+ BROWSER_OS_CLICKCOORDINATES = 1976,
|
||||
+ BROWSER_OS_TYPEATCOORDINATES = 1977,
|
||||
+ SIDEPANEL_BROWSEROSTOGGLE = 1978,
|
||||
+ SIDEPANEL_BROWSEROSISOPEN = 1979,
|
||||
+ BROWSER_OS_GETBROWSEROSVERSIONNUMBER = 1980,
|
||||
+ BROWSER_OS_CHOOSEPATH = 1981,
|
||||
// Last entry: Add new entries above, then run:
|
||||
// tools/metrics/histograms/update_extension_histograms.py
|
||||
ENUM_BOUNDARY
|
||||
|
||||
@@ -1,12 +1,12 @@
|
||||
diff --git a/tools/metrics/histograms/metadata/browser/enums.xml b/tools/metrics/histograms/metadata/browser/enums.xml
|
||||
index bc3f8f03d346c..c8d293bb0fd10 100644
|
||||
index 007aa3eb6038e..789d47a8811e5 100644
|
||||
--- a/tools/metrics/histograms/metadata/browser/enums.xml
|
||||
+++ b/tools/metrics/histograms/metadata/browser/enums.xml
|
||||
@@ -361,6 +361,7 @@ chromium-metrics-reviews@google.com.
|
||||
<int value="127" label="PIN_TO_TASKBAR_INFOBAR_DELEGATE"/>
|
||||
@@ -363,6 +363,7 @@ chromium-metrics-reviews@google.com.
|
||||
<int value="128" label="SESSION_RESTORE_INFOBAR_DELEGATE"/>
|
||||
<int value="129" label="ROLL_BACK_MODE_B_INFOBAR_DELEGATE"/>
|
||||
+ <int value="130" label="BROWSEROS_AGENT_INSTALLING_INFOBAR_DELEGATE"/>
|
||||
<int value="130" label="DEV_TOOLS_REMOTE_DEBUGGING_INFOBAR_DELEGATE"/>
|
||||
+ <int value="131" label="BROWSEROS_AGENT_INSTALLING_INFOBAR_DELEGATE"/>
|
||||
</enum>
|
||||
|
||||
<!-- LINT.ThenChange(//components/infobars/core/infobar_delegate.h:InfoBarIdentifier) -->
|
||||
|
||||
@@ -1,36 +1,36 @@
|
||||
diff --git a/tools/metrics/histograms/metadata/extensions/enums.xml b/tools/metrics/histograms/metadata/extensions/enums.xml
|
||||
index c36ba9e58148d..fbc5eefb3a231 100644
|
||||
index 6a374906f9f2e..4defc26e74df9 100644
|
||||
--- a/tools/metrics/histograms/metadata/extensions/enums.xml
|
||||
+++ b/tools/metrics/histograms/metadata/extensions/enums.xml
|
||||
@@ -2843,6 +2843,31 @@ Called by update_extension_histograms.py.-->
|
||||
label="ACCESSIBILITY_PRIVATE_PROCESSPENDINGSPOKENFEEDBACKEVENT"/>
|
||||
<int value="1950"
|
||||
label="ACCESSIBILITY_PRIVATE_ENABLESPOKENFEEDBACKMV3KEYHANDLING"/>
|
||||
+ <int value="1951" label="BROWSER_OS_GETACCESSIBILITYTREE"/>
|
||||
+ <int value="1952" label="BROWSER_OS_GETINTERACTIVESNAPSHOT"/>
|
||||
+ <int value="1953" label="BROWSER_OS_CLICK"/>
|
||||
+ <int value="1954" label="BROWSER_OS_INPUTTEXT"/>
|
||||
+ <int value="1955" label="BROWSER_OS_CLEAR"/>
|
||||
+ <int value="1956" label="BROWSER_OS_GETPAGELOADSTATUS"/>
|
||||
+ <int value="1957" label="BROWSER_OS_SCROLLUP"/>
|
||||
+ <int value="1958" label="BROWSER_OS_SCROLLDOWN"/>
|
||||
+ <int value="1959" label="BROWSER_OS_SCROLLTONODE"/>
|
||||
+ <int value="1960" label="BROWSER_OS_SENDKEYS"/>
|
||||
+ <int value="1961" label="BROWSER_OS_GETPAGESTRUCTURE"/>
|
||||
+ <int value="1962" label="BROWSER_OS_CAPTURESCREENSHOT"/>
|
||||
+ <int value="1963" label="BROWSER_OS_GETSNAPSHOT"/>
|
||||
+ <int value="1964" label="BROWSER_OS_GETPREF"/>
|
||||
+ <int value="1965" label="BROWSER_OS_SETPREF"/>
|
||||
+ <int value="1966" label="BROWSER_OS_GETALLPREFS"/>
|
||||
+ <int value="1967" label="BROWSER_OS_LOGMETRIC"/>
|
||||
+ <int value="1968" label="BROWSER_OS_GETVERSIONNUMBER"/>
|
||||
+ <int value="1969" label="BROWSER_OS_EXECUTEJAVASCRIPT"/>
|
||||
+ <int value="1970" label="BROWSER_OS_CLICKCOORDINATES"/>
|
||||
+ <int value="1971" label="BROWSER_OS_TYPEATCOORDINATES"/>
|
||||
+ <int value="1972" label="SIDEPANEL_BROWSEROSTOGGLE"/>
|
||||
+ <int value="1973" label="SIDEPANEL_BROWSEROSISOPEN"/>
|
||||
+ <int value="1974" label="BROWSER_OS_GETBROWSEROSVERSIONNUMBER"/>
|
||||
+ <int value="1975" label="BROWSER_OS_CHOOSEPATH"/>
|
||||
@@ -2871,6 +2871,31 @@ Called by update_extension_histograms.py.-->
|
||||
label="WEBSTOREPRIVATE_SHOULDSHOWENTERPRISEPROMOTIONBANNER"/>
|
||||
<int value="1955" label="WEBSTOREPRIVATE_LOGENTERPRISEPROMOSHOWN"/>
|
||||
<int value="1956" label="WEBSTOREPRIVATE_ONENTERPRISEPROMOCLICK"/>
|
||||
+ <int value="1957" label="BROWSER_OS_GETACCESSIBILITYTREE"/>
|
||||
+ <int value="1958" label="BROWSER_OS_GETINTERACTIVESNAPSHOT"/>
|
||||
+ <int value="1959" label="BROWSER_OS_CLICK"/>
|
||||
+ <int value="1960" label="BROWSER_OS_INPUTTEXT"/>
|
||||
+ <int value="1961" label="BROWSER_OS_CLEAR"/>
|
||||
+ <int value="1962" label="BROWSER_OS_GETPAGELOADSTATUS"/>
|
||||
+ <int value="1963" label="BROWSER_OS_SCROLLUP"/>
|
||||
+ <int value="1964" label="BROWSER_OS_SCROLLDOWN"/>
|
||||
+ <int value="1965" label="BROWSER_OS_SCROLLTONODE"/>
|
||||
+ <int value="1966" label="BROWSER_OS_SENDKEYS"/>
|
||||
+ <int value="1967" label="BROWSER_OS_GETPAGESTRUCTURE"/>
|
||||
+ <int value="1968" label="BROWSER_OS_CAPTURESCREENSHOT"/>
|
||||
+ <int value="1969" label="BROWSER_OS_GETSNAPSHOT"/>
|
||||
+ <int value="1970" label="BROWSER_OS_GETPREF"/>
|
||||
+ <int value="1971" label="BROWSER_OS_SETPREF"/>
|
||||
+ <int value="1972" label="BROWSER_OS_GETALLPREFS"/>
|
||||
+ <int value="1973" label="BROWSER_OS_LOGMETRIC"/>
|
||||
+ <int value="1974" label="BROWSER_OS_GETVERSIONNUMBER"/>
|
||||
+ <int value="1975" label="BROWSER_OS_EXECUTEJAVASCRIPT"/>
|
||||
+ <int value="1976" label="BROWSER_OS_CLICKCOORDINATES"/>
|
||||
+ <int value="1977" label="BROWSER_OS_TYPEATCOORDINATES"/>
|
||||
+ <int value="1978" label="SIDEPANEL_BROWSEROSTOGGLE"/>
|
||||
+ <int value="1979" label="SIDEPANEL_BROWSEROSISOPEN"/>
|
||||
+ <int value="1980" label="BROWSER_OS_GETBROWSEROSVERSIONNUMBER"/>
|
||||
+ <int value="1981" label="BROWSER_OS_CHOOSEPATH"/>
|
||||
</enum>
|
||||
|
||||
<!-- LINT.ThenChange(//extensions/browser/extension_function_histogram_value.h:HistogramValue) -->
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
BROWSEROS_MAJOR=0
|
||||
BROWSEROS_MINOR=39
|
||||
BROWSEROS_MINOR=40
|
||||
BROWSEROS_BUILD=0
|
||||
BROWSEROS_PATCH=3
|
||||
BROWSEROS_PATCH=0
|
||||
|
||||
@@ -11,4 +11,4 @@
|
||||
# Comments start with #
|
||||
# Inline comments: path/to/patch.patch # comment here
|
||||
|
||||
ungoogle-chromium/extensions-manifestv2.patch
|
||||
# ungoogle-chromium/extensions-manifestv2.patch
|
||||
|
||||
@@ -3,8 +3,8 @@
|
||||
# These patches are applied only when building on Windows.
|
||||
# Paths are relative to the series_patches directory.
|
||||
|
||||
windows/ungoogled-chromium/windows-disable-rcpy.patch
|
||||
windows/ungoogled-chromium/windows-fix-rc.patch
|
||||
windows/ungoogled-chromium/windows-fix-command-ids.patch
|
||||
windows/ungoogled-chromium/windows-disable-download-warning-prompt.patch
|
||||
windows/ungoogled-chromium/windows-fix-rc-terminating-error.patch
|
||||
# windows/ungoogled-chromium/windows-disable-rcpy.patch
|
||||
# windows/ungoogled-chromium/windows-fix-rc.patch
|
||||
# windows/ungoogled-chromium/windows-fix-command-ids.patch
|
||||
# windows/ungoogled-chromium/windows-disable-download-warning-prompt.patch
|
||||
# windows/ungoogled-chromium/windows-fix-rc-terminating-error.patch
|
||||
|
||||
Reference in New Issue
Block a user