temporary fix for the "window is 1x1 and blank on startup" problem.
hyatt / pavlov are working on a better fix.
This commit is contained in:
@@ -496,6 +496,7 @@ nsAppShellService::CreateTopLevelWindow(nsIWebShellWindow *aParent,
|
||||
nsWidgetInitData widgetInitData;
|
||||
widgetInitData.mBorderStyle = eBorderStyle_window;
|
||||
|
||||
#ifndef XP_UNIX
|
||||
if (aInitialWidth == NS_SIZETOCONTENT ||
|
||||
aInitialHeight == NS_SIZETOCONTENT) {
|
||||
aInitialWidth = 1;
|
||||
@@ -503,6 +504,7 @@ nsAppShellService::CreateTopLevelWindow(nsIWebShellWindow *aParent,
|
||||
showWindow = PR_FALSE; // Don't show until we have the intrinsic size figured out.
|
||||
window->SetIntrinsicallySized(PR_TRUE);
|
||||
}
|
||||
#endif
|
||||
|
||||
rv = window->Initialize((nsIWebShellWindow *) nsnull, mAppShell, aUrl,
|
||||
anObserver, aCallbacks,
|
||||
@@ -556,6 +558,7 @@ nsAppShellService::CreateDialogWindow(nsIWebShellWindow * aParent,
|
||||
nsWidgetInitData widgetInitData;
|
||||
widgetInitData.mBorderStyle = eBorderStyle_dialog;
|
||||
|
||||
#ifndef XP_UNIX
|
||||
if (aInitialWidth == NS_SIZETOCONTENT ||
|
||||
aInitialHeight == NS_SIZETOCONTENT) {
|
||||
aInitialWidth = 1;
|
||||
@@ -563,6 +566,7 @@ nsAppShellService::CreateDialogWindow(nsIWebShellWindow * aParent,
|
||||
showWindow = PR_FALSE; // Don't show until we have the intrinsic size figured out.
|
||||
window->SetIntrinsicallySized(PR_TRUE);
|
||||
}
|
||||
#endif
|
||||
|
||||
rv = window->Initialize((nsIWebShellWindow *) nsnull, mAppShell, aUrl,
|
||||
anObserver, aCallbacks,
|
||||
|
||||
Reference in New Issue
Block a user