layout/base/nsIFrameTraversal.h

Wed, 31 Dec 2014 06:09:35 +0100

author
Michael Schloh von Bennewitz <michael@schloh.com>
date
Wed, 31 Dec 2014 06:09:35 +0100
changeset 0
6474c204b198
permissions
-rw-r--r--

Cloned upstream origin tor-browser at tor-browser-31.3.0esr-4.5-1-build1
revision ID fc1c9ff7c1b2defdbc039f12214767608f46423f for hacking purpose.

michael@0 1 /* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
michael@0 2 /* This Source Code Form is subject to the terms of the Mozilla Public
michael@0 3 * License, v. 2.0. If a copy of the MPL was not distributed with this
michael@0 4 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
michael@0 5 #ifndef NSIFRAMETRAVERSAL_H
michael@0 6 #define NSIFRAMETRAVERSAL_H
michael@0 7
michael@0 8 #include "nsISupports.h"
michael@0 9 #include "nsIFrame.h"
michael@0 10
michael@0 11 #define NS_IFRAMEENUMERATOR_IID \
michael@0 12 { 0x7c633f5d, 0x91eb, 0x494e, \
michael@0 13 { 0xa1, 0x40, 0x17, 0x46, 0x17, 0x4c, 0x23, 0xd3 } }
michael@0 14
michael@0 15 class nsIFrameEnumerator : public nsISupports
michael@0 16 {
michael@0 17 public:
michael@0 18 NS_DECLARE_STATIC_IID_ACCESSOR(NS_IFRAMEENUMERATOR_IID)
michael@0 19
michael@0 20 virtual void First() = 0;
michael@0 21 virtual void Next() = 0;
michael@0 22 virtual nsIFrame* CurrentItem() = 0;
michael@0 23 virtual bool IsDone() = 0;
michael@0 24
michael@0 25 virtual void Last() = 0;
michael@0 26 virtual void Prev() = 0;
michael@0 27 };
michael@0 28
michael@0 29 NS_DEFINE_STATIC_IID_ACCESSOR(nsIFrameEnumerator, NS_IFRAMEENUMERATOR_IID)
michael@0 30
michael@0 31 enum nsIteratorType {
michael@0 32 eLeaf,
michael@0 33 ePreOrder,
michael@0 34 ePostOrder
michael@0 35 };
michael@0 36
michael@0 37 // {9d469828-9bf2-4151-a385-05f30219221b}
michael@0 38 #define NS_IFRAMETRAVERSAL_IID \
michael@0 39 { 0x9d469828, 0x9bf2, 0x4151, { 0xa3, 0x85, 0x05, 0xf3, 0x02, 0x19, 0x22, 0x1b } }
michael@0 40
michael@0 41 class nsIFrameTraversal : public nsISupports
michael@0 42 {
michael@0 43 public:
michael@0 44 NS_DECLARE_STATIC_IID_ACCESSOR(NS_IFRAMETRAVERSAL_IID)
michael@0 45
michael@0 46 /**
michael@0 47 * Create a frame iterator with the specified properties.
michael@0 48 * @param aEnumerator [out] the created iterator
michael@0 49 * @param aPresContext [in]
michael@0 50 * @param aStart [in] the frame to start iterating from
michael@0 51 * @param aType [in] the type of the iterator: leaf, pre-order, or post-order
michael@0 52 * @param aVisual [in] whether the iterator should traverse frames in visual
michael@0 53 * bidi order
michael@0 54 * @param aLockInScrollView [in] whether to stop iterating when exiting a
michael@0 55 * scroll view
michael@0 56 * @param aFollowOOFs [in] whether the iterator should follow out-of-flows.
michael@0 57 * If true, when reaching a placeholder frame while going down will get
michael@0 58 * the real frame. Going back up will go on past the placeholder,
michael@0 59 * so the placeholders are logically part of the frame tree.
michael@0 60 */
michael@0 61 NS_IMETHOD NewFrameTraversal(nsIFrameEnumerator **aEnumerator,
michael@0 62 nsPresContext* aPresContext,
michael@0 63 nsIFrame *aStart,
michael@0 64 int32_t aType,
michael@0 65 bool aVisual,
michael@0 66 bool aLockInScrollView,
michael@0 67 bool aFollowOOFs) = 0;
michael@0 68 };
michael@0 69
michael@0 70 NS_DEFINE_STATIC_IID_ACCESSOR(nsIFrameTraversal, NS_IFRAMETRAVERSAL_IID)
michael@0 71
michael@0 72 #endif //NSIFRAMETRAVERSAL_H

mercurial