layout/xul/grid/nsGridRowLeafFrame.h

Fri, 16 Jan 2015 18:13:44 +0100

author
Michael Schloh von Bennewitz <michael@schloh.com>
date
Fri, 16 Jan 2015 18:13:44 +0100
branch
TOR_BUG_9701
changeset 14
925c144e1f1f
permissions
-rw-r--r--

Integrate suggestion from review to improve consistency with existing code.

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
michael@0 6 /**
michael@0 7
michael@0 8 Eric D Vaughan
michael@0 9 A frame that can have multiple children. Only one child may be displayed at one time. So the
michael@0 10 can be flipped though like a deck of cards.
michael@0 11
michael@0 12 **/
michael@0 13
michael@0 14 #ifndef nsGridRowLeafFrame_h___
michael@0 15 #define nsGridRowLeafFrame_h___
michael@0 16
michael@0 17 #include "mozilla/Attributes.h"
michael@0 18 #include "nsBoxFrame.h"
michael@0 19
michael@0 20 /**
michael@0 21 * A frame representing a grid row (or column). Grid row (and column)
michael@0 22 * elements are the children of row group (or column group) elements,
michael@0 23 * and their children are placed one to a cell.
michael@0 24 */
michael@0 25 // XXXldb This needs a better name that indicates that it's for any grid
michael@0 26 // row.
michael@0 27 class nsGridRowLeafFrame : public nsBoxFrame
michael@0 28 {
michael@0 29 public:
michael@0 30 NS_DECL_FRAMEARENA_HELPERS
michael@0 31
michael@0 32 friend nsIFrame* NS_NewGridRowLeafFrame(nsIPresShell* aPresShell,
michael@0 33 nsStyleContext* aContext);
michael@0 34
michael@0 35 #ifdef DEBUG_FRAME_DUMP
michael@0 36 virtual nsresult GetFrameName(nsAString& aResult) const MOZ_OVERRIDE
michael@0 37 {
michael@0 38 return MakeFrameName(NS_LITERAL_STRING("nsGridRowLeaf"), aResult);
michael@0 39 }
michael@0 40 #endif
michael@0 41
michael@0 42 nsGridRowLeafFrame(nsIPresShell* aPresShell,
michael@0 43 nsStyleContext* aContext,
michael@0 44 bool aIsRoot,
michael@0 45 nsBoxLayout* aLayoutManager):
michael@0 46 nsBoxFrame(aPresShell, aContext, aIsRoot, aLayoutManager) {}
michael@0 47
michael@0 48 virtual nsresult GetBorderAndPadding(nsMargin& aBorderAndPadding) MOZ_OVERRIDE;
michael@0 49
michael@0 50 }; // class nsGridRowLeafFrame
michael@0 51
michael@0 52
michael@0 53
michael@0 54 #endif
michael@0 55

mercurial