Bug 1398520 part 4 - Rename nsFormControlFrame to nsCheckboxRadioFrame. r=dholbert

MozReview-Commit-ID: 9nwikVD1cd9

--HG--
rename : layout/forms/nsFormControlFrame.cpp => layout/forms/nsCheckboxRadioFrame.cpp
rename : layout/forms/nsFormControlFrame.h => layout/forms/nsCheckboxRadioFrame.h
This commit is contained in:
Mats Palmgren 2017-09-27 14:12:00 +02:00
Родитель 9d74c12453
Коммит d9d785d520
21 изменённых файлов: 88 добавлений и 88 удалений

Просмотреть файл

@ -3789,8 +3789,8 @@ nsCSSFrameConstructor::FindInputData(Element* aElement,
nsStyleContext* aStyleContext)
{
static const FrameConstructionDataByInt sInputData[] = {
SIMPLE_INT_CREATE(NS_FORM_INPUT_CHECKBOX, NS_NewFormControlFrame),
SIMPLE_INT_CREATE(NS_FORM_INPUT_RADIO, NS_NewFormControlFrame),
SIMPLE_INT_CREATE(NS_FORM_INPUT_CHECKBOX, NS_NewCheckboxRadioFrame),
SIMPLE_INT_CREATE(NS_FORM_INPUT_RADIO, NS_NewCheckboxRadioFrame),
SIMPLE_INT_CREATE(NS_FORM_INPUT_FILE, NS_NewFileControlFrame),
SIMPLE_INT_CHAIN(NS_FORM_INPUT_IMAGE,
nsCSSFrameConstructor::FindImgControlData),

Просмотреть файл

@ -8210,7 +8210,7 @@ nsLayoutUtils::FontSizeInflationInner(const nsIFrame *aFrame,
fType != LayoutFrameType::Inline &&
// ignore width on radios and checkboxes since we enlarge them and
// they have width/height in ua.css
fType != LayoutFrameType::FormControl) {
fType != LayoutFrameType::CheckboxRadio) {
// ruby annotations should have the same inflation as its
// grandparent, which is the ruby frame contains the annotation.
if (fType == LayoutFrameType::RubyText) {

Просмотреть файл

@ -20,12 +20,12 @@ EXPORTS += [
UNIFIED_SOURCES += [
'nsButtonFrameRenderer.cpp',
'nsCheckboxRadioFrame.cpp',
'nsColorControlFrame.cpp',
'nsComboboxControlFrame.cpp',
'nsDateTimeControlFrame.cpp',
'nsFieldSetFrame.cpp',
'nsFileControlFrame.cpp',
'nsFormControlFrame.cpp',
'nsGfxButtonControlFrame.cpp',
'nsHTMLButtonControlFrame.cpp',
'nsImageControlFrame.cpp',

Просмотреть файл

@ -3,7 +3,7 @@
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#include "nsFormControlFrame.h"
#include "nsCheckboxRadioFrame.h"
#include "nsGkAtoms.h"
#include "nsLayoutUtils.h"
@ -18,37 +18,37 @@ using namespace mozilla;
//#define FCF_NOISY
nsFormControlFrame*
NS_NewFormControlFrame(nsIPresShell* aPresShell, nsStyleContext* aContext)
nsCheckboxRadioFrame*
NS_NewCheckboxRadioFrame(nsIPresShell* aPresShell, nsStyleContext* aContext)
{
return new (aPresShell) nsFormControlFrame(aContext);
return new (aPresShell) nsCheckboxRadioFrame(aContext);
}
nsFormControlFrame::nsFormControlFrame(nsStyleContext* aContext)
nsCheckboxRadioFrame::nsCheckboxRadioFrame(nsStyleContext* aContext)
: nsAtomicContainerFrame(aContext, kClassID)
{
}
nsFormControlFrame::~nsFormControlFrame()
nsCheckboxRadioFrame::~nsCheckboxRadioFrame()
{
}
void
nsFormControlFrame::DestroyFrom(nsIFrame* aDestructRoot)
nsCheckboxRadioFrame::DestroyFrom(nsIFrame* aDestructRoot)
{
// Unregister the access key registered in reflow
nsFormControlFrame::RegUnRegAccessKey(static_cast<nsIFrame*>(this), false);
nsCheckboxRadioFrame::RegUnRegAccessKey(static_cast<nsIFrame*>(this), false);
nsAtomicContainerFrame::DestroyFrom(aDestructRoot);
}
NS_IMPL_FRAMEARENA_HELPERS(nsFormControlFrame)
NS_IMPL_FRAMEARENA_HELPERS(nsCheckboxRadioFrame)
NS_QUERYFRAME_HEAD(nsFormControlFrame)
NS_QUERYFRAME_HEAD(nsCheckboxRadioFrame)
NS_QUERYFRAME_ENTRY(nsIFormControlFrame)
NS_QUERYFRAME_TAIL_INHERITING(nsAtomicContainerFrame)
/* virtual */ nscoord
nsFormControlFrame::GetMinISize(gfxContext *aRenderingContext)
nsCheckboxRadioFrame::GetMinISize(gfxContext *aRenderingContext)
{
nscoord result;
DISPLAY_MIN_WIDTH(this, result);
@ -57,7 +57,7 @@ nsFormControlFrame::GetMinISize(gfxContext *aRenderingContext)
}
/* virtual */ nscoord
nsFormControlFrame::GetPrefISize(gfxContext *aRenderingContext)
nsCheckboxRadioFrame::GetPrefISize(gfxContext* aRenderingContext)
{
nscoord result;
DISPLAY_PREF_WIDTH(this, result);
@ -67,14 +67,14 @@ nsFormControlFrame::GetPrefISize(gfxContext *aRenderingContext)
/* virtual */
LogicalSize
nsFormControlFrame::ComputeAutoSize(gfxContext* aRC,
WritingMode aWM,
const LogicalSize& aCBSize,
nscoord aAvailableISize,
const LogicalSize& aMargin,
const LogicalSize& aBorder,
const LogicalSize& aPadding,
ComputeSizeFlags aFlags)
nsCheckboxRadioFrame::ComputeAutoSize(gfxContext* aRC,
WritingMode aWM,
const LogicalSize& aCBSize,
nscoord aAvailableISize,
const LogicalSize& aMargin,
const LogicalSize& aBorder,
const LogicalSize& aPadding,
ComputeSizeFlags aFlags)
{
LogicalSize size(aWM, 0, 0);
if (StyleDisplay()->mAppearance == NS_THEME_NONE) {
@ -90,7 +90,7 @@ nsFormControlFrame::ComputeAutoSize(gfxContext* aRC,
}
nscoord
nsFormControlFrame::GetLogicalBaseline(WritingMode aWritingMode) const
nsCheckboxRadioFrame::GetLogicalBaseline(WritingMode aWritingMode) const
{
NS_ASSERTION(!NS_SUBTREE_DIRTY(this),
"frame must not be dirty");
@ -114,17 +114,17 @@ nsFormControlFrame::GetLogicalBaseline(WritingMode aWritingMode) const
}
void
nsFormControlFrame::Reflow(nsPresContext* aPresContext,
ReflowOutput& aDesiredSize,
const ReflowInput& aReflowInput,
nsReflowStatus& aStatus)
nsCheckboxRadioFrame::Reflow(nsPresContext* aPresContext,
ReflowOutput& aDesiredSize,
const ReflowInput& aReflowInput,
nsReflowStatus& aStatus)
{
MarkInReflow();
DO_GLOBAL_REFLOW_COUNT("nsFormControlFrame");
DO_GLOBAL_REFLOW_COUNT("nsCheckboxRadioFrame");
DISPLAY_REFLOW(aPresContext, this, aReflowInput, aDesiredSize, aStatus);
MOZ_ASSERT(aStatus.IsEmpty(), "Caller should pass a fresh reflow status!");
NS_FRAME_TRACE(NS_FRAME_TRACE_CALLS,
("enter nsFormControlFrame::Reflow: aMaxSize=%d,%d",
("enter nsCheckboxRadioFrame::Reflow: aMaxSize=%d,%d",
aReflowInput.AvailableWidth(), aReflowInput.AvailableHeight()));
if (mState & NS_FRAME_FIRST_REFLOW) {
@ -141,7 +141,7 @@ nsFormControlFrame::Reflow(nsPresContext* aPresContext,
}
NS_FRAME_TRACE(NS_FRAME_TRACE_CALLS,
("exit nsFormControlFrame::Reflow: size=%d,%d",
("exit nsCheckboxRadioFrame::Reflow: size=%d,%d",
aDesiredSize.Width(), aDesiredSize.Height()));
NS_FRAME_SET_TRUNCATION(aStatus, aReflowInput, aDesiredSize);
@ -150,7 +150,7 @@ nsFormControlFrame::Reflow(nsPresContext* aPresContext,
}
nsresult
nsFormControlFrame::RegUnRegAccessKey(nsIFrame * aFrame, bool aDoReg)
nsCheckboxRadioFrame::RegUnRegAccessKey(nsIFrame* aFrame, bool aDoReg)
{
NS_ENSURE_ARG_POINTER(aFrame);
@ -175,14 +175,14 @@ nsFormControlFrame::RegUnRegAccessKey(nsIFrame * aFrame, bool aDoReg)
}
void
nsFormControlFrame::SetFocus(bool aOn, bool aRepaint)
nsCheckboxRadioFrame::SetFocus(bool aOn, bool aRepaint)
{
}
nsresult
nsFormControlFrame::HandleEvent(nsPresContext* aPresContext,
WidgetGUIEvent* aEvent,
nsEventStatus* aEventStatus)
nsCheckboxRadioFrame::HandleEvent(nsPresContext* aPresContext,
WidgetGUIEvent* aEvent,
nsEventStatus* aEventStatus)
{
// Check for user-input:none style
const nsStyleUserInterface* uiStyle = StyleUserInterface();
@ -194,7 +194,7 @@ nsFormControlFrame::HandleEvent(nsPresContext* aPresContext,
}
void
nsFormControlFrame::GetCurrentCheckState(bool *aState)
nsCheckboxRadioFrame::GetCurrentCheckState(bool* aState)
{
nsCOMPtr<nsIDOMHTMLInputElement> inputElement = do_QueryInterface(mContent);
if (inputElement) {
@ -203,14 +203,14 @@ nsFormControlFrame::GetCurrentCheckState(bool *aState)
}
nsresult
nsFormControlFrame::SetFormProperty(nsIAtom* aName, const nsAString& aValue)
nsCheckboxRadioFrame::SetFormProperty(nsIAtom* aName, const nsAString& aValue)
{
return NS_OK;
}
// static
nsRect
nsFormControlFrame::GetUsableScreenRect(nsPresContext* aPresContext)
nsCheckboxRadioFrame::GetUsableScreenRect(nsPresContext* aPresContext)
{
nsRect screen;

Просмотреть файл

@ -3,8 +3,8 @@
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#ifndef nsFormControlFrame_h___
#define nsFormControlFrame_h___
#ifndef nsCheckboxRadioFrame_h___
#define nsCheckboxRadioFrame_h___
#include "mozilla/Attributes.h"
#include "nsIFormControlFrame.h"
@ -12,18 +12,18 @@
#include "nsDisplayList.h"
/**
* nsFormControlFrame is used for radio buttons and checkboxes.
* nsCheckboxRadioFrame is used for radio buttons and checkboxes.
* It also has two static methods (RegUnRegAccessKey and
* GetScreenHeight) that are used by other form controls.
*/
class nsFormControlFrame final : public nsAtomicContainerFrame,
public nsIFormControlFrame
class nsCheckboxRadioFrame final : public nsAtomicContainerFrame,
public nsIFormControlFrame
{
public:
NS_DECL_QUERYFRAME
NS_DECL_FRAMEARENA_HELPERS(nsFormControlFrame)
NS_DECL_FRAMEARENA_HELPERS(nsCheckboxRadioFrame)
explicit nsFormControlFrame(nsStyleContext* aContext);
explicit nsCheckboxRadioFrame(nsStyleContext* aContext);
// nsIFrame replacements
virtual bool IsFrameOfType(uint32_t aFlags) const override
@ -34,7 +34,7 @@ public:
virtual void BuildDisplayList(nsDisplayListBuilder* aBuilder,
const nsDisplayListSet& aLists) override {
DO_GLOBAL_REFLOW_COUNT_DSP("nsFormControlFrame");
DO_GLOBAL_REFLOW_COUNT_DSP("nsCheckboxRadioFrame");
DisplayBorderBackgroundOutline(aBuilder, aLists);
}
@ -98,7 +98,7 @@ public:
protected:
virtual ~nsFormControlFrame();
virtual ~nsCheckboxRadioFrame();
static nscoord DefaultSize()
{

Просмотреть файл

@ -8,7 +8,7 @@
#include "nsContentCreatorFunctions.h"
#include "nsContentUtils.h"
#include "nsCSSPseudoElements.h"
#include "nsFormControlFrame.h"
#include "nsCheckboxRadioFrame.h"
#include "nsGkAtoms.h"
#include "nsIDOMNode.h"
#include "nsIFormControl.h"
@ -42,7 +42,7 @@ NS_QUERYFRAME_TAIL_INHERITING(nsHTMLButtonControlFrame)
void nsColorControlFrame::DestroyFrom(nsIFrame* aDestructRoot)
{
nsFormControlFrame::RegUnRegAccessKey(static_cast<nsIFrame*>(this), false);
nsCheckboxRadioFrame::RegUnRegAccessKey(static_cast<nsIFrame*>(this), false);
DestroyAnonymousContent(mColorContent.forget());
nsHTMLButtonControlFrame::DestroyFrom(aDestructRoot);
}

Просмотреть файл

@ -11,7 +11,7 @@
#include "mozilla/gfx/PathHelpers.h"
#include "nsCOMPtr.h"
#include "nsFocusManager.h"
#include "nsFormControlFrame.h"
#include "nsCheckboxRadioFrame.h"
#include "nsGkAtoms.h"
#include "nsCSSAnonBoxes.h"
#include "nsHTMLParts.h"
@ -595,7 +595,7 @@ nsComboboxControlFrame::GetAvailableDropdownSpace(WritingMode aWM,
*aBefore = 0;
*aAfter = 0;
nsRect screen = nsFormControlFrame::GetUsableScreenRect(PresContext());
nsRect screen = nsCheckboxRadioFrame::GetUsableScreenRect(PresContext());
nsSize containerSize = screen.Size();
LogicalRect logicalScreen(aWM, screen, containerSize);
if (mLastDropDownAfterScreenBCoord == nscoord_MIN) {
@ -1406,7 +1406,7 @@ nsComboboxControlFrame::DestroyFrom(nsIFrame* aDestructRoot)
// Revoke any pending RedisplayTextEvent
mRedisplayTextEvent.Revoke();
nsFormControlFrame::RegUnRegAccessKey(static_cast<nsIFrame*>(this), false);
nsCheckboxRadioFrame::RegUnRegAccessKey(static_cast<nsIFrame*>(this), false);
if (mDroppedDown) {
MOZ_ASSERT(mDropdownFrame, "mDroppedDown without frame");

Просмотреть файл

@ -11,7 +11,7 @@
#include "nsDateTimeControlFrame.h"
#include "nsContentUtils.h"
#include "nsFormControlFrame.h"
#include "nsCheckboxRadioFrame.h"
#include "nsGkAtoms.h"
#include "nsContentUtils.h"
#include "nsContentCreatorFunctions.h"

Просмотреть файл

@ -11,7 +11,7 @@
#include "nsGkAtoms.h"
#include "nsButtonFrameRenderer.h"
#include "nsCSSAnonBoxes.h"
#include "nsFormControlFrame.h"
#include "nsCheckboxRadioFrame.h"
#include "nsNameSpaceManager.h"
#include "nsDisplayList.h"
#include <algorithm>
@ -39,7 +39,7 @@ nsHTMLButtonControlFrame::~nsHTMLButtonControlFrame()
void
nsHTMLButtonControlFrame::DestroyFrom(nsIFrame* aDestructRoot)
{
nsFormControlFrame::RegUnRegAccessKey(static_cast<nsIFrame*>(this), false);
nsCheckboxRadioFrame::RegUnRegAccessKey(static_cast<nsIFrame*>(this), false);
nsContainerFrame::DestroyFrom(aDestructRoot);
}
@ -180,7 +180,7 @@ nsHTMLButtonControlFrame::Reflow(nsPresContext* aPresContext,
MOZ_ASSERT(aStatus.IsEmpty(), "Caller should pass a fresh reflow status!");
if (mState & NS_FRAME_FIRST_REFLOW) {
nsFormControlFrame::RegUnRegAccessKey(static_cast<nsIFrame*>(this), true);
nsCheckboxRadioFrame::RegUnRegAccessKey(static_cast<nsIFrame*>(this), true);
}
// Reflow the child

Просмотреть файл

@ -8,7 +8,7 @@
#include "nsPresContext.h"
#include "nsGkAtoms.h"
#include "nsStyleConsts.h"
#include "nsFormControlFrame.h"
#include "nsCheckboxRadioFrame.h"
#include "nsLayoutUtils.h"
#include "mozilla/MouseEvents.h"
#include "nsIContent.h"
@ -70,7 +70,7 @@ void
nsImageControlFrame::DestroyFrom(nsIFrame* aDestructRoot)
{
if (!GetPrevInFlow()) {
nsFormControlFrame::RegUnRegAccessKey(this, false);
nsCheckboxRadioFrame::RegUnRegAccessKey(this, false);
}
nsImageFrame::DestroyFrom(aDestructRoot);
}
@ -125,7 +125,7 @@ nsImageControlFrame::Reflow(nsPresContext* aPresContext,
DISPLAY_REFLOW(aPresContext, this, aReflowInput, aDesiredSize, aStatus);
MOZ_ASSERT(aStatus.IsEmpty(), "Caller should pass a fresh reflow status!");
if (!GetPrevInFlow() && (mState & NS_FRAME_FIRST_REFLOW)) {
nsFormControlFrame::RegUnRegAccessKey(this, true);
nsCheckboxRadioFrame::RegUnRegAccessKey(this, true);
}
return nsImageFrame::Reflow(aPresContext, aDesiredSize, aReflowInput, aStatus);
}

Просмотреть файл

@ -10,7 +10,7 @@
#include "nsHTMLParts.h"
#include "nsGkAtoms.h"
#include "nsStyleConsts.h"
#include "nsFormControlFrame.h"
#include "nsCheckboxRadioFrame.h"
nsIFrame*
NS_NewLegendFrame(nsIPresShell* aPresShell, nsStyleContext* aContext)
@ -31,7 +31,7 @@ NS_IMPL_FRAMEARENA_HELPERS(nsLegendFrame)
void
nsLegendFrame::DestroyFrom(nsIFrame* aDestructRoot)
{
nsFormControlFrame::RegUnRegAccessKey(static_cast<nsIFrame*>(this), false);
nsCheckboxRadioFrame::RegUnRegAccessKey(static_cast<nsIFrame*>(this), false);
nsBlockFrame::DestroyFrom(aDestructRoot);
}
@ -49,7 +49,7 @@ nsLegendFrame::Reflow(nsPresContext* aPresContext,
DISPLAY_REFLOW(aPresContext, this, aReflowInput, aDesiredSize, aStatus);
MOZ_ASSERT(aStatus.IsEmpty(), "Caller should pass a fresh reflow status!");
if (mState & NS_FRAME_FIRST_REFLOW) {
nsFormControlFrame::RegUnRegAccessKey(static_cast<nsIFrame*>(this), true);
nsCheckboxRadioFrame::RegUnRegAccessKey(static_cast<nsIFrame*>(this), true);
}
return nsBlockFrame::Reflow(aPresContext, aDesiredSize, aReflowInput, aStatus);
}

Просмотреть файл

@ -7,7 +7,7 @@
#include "nsCOMPtr.h"
#include "nsUnicharUtils.h"
#include "nsListControlFrame.h"
#include "nsFormControlFrame.h" // for COMPARE macro
#include "nsCheckboxRadioFrame.h" // for COMPARE macro
#include "nsGkAtoms.h"
#include "nsIDOMHTMLSelectElement.h"
#include "nsIDOMHTMLOptionElement.h"
@ -155,7 +155,7 @@ nsListControlFrame::DestroyFrom(nsIFrame* aDestructRoot)
true));
}
nsFormControlFrame::RegUnRegAccessKey(static_cast<nsIFrame*>(this), false);
nsCheckboxRadioFrame::RegUnRegAccessKey(static_cast<nsIFrame*>(this), false);
nsHTMLScrollFrame::DestroyFrom(aDestructRoot);
}
@ -383,7 +383,7 @@ nsListControlFrame::Reflow(nsPresContext* aPresContext,
}
if (GetStateBits() & NS_FRAME_FIRST_REFLOW) {
nsFormControlFrame::RegUnRegAccessKey(this, true);
nsCheckboxRadioFrame::RegUnRegAccessKey(this, true);
}
if (IsInDropDownMode()) {

Просмотреть файл

@ -14,7 +14,7 @@
#include "nsNodeInfoManager.h"
#include "nsContentCreatorFunctions.h"
#include "nsContentUtils.h"
#include "nsFormControlFrame.h"
#include "nsCheckboxRadioFrame.h"
#include "nsFontMetrics.h"
#include "mozilla/dom/Element.h"
#include "mozilla/dom/HTMLMeterElement.h"
@ -53,7 +53,7 @@ nsMeterFrame::DestroyFrom(nsIFrame* aDestructRoot)
NS_ASSERTION(!GetPrevContinuation(),
"nsMeterFrame should not have continuations; if it does we "
"need to call RegUnregAccessKey only for the first.");
nsFormControlFrame::RegUnRegAccessKey(static_cast<nsIFrame*>(this), false);
nsCheckboxRadioFrame::RegUnRegAccessKey(static_cast<nsIFrame*>(this), false);
DestroyAnonymousContent(mBarDiv.forget());
nsContainerFrame::DestroyFrom(aDestructRoot);
}
@ -107,7 +107,7 @@ nsMeterFrame::Reflow(nsPresContext* aPresContext,
"need to call RegUnregAccessKey only for the first.");
if (mState & NS_FRAME_FIRST_REFLOW) {
nsFormControlFrame::RegUnRegAccessKey(this, true);
nsCheckboxRadioFrame::RegUnRegAccessKey(this, true);
}
nsIFrame* barFrame = mBarDiv->GetPrimaryFrame();

Просмотреть файл

@ -11,7 +11,7 @@
#include "nsIPresShell.h"
#include "nsFocusManager.h"
#include "nsFontMetrics.h"
#include "nsFormControlFrame.h"
#include "nsCheckboxRadioFrame.h"
#include "nsGkAtoms.h"
#include "nsNameSpaceManager.h"
#include "nsThemeConstants.h"
@ -60,7 +60,7 @@ nsNumberControlFrame::DestroyFrom(nsIFrame* aDestructRoot)
NS_ASSERTION(!GetPrevContinuation() && !GetNextContinuation(),
"nsNumberControlFrame should not have continuations; if it does we "
"need to call RegUnregAccessKey only for the first");
nsFormControlFrame::RegUnRegAccessKey(static_cast<nsIFrame*>(this), false);
nsCheckboxRadioFrame::RegUnRegAccessKey(static_cast<nsIFrame*>(this), false);
DestroyAnonymousContent(mOuterWrapper.forget());
nsContainerFrame::DestroyFrom(aDestructRoot);
}
@ -123,7 +123,7 @@ nsNumberControlFrame::Reflow(nsPresContext* aPresContext,
"We expect at most one direct child frame");
if (mState & NS_FRAME_FIRST_REFLOW) {
nsFormControlFrame::RegUnRegAccessKey(this, true);
nsCheckboxRadioFrame::RegUnRegAccessKey(this, true);
}
const WritingMode myWM = aReflowInput.GetWritingMode();

Просмотреть файл

@ -14,7 +14,7 @@
#include "nsNodeInfoManager.h"
#include "nsContentCreatorFunctions.h"
#include "nsContentUtils.h"
#include "nsFormControlFrame.h"
#include "nsCheckboxRadioFrame.h"
#include "nsFontMetrics.h"
#include "mozilla/dom/Element.h"
#include "mozilla/dom/HTMLProgressElement.h"
@ -52,7 +52,7 @@ nsProgressFrame::DestroyFrom(nsIFrame* aDestructRoot)
NS_ASSERTION(!GetPrevContinuation(),
"nsProgressFrame should not have continuations; if it does we "
"need to call RegUnregAccessKey only for the first.");
nsFormControlFrame::RegUnRegAccessKey(static_cast<nsIFrame*>(this), false);
nsCheckboxRadioFrame::RegUnRegAccessKey(static_cast<nsIFrame*>(this), false);
DestroyAnonymousContent(mBarDiv.forget());
nsContainerFrame::DestroyFrom(aDestructRoot);
}
@ -116,7 +116,7 @@ nsProgressFrame::Reflow(nsPresContext* aPresContext,
"need to call RegUnregAccessKey only for the first.");
if (mState & NS_FRAME_FIRST_REFLOW) {
nsFormControlFrame::RegUnRegAccessKey(this, true);
nsCheckboxRadioFrame::RegUnRegAccessKey(this, true);
}
aDesiredSize.SetSize(aReflowInput.GetWritingMode(),

Просмотреть файл

@ -13,7 +13,7 @@
#include "nsContentUtils.h"
#include "nsCSSPseudoElements.h"
#include "nsCSSRendering.h"
#include "nsFormControlFrame.h"
#include "nsCheckboxRadioFrame.h"
#include "nsIContent.h"
#include "nsIDocument.h"
#include "nsNameSpaceManager.h"
@ -102,7 +102,7 @@ nsRangeFrame::DestroyFrom(nsIFrame* aDestructRoot)
mContent->RemoveEventListener(NS_LITERAL_STRING("touchstart"), mDummyTouchListener, false);
nsFormControlFrame::RegUnRegAccessKey(static_cast<nsIFrame*>(this), false);
nsCheckboxRadioFrame::RegUnRegAccessKey(static_cast<nsIFrame*>(this), false);
DestroyAnonymousContent(mTrackDiv.forget());
DestroyAnonymousContent(mProgressDiv.forget());
DestroyAnonymousContent(mThumbDiv.forget());
@ -326,7 +326,7 @@ nsRangeFrame::Reflow(nsPresContext* aPresContext,
"need to call RegUnregAccessKey only for the first.");
if (mState & NS_FRAME_FIRST_REFLOW) {
nsFormControlFrame::RegUnRegAccessKey(this, true);
nsCheckboxRadioFrame::RegUnRegAccessKey(this, true);
}
WritingMode wm = aReflowInput.GetWritingMode();

Просмотреть файл

@ -17,7 +17,7 @@
#include "nsTextFragment.h"
#include "nsIDOMHTMLTextAreaElement.h"
#include "nsNameSpaceManager.h"
#include "nsFormControlFrame.h" //for registering accesskeys
#include "nsCheckboxRadioFrame.h" //for registering accesskeys
#include "nsIContent.h"
#include "nsPresContext.h"
@ -147,7 +147,7 @@ nsTextControlFrame::DestroyFrom(nsIFrame* aDestructRoot)
NS_ASSERTION(txtCtrl, "Content not a text control element");
txtCtrl->UnbindFromFrame(this);
nsFormControlFrame::RegUnRegAccessKey(static_cast<nsIFrame*>(this), false);
nsCheckboxRadioFrame::RegUnRegAccessKey(static_cast<nsIFrame*>(this), false);
if (mMutationObserver) {
mRootNode->RemoveMutationObserver(mMutationObserver);
@ -613,7 +613,7 @@ nsTextControlFrame::Reflow(nsPresContext* aPresContext,
// make sure that the form registers itself on the initial/first reflow
if (mState & NS_FRAME_FIRST_REFLOW) {
nsFormControlFrame::RegUnRegAccessKey(this, true);
nsCheckboxRadioFrame::RegUnRegAccessKey(this, true);
}
// set values of reflow's out parameters

Просмотреть файл

@ -14,6 +14,7 @@ FRAME_TYPE(Br)
FRAME_TYPE(Bullet)
FRAME_TYPE(BCTableCell)
FRAME_TYPE(Canvas)
FRAME_TYPE(CheckboxRadio)
FRAME_TYPE(ColorControl)
FRAME_TYPE(ColumnSet)
FRAME_TYPE(ComboboxControl)
@ -24,7 +25,6 @@ FRAME_TYPE(Details)
FRAME_TYPE(FieldSet)
FRAME_TYPE(FlexContainer)
FRAME_TYPE(FrameSet)
FRAME_TYPE(FormControl)
FRAME_TYPE(GfxButtonControl)
FRAME_TYPE(GridContainer)
FRAME_TYPE(HTMLButtonControl)

Просмотреть файл

@ -13,6 +13,7 @@ FRAME_ID(nsBoxFrame, Box, NotLeaf)
FRAME_ID(nsBulletFrame, Bullet, Leaf)
FRAME_ID(nsButtonBoxFrame, Box, NotLeaf)
FRAME_ID(nsCanvasFrame, Canvas, NotLeaf)
FRAME_ID(nsCheckboxRadioFrame, CheckboxRadio, Leaf)
FRAME_ID(nsColorControlFrame, ColorControl, Leaf)
FRAME_ID(nsColumnSetFrame, ColumnSet, NotLeaf)
FRAME_ID(nsComboboxControlFrame, ComboboxControl, NotLeaf)
@ -26,7 +27,6 @@ FRAME_ID(nsFileControlFrame, Block, Leaf)
FRAME_ID(nsFirstLetterFrame, Letter, NotLeaf)
FRAME_ID(nsFirstLineFrame, Line, NotLeaf)
FRAME_ID(nsFlexContainerFrame, FlexContainer, NotLeaf)
FRAME_ID(nsFormControlFrame, FormControl, Leaf)
FRAME_ID(nsFrame, None, NotLeaf)
FRAME_ID(nsGfxButtonControlFrame, GfxButtonControl, Leaf)
FRAME_ID(nsGridContainerFrame, GridContainer, NotLeaf)

Просмотреть файл

@ -12,7 +12,7 @@
#include "nsISupports.h"
#include "nsIFrame.h"
class nsComboboxControlFrame;
class nsFormControlFrame;
class nsCheckboxRadioFrame;
class nsIAtom;
class nsNodeInfoManager;
class nsIContent;
@ -132,8 +132,8 @@ NS_NewFirstLineFrame(nsIPresShell* aPresShell, nsStyleContext* aContext);
// forms
nsContainerFrame*
NS_NewGfxButtonControlFrame(nsIPresShell* aPresShell, nsStyleContext* aContext);
nsFormControlFrame*
NS_NewFormControlFrame(nsIPresShell* aPresShell, nsStyleContext* aContext);
nsCheckboxRadioFrame*
NS_NewCheckboxRadioFrame(nsIPresShell* aPresShell, nsStyleContext* aContext);
nsIFrame*
NS_NewImageControlFrame(nsIPresShell* aPresShell, nsStyleContext* aContext);
nsContainerFrame*

Просмотреть файл

@ -3003,7 +3003,7 @@ nsNativeThemeCocoa::GetWidgetBorder(nsDeviceContext* aContext,
case NS_THEME_CHECKBOX:
case NS_THEME_RADIO:
{
// nsFormControlFrame::GetIntrinsicWidth and nsFormControlFrame::GetIntrinsicHeight
// nsCheckboxRadioFrame::GetIntrinsicWidth and nsCheckboxRadioFrame::GetIntrinsicHeight
// assume a border width of 2px.
aResult->SizeTo(2, 2, 2, 2);
break;