From 05d5e530a2ab57e9d4a210c688cf6159a8406077 Mon Sep 17 00:00:00 2001 From: Alexander Surkov Date: Fri, 13 Mar 2015 20:42:57 -0400 Subject: [PATCH] Bug 1139576 - New_ functions should be static --- accessible/base/nsAccessibilityService.cpp | 30 +++++++++++----------- 1 file changed, 15 insertions(+), 15 deletions(-) diff --git a/accessible/base/nsAccessibilityService.cpp b/accessible/base/nsAccessibilityService.cpp index 08ae2fb60c0..11fb96250b4 100644 --- a/accessible/base/nsAccessibilityService.cpp +++ b/accessible/base/nsAccessibilityService.cpp @@ -136,7 +136,7 @@ MustBeAccessible(nsIContent* aContent, DocAccessible* aDocument) //////////////////////////////////////////////////////////////////////////////// // Accessible constructors -Accessible* +static Accessible* New_HTMLLink(nsIContent* aContent, Accessible* aContext) { // Only some roles truly enjoy life as HTMLLinkAccessibles, for details @@ -150,28 +150,28 @@ New_HTMLLink(nsIContent* aContent, Accessible* aContext) return new HTMLLinkAccessible(aContent, aContext->Document()); } -Accessible* New_HyperText(nsIContent* aContent, Accessible* aContext) +static Accessible* New_HyperText(nsIContent* aContent, Accessible* aContext) { return new HyperTextAccessibleWrap(aContent, aContext->Document()); } -Accessible* New_HTMLFigcaption(nsIContent* aContent, Accessible* aContext) +static Accessible* New_HTMLFigcaption(nsIContent* aContent, Accessible* aContext) { return new HTMLFigcaptionAccessible(aContent, aContext->Document()); } -Accessible* New_HTMLFigure(nsIContent* aContent, Accessible* aContext) +static Accessible* New_HTMLFigure(nsIContent* aContent, Accessible* aContext) { return new HTMLFigureAccessible(aContent, aContext->Document()); } -Accessible* New_HTMLLegend(nsIContent* aContent, Accessible* aContext) +static Accessible* New_HTMLLegend(nsIContent* aContent, Accessible* aContext) { return new HTMLLegendAccessible(aContent, aContext->Document()); } -Accessible* New_HTMLOption(nsIContent* aContent, Accessible* aContext) +static Accessible* New_HTMLOption(nsIContent* aContent, Accessible* aContext) { return new HTMLSelectOptionAccessible(aContent, aContext->Document()); } -Accessible* New_HTMLOptgroup(nsIContent* aContent, Accessible* aContext) +static Accessible* New_HTMLOptgroup(nsIContent* aContent, Accessible* aContext) { return new HTMLSelectOptGroupAccessible(aContent, aContext->Document()); } -Accessible* New_HTMLList(nsIContent* aContent, Accessible* aContext) +static Accessible* New_HTMLList(nsIContent* aContent, Accessible* aContext) { return new HTMLListAccessible(aContent, aContext->Document()); } -Accessible* +static Accessible* New_HTMLListitem(nsIContent* aContent, Accessible* aContext) { // If list item is a child of accessible list then create an accessible for @@ -183,7 +183,7 @@ New_HTMLListitem(nsIContent* aContent, Accessible* aContext) return nullptr; } -Accessible* +static Accessible* New_HTMLDefinition(nsIContent* aContent, Accessible* aContext) { if (aContext->IsList()) @@ -191,16 +191,16 @@ New_HTMLDefinition(nsIContent* aContent, Accessible* aContext) return nullptr; } -Accessible* New_HTMLLabel(nsIContent* aContent, Accessible* aContext) +static Accessible* New_HTMLLabel(nsIContent* aContent, Accessible* aContext) { return new HTMLLabelAccessible(aContent, aContext->Document()); } -Accessible* New_HTMLOutput(nsIContent* aContent, Accessible* aContext) +static Accessible* New_HTMLOutput(nsIContent* aContent, Accessible* aContext) { return new HTMLOutputAccessible(aContent, aContext->Document()); } -Accessible* New_HTMLProgress(nsIContent* aContent, Accessible* aContext) +static Accessible* New_HTMLProgress(nsIContent* aContent, Accessible* aContext) { return new HTMLProgressMeterAccessible(aContent, aContext->Document()); } -Accessible* +static Accessible* New_HTMLTableHeaderCell(nsIContent* aContent, Accessible* aContext) { if (aContext->IsTableRow() && aContext->GetContent() == aContent->GetParent()) @@ -208,7 +208,7 @@ New_HTMLTableHeaderCell(nsIContent* aContent, Accessible* aContext) return nullptr; } -Accessible* +static Accessible* New_HTMLTableHeaderCellIfScope(nsIContent* aContent, Accessible* aContext) { if (aContext->IsTableRow() && aContext->GetContent() == aContent->GetParent() &&