LCOV - code coverage report
Current view: top level - layout/xul - nsBoxLayout.cpp (source / functions) Hit Total Coverage
Test: output.info Lines: 7 36 19.4 %
Date: 2017-07-14 16:53:18 Functions: 5 13 38.5 %
Legend: Lines: hit not hit

          Line data    Source code
       1             : /* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
       2             : /* This Source Code Form is subject to the terms of the Mozilla Public
       3             :  * License, v. 2.0. If a copy of the MPL was not distributed with this
       4             :  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
       5             : 
       6             : //
       7             : // Eric Vaughan
       8             : // Netscape Communications
       9             : //
      10             : // See documentation in associated header file
      11             : //
      12             : 
      13             : #include "nsBox.h"
      14             : #include "nsCOMPtr.h"
      15             : #include "nsContainerFrame.h"
      16             : #include "nsBoxLayout.h"
      17             : 
      18             : void
      19        1073 : nsBoxLayout::AddBorderAndPadding(nsIFrame* aBox, nsSize& aSize)
      20             : {
      21        1073 :   nsBox::AddBorderAndPadding(aBox, aSize);
      22        1073 : }
      23             : 
      24             : void
      25        5582 : nsBoxLayout::AddMargin(nsIFrame* aBox, nsSize& aSize)
      26             : {
      27        5582 :   nsBox::AddMargin(aBox, aSize);
      28        5582 : }
      29             : 
      30             : void
      31           0 : nsBoxLayout::AddMargin(nsSize& aSize, const nsMargin& aMargin)
      32             : {
      33           0 :   nsBox::AddMargin(aSize, aMargin);
      34           0 : }
      35             : 
      36             : nsSize
      37           0 : nsBoxLayout::GetXULPrefSize(nsIFrame* aBox, nsBoxLayoutState& aBoxLayoutState)
      38             : {
      39           0 :   nsSize pref (0, 0);
      40           0 :   AddBorderAndPadding(aBox, pref);
      41             : 
      42           0 :   return pref;
      43             : }
      44             : 
      45             : nsSize
      46           0 : nsBoxLayout::GetXULMinSize(nsIFrame* aBox, nsBoxLayoutState& aBoxLayoutState)
      47             : {
      48           0 :   nsSize minSize (0,0);
      49           0 :   AddBorderAndPadding(aBox, minSize);
      50           0 :   return minSize;
      51             : }
      52             : 
      53             : nsSize
      54           0 : nsBoxLayout::GetXULMaxSize(nsIFrame* aBox, nsBoxLayoutState& aBoxLayoutState)
      55             : {
      56             :   //AddBorderAndPadding () never changes maxSize (NS_INTRINSICSIZE)
      57             :   //AddBorderAndPadding(aBox, maxSize);
      58           0 :   return nsSize (NS_INTRINSICSIZE,NS_INTRINSICSIZE);
      59             : }
      60             : 
      61             : 
      62             : nscoord
      63           0 : nsBoxLayout::GetAscent(nsIFrame* aBox, nsBoxLayoutState& aBoxLayoutState)
      64             : {
      65           0 :   return 0;
      66             : }
      67             : 
      68             : NS_IMETHODIMP
      69           0 : nsBoxLayout::XULLayout(nsIFrame* aBox, nsBoxLayoutState& aBoxLayoutState)
      70             : {
      71           0 :   return NS_OK;
      72             : }
      73             : 
      74             : void
      75           0 : nsBoxLayout::AddLargestSize(nsSize& aSize, const nsSize& aSize2)
      76             : {
      77           0 :   if (aSize2.width > aSize.width)
      78           0 :      aSize.width = aSize2.width;
      79             : 
      80           0 :   if (aSize2.height > aSize.height)
      81           0 :      aSize.height = aSize2.height;
      82           0 : }
      83             : 
      84             : void
      85           0 : nsBoxLayout::AddSmallestSize(nsSize& aSize, const nsSize& aSize2)
      86             : {
      87           0 :   if (aSize2.width < aSize.width)
      88           0 :      aSize.width = aSize2.width;
      89             : 
      90           0 :   if (aSize2.height < aSize.height)
      91           0 :      aSize.height = aSize2.height;
      92           0 : }
      93             : 
      94        2314 : NS_IMPL_ISUPPORTS(nsBoxLayout, nsBoxLayout)

Generated by: LCOV version 1.13