Trying to fix build bustage.

This commit is contained in:
hyatt%netscape.com 1999-07-06 18:53:41 +00:00
parent ed6cec2dac
commit 5101e52906
4 changed files with 28 additions and 2 deletions

View File

@ -108,6 +108,7 @@
#include "rdf.h"
#include "nsIFrameReflow.h"
#include "nsIBrowserWindow.h"
#include "nsIDOMXULFocusTracker.h"
#include "nsIXULFocusTracker.h"
#include "nsIDOMEventCapturer.h"
@ -3960,6 +3961,7 @@ XULDocumentImpl::StartLayout(void)
nsCOMPtr<nsIPresContext> cx;
shell->GetPresContext(getter_AddRefs(cx));
PRBool intrinsic = PR_FALSE;
if (cx) {
nsCOMPtr<nsISupports> container;
cx->GetContainer(getter_AddRefs(container));
@ -3968,13 +3970,20 @@ XULDocumentImpl::StartLayout(void)
webShell = do_QueryInterface(container);
if (webShell) {
webShell->SetScrolling(NS_STYLE_OVERFLOW_HIDDEN);
nsCOMPtr<nsIWebShellContainer> webShellContainer;
webShell->GetContainer(*getter_AddRefs(webShellContainer));
if (webShellContainer) {
nsCOMPtr<nsIBrowserWindow> browser = do_QueryInterface(webShellContainer);
if (browser)
browser->IsIntrinsicallySized(intrinsic);
}
}
}
}
nsRect r;
cx->GetVisibleArea(r);
if (r.width < 5 || r.height < 5) {
if (intrinsic) {
// Flow at an unconstrained width and height
r.width = NS_UNCONSTRAINEDSIZE;
r.height = NS_UNCONSTRAINEDSIZE;

View File

@ -108,6 +108,7 @@
#include "rdf.h"
#include "nsIFrameReflow.h"
#include "nsIBrowserWindow.h"
#include "nsIDOMXULFocusTracker.h"
#include "nsIXULFocusTracker.h"
#include "nsIDOMEventCapturer.h"
@ -3960,6 +3961,7 @@ XULDocumentImpl::StartLayout(void)
nsCOMPtr<nsIPresContext> cx;
shell->GetPresContext(getter_AddRefs(cx));
PRBool intrinsic = PR_FALSE;
if (cx) {
nsCOMPtr<nsISupports> container;
cx->GetContainer(getter_AddRefs(container));
@ -3968,13 +3970,20 @@ XULDocumentImpl::StartLayout(void)
webShell = do_QueryInterface(container);
if (webShell) {
webShell->SetScrolling(NS_STYLE_OVERFLOW_HIDDEN);
nsCOMPtr<nsIWebShellContainer> webShellContainer;
webShell->GetContainer(*getter_AddRefs(webShellContainer));
if (webShellContainer) {
nsCOMPtr<nsIBrowserWindow> browser = do_QueryInterface(webShellContainer);
if (browser)
browser->IsIntrinsicallySized(intrinsic);
}
}
}
}
nsRect r;
cx->GetVisibleArea(r);
if (r.width < 5 || r.height < 5) {
if (intrinsic) {
// Flow at an unconstrained width and height
r.width = NS_UNCONSTRAINEDSIZE;
r.height = NS_UNCONSTRAINEDSIZE;

View File

@ -2855,3 +2855,10 @@ nsWebShellWindow::HandleUrl(const PRUnichar * aCommand, const PRUnichar * aURLSp
return NS_OK;
}
NS_IMETHODIMP
nsWebShellWindow::IsIntrinsicallySized(PRBool& aResult)
{
aResult = mIntrinsicallySized;
return NS_OK;
}

View File

@ -232,6 +232,7 @@ public:
NS_IMETHOD SizeWindowTo(PRInt32 aWidth, PRInt32 aHeight);
NS_IMETHOD GetContentBounds(nsRect& aResult);
NS_IMETHOD GetWindowBounds(nsRect& aResult);
NS_IMETHOD IsIntrinsicallySized(PRBool& aResult);
NS_IMETHOD Show() { Show(PR_TRUE); return NS_OK; }
NS_IMETHOD Hide() { Show(PR_FALSE); return NS_OK; }
NS_IMETHOD SetChrome(PRUint32 aNewChromeMask);