1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/gfx/src/nsMargin.h Wed Dec 31 06:09:35 2014 +0100 1.3 @@ -0,0 +1,34 @@ 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 + 1.9 +#ifndef NSMARGIN_H 1.10 +#define NSMARGIN_H 1.11 + 1.12 +#include "nsCoord.h" 1.13 +#include "nsPoint.h" 1.14 +#include "gfxCore.h" 1.15 +#include "mozilla/gfx/BaseMargin.h" 1.16 + 1.17 +struct nsMargin : public mozilla::gfx::BaseMargin<nscoord, nsMargin> { 1.18 + typedef mozilla::gfx::BaseMargin<nscoord, nsMargin> Super; 1.19 + 1.20 + // Constructors 1.21 + nsMargin() : Super() {} 1.22 + nsMargin(const nsMargin& aMargin) : Super(aMargin) {} 1.23 + nsMargin(nscoord aTop, nscoord aRight, nscoord aBottom, nscoord aLeft) 1.24 + : Super(aTop, aRight, aBottom, aLeft) {} 1.25 +}; 1.26 + 1.27 +struct nsIntMargin : public mozilla::gfx::BaseMargin<int32_t, nsIntMargin> { 1.28 + typedef mozilla::gfx::BaseMargin<int32_t, nsIntMargin> Super; 1.29 + 1.30 + // Constructors 1.31 + nsIntMargin() : Super() {} 1.32 + nsIntMargin(const nsIntMargin& aMargin) : Super(aMargin) {} 1.33 + nsIntMargin(int32_t aTop, int32_t aRight, int32_t aBottom, int32_t aLeft) 1.34 + : Super(aTop, aRight, aBottom, aLeft) {} 1.35 +}; 1.36 + 1.37 +#endif /* NSMARGIN_H */