Upstream has done changes around the use of vector of these values to rely on `unique_ptr`. This affects several places in our code base, including patching, and overriding. Chromium changes: https://chromium.googlesource.com/chromium/src/+/11f9810792ad5bad447d9d3aeae3c57a146b6bba commit 11f9810792ad5bad447d9d3aeae3c57a146b6bba Author: Florian Jacky <fjacky@google.com> Date: Tue May 20 08:57:18 2025 -0700 [PermissionOptions] Improve PermissionRequest lifecycle management - Require all permission requests to be be passed as unique_ptrs, and let PermissionRequestManager take ownership of the request object lifetime - Remove delete-only cleanup callbacks, and stop relying on cleanup callbacks for object lifetime management. - Get rid of std::vector<raw_ptr<permissions::PermissionRequest, VectorExperimental>> in PermissionRequestManager - Use weak ptrs where we can't use unique ptrs (e.g. bookkeeping in the PermissionRequestManager or on Clank) DD: https://docs.google.com/document/d/1eayA06lALdfwa3vnYLph-tOEoRvcrtvUjqoTxl03QlA/edit?tab=t.0#bookmark=id.oygla6y7rc8q Change-Id: I23e5d708e3501e63eec80c58c6f59781a69dbfe5 Bug: 394545912, 393053278 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6523566 Reviewed-by: Sylvain Defresne <sdefresne@chromium.org> Commit-Queue: Florian Jacky <fjacky@chromium.org> Reviewed-by: Theresa Sullivan <twellington@chromium.org> Reviewed-by: Andy Paicu <andypaicu@chromium.org> Cr-Commit-Position: refs/heads/main@{#1462828}
22 lines
714 B
C++
22 lines
714 B
C++
/* Copyright (c) 2023 The Brave Authors. All rights reserved.
|
|
* This Source Code Form is subject to the terms of the Mozilla Public
|
|
* License, v. 2.0. If a copy of the MPL was not distributed with this file,
|
|
* You can obtain one at https://mozilla.org/MPL/2.0/. */
|
|
|
|
#ifndef BRAVE_COMPONENTS_PERMISSIONS_PERMISSION_WIDEVINE_UTILS_H_
|
|
#define BRAVE_COMPONENTS_PERMISSIONS_PERMISSION_WIDEVINE_UTILS_H_
|
|
|
|
#include <memory>
|
|
#include <vector>
|
|
|
|
namespace permissions {
|
|
class PermissionRequest;
|
|
|
|
bool HasWidevinePermissionRequest(
|
|
const std::vector<std::unique_ptr<permissions::PermissionRequest>>&
|
|
requests);
|
|
|
|
} // namespace permissions
|
|
|
|
#endif // BRAVE_COMPONENTS_PERMISSIONS_PERMISSION_WIDEVINE_UTILS_H_
|