content/base/public/mozFlushType.h

changeset 0
6474c204b198
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/content/base/public/mozFlushType.h	Wed Dec 31 06:09:35 2014 +0100
     1.3 @@ -0,0 +1,44 @@
     1.4 +/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
     1.5 +/* This Source Code Form is subject to the terms of the Mozilla Public
     1.6 + * License, v. 2.0. If a copy of the MPL was not distributed with this
     1.7 + * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
     1.8 +#ifndef mozFlushType_h___
     1.9 +#define mozFlushType_h___
    1.10 +
    1.11 +/**
    1.12 + * This is the enum used by nsIDocument::FlushPendingNotifications to
    1.13 + * decide what to flush.
    1.14 + *
    1.15 + * Please note that if you change these values, you should sync it with the
    1.16 + * flushTypeNames array inside PresShell::FlushPendingNotifications.
    1.17 + */
    1.18 +enum mozFlushType {
    1.19 +  Flush_None             = 0, /* Actually don't flush anything */
    1.20 +  Flush_Content          = 1, /* flush the content model construction */
    1.21 +  Flush_ContentAndNotify = 2, /* As above, plus flush the frame model
    1.22 +                                 construction and other nsIMutationObserver
    1.23 +                                 notifications. */
    1.24 +  Flush_Style            = 3, /* As above, plus flush style reresolution */
    1.25 +  Flush_Frames           = Flush_Style,
    1.26 +  Flush_InterruptibleLayout = 4, /* As above, plus flush reflow,
    1.27 +                                    but allow it to be interrupted (so
    1.28 +                                    an incomplete layout may result) */
    1.29 +  Flush_Layout           = 5, /* As above, but layout must run to
    1.30 +                                 completion */
    1.31 +  Flush_Display          = 6  /* As above, plus flush painting */
    1.32 +};
    1.33 +
    1.34 +namespace mozilla {
    1.35 +
    1.36 +struct ChangesToFlush {
    1.37 +  ChangesToFlush(mozFlushType aFlushType, bool aFlushAnimations)
    1.38 +    : mFlushType(aFlushType)
    1.39 +    , mFlushAnimations(aFlushAnimations)
    1.40 +  {}
    1.41 +
    1.42 +  mozFlushType mFlushType;
    1.43 +  bool mFlushAnimations;
    1.44 +};
    1.45 +
    1.46 +}
    1.47 +#endif /* mozFlushType_h___ */

mercurial