Bug 1054563: Remove unnecessary nsresult return value from BuildScrollFrame, and de-indent it. r=tn

This commit is contained in:
Daniel Holbert 2014-08-15 20:22:09 -07:00
parent c33a664a92
commit 171665617d
2 changed files with 9 additions and 10 deletions

View File

@ -4470,7 +4470,7 @@ nsCSSFrameConstructor::FinishBuildingScrollFrame(nsContainerFrame* aScrollFrame,
* If this is not null, we'll just use it
* @param aScrolledContentStyle the style that was resolved for the scrolled frame. (returned)
*/
nsresult
void
nsCSSFrameConstructor::BuildScrollFrame(nsFrameConstructorState& aState,
nsIContent* aContent,
nsStyleContext* aContentStyle,
@ -4478,16 +4478,15 @@ nsCSSFrameConstructor::BuildScrollFrame(nsFrameConstructorState& aState,
nsContainerFrame* aParentFrame,
nsContainerFrame*& aNewFrame)
{
nsRefPtr<nsStyleContext> scrolledContentStyle =
BeginBuildingScrollFrame(aState, aContent, aContentStyle, aParentFrame,
nsCSSAnonBoxes::scrolledContent,
false, aNewFrame);
nsRefPtr<nsStyleContext> scrolledContentStyle =
BeginBuildingScrollFrame(aState, aContent, aContentStyle, aParentFrame,
nsCSSAnonBoxes::scrolledContent,
false, aNewFrame);
aScrolledFrame->SetStyleContextWithoutNotification(scrolledContentStyle);
InitAndRestoreFrame(aState, aContent, aNewFrame, aScrolledFrame);
aScrolledFrame->SetStyleContextWithoutNotification(scrolledContentStyle);
InitAndRestoreFrame(aState, aContent, aNewFrame, aScrolledFrame);
FinishBuildingScrollFrame(aNewFrame, aScrolledFrame);
return NS_OK;
FinishBuildingScrollFrame(aNewFrame, aScrolledFrame);
}
const nsCSSFrameConstructor::FrameConstructionData*

View File

@ -1425,7 +1425,7 @@ private:
// Calls BeginBuildingScrollFrame, InitAndRestoreFrame, and then FinishBuildingScrollFrame.
// @param aNewFrame the created scrollframe --- output only
// @param aParentFrame the geometric parent that the scrollframe will have.
nsresult
void
BuildScrollFrame(nsFrameConstructorState& aState,
nsIContent* aContent,
nsStyleContext* aContentStyle,