2001-09-29 00:14:13 +04:00
|
|
|
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
|
|
|
/* ***** BEGIN LICENSE BLOCK *****
|
2004-04-18 18:30:37 +04:00
|
|
|
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
1999-01-26 03:05:21 +03:00
|
|
|
*
|
2004-04-18 18:30:37 +04:00
|
|
|
* The contents of this file are subject to the Mozilla Public License Version
|
|
|
|
* 1.1 (the "License"); you may not use this file except in compliance with
|
|
|
|
* the License. You may obtain a copy of the License at
|
|
|
|
* http://www.mozilla.org/MPL/
|
1999-01-26 03:05:21 +03:00
|
|
|
*
|
2001-09-29 00:14:13 +04:00
|
|
|
* Software distributed under the License is distributed on an "AS IS" basis,
|
|
|
|
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
|
|
|
* for the specific language governing rights and limitations under the
|
|
|
|
* License.
|
1999-01-26 03:05:21 +03:00
|
|
|
*
|
1999-11-06 06:40:37 +03:00
|
|
|
* The Original Code is mozilla.org code.
|
|
|
|
*
|
2004-04-18 18:30:37 +04:00
|
|
|
* The Initial Developer of the Original Code is
|
2001-09-29 00:14:13 +04:00
|
|
|
* Netscape Communications Corporation.
|
|
|
|
* Portions created by the Initial Developer are Copyright (C) 1998
|
|
|
|
* the Initial Developer. All Rights Reserved.
|
1999-11-06 06:40:37 +03:00
|
|
|
*
|
2001-09-29 00:14:13 +04:00
|
|
|
* Contributor(s):
|
|
|
|
*
|
|
|
|
* Alternatively, the contents of this file may be used under the terms of
|
2004-04-18 18:30:37 +04:00
|
|
|
* either of the GNU General Public License Version 2 or later (the "GPL"),
|
|
|
|
* or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
2001-09-29 00:14:13 +04:00
|
|
|
* in which case the provisions of the GPL or the LGPL are applicable instead
|
|
|
|
* of those above. If you wish to allow use of your version of this file only
|
|
|
|
* under the terms of either the GPL or the LGPL, and not to allow others to
|
2004-04-18 18:30:37 +04:00
|
|
|
* use your version of this file under the terms of the MPL, indicate your
|
2001-09-29 00:14:13 +04:00
|
|
|
* decision by deleting the provisions above and replace them with the notice
|
|
|
|
* and other provisions required by the GPL or the LGPL. If you do not delete
|
|
|
|
* the provisions above, a recipient may use your version of this file under
|
2004-04-18 18:30:37 +04:00
|
|
|
* the terms of any one of the MPL, the GPL or the LGPL.
|
2001-09-29 00:14:13 +04:00
|
|
|
*
|
|
|
|
* ***** END LICENSE BLOCK ***** */
|
1999-02-12 20:45:58 +03:00
|
|
|
#include "nsCOMPtr.h"
|
2003-01-20 21:04:34 +03:00
|
|
|
#include "nsViewportFrame.h"
|
1999-01-28 20:14:13 +03:00
|
|
|
#include "nsHTMLParts.h"
|
|
|
|
#include "nsLayoutAtoms.h"
|
|
|
|
#include "nsIViewManager.h"
|
2001-04-17 05:45:38 +04:00
|
|
|
#include "nsIScrollableFrame.h"
|
1999-02-03 20:01:51 +03:00
|
|
|
#include "nsIDeviceContext.h"
|
2004-08-01 03:15:21 +04:00
|
|
|
#include "nsPresContext.h"
|
2002-05-10 22:22:41 +04:00
|
|
|
#include "nsReflowPath.h"
|
1999-07-24 07:59:47 +04:00
|
|
|
#include "nsIPresShell.h"
|
1999-01-26 03:05:21 +03:00
|
|
|
|
|
|
|
nsresult
|
1999-12-05 02:49:50 +03:00
|
|
|
NS_NewViewportFrame(nsIPresShell* aPresShell, nsIFrame** aNewFrame)
|
1999-01-26 03:05:21 +03:00
|
|
|
{
|
1999-05-12 02:03:29 +04:00
|
|
|
NS_PRECONDITION(aNewFrame, "null OUT ptr");
|
|
|
|
if (nsnull == aNewFrame) {
|
|
|
|
return NS_ERROR_NULL_POINTER;
|
|
|
|
}
|
1999-12-05 02:49:50 +03:00
|
|
|
ViewportFrame* it = new (aPresShell) ViewportFrame;
|
1999-05-12 02:03:29 +04:00
|
|
|
if (nsnull == it) {
|
1999-01-26 03:05:21 +03:00
|
|
|
return NS_ERROR_OUT_OF_MEMORY;
|
|
|
|
}
|
1999-05-12 02:03:29 +04:00
|
|
|
*aNewFrame = it;
|
1999-01-26 03:05:21 +03:00
|
|
|
return NS_OK;
|
|
|
|
}
|
|
|
|
|
1999-01-28 20:14:13 +03:00
|
|
|
NS_IMETHODIMP
|
2004-08-01 03:15:21 +04:00
|
|
|
ViewportFrame::Destroy(nsPresContext* aPresContext)
|
1999-01-28 20:14:13 +03:00
|
|
|
{
|
2003-01-20 21:04:34 +03:00
|
|
|
mFixedContainer.DestroyFrames(this, aPresContext);
|
1999-07-22 06:24:52 +04:00
|
|
|
return nsContainerFrame::Destroy(aPresContext);
|
1999-01-28 20:14:13 +03:00
|
|
|
}
|
|
|
|
|
|
|
|
NS_IMETHODIMP
|
2004-08-01 03:15:21 +04:00
|
|
|
ViewportFrame::SetInitialChildList(nsPresContext* aPresContext,
|
1999-01-28 20:14:13 +03:00
|
|
|
nsIAtom* aListName,
|
|
|
|
nsIFrame* aChildList)
|
|
|
|
{
|
2003-01-20 21:04:34 +03:00
|
|
|
nsresult rv = NS_OK;
|
1999-01-28 20:14:13 +03:00
|
|
|
|
1999-07-24 07:59:47 +04:00
|
|
|
// See which child list to add the frames to
|
|
|
|
#ifdef NS_DEBUG
|
|
|
|
nsFrame::VerifyDirtyBitSet(aChildList);
|
|
|
|
#endif
|
2003-01-20 21:04:34 +03:00
|
|
|
if (mFixedContainer.GetChildListName() == aListName) {
|
|
|
|
rv = mFixedContainer.SetInitialChildList(this, aPresContext, aListName, aChildList);
|
|
|
|
}
|
|
|
|
else {
|
1999-01-28 20:14:13 +03:00
|
|
|
rv = nsContainerFrame::SetInitialChildList(aPresContext, aListName, aChildList);
|
|
|
|
}
|
|
|
|
|
|
|
|
return rv;
|
|
|
|
}
|
|
|
|
|
2000-03-22 05:43:08 +03:00
|
|
|
NS_IMETHODIMP
|
2004-08-01 03:15:21 +04:00
|
|
|
ViewportFrame::GetFrameForPoint(nsPresContext* aPresContext,
|
2000-03-22 05:43:08 +03:00
|
|
|
const nsPoint& aPoint,
|
|
|
|
nsFramePaintLayer aWhichLayer,
|
|
|
|
nsIFrame** aFrame)
|
|
|
|
{
|
|
|
|
// this should act like a block, so we need to override
|
2003-01-20 21:04:34 +03:00
|
|
|
return GetFrameForPointUsing(aPresContext, aPoint, nsnull, aWhichLayer,
|
|
|
|
(aWhichLayer == NS_FRAME_PAINT_LAYER_BACKGROUND), aFrame);
|
2000-03-22 05:43:08 +03:00
|
|
|
}
|
|
|
|
|
1999-07-24 07:59:47 +04:00
|
|
|
NS_IMETHODIMP
|
2004-08-01 03:15:21 +04:00
|
|
|
ViewportFrame::AppendFrames(nsPresContext* aPresContext,
|
1999-07-24 07:59:47 +04:00
|
|
|
nsIPresShell& aPresShell,
|
|
|
|
nsIAtom* aListName,
|
|
|
|
nsIFrame* aFrameList)
|
|
|
|
{
|
2003-01-20 21:04:34 +03:00
|
|
|
nsresult rv = NS_OK;
|
|
|
|
|
|
|
|
if (mFixedContainer.GetChildListName() == aListName) {
|
|
|
|
rv = mFixedContainer.AppendFrames(this, aPresContext, aPresShell,
|
|
|
|
aListName, aFrameList);
|
|
|
|
}
|
|
|
|
else {
|
1999-07-27 18:15:42 +04:00
|
|
|
// We only expect incremental changes for our fixed frames
|
2003-01-20 21:04:34 +03:00
|
|
|
NS_ERROR("unexpected child list");
|
1999-07-27 18:15:42 +04:00
|
|
|
rv = NS_ERROR_INVALID_ARG;
|
1999-07-24 07:59:47 +04:00
|
|
|
}
|
|
|
|
|
|
|
|
return rv;
|
|
|
|
}
|
|
|
|
|
|
|
|
NS_IMETHODIMP
|
2004-08-01 03:15:21 +04:00
|
|
|
ViewportFrame::InsertFrames(nsPresContext* aPresContext,
|
2003-01-20 21:04:34 +03:00
|
|
|
nsIPresShell& aPresShell,
|
|
|
|
nsIAtom* aListName,
|
|
|
|
nsIFrame* aPrevFrame,
|
|
|
|
nsIFrame* aFrameList)
|
1999-07-24 07:59:47 +04:00
|
|
|
{
|
2003-01-20 21:04:34 +03:00
|
|
|
nsresult rv = NS_OK;
|
1999-07-24 07:59:47 +04:00
|
|
|
|
2003-01-20 21:04:34 +03:00
|
|
|
if (mFixedContainer.GetChildListName() == aListName) {
|
|
|
|
rv = mFixedContainer.InsertFrames(this, aPresContext, aPresShell, aListName,
|
|
|
|
aPrevFrame, aFrameList);
|
|
|
|
}
|
|
|
|
else {
|
1999-07-27 18:15:42 +04:00
|
|
|
// We only expect incremental changes for our fixed frames
|
2003-01-20 21:04:34 +03:00
|
|
|
NS_ERROR("unexpected child list");
|
1999-07-27 18:15:42 +04:00
|
|
|
rv = NS_ERROR_INVALID_ARG;
|
1999-07-24 07:59:47 +04:00
|
|
|
}
|
|
|
|
|
|
|
|
return rv;
|
|
|
|
}
|
|
|
|
|
|
|
|
NS_IMETHODIMP
|
2004-08-01 03:15:21 +04:00
|
|
|
ViewportFrame::RemoveFrame(nsPresContext* aPresContext,
|
2003-01-20 21:04:34 +03:00
|
|
|
nsIPresShell& aPresShell,
|
|
|
|
nsIAtom* aListName,
|
|
|
|
nsIFrame* aOldFrame)
|
1999-07-24 07:59:47 +04:00
|
|
|
{
|
2003-01-20 21:04:34 +03:00
|
|
|
nsresult rv = NS_OK;
|
1999-07-27 18:15:42 +04:00
|
|
|
|
2003-01-20 21:04:34 +03:00
|
|
|
if (mFixedContainer.GetChildListName() == aListName) {
|
|
|
|
rv = mFixedContainer.RemoveFrame(this, aPresContext, aPresShell, aListName, aOldFrame);
|
|
|
|
}
|
|
|
|
else {
|
1999-07-27 18:15:42 +04:00
|
|
|
// We only expect incremental changes for our fixed frames
|
2003-01-20 21:04:34 +03:00
|
|
|
NS_ERROR("unexpected child list");
|
1999-07-27 18:15:42 +04:00
|
|
|
rv = NS_ERROR_INVALID_ARG;
|
|
|
|
}
|
|
|
|
|
|
|
|
return rv;
|
1999-07-24 07:59:47 +04:00
|
|
|
}
|
|
|
|
|
2004-01-09 17:20:53 +03:00
|
|
|
nsIAtom*
|
|
|
|
ViewportFrame::GetAdditionalChildListName(PRInt32 aIndex) const
|
1999-01-28 20:14:13 +03:00
|
|
|
{
|
2004-01-09 17:20:53 +03:00
|
|
|
NS_PRECONDITION(aIndex >= 0, "illegal index");
|
1999-01-28 20:14:13 +03:00
|
|
|
|
2003-01-20 21:04:34 +03:00
|
|
|
if (0 == aIndex) {
|
2004-01-09 17:20:53 +03:00
|
|
|
return mFixedContainer.GetChildListName();
|
1999-01-28 20:14:13 +03:00
|
|
|
}
|
|
|
|
|
2004-01-09 17:20:53 +03:00
|
|
|
return nsnull;
|
1999-01-28 20:14:13 +03:00
|
|
|
}
|
|
|
|
|
2004-01-09 17:20:53 +03:00
|
|
|
nsIFrame*
|
|
|
|
ViewportFrame::GetFirstChild(nsIAtom* aListName) const
|
1999-01-28 20:14:13 +03:00
|
|
|
{
|
2003-01-20 21:04:34 +03:00
|
|
|
if (mFixedContainer.GetChildListName() == aListName) {
|
2004-01-09 17:20:53 +03:00
|
|
|
nsIFrame* result = nsnull;
|
|
|
|
mFixedContainer.FirstChild(this, aListName, &result);
|
|
|
|
return result;
|
1999-01-28 20:14:13 +03:00
|
|
|
}
|
|
|
|
|
2004-01-09 17:20:53 +03:00
|
|
|
return nsContainerFrame::GetFirstChild(aListName);
|
1999-01-28 20:14:13 +03:00
|
|
|
}
|
|
|
|
|
2004-01-09 22:21:20 +03:00
|
|
|
nsPoint
|
|
|
|
ViewportFrame::AdjustReflowStateForScrollbars(nsHTMLReflowState* aReflowState) const
|
1999-02-03 20:01:51 +03:00
|
|
|
{
|
2002-05-14 05:44:00 +04:00
|
|
|
// Calculate how much room is available for fixed frames. That means
|
|
|
|
// determining if the viewport is scrollable and whether the vertical and/or
|
|
|
|
// horizontal scrollbars are visible
|
1999-02-03 20:01:51 +03:00
|
|
|
|
|
|
|
// Get our prinicpal child frame and see if we're scrollable
|
|
|
|
nsIFrame* kidFrame = mFrames.FirstChild();
|
2001-04-17 05:45:38 +04:00
|
|
|
nsCOMPtr<nsIScrollableFrame> scrollingFrame(do_QueryInterface(kidFrame));
|
|
|
|
|
|
|
|
if (scrollingFrame) {
|
2004-01-09 22:21:20 +03:00
|
|
|
nsMargin scrollbars = scrollingFrame->GetActualScrollbarSizes();
|
|
|
|
aReflowState->mComputedWidth -= scrollbars.left + scrollbars.right;
|
|
|
|
aReflowState->availableWidth -= scrollbars.left + scrollbars.right;
|
|
|
|
aReflowState->mComputedHeight -= scrollbars.top + scrollbars.bottom;
|
|
|
|
// XXX why don't we also adjust "aReflowState->availableHeight"?
|
|
|
|
return nsPoint(scrollbars.left, scrollbars.top);
|
1999-02-03 20:01:51 +03:00
|
|
|
}
|
2004-01-09 22:21:20 +03:00
|
|
|
return nsPoint(0, 0);
|
1999-02-03 20:01:51 +03:00
|
|
|
}
|
|
|
|
|
1999-01-26 03:05:21 +03:00
|
|
|
NS_IMETHODIMP
|
2004-08-01 03:15:21 +04:00
|
|
|
ViewportFrame::Reflow(nsPresContext* aPresContext,
|
1999-01-26 03:05:21 +03:00
|
|
|
nsHTMLReflowMetrics& aDesiredSize,
|
|
|
|
const nsHTMLReflowState& aReflowState,
|
|
|
|
nsReflowStatus& aStatus)
|
|
|
|
{
|
2000-04-21 18:59:47 +04:00
|
|
|
DO_GLOBAL_REFLOW_COUNT("ViewportFrame", aReflowState.reason);
|
2001-11-14 16:40:03 +03:00
|
|
|
DISPLAY_REFLOW(aPresContext, this, aReflowState, aDesiredSize, aStatus);
|
1999-01-26 03:05:21 +03:00
|
|
|
NS_FRAME_TRACE_REFLOW_IN("ViewportFrame::Reflow");
|
2003-01-09 17:26:32 +03:00
|
|
|
NS_PRECONDITION(!aDesiredSize.mComputeMEW, "unexpected request");
|
1999-01-26 03:05:21 +03:00
|
|
|
|
2003-01-20 21:04:34 +03:00
|
|
|
// Initialize OUT parameters
|
1999-01-26 03:05:21 +03:00
|
|
|
aStatus = NS_FRAME_COMPLETE;
|
|
|
|
|
2003-02-22 23:13:12 +03:00
|
|
|
// Reflow the main content first so that the placeholders of the
|
|
|
|
// fixed-position frames will be in the right places on an initial
|
|
|
|
// reflow.
|
1999-07-04 08:09:54 +04:00
|
|
|
nsRect kidRect(0,0,aReflowState.availableWidth,aReflowState.availableHeight);
|
|
|
|
|
2003-02-22 23:13:12 +03:00
|
|
|
nsresult rv = NS_OK;
|
|
|
|
|
2002-05-10 22:22:41 +04:00
|
|
|
if (mFrames.NotEmpty()) {
|
|
|
|
// Deal with a non-incremental reflow or an incremental reflow
|
|
|
|
// targeted at our one-and-only principal child frame.
|
|
|
|
if (eReflowReason_Incremental != aReflowState.reason ||
|
|
|
|
aReflowState.path->HasChild(mFrames.FirstChild())) {
|
|
|
|
// Reflow our one-and-only principal child frame
|
|
|
|
nsIFrame* kidFrame = mFrames.FirstChild();
|
|
|
|
nsHTMLReflowMetrics kidDesiredSize(nsnull);
|
|
|
|
nsSize availableSpace(aReflowState.availableWidth,
|
|
|
|
aReflowState.availableHeight);
|
|
|
|
nsHTMLReflowState kidReflowState(aPresContext, aReflowState,
|
|
|
|
kidFrame, availableSpace);
|
|
|
|
|
|
|
|
// Reflow the frame
|
|
|
|
kidReflowState.mComputedHeight = aReflowState.availableHeight;
|
2003-01-20 21:04:34 +03:00
|
|
|
rv = ReflowChild(kidFrame, aPresContext, kidDesiredSize, kidReflowState,
|
|
|
|
0, 0, 0, aStatus);
|
2002-05-10 22:22:41 +04:00
|
|
|
kidRect.width = kidDesiredSize.width;
|
|
|
|
kidRect.height = kidDesiredSize.height;
|
|
|
|
|
|
|
|
FinishReflowChild(kidFrame, aPresContext, nsnull, kidDesiredSize, 0, 0, 0);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
1999-07-04 08:09:54 +04:00
|
|
|
// If we were flowed initially at both an unconstrained width and height,
|
|
|
|
// this is a hint that we should return our child's intrinsic size.
|
1999-09-04 02:41:56 +04:00
|
|
|
if ((eReflowReason_Initial == aReflowState.reason ||
|
|
|
|
eReflowReason_Resize == aReflowState.reason) &&
|
1999-07-04 08:09:54 +04:00
|
|
|
aReflowState.availableWidth == NS_UNCONSTRAINEDSIZE &&
|
|
|
|
aReflowState.availableHeight == NS_UNCONSTRAINEDSIZE) {
|
|
|
|
aDesiredSize.width = kidRect.width;
|
|
|
|
aDesiredSize.height = kidRect.height;
|
|
|
|
aDesiredSize.ascent = kidRect.height;
|
|
|
|
aDesiredSize.descent = 0;
|
|
|
|
}
|
|
|
|
else {
|
|
|
|
// Return the max size as our desired size
|
|
|
|
aDesiredSize.width = aReflowState.availableWidth;
|
|
|
|
aDesiredSize.height = aReflowState.availableHeight;
|
|
|
|
aDesiredSize.ascent = aReflowState.availableHeight;
|
|
|
|
aDesiredSize.descent = 0;
|
|
|
|
}
|
1999-01-26 03:05:21 +03:00
|
|
|
|
2003-02-22 23:13:12 +03:00
|
|
|
// Make a copy of the reflow state and change the computed width and height
|
|
|
|
// to reflect the available space for the fixed items
|
|
|
|
nsHTMLReflowState reflowState(aReflowState);
|
2004-01-09 22:21:20 +03:00
|
|
|
nsPoint offset = AdjustReflowStateForScrollbars(&reflowState);
|
2003-02-22 23:13:12 +03:00
|
|
|
|
2004-01-09 22:21:20 +03:00
|
|
|
#ifdef DEBUG
|
|
|
|
nsIFrame* f;
|
|
|
|
mFixedContainer.FirstChild(this, nsLayoutAtoms::fixedList, &f);
|
|
|
|
NS_ASSERTION(!f || (offset.x == 0 && offset.y == 0),
|
|
|
|
"We don't handle correct positioning of fixed frames with "
|
|
|
|
"scrollbars in odd positions");
|
|
|
|
#endif
|
|
|
|
|
2003-02-22 23:13:12 +03:00
|
|
|
nsReflowType reflowType = eReflowType_ContentChanged;
|
|
|
|
if (aReflowState.path) {
|
|
|
|
// XXXwaterson this is more restrictive than the previous code
|
|
|
|
// was: it insists that the UserDefined reflow be targeted at
|
|
|
|
// _this_ frame.
|
|
|
|
nsHTMLReflowCommand *command = aReflowState.path->mReflowCommand;
|
|
|
|
if (command)
|
|
|
|
command->GetType(reflowType);
|
|
|
|
}
|
|
|
|
|
|
|
|
if (reflowType != eReflowType_UserDefined &&
|
|
|
|
aReflowState.reason == eReflowReason_Incremental) {
|
|
|
|
// Incremental reflow
|
2004-11-14 23:22:58 +03:00
|
|
|
mFixedContainer.IncrementalReflow(this, aPresContext, reflowState,
|
|
|
|
reflowState.mComputedWidth,
|
|
|
|
reflowState.mComputedHeight);
|
2003-02-22 23:13:12 +03:00
|
|
|
}
|
|
|
|
|
2004-11-14 23:22:58 +03:00
|
|
|
// Just reflow all the fixed-pos frames.
|
|
|
|
rv = mFixedContainer.Reflow(this, aPresContext, reflowState,
|
|
|
|
reflowState.mComputedWidth,
|
|
|
|
reflowState.mComputedHeight);
|
2003-02-22 23:13:12 +03:00
|
|
|
|
2000-03-15 18:16:03 +03:00
|
|
|
// If this is an initial reflow, resize reflow, or style change reflow
|
|
|
|
// then do a repaint
|
1999-07-24 19:18:24 +04:00
|
|
|
if ((eReflowReason_Initial == aReflowState.reason) ||
|
2000-03-15 18:16:03 +03:00
|
|
|
(eReflowReason_Resize == aReflowState.reason) ||
|
|
|
|
(eReflowReason_StyleChange == aReflowState.reason)) {
|
2003-01-20 21:04:34 +03:00
|
|
|
nsRect damageRect(0, 0, aDesiredSize.width, aDesiredSize.height);
|
2004-03-10 06:09:05 +03:00
|
|
|
Invalidate(damageRect, PR_FALSE);
|
1999-07-24 19:18:24 +04:00
|
|
|
}
|
|
|
|
|
1999-01-26 03:05:21 +03:00
|
|
|
NS_FRAME_TRACE_REFLOW_OUT("ViewportFrame::Reflow", aStatus);
|
2002-05-29 02:50:43 +04:00
|
|
|
NS_FRAME_SET_TRUNCATION(aStatus, aReflowState, aDesiredSize);
|
2003-01-20 21:04:34 +03:00
|
|
|
return rv;
|
1999-01-26 03:05:21 +03:00
|
|
|
}
|
|
|
|
|
2003-10-31 23:19:18 +03:00
|
|
|
nsIAtom*
|
|
|
|
ViewportFrame::GetType() const
|
1999-02-14 06:47:33 +03:00
|
|
|
{
|
2003-10-31 23:19:18 +03:00
|
|
|
return nsLayoutAtoms::viewportFrame;
|
1999-02-14 06:47:33 +03:00
|
|
|
}
|
|
|
|
|
2004-03-12 07:40:17 +03:00
|
|
|
/* virtual */ PRBool
|
|
|
|
ViewportFrame::IsContainingBlock() const
|
2002-11-26 02:40:58 +03:00
|
|
|
{
|
2004-03-12 07:40:17 +03:00
|
|
|
return PR_TRUE;
|
2002-11-26 02:40:58 +03:00
|
|
|
}
|
|
|
|
|
1999-11-02 01:12:45 +03:00
|
|
|
#ifdef DEBUG
|
1999-01-26 03:05:21 +03:00
|
|
|
NS_IMETHODIMP
|
2001-11-14 04:33:42 +03:00
|
|
|
ViewportFrame::GetFrameName(nsAString& aResult) const
|
1999-01-26 03:05:21 +03:00
|
|
|
{
|
2001-11-14 04:33:42 +03:00
|
|
|
return MakeFrameName(NS_LITERAL_STRING("Viewport"), aResult);
|
1999-01-26 03:05:21 +03:00
|
|
|
}
|
1999-09-01 05:02:16 +04:00
|
|
|
#endif
|