mirror of
https://github.com/klzgrad/naiveproxy.git
synced 2024-12-01 09:46:09 +03:00
45 lines
1.2 KiB
Plaintext
45 lines
1.2 KiB
Plaintext
|
// Copyright 2017 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 mojom;
|
||
|
|
||
|
import "url/mojo/url.mojom";
|
||
|
|
||
|
struct PreviewsStatus {
|
||
|
// The human readable description of the status that will be displayed on
|
||
|
// chrome://interventions-internals.
|
||
|
string description;
|
||
|
bool enabled;
|
||
|
};
|
||
|
|
||
|
struct MessageLog {
|
||
|
// The tye of event message (E.g. "Navigation").
|
||
|
string type;
|
||
|
|
||
|
// The human readable description of the event.
|
||
|
string description;
|
||
|
|
||
|
// The url that associated with the event.
|
||
|
url.mojom.Url url;
|
||
|
|
||
|
// The time when the event happened in millisecond since Unix epoch.
|
||
|
int64 time;
|
||
|
};
|
||
|
|
||
|
|
||
|
interface InterventionsInternalsPageHandler {
|
||
|
// Returns a map of previews modes statuses.
|
||
|
GetPreviewsEnabled() => (map<string, PreviewsStatus> statuses);
|
||
|
|
||
|
// Inject the client side page object.
|
||
|
SetClientPage(InterventionsInternalsPage page);
|
||
|
};
|
||
|
|
||
|
interface InterventionsInternalsPage {
|
||
|
// Pushes a new log message to the page. This is called by
|
||
|
// InterventionsInternalsPageHandler when it receives a new MessageLog, and
|
||
|
// publishes it on the javscript side.
|
||
|
LogNewMessage(MessageLog log);
|
||
|
};
|