mirror of
https://github.com/klzgrad/naiveproxy.git
synced 2024-11-25 06:46:09 +03:00
37 lines
1.2 KiB
Plaintext
37 lines
1.2 KiB
Plaintext
|
// Copyright 2016 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.
|
||
|
|
||
|
module blink.mojom;
|
||
|
|
||
|
import "url/mojo/url.mojom";
|
||
|
|
||
|
// Maps to blink::WebReferrerPolicy in
|
||
|
// src/third_party/WebKit/public/platform/WebReferrerPolicy.h.
|
||
|
//
|
||
|
// TODO(rockot): Update all WebReferrerPolicy consumers to use this type
|
||
|
// instead, and remove the typemap.
|
||
|
// Don't make backwards-incompatible changes to this definition!
|
||
|
// It's used in PageState serialization, so backwards incompatible changes
|
||
|
// would cause stored PageState objects to be un-parseable. Please contact the
|
||
|
// page state serialization owners before making such a change.
|
||
|
enum ReferrerPolicy {
|
||
|
ALWAYS,
|
||
|
DEFAULT,
|
||
|
NO_REFERRER_WHEN_DOWNGRADE,
|
||
|
NEVER,
|
||
|
ORIGIN,
|
||
|
ORIGIN_WHEN_CROSS_ORIGIN,
|
||
|
SAME_ORIGIN,
|
||
|
STRICT_ORIGIN,
|
||
|
NO_REFERRER_WHEN_DOWNGRADE_ORIGIN_WHEN_CROSS_ORIGIN,
|
||
|
};
|
||
|
|
||
|
// This struct holds a referrer URL, as well as the referrer policy to be
|
||
|
// applied to this URL. When passing around referrers that will eventually end
|
||
|
// up being used for URL requests, always use this struct.
|
||
|
struct Referrer {
|
||
|
url.mojom.Url url;
|
||
|
ReferrerPolicy policy;
|
||
|
};
|