summaryrefslogtreecommitdiffstats
path: root/dom/ipc/PBrowser.ipdl
diff options
context:
space:
mode:
Diffstat (limited to 'dom/ipc/PBrowser.ipdl')
-rw-r--r--dom/ipc/PBrowser.ipdl29
1 files changed, 27 insertions, 2 deletions
diff --git a/dom/ipc/PBrowser.ipdl b/dom/ipc/PBrowser.ipdl
index caef472ec2..372a81b139 100644
--- a/dom/ipc/PBrowser.ipdl
+++ b/dom/ipc/PBrowser.ipdl
@@ -87,7 +87,7 @@ using nsCursor from "nsIWidget.h";
using struct LookAndFeelInt from "mozilla/widget/WidgetMessageUtils.h";
using struct mozilla::DimensionRequest from "mozilla/widget/WidgetMessageUtils.h";
using class mozilla::dom::MessagePort from "mozilla/dom/MessagePort.h";
-using class mozilla::dom::ipc::StructuredCloneData from "mozilla/dom/ipc/StructuredCloneData.h";
+[MoveOnly=data] using class mozilla::dom::ipc::StructuredCloneData from "mozilla/dom/ipc/StructuredCloneData.h";
using mozilla::dom::MaybeDiscardedWindowContext from "mozilla/dom/WindowContext.h";
using mozilla::EventMessage from "mozilla/EventForwards.h";
using nsEventStatus from "mozilla/EventForwards.h";
@@ -960,8 +960,33 @@ child:
*
* @param aBrowsingContext the browsing context to print.
* @param aPrintData the serialized settings to print with
+ * @param aReturnStaticClone If the document in aBrowsingContext is not a static clone, whether
+ * to return the static document clone created.
+ * Note that if you call this with true but do not later call PrintClonedPage(),
+ * you must call DestroyPrintCache() to avoid leaks.
*/
- async Print(MaybeDiscardedBrowsingContext aBC, PrintData aPrintData);
+ async Print(MaybeDiscardedBrowsingContext aBC, PrintData aPrintData, bool aReturnStaticClone) returns(MaybeDiscardedBrowsingContext staticCloneBrowsingContext);
+
+ /**
+ * Tell the child to print the passed in static clone browsing context with the given settings.
+ *
+ * @param aBrowsingContext the browsing context to print.
+ * @param aPrintData the serialized settings to print with
+ * @param aStaticCloneBrowsingContext The static clone of aBrowsingContext that
+ * was created by an earlier call to Print(). This is the page that will actually be
+ * printed.
+ */
+ async PrintClonedPage(MaybeDiscardedBrowsingContext aBC, PrintData aPrintData, MaybeDiscardedBrowsingContext aStaticCloneBrowsingContext);
+
+ /**
+ * Destroy the static document clone for printing, if present. See Print() for details.
+ * For callers' simplicity, it is safe to call this method even if aStaticCloneBrowsingContext
+ * is null or has already been discarded.
+ *
+ * @param aStaticCloneBrowsingContext The static clone that was created by
+ * an earlier call to Print().
+ */
+ async DestroyPrintClone(MaybeDiscardedBrowsingContext aStaticCloneBrowsingContext);
/**
* Update the child with the tab's current top-level native window handle.