#include "chrome/browser/permissions/system/system_permission_settings.h"
#include <map>
#include <memory>
#include <utility>
#include "base/check.h"
#include "base/check_deref.h"
#include "chrome/browser/browser_process.h"
#include "chrome/browser/global_features.h"
#include "chrome/browser/permissions/system/platform_handle.h"
namespace system_permission_settings {
namespace {
PlatformHandle* instance_for_testing_ = …;
std::map<ContentSettingsType, bool>& GlobalTestingBlockOverrides() { … }
PlatformHandle* GetPlatformHandle() { … }
}
void SetInstanceForTesting(PlatformHandle* instance_for_testing) { … }
bool CanPrompt(ContentSettingsType type) { … }
bool IsDenied(ContentSettingsType type) { … }
bool IsAllowed(ContentSettingsType type) { … }
void OpenSystemSettings(content::WebContents* web_contents,
ContentSettingsType type) { … }
void Request(ContentSettingsType type,
SystemPermissionResponseCallback callback) { … }
std::unique_ptr<ScopedObservation> Observe(
SystemPermissionChangedCallback observer) { … }
ScopedSettingsForTesting::ScopedSettingsForTesting(ContentSettingsType type,
bool blocked)
: … { … }
ScopedSettingsForTesting::~ScopedSettingsForTesting() { … }
}