2009-09-09 22:00:14 +00:00
|
|
|
/* -*- Mode: C++; c-basic-offset: 4; indent-tabs-mode: nil; tab-width: 8 -*- */
|
2009-08-18 19:05:15 +00:00
|
|
|
/* vim: set sw=4 ts=8 et tw=80 ft=cpp : */
|
2012-05-21 11:12:37 +00:00
|
|
|
/* This Source Code Form is subject to the terms of the Mozilla Public
|
|
|
|
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
|
|
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
2009-07-11 06:33:10 +00:00
|
|
|
|
2012-08-02 06:02:29 +00:00
|
|
|
include protocol PBlob;
|
2012-09-13 16:37:14 +00:00
|
|
|
include protocol PBluetooth;
|
2010-07-19 18:33:33 +00:00
|
|
|
include protocol PBrowser;
|
2012-07-17 23:59:45 +00:00
|
|
|
include protocol PCompositor;
|
2010-11-24 14:15:03 +00:00
|
|
|
include protocol PCrashReporter;
|
2010-09-15 22:55:08 +00:00
|
|
|
include protocol PExternalHelperApp;
|
2012-06-19 23:14:39 +00:00
|
|
|
include protocol PDeviceStorageRequest;
|
2011-10-05 22:15:45 +00:00
|
|
|
include protocol PHal;
|
2012-08-29 12:24:48 +00:00
|
|
|
include protocol PImageBridge;
|
2012-07-14 11:24:20 +00:00
|
|
|
include protocol PIndexedDB;
|
2011-02-16 18:43:23 +00:00
|
|
|
include protocol PMemoryReportRequest;
|
2011-10-05 22:15:45 +00:00
|
|
|
include protocol PNecko;
|
2011-11-20 22:40:53 +00:00
|
|
|
include protocol PSms;
|
2013-04-03 22:13:17 +00:00
|
|
|
include protocol PSpeechSynthesis;
|
2011-10-05 22:15:45 +00:00
|
|
|
include protocol PStorage;
|
|
|
|
include protocol PTestShell;
|
2013-07-03 07:24:32 +00:00
|
|
|
include protocol PJavaScript;
|
2012-08-23 19:33:46 +00:00
|
|
|
include DOMTypes;
|
2013-07-10 22:05:39 +00:00
|
|
|
include JavaScriptTypes;
|
2013-01-17 20:17:33 +00:00
|
|
|
include InputStreamParams;
|
2013-07-10 17:07:50 +00:00
|
|
|
include PTabContext;
|
2012-08-23 19:33:46 +00:00
|
|
|
include URIParams;
|
2009-09-09 22:00:14 +00:00
|
|
|
|
2010-03-11 05:33:00 +00:00
|
|
|
include "mozilla/chrome/RegistryMessageUtils.h";
|
2013-01-02 21:21:37 +00:00
|
|
|
include "mozilla/dom/PermissionMessageUtils.h";
|
2011-06-08 19:56:31 +00:00
|
|
|
include "mozilla/dom/TabMessageUtils.h";
|
2013-04-26 00:53:26 +00:00
|
|
|
include "mozilla/HalTypes.h";
|
2012-11-27 20:43:52 +00:00
|
|
|
include "mozilla/layout/RenderFrameUtils.h";
|
|
|
|
include "mozilla/net/NeckoMessageUtils.h";
|
2010-09-21 04:16:37 +00:00
|
|
|
include "nsGeoPositionIPCSerialiser.h";
|
2013-07-26 19:28:31 +00:00
|
|
|
include "gfxPoint.h";
|
2010-09-21 04:16:37 +00:00
|
|
|
|
|
|
|
using GeoPosition;
|
2010-10-19 20:35:08 +00:00
|
|
|
using PrefTuple;
|
2010-09-21 04:16:37 +00:00
|
|
|
|
2010-03-11 05:33:00 +00:00
|
|
|
using ChromePackage;
|
|
|
|
using ResourceMapping;
|
|
|
|
using OverrideMapping;
|
2013-01-17 20:06:36 +00:00
|
|
|
using base::ChildPrivileges;
|
2010-10-09 18:07:38 +00:00
|
|
|
using IPC::Permission;
|
2013-01-02 21:21:37 +00:00
|
|
|
using IPC::Principal;
|
2010-11-19 01:15:23 +00:00
|
|
|
using mozilla::null_t;
|
2012-08-02 06:02:29 +00:00
|
|
|
using mozilla::void_t;
|
2012-12-06 03:01:58 +00:00
|
|
|
using mozilla::dom::AudioChannelType;
|
2013-07-10 17:07:51 +00:00
|
|
|
using mozilla::dom::BlobConstructorParams;
|
2011-06-08 19:56:31 +00:00
|
|
|
using mozilla::dom::NativeThreadId;
|
2013-04-26 00:53:26 +00:00
|
|
|
using mozilla::hal::ProcessPriority;
|
2010-11-24 18:22:40 +00:00
|
|
|
using gfxIntSize;
|
2009-09-09 22:00:14 +00:00
|
|
|
|
2009-07-11 06:33:10 +00:00
|
|
|
namespace mozilla {
|
2009-09-09 22:00:14 +00:00
|
|
|
namespace dom {
|
2009-07-11 06:33:10 +00:00
|
|
|
|
2011-01-13 04:04:42 +00:00
|
|
|
struct FontListEntry {
|
2011-09-23 11:15:36 +00:00
|
|
|
nsString familyName;
|
|
|
|
nsString faceName;
|
2011-01-13 04:04:42 +00:00
|
|
|
nsCString filepath;
|
2012-08-22 15:56:38 +00:00
|
|
|
uint16_t weight;
|
|
|
|
int16_t stretch;
|
|
|
|
uint8_t italic;
|
|
|
|
uint8_t index;
|
2011-01-13 04:04:42 +00:00
|
|
|
};
|
|
|
|
|
2013-01-25 19:05:24 +00:00
|
|
|
struct DeviceStorageFreeSpaceParams
|
2012-07-31 19:28:23 +00:00
|
|
|
{
|
2012-08-30 22:17:37 +00:00
|
|
|
nsString type;
|
2013-05-11 09:10:18 +00:00
|
|
|
nsString storageName;
|
2012-07-31 19:28:23 +00:00
|
|
|
};
|
|
|
|
|
2013-01-25 19:05:24 +00:00
|
|
|
struct DeviceStorageUsedSpaceParams
|
|
|
|
{
|
|
|
|
nsString type;
|
2013-05-11 09:10:18 +00:00
|
|
|
nsString storageName;
|
2013-01-25 19:05:24 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
struct DeviceStorageAvailableParams
|
|
|
|
{
|
|
|
|
nsString type;
|
2013-05-11 09:10:18 +00:00
|
|
|
nsString storageName;
|
2013-01-25 19:05:24 +00:00
|
|
|
};
|
|
|
|
|
2012-06-19 23:14:39 +00:00
|
|
|
struct DeviceStorageAddParams
|
|
|
|
{
|
2012-08-30 22:17:37 +00:00
|
|
|
nsString type;
|
2013-05-11 09:10:18 +00:00
|
|
|
nsString storageName;
|
2013-04-18 14:13:23 +00:00
|
|
|
nsString relpath;
|
2012-08-09 22:41:18 +00:00
|
|
|
PBlob blob;
|
2012-06-19 23:14:39 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
struct DeviceStorageGetParams
|
|
|
|
{
|
2012-08-30 22:17:37 +00:00
|
|
|
nsString type;
|
2013-05-11 09:10:18 +00:00
|
|
|
nsString storageName;
|
2013-04-18 14:13:23 +00:00
|
|
|
nsString rootDir;
|
|
|
|
nsString relpath;
|
2012-06-19 23:14:39 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
struct DeviceStorageDeleteParams
|
|
|
|
{
|
2012-08-30 22:17:37 +00:00
|
|
|
nsString type;
|
2013-05-11 09:10:18 +00:00
|
|
|
nsString storageName;
|
2013-04-18 14:13:23 +00:00
|
|
|
nsString relpath;
|
2012-06-19 23:14:39 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
struct DeviceStorageEnumerationParams
|
|
|
|
{
|
2012-08-30 22:17:37 +00:00
|
|
|
nsString type;
|
2013-05-11 09:10:18 +00:00
|
|
|
nsString storageName;
|
|
|
|
nsString rootdir;
|
2012-08-22 15:56:38 +00:00
|
|
|
uint64_t since;
|
2012-06-19 23:14:39 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
union DeviceStorageParams
|
|
|
|
{
|
|
|
|
DeviceStorageAddParams;
|
|
|
|
DeviceStorageGetParams;
|
|
|
|
DeviceStorageDeleteParams;
|
|
|
|
DeviceStorageEnumerationParams;
|
2013-01-25 19:05:24 +00:00
|
|
|
DeviceStorageFreeSpaceParams;
|
|
|
|
DeviceStorageUsedSpaceParams;
|
|
|
|
DeviceStorageAvailableParams;
|
2012-06-19 23:14:39 +00:00
|
|
|
};
|
2012-08-02 06:02:29 +00:00
|
|
|
|
2012-08-22 20:00:21 +00:00
|
|
|
union PrefValue {
|
|
|
|
nsCString;
|
|
|
|
int32_t;
|
|
|
|
bool;
|
|
|
|
};
|
|
|
|
|
|
|
|
union MaybePrefValue {
|
|
|
|
PrefValue;
|
|
|
|
null_t;
|
|
|
|
};
|
|
|
|
|
|
|
|
struct PrefSetting {
|
|
|
|
nsCString name;
|
|
|
|
MaybePrefValue defaultValue;
|
|
|
|
MaybePrefValue userValue;
|
|
|
|
};
|
|
|
|
|
2010-07-19 18:33:33 +00:00
|
|
|
rpc protocol PContent
|
2009-07-11 06:33:10 +00:00
|
|
|
{
|
2012-07-17 23:59:45 +00:00
|
|
|
parent opens PCompositor;
|
2012-08-29 12:24:48 +00:00
|
|
|
parent opens PImageBridge;
|
2012-07-17 23:59:45 +00:00
|
|
|
|
2012-08-02 06:02:29 +00:00
|
|
|
manages PBlob;
|
2012-09-13 16:37:14 +00:00
|
|
|
manages PBluetooth;
|
2010-07-19 18:33:33 +00:00
|
|
|
manages PBrowser;
|
2010-11-24 14:15:03 +00:00
|
|
|
manages PCrashReporter;
|
2012-06-19 23:14:39 +00:00
|
|
|
manages PDeviceStorageRequest;
|
2010-09-15 22:55:08 +00:00
|
|
|
manages PExternalHelperApp;
|
2011-10-05 22:15:45 +00:00
|
|
|
manages PHal;
|
2012-07-14 11:24:20 +00:00
|
|
|
manages PIndexedDB;
|
2011-02-16 18:43:23 +00:00
|
|
|
manages PMemoryReportRequest;
|
2011-10-05 22:15:45 +00:00
|
|
|
manages PNecko;
|
2011-11-20 22:40:53 +00:00
|
|
|
manages PSms;
|
2013-04-03 22:13:17 +00:00
|
|
|
manages PSpeechSynthesis;
|
2011-10-05 22:15:45 +00:00
|
|
|
manages PStorage;
|
|
|
|
manages PTestShell;
|
2013-07-03 07:24:32 +00:00
|
|
|
manages PJavaScript;
|
2009-08-25 23:07:22 +00:00
|
|
|
|
2012-06-12 22:01:25 +00:00
|
|
|
both:
|
|
|
|
// Depending on exactly how the new browser is being created, it might be
|
|
|
|
// created from either the child or parent process!
|
|
|
|
//
|
|
|
|
// The child creates the PBrowser as part of
|
Bug 802366 - The main event: Let a browser process inherit its app's id. r=bz,cjones
The main bug fixed here is that in half of our interfaces, we use "is browser frame/element" to mean "browser or app", and in the other half, we use it to mean "is browser not app".
There's a related, functional bug also fixed here, which is that a browser process doesn't inherit its parent's app-id. This causes problems e.g. for IndexedDB: If a browser inside an app uses IndexedDB, the DB should have the app's app-id.
I also modified Tab{Parent,Child} and nsFrameLoader to call "app" "ownOrContainingApp", to emphasize that we might have inherited the app from a parent process. I left nsIDocShell::appId alone, because changing that would have necessitated changing nsILoadGroup and therefore a /lot/ of users in Necko; it's also not clear it would have clarified anything in those cases.
2012-11-10 18:32:37 +00:00
|
|
|
// TabChild::BrowserFrameProvideWindow (which happens when the child's
|
|
|
|
// content calls window.open()), and the parent creates the PBrowser as part
|
2013-06-20 22:54:01 +00:00
|
|
|
// of ContentParent::CreateBrowserOrApp.
|
Bug 802366 - The main event: Let a browser process inherit its app's id. r=bz,cjones
The main bug fixed here is that in half of our interfaces, we use "is browser frame/element" to mean "browser or app", and in the other half, we use it to mean "is browser not app".
There's a related, functional bug also fixed here, which is that a browser process doesn't inherit its parent's app-id. This causes problems e.g. for IndexedDB: If a browser inside an app uses IndexedDB, the DB should have the app's app-id.
I also modified Tab{Parent,Child} and nsFrameLoader to call "app" "ownOrContainingApp", to emphasize that we might have inherited the app from a parent process. I left nsIDocShell::appId alone, because changing that would have necessitated changing nsILoadGroup and therefore a /lot/ of users in Necko; it's also not clear it would have clarified anything in those cases.
2012-11-10 18:32:37 +00:00
|
|
|
//
|
|
|
|
// When the parent constructs a PBrowser, the child trusts the app token it
|
|
|
|
// receives from the parent. In that case, context can be any of the
|
|
|
|
// IPCTabContext subtypes.
|
|
|
|
//
|
|
|
|
// When the child constructs a PBrowser, the parent doesn't trust the app
|
|
|
|
// token it receives from the child. In this case, context must have type
|
|
|
|
// PopupIPCTabContext. The browser created using a PopupIPCTabContext has
|
|
|
|
// the opener PBrowser's app-id and containing-app-id. The parent checks
|
|
|
|
// that if the opener is a browser element, the context is also for a
|
|
|
|
// browser element.
|
2012-08-09 02:58:06 +00:00
|
|
|
//
|
Bug 802366 - The main event: Let a browser process inherit its app's id. r=bz,cjones
The main bug fixed here is that in half of our interfaces, we use "is browser frame/element" to mean "browser or app", and in the other half, we use it to mean "is browser not app".
There's a related, functional bug also fixed here, which is that a browser process doesn't inherit its parent's app-id. This causes problems e.g. for IndexedDB: If a browser inside an app uses IndexedDB, the DB should have the app's app-id.
I also modified Tab{Parent,Child} and nsFrameLoader to call "app" "ownOrContainingApp", to emphasize that we might have inherited the app from a parent process. I left nsIDocShell::appId alone, because changing that would have necessitated changing nsILoadGroup and therefore a /lot/ of users in Necko; it's also not clear it would have clarified anything in those cases.
2012-11-10 18:32:37 +00:00
|
|
|
// This allows the parent to prevent a malicious child from escalating its
|
|
|
|
// privileges by requesting a PBrowser corresponding to a highly-privileged
|
|
|
|
// app; the child can only request privileges for an app which the child has
|
|
|
|
// access to (in the form of a TabChild).
|
|
|
|
async PBrowser(IPCTabContext context, uint32_t chromeFlags);
|
2009-08-25 23:07:22 +00:00
|
|
|
|
2012-08-02 06:02:29 +00:00
|
|
|
async PBlob(BlobConstructorParams params);
|
|
|
|
|
2013-07-10 22:05:39 +00:00
|
|
|
async PJavaScript();
|
2013-07-03 07:24:32 +00:00
|
|
|
|
2012-06-12 22:01:25 +00:00
|
|
|
child:
|
2013-01-17 20:06:36 +00:00
|
|
|
/**
|
|
|
|
* Update OS process privileges to |privs|. Can usually only be
|
|
|
|
* performed zero or one times. The child will abnormally exit if
|
|
|
|
* the privilege update fails.
|
|
|
|
*/
|
|
|
|
async SetProcessPrivileges(ChildPrivileges privs);
|
|
|
|
|
2011-02-16 18:43:23 +00:00
|
|
|
PMemoryReportRequest();
|
|
|
|
|
2012-12-06 03:01:58 +00:00
|
|
|
/**
|
|
|
|
* Notify the AudioChannelService in the child processes.
|
|
|
|
*/
|
|
|
|
async AudioChannelNotify();
|
|
|
|
|
2012-10-03 01:19:11 +00:00
|
|
|
/**
|
2013-03-28 03:31:26 +00:00
|
|
|
* Do a memory info dump to a file in our temp directory.
|
2012-10-03 01:19:11 +00:00
|
|
|
*
|
|
|
|
* For documentation on the args, see
|
2013-03-28 03:31:26 +00:00
|
|
|
* MemoryInfoDumper::dumpMemoryInfoToTempDir.
|
2012-10-03 01:19:11 +00:00
|
|
|
*/
|
2013-03-28 03:31:26 +00:00
|
|
|
async DumpMemoryInfoToTempDir(nsString identifier,
|
2012-10-03 01:19:11 +00:00
|
|
|
bool minimizeMemoryUsage,
|
|
|
|
bool dumpChildProcesses);
|
|
|
|
|
2012-10-16 02:12:14 +00:00
|
|
|
/**
|
|
|
|
* Dump this process's GC and CC logs.
|
|
|
|
*
|
|
|
|
* For documentation on the args, see
|
2012-10-16 02:12:14 +00:00
|
|
|
* MemoryInfoDumper::dumpGCAndCCLogsToFile.
|
2012-10-16 02:12:14 +00:00
|
|
|
*/
|
|
|
|
async DumpGCAndCCLogsToFile(nsString identifier,
|
2013-07-08 17:20:39 +00:00
|
|
|
bool dumpAllTraces,
|
2012-10-16 02:12:14 +00:00
|
|
|
bool dumpChildProcesses);
|
|
|
|
|
2009-09-09 22:00:14 +00:00
|
|
|
PTestShell();
|
2009-08-25 23:07:22 +00:00
|
|
|
|
2010-03-11 05:33:00 +00:00
|
|
|
RegisterChrome(ChromePackage[] packages, ResourceMapping[] resources,
|
2011-01-11 21:34:31 +00:00
|
|
|
OverrideMapping[] overrides, nsCString locale);
|
2010-03-11 05:33:00 +00:00
|
|
|
|
2011-09-29 06:19:26 +00:00
|
|
|
async SetOffline(bool offline);
|
2010-05-11 12:44:12 +00:00
|
|
|
|
2012-08-23 19:33:46 +00:00
|
|
|
async NotifyVisited(URIParams uri);
|
2010-07-02 15:50:41 +00:00
|
|
|
|
2012-08-22 20:00:21 +00:00
|
|
|
PreferenceUpdate(PrefSetting pref);
|
2010-05-26 00:13:47 +00:00
|
|
|
|
2010-09-15 16:44:57 +00:00
|
|
|
NotifyAlertsObserver(nsCString topic, nsString data);
|
|
|
|
|
2010-09-21 04:16:37 +00:00
|
|
|
GeolocationUpdate(GeoPosition somewhere);
|
|
|
|
|
2010-10-09 18:07:38 +00:00
|
|
|
// nsIPermissionManager messages
|
|
|
|
AddPermission(Permission permission);
|
|
|
|
|
2010-11-24 18:22:40 +00:00
|
|
|
ScreenSizeChanged(gfxIntSize size);
|
|
|
|
|
2010-12-11 22:36:08 +00:00
|
|
|
FlushMemory(nsString reason);
|
|
|
|
|
2011-09-13 17:53:51 +00:00
|
|
|
GarbageCollect();
|
|
|
|
CycleCollect();
|
|
|
|
|
2011-07-21 04:37:32 +00:00
|
|
|
/**
|
|
|
|
* Start accessibility engine in content process.
|
|
|
|
*/
|
|
|
|
ActivateA11y();
|
|
|
|
|
2013-04-22 16:41:59 +00:00
|
|
|
AppInfo(nsCString version, nsCString buildID, nsCString name, nsCString UAName);
|
2011-10-04 20:31:00 +00:00
|
|
|
|
2012-04-20 00:13:20 +00:00
|
|
|
// Notify child that last-pb-context-exited notification was observed
|
|
|
|
LastPrivateDocShellDestroyed();
|
|
|
|
|
2013-05-11 09:10:18 +00:00
|
|
|
FilePathUpdate(nsString storageType, nsString storageName, nsString filepath,
|
|
|
|
nsCString reasons);
|
2012-08-02 06:32:04 +00:00
|
|
|
|
2012-12-15 00:01:34 +00:00
|
|
|
FileSystemUpdate(nsString fsName, nsString mountPoint, int32_t fsState,
|
2013-08-22 23:12:25 +00:00
|
|
|
int32_t mountGeneration, bool isMediaPresent,
|
|
|
|
bool isSharing);
|
2012-08-03 23:48:58 +00:00
|
|
|
|
2013-04-26 00:53:26 +00:00
|
|
|
NotifyProcessPriorityChanged(ProcessPriority priority);
|
|
|
|
MinimizeMemoryUsage();
|
|
|
|
CancelMinimizeMemoryUsage();
|
|
|
|
|
2013-08-27 17:10:39 +00:00
|
|
|
/**
|
|
|
|
* Used to manage nsIStyleSheetService across processes.
|
|
|
|
*/
|
|
|
|
async LoadAndRegisterSheet(URIParams uri, uint32_t type);
|
|
|
|
async UnregisterSheet(URIParams uri, uint32_t type);
|
|
|
|
|
2009-08-18 19:05:15 +00:00
|
|
|
parent:
|
2012-09-05 00:36:16 +00:00
|
|
|
/**
|
|
|
|
* Tell the content process some attributes of itself. This is
|
|
|
|
* among the first information queried by content processes after
|
|
|
|
* startup. (The message is sync to allow the content process to
|
|
|
|
* control when it receives the information.)
|
|
|
|
*
|
|
|
|
* |id| is a unique ID among all subprocesses. When |isForApp &&
|
|
|
|
* isForBrowser|, we're loading <browser> for an app. When
|
|
|
|
* |isForBrowser|, we're loading <browser>. When |!isForApp &&
|
|
|
|
* !isForBrowser|, we're probably loading <xul:browser remote>.
|
|
|
|
*/
|
|
|
|
sync GetProcessAttributes()
|
2013-01-26 21:14:01 +00:00
|
|
|
returns (uint64_t id, bool isForApp, bool isForBrowser);
|
2012-11-08 21:09:39 +00:00
|
|
|
sync GetXPCOMProcessAttributes()
|
|
|
|
returns (bool isOffline);
|
2012-09-05 00:36:16 +00:00
|
|
|
|
2012-06-19 23:14:39 +00:00
|
|
|
PDeviceStorageRequest(DeviceStorageParams params);
|
|
|
|
|
2012-08-22 15:56:38 +00:00
|
|
|
sync PCrashReporter(NativeThreadId tid, uint32_t processType);
|
2011-06-08 19:56:31 +00:00
|
|
|
|
2013-02-27 20:31:19 +00:00
|
|
|
sync GetRandomValues(uint32_t length)
|
|
|
|
returns (uint8_t[] randomValues);
|
|
|
|
|
2011-10-05 22:15:45 +00:00
|
|
|
PHal();
|
|
|
|
|
2012-07-14 11:24:20 +00:00
|
|
|
PIndexedDB();
|
|
|
|
|
2011-10-05 22:15:45 +00:00
|
|
|
PNecko();
|
2011-11-20 22:40:53 +00:00
|
|
|
|
|
|
|
PSms();
|
2013-04-03 22:13:17 +00:00
|
|
|
|
|
|
|
PSpeechSynthesis();
|
2013-04-10 12:18:38 +00:00
|
|
|
|
2013-04-15 12:38:48 +00:00
|
|
|
PStorage();
|
2011-10-05 22:15:45 +00:00
|
|
|
|
2012-09-13 16:37:14 +00:00
|
|
|
PBluetooth();
|
|
|
|
|
2010-07-15 14:04:25 +00:00
|
|
|
// Services remoting
|
|
|
|
|
2012-08-23 19:33:46 +00:00
|
|
|
async StartVisitedQuery(URIParams uri);
|
|
|
|
async VisitURI(URIParams uri, OptionalURIParams referrer, uint32_t flags);
|
|
|
|
async SetURITitle(URIParams uri, nsString title);
|
2010-10-20 15:19:24 +00:00
|
|
|
|
|
|
|
// filepicker remoting
|
2012-08-22 15:56:38 +00:00
|
|
|
sync ShowFilePicker(int16_t mode, int16_t selectedType, bool addToRecentDocs,
|
2010-10-20 15:19:24 +00:00
|
|
|
nsString title, nsString defaultFile, nsString defaultExtension,
|
|
|
|
nsString[] filters, nsString[] filterNames)
|
2012-08-22 15:56:38 +00:00
|
|
|
returns (nsString[] files, int16_t retValue, nsresult result);
|
2010-07-02 15:50:41 +00:00
|
|
|
|
2012-08-23 19:33:46 +00:00
|
|
|
async LoadURIExternal(URIParams uri);
|
2010-08-10 17:14:45 +00:00
|
|
|
|
2010-10-19 20:35:08 +00:00
|
|
|
// PrefService message
|
2012-08-22 20:00:21 +00:00
|
|
|
sync ReadPrefsArray() returns (PrefSetting[] prefs);
|
2010-07-15 14:04:25 +00:00
|
|
|
|
2011-01-13 04:04:42 +00:00
|
|
|
sync ReadFontList() returns (FontListEntry[] retValue);
|
|
|
|
|
2013-07-10 22:05:39 +00:00
|
|
|
sync SyncMessage(nsString aMessage, ClonedMessageData aData, CpowEntry[] aCpows)
|
2010-08-31 18:58:35 +00:00
|
|
|
returns (nsString[] retval);
|
|
|
|
|
2013-03-18 13:24:53 +00:00
|
|
|
ShowAlertNotification(nsString imageUrl,
|
|
|
|
nsString title,
|
|
|
|
nsString text,
|
2011-09-29 06:19:26 +00:00
|
|
|
bool textClickable,
|
2010-09-15 16:44:57 +00:00
|
|
|
nsString cookie,
|
2013-03-18 13:24:53 +00:00
|
|
|
nsString name,
|
|
|
|
nsString bidi,
|
|
|
|
nsString lang);
|
|
|
|
|
|
|
|
CloseAlert(nsString name);
|
2010-09-15 16:44:57 +00:00
|
|
|
|
2012-08-23 19:33:46 +00:00
|
|
|
PExternalHelperApp(OptionalURIParams uri, nsCString aMimeContentType,
|
2010-09-15 22:55:08 +00:00
|
|
|
nsCString aContentDisposition, bool aForceSave,
|
2012-08-23 19:33:46 +00:00
|
|
|
int64_t aContentLength, OptionalURIParams aReferrer);
|
|
|
|
|
2013-02-26 17:27:31 +00:00
|
|
|
AddGeolocationListener(Principal principal, bool highAccuracy);
|
2010-11-05 17:43:13 +00:00
|
|
|
RemoveGeolocationListener();
|
2012-12-31 16:36:46 +00:00
|
|
|
SetGeolocationHigherAccuracy(bool enable);
|
2010-09-15 22:55:08 +00:00
|
|
|
|
2010-09-24 01:39:32 +00:00
|
|
|
ConsoleMessage(nsString message);
|
|
|
|
ScriptError(nsString message, nsString sourceName, nsString sourceLine,
|
2012-08-22 15:56:38 +00:00
|
|
|
uint32_t lineNumber, uint32_t colNumber, uint32_t flags,
|
2010-09-24 01:39:32 +00:00
|
|
|
nsCString category);
|
|
|
|
|
2010-10-09 18:07:38 +00:00
|
|
|
// nsIPermissionManager messages
|
|
|
|
sync ReadPermissions() returns (Permission[] permissions);
|
|
|
|
|
2011-03-01 05:36:43 +00:00
|
|
|
// These clipboard methods are only really used on Android since
|
|
|
|
// the clipboard is not available in the content process.
|
2012-08-22 15:56:38 +00:00
|
|
|
SetClipboardText(nsString text, bool isPrivateData, int32_t whichClipboard);
|
|
|
|
sync GetClipboardText(int32_t whichClipboard)
|
2011-03-01 05:36:43 +00:00
|
|
|
returns (nsString text);
|
|
|
|
EmptyClipboard();
|
|
|
|
sync ClipboardHasText()
|
2011-09-29 06:19:26 +00:00
|
|
|
returns (bool hasText);
|
2011-03-01 05:36:43 +00:00
|
|
|
|
2012-08-22 15:56:38 +00:00
|
|
|
sync GetSystemColors(uint32_t colorsCount)
|
|
|
|
returns (uint32_t[] colors);
|
2011-03-30 18:04:41 +00:00
|
|
|
|
2012-08-22 15:56:38 +00:00
|
|
|
sync GetIconForExtension(nsCString aFileExt, uint32_t aIconSize)
|
|
|
|
returns (uint8_t[] bits);
|
2011-06-13 21:02:13 +00:00
|
|
|
|
2011-07-27 01:14:52 +00:00
|
|
|
sync GetShowPasswordSetting()
|
2011-09-29 06:19:26 +00:00
|
|
|
returns (bool showPassword);
|
2011-07-27 01:14:52 +00:00
|
|
|
|
2012-04-20 00:13:20 +00:00
|
|
|
// Notify the parent of the presence or absence of private docshells
|
|
|
|
PrivateDocShellsExist(bool aExist);
|
|
|
|
|
2012-10-09 04:46:19 +00:00
|
|
|
// Tell the parent that the child has gone idle for the first time
|
|
|
|
async FirstIdle();
|
|
|
|
|
2012-12-06 03:01:58 +00:00
|
|
|
// Get Muted from the main AudioChannelService.
|
2013-01-09 07:18:16 +00:00
|
|
|
sync AudioChannelGetMuted(AudioChannelType aType, bool aElementHidden,
|
|
|
|
bool aElementWasHidden)
|
2012-12-06 03:01:58 +00:00
|
|
|
returns (bool value);
|
|
|
|
|
2013-01-09 07:18:16 +00:00
|
|
|
sync AudioChannelRegisterType(AudioChannelType aType);
|
|
|
|
sync AudioChannelUnregisterType(AudioChannelType aType,
|
|
|
|
bool aElementHidden);
|
|
|
|
|
|
|
|
async AudioChannelChangedNotification();
|
2012-12-06 03:01:58 +00:00
|
|
|
|
2013-01-09 15:03:28 +00:00
|
|
|
async FilePathUpdateNotify(nsString aType,
|
2013-05-11 09:10:18 +00:00
|
|
|
nsString aStorageName,
|
2013-01-09 15:03:28 +00:00
|
|
|
nsString aFilepath,
|
|
|
|
nsCString aReason);
|
2012-12-15 00:01:34 +00:00
|
|
|
// get nsIVolumeService to broadcast volume information
|
|
|
|
async BroadcastVolume(nsString volumeName);
|
|
|
|
|
2013-01-25 02:45:36 +00:00
|
|
|
async RecordingDeviceEvents(nsString recordingStatus);
|
|
|
|
|
2013-02-14 20:41:30 +00:00
|
|
|
// Notify the parent that the child has finished handling a system message.
|
|
|
|
async SystemMessageHandled();
|
|
|
|
|
2013-07-09 06:37:47 +00:00
|
|
|
// called by the child (test code only) to propagate volume changes to the parent
|
|
|
|
async CreateFakeVolume(nsString fsName, nsString mountPoint);
|
|
|
|
async SetFakeVolumeState(nsString fsName, int32_t fsState);
|
|
|
|
|
2013-08-16 17:59:31 +00:00
|
|
|
sync KeywordToURI(nsCString keyword)
|
|
|
|
returns (OptionalInputStreamParams postData, OptionalURIParams uri);
|
|
|
|
|
2010-08-31 18:58:35 +00:00
|
|
|
both:
|
2013-07-10 22:05:39 +00:00
|
|
|
AsyncMessage(nsString aMessage, ClonedMessageData aData, CpowEntry[] aCpows);
|
2009-07-11 06:33:10 +00:00
|
|
|
};
|
|
|
|
|
2009-09-09 22:00:14 +00:00
|
|
|
}
|
2012-08-29 12:24:48 +00:00
|
|
|
}
|