Wed, 31 Dec 2014 07:16:47 +0100
Revert simplistic fix pending revisit of Mozilla integration attempt.
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 | Author: |
michael@0 | 9 | Eric D Vaughan |
michael@0 | 10 | |
michael@0 | 11 | **/ |
michael@0 | 12 | |
michael@0 | 13 | #ifndef nsGridCell_h___ |
michael@0 | 14 | #define nsGridCell_h___ |
michael@0 | 15 | |
michael@0 | 16 | class nsBoxLayoutState; |
michael@0 | 17 | struct nsSize; |
michael@0 | 18 | class nsIFrame; |
michael@0 | 19 | |
michael@0 | 20 | /* |
michael@0 | 21 | * Grid cell is what makes up the cellmap in the grid. Each GridCell contains |
michael@0 | 22 | * 2 pointers. One to the matching box in the columns and one to the matching box |
michael@0 | 23 | * in the rows. Remember that you can put content in both rows and columns. |
michael@0 | 24 | * When asked for preferred/min/max sizes it works like a stack and takes the |
michael@0 | 25 | * biggest sizes. |
michael@0 | 26 | */ |
michael@0 | 27 | |
michael@0 | 28 | class nsGridCell |
michael@0 | 29 | { |
michael@0 | 30 | public: |
michael@0 | 31 | nsGridCell(); |
michael@0 | 32 | virtual ~nsGridCell(); |
michael@0 | 33 | |
michael@0 | 34 | nsSize GetPrefSize(nsBoxLayoutState& aBoxLayoutState); |
michael@0 | 35 | nsSize GetMinSize(nsBoxLayoutState& aBoxLayoutState); |
michael@0 | 36 | nsSize GetMaxSize(nsBoxLayoutState& aBoxLayoutState); |
michael@0 | 37 | bool IsCollapsed(); |
michael@0 | 38 | |
michael@0 | 39 | // accessors |
michael@0 | 40 | nsIFrame* GetBoxInColumn() { return mBoxInColumn; } |
michael@0 | 41 | nsIFrame* GetBoxInRow() { return mBoxInRow; } |
michael@0 | 42 | void SetBoxInRow(nsIFrame* aBox) { mBoxInRow = aBox; } |
michael@0 | 43 | void SetBoxInColumn(nsIFrame* aBox) { mBoxInColumn = aBox; } |
michael@0 | 44 | |
michael@0 | 45 | private: |
michael@0 | 46 | nsIFrame* mBoxInColumn; |
michael@0 | 47 | nsIFrame* mBoxInRow; |
michael@0 | 48 | }; |
michael@0 | 49 | |
michael@0 | 50 | #endif |
michael@0 | 51 |