Commit 9c1f87c5 authored by Sigurdur Asgeirsson's avatar Sigurdur Asgeirsson Committed by Commit Bot

Deprecate ScopedObserver.

It's replaced by base::ScopedObservation for observing a single source,
or base::ScopedMultiSourceObservation for observing multiple sources.

Bug: 1145565
Change-Id: Iadc2e3efee7860e1b17b86b077d4c6a2566b6a95
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2527541
Commit-Queue: Daniel Cheng <dcheng@chromium.org>
Reviewed-by: default avatarDaniel Cheng <dcheng@chromium.org>
Cr-Commit-Position: refs/heads/master@{#825580}
parent 99d8a0c6
......@@ -1081,6 +1081,16 @@ _BANNED_CPP_FUNCTIONS = (
r'^base/tracing/.*',
),
),
(
r'/\bScopedObserver',
(
'ScopedObserver is deprecated.',
'Please use base::ScopedObservation for observing a single source,',
'or base::ScopedMultiSourceObservation for observing multple sources',
),
False,
(),
),
)
# Format: Sequence of tuples containing:
......
......@@ -13,6 +13,10 @@
#include "base/ranges/algorithm.h"
#include "base/stl_util.h"
// This class is DEPRECATED. Instead please use one of:
// - base::ScopedObservation for observing a single source.
// - base::ScopedMultiSourceObservation for observing multiple sources.
//
// ScopedObserver is used to keep track of the set of sources an object has
// attached itself to as an observer. When ScopedObserver is destroyed it
// removes the object as an observer from all sources it has been added to.
......
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