author Jan Henning <>
Fri, 11 Jan 2019 19:50:24 +0000
changeset 453555 a99bf382e5f7a2e784f6aaad31e1ca7a502666f6
parent 449736 fd2587f34b52775d4f6b8816a4310485bef78575
permissions -rw-r--r--
Bug 1498812 - Part 11: Use Visual Viewport for storing scroll position in the PresState. r=botond,tnikkel Differential Revision:

/* -*- Mode: C++; c-basic-offset: 2; indent-tabs-mode: nil; tab-width: 8 -*- */
/* vim: set sw=2 ts=8 et tw=80 ft=cpp : */
/* 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 */

using mozilla::void_t from "ipc/IPCMessageUtils.h";
using nsPoint from "mozilla/GfxMessageUtils.h";
using refcounted class mozilla::dom::BlobImpl from "mozilla/dom/IPCBlobUtils.h";

namespace mozilla {

struct SelectContentData {
  uint32_t[] indices;
  nsString[] values;

struct CheckedContentData {
  bool checked;

union FileContentData {

union PresContentData {
  // We can need to serialize blobs in order to transmit this type, so we need
  // to handle that in a custom handler.

struct PresState {
  PresContentData contentData;
  // For frames where layout and visual viewport aren't one and the same thing,
  // scrollState will store the position of the *visual* viewport.
  nsPoint scrollState;
  bool allowScrollOriginDowngrade;
  float resolution;
  bool disabledSet;
  bool disabled;
  bool droppedDown;

} // namespace mozilla