2014-02-26 23:45:29 -08:00
|
|
|
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
|
|
|
/* vim: set ts=2 et sw=2 tw=80: */
|
|
|
|
/* This Source Code is subject to the terms of the Mozilla Public License
|
|
|
|
* version 2.0 (the "License"). You can obtain a copy of the License at
|
|
|
|
* http://mozilla.org/MPL/2.0/. */
|
|
|
|
|
2014-05-12 14:16:05 -07:00
|
|
|
/* rendering object for CSS "display: grid | inline-grid" */
|
2014-02-26 23:45:29 -08:00
|
|
|
|
|
|
|
#ifndef nsGridContainerFrame_h___
|
|
|
|
#define nsGridContainerFrame_h___
|
|
|
|
|
|
|
|
#include "nsContainerFrame.h"
|
|
|
|
|
2014-05-12 14:16:05 -07:00
|
|
|
/**
|
|
|
|
* Factory function.
|
|
|
|
* @return a newly allocated nsGridContainerFrame (infallible)
|
|
|
|
*/
|
2014-05-24 15:20:40 -07:00
|
|
|
nsContainerFrame* NS_NewGridContainerFrame(nsIPresShell* aPresShell,
|
|
|
|
nsStyleContext* aContext);
|
2014-02-26 23:45:29 -08:00
|
|
|
|
2014-05-12 14:16:05 -07:00
|
|
|
class nsGridContainerFrame MOZ_FINAL : public nsContainerFrame
|
|
|
|
{
|
|
|
|
public:
|
2014-02-26 23:45:29 -08:00
|
|
|
NS_DECL_FRAMEARENA_HELPERS
|
|
|
|
NS_DECL_QUERYFRAME_TARGET(nsGridContainerFrame)
|
|
|
|
NS_DECL_QUERYFRAME
|
|
|
|
|
|
|
|
// nsIFrame overrides
|
2014-05-12 17:47:54 -07:00
|
|
|
void Reflow(nsPresContext* aPresContext,
|
|
|
|
nsHTMLReflowMetrics& aDesiredSize,
|
|
|
|
const nsHTMLReflowState& aReflowState,
|
|
|
|
nsReflowStatus& aStatus) MOZ_OVERRIDE;
|
2014-02-26 23:45:29 -08:00
|
|
|
virtual nsIAtom* GetType() const MOZ_OVERRIDE;
|
2014-05-12 14:16:05 -07:00
|
|
|
|
2014-02-26 23:45:29 -08:00
|
|
|
#ifdef DEBUG_FRAME_DUMP
|
|
|
|
virtual nsresult GetFrameName(nsAString& aResult) const MOZ_OVERRIDE;
|
|
|
|
#endif
|
|
|
|
|
|
|
|
protected:
|
2014-05-24 15:20:40 -07:00
|
|
|
friend nsContainerFrame* NS_NewGridContainerFrame(nsIPresShell* aPresShell,
|
|
|
|
nsStyleContext* aContext);
|
2014-05-12 14:16:05 -07:00
|
|
|
nsGridContainerFrame(nsStyleContext* aContext) : nsContainerFrame(aContext) {}
|
2014-05-19 16:57:00 -07:00
|
|
|
|
|
|
|
#ifdef DEBUG
|
|
|
|
void SanityCheckAnonymousGridItems() const;
|
|
|
|
#endif // DEBUG
|
2014-02-26 23:45:29 -08:00
|
|
|
};
|
|
|
|
|
|
|
|
#endif /* nsGridContainerFrame_h___ */
|