1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/layout/xul/nsXULLabelFrame.h Wed Dec 31 06:09:35 2014 +0100 1.3 @@ -0,0 +1,57 @@ 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 +/* derived class of nsBlockFrame used for xul:label elements */ 1.10 + 1.11 +#ifndef nsXULLabelFrame_h_ 1.12 +#define nsXULLabelFrame_h_ 1.13 + 1.14 +#include "mozilla/Attributes.h" 1.15 +#include "nsBlockFrame.h" 1.16 + 1.17 +#ifndef MOZ_XUL 1.18 +#error "This file should not be included" 1.19 +#endif 1.20 + 1.21 +class nsXULLabelFrame : public nsBlockFrame 1.22 +{ 1.23 +public: 1.24 + NS_DECL_FRAMEARENA_HELPERS 1.25 + 1.26 + friend nsIFrame* NS_NewXULLabelFrame(nsIPresShell* aPresShell, 1.27 + nsStyleContext *aContext); 1.28 + 1.29 + // nsIFrame 1.30 + virtual void Init(nsIContent* aContent, 1.31 + nsIFrame* aParent, 1.32 + nsIFrame* aPrevInFlow) MOZ_OVERRIDE; 1.33 + 1.34 + virtual void DestroyFrom(nsIFrame* aDestructRoot) MOZ_OVERRIDE; 1.35 + 1.36 + virtual nsresult AttributeChanged(int32_t aNameSpaceID, 1.37 + nsIAtom* aAttribute, 1.38 + int32_t aModType) MOZ_OVERRIDE; 1.39 + 1.40 + /** 1.41 + * Get the "type" of the frame 1.42 + * 1.43 + * @see nsGkAtoms::XULLabelFrame 1.44 + */ 1.45 + virtual nsIAtom* GetType() const MOZ_OVERRIDE; 1.46 + 1.47 +#ifdef DEBUG_FRAME_DUMP 1.48 + virtual nsresult GetFrameName(nsAString& aResult) const MOZ_OVERRIDE; 1.49 +#endif 1.50 + 1.51 +protected: 1.52 + nsXULLabelFrame(nsStyleContext *aContext) : nsBlockFrame(aContext) {} 1.53 + 1.54 + nsresult RegUnregAccessKey(bool aDoReg); 1.55 +}; 1.56 + 1.57 +nsIFrame* 1.58 +NS_NewXULLabelFrame(nsIPresShell* aPresShell, nsStyleContext* aContext); 1.59 + 1.60 +#endif /* !defined(nsXULLabelFrame_h_) */