Commit 7415f4c7 authored by James Cook's avatar James Cook Committed by Commit Bot

Introduce platform_util_lacros.cc

platform_util contains utilities for showing a file in a file explorer
and opening a URL with an external protocol handler. These will need
to be plumbed from lacros to ash via crosapi.

Introduce a stub file for lacros.  Rename the existing _chromeos file
to _ash to match our naming scheme.

No functional changes.

Bug: 1139128, 1140585
Change-Id: I51d50f3687010f8397c8ea584cce21caccbe6982
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2488084
Auto-Submit: James Cook <jamescook@chromium.org>
Reviewed-by: default avatarDarin Fisher <darin@chromium.org>
Commit-Queue: James Cook <jamescook@chromium.org>
Cr-Commit-Position: refs/heads/master@{#819892}
parent ec79631b
......@@ -4276,7 +4276,7 @@ static_library("browser") {
"performance_manager/policies/userspace_swap_policy_chromeos.h",
"performance_manager/policies/working_set_trimmer_policy_chromeos.cc",
"performance_manager/policies/working_set_trimmer_policy_chromeos.h",
"platform_util_chromeos.cc",
"platform_util_ash.cc",
"policy/default_geolocation_policy_handler.cc",
"policy/default_geolocation_policy_handler.h",
"renderer_context_menu/quick_answers_menu_observer.cc",
......@@ -4418,8 +4418,7 @@ static_library("browser") {
]
}
# TODO(crbug.com/1052397): Rename chromeos_is_browser_only to is_lacros.
if (chromeos_is_browser_only) {
if (is_lacros) {
assert(enable_native_notifications)
sources += [
"feedback/show_feedback_page_lacros.cc",
......@@ -4443,6 +4442,7 @@ static_library("browser") {
"notifications/notification_platform_bridge_delegate.h",
"notifications/notification_platform_bridge_lacros.cc",
"notifications/notification_platform_bridge_lacros.h",
"platform_util_lacros.cc",
]
deps += [
"//chromeos/crosapi/mojom",
......@@ -4862,7 +4862,6 @@ static_library("browser") {
"first_run/upgrade_util_linux.cc",
"first_run/upgrade_util_linux.h",
"icon_loader_auralinux.cc",
"platform_util_linux.cc",
"shell_integration_linux.cc",
"shell_integration_linux.h",
"themes/theme_service_aura_linux.cc",
......@@ -4877,12 +4876,15 @@ static_library("browser") {
deps += [ "//components/dbus/thread_linux" ]
}
# TODO(crbug.com/1052397): Rename chromeos_is_browser_only to is_lacros.
if (enable_native_notifications && !chromeos_is_browser_only) {
sources += [
"notifications/notification_platform_bridge_linux.cc",
"notifications/notification_platform_bridge_linux.h",
]
if (!is_lacros) {
sources += [ "platform_util_linux.cc" ]
if (enable_native_notifications) {
sources += [
"notifications/notification_platform_bridge_linux.cc",
"notifications/notification_platform_bridge_linux.h",
]
}
}
if (use_x11) {
......
// Copyright 2020 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#include "chrome/browser/platform_util.h"
#include "base/notreached.h"
#include "chrome/browser/platform_util_internal.h"
namespace platform_util {
namespace internal {
void PlatformOpenVerifiedItem(const base::FilePath& path, OpenItemType type) {
NOTIMPLEMENTED();
}
} // namespace internal
void ShowItemInFolder(Profile* profile, const base::FilePath& full_path) {
// TODO(https://crbug.com/1139128): Add crosapi to show item in file manager.
NOTIMPLEMENTED();
}
void OpenExternal(Profile* profile, const GURL& url) {
// TODO(https://crbug.com/1140585): Add crosapi for opening links with
// external protocol handlers.
NOTIMPLEMENTED();
}
} // namespace platform_util
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment