#include "chrome/browser/download/notification/multi_profile_download_notifier.h"
#include "base/memory/raw_ptr.h"
#include "base/not_fatal_until.h"
#include "base/ranges/algorithm.h"
#include "base/task/sequenced_task_runner.h"
#include "chrome/browser/profiles/profile_selections.h"
#include "components/download/public/common/simple_download_manager.h"
#include "content/public/browser/download_manager.h"
bool MultiProfileDownloadNotifier::Client::ShouldObserveProfile(
Profile* profile) { … }
MultiProfileDownloadNotifier::MultiProfileDownloadNotifier(
MultiProfileDownloadNotifier::Client* client,
bool wait_for_manager_initialization)
: … { … }
MultiProfileDownloadNotifier::~MultiProfileDownloadNotifier() = default;
void MultiProfileDownloadNotifier::AddProfile(Profile* profile) { … }
std::vector<raw_ptr<download::DownloadItem, VectorExperimental>>
MultiProfileDownloadNotifier::GetAllDownloads() { … }
download::DownloadItem* MultiProfileDownloadNotifier::GetDownloadByGuid(
const std::string& guid) { … }
void MultiProfileDownloadNotifier::OnOffTheRecordProfileCreated(
Profile* off_the_record) { … }
void MultiProfileDownloadNotifier::OnProfileWillBeDestroyed(Profile* profile) { … }
void MultiProfileDownloadNotifier::OnManagerInitialized(
content::DownloadManager* manager) { … }
void MultiProfileDownloadNotifier::OnManagerGoingDown(
content::DownloadManager* manager) { … }
void MultiProfileDownloadNotifier::OnDownloadCreated(
content::DownloadManager* manager,
download::DownloadItem* item) { … }
void MultiProfileDownloadNotifier::OnDownloadUpdated(
content::DownloadManager* manager,
download::DownloadItem* item) { … }
void MultiProfileDownloadNotifier::OnDownloadDestroyed(
content::DownloadManager* manager,
download::DownloadItem* item) { … }
bool MultiProfileDownloadNotifier::IsManagerReady(
content::DownloadManager* manager) { … }