electron/shell/common/api/api.mojom
Shelley Vohr e46446e7e4
chore: bump chromium to e836cbe709f3cd703f233de8eb6cc6ec99b72c9d (#27475)
Co-authored-by: deepak1556 <hop2deep@gmail.com>
Co-authored-by: Jeremy Rose <nornagon@nornagon.net>
2021-02-09 12:16:21 -08:00

82 lines
2.3 KiB
Text

module electron.mojom;
import "mojo/public/mojom/base/string16.mojom";
import "ui/gfx/geometry/mojom/geometry.mojom";
import "third_party/blink/public/mojom/messaging/cloneable_message.mojom";
import "third_party/blink/public/mojom/messaging/transferable_message.mojom";
interface ElectronRenderer {
Message(
bool internal,
string channel,
blink.mojom.CloneableMessage arguments,
int32 sender_id);
ReceivePostMessage(string channel, blink.mojom.TransferableMessage message);
TakeHeapSnapshot(handle file) => (bool success);
};
interface ElectronAutofillAgent {
AcceptDataListSuggestion(mojo_base.mojom.String16 value);
};
interface ElectronAutofillDriver {
ShowAutofillPopup(gfx.mojom.RectF bounds, array<mojo_base.mojom.String16> values, array<mojo_base.mojom.String16> labels);
HideAutofillPopup();
};
struct DraggableRegion {
bool draggable;
gfx.mojom.Rect bounds;
};
interface ElectronBrowser {
// Emits an event on |channel| from the ipcMain JavaScript object in the main
// process.
Message(
bool internal,
string channel,
blink.mojom.CloneableMessage arguments);
// Emits an event on |channel| from the ipcMain JavaScript object in the main
// process, and returns the response.
Invoke(
bool internal,
string channel,
blink.mojom.CloneableMessage arguments) => (blink.mojom.CloneableMessage result);
// Informs underlying WebContents that first non-empty layout was performed
// by compositor.
OnFirstNonEmptyLayout();
ReceivePostMessage(string channel, blink.mojom.TransferableMessage message);
// Emits an event on |channel| from the ipcMain JavaScript object in the main
// process, and waits synchronously for a response.
[Sync]
MessageSync(
bool internal,
string channel,
blink.mojom.CloneableMessage arguments) => (blink.mojom.CloneableMessage result);
// Emits an event from the |ipcRenderer| JavaScript object in the target
// WebContents's main frame, specified by |web_contents_id|.
MessageTo(
bool internal,
int32 web_contents_id,
string channel,
blink.mojom.CloneableMessage arguments);
MessageHost(
string channel,
blink.mojom.CloneableMessage arguments);
UpdateDraggableRegions(
array<DraggableRegion> regions);
SetTemporaryZoomLevel(double zoom_level);
[Sync]
DoGetZoomLevel() => (double result);
};