From c70e68e62c50971c1cbe820e6d4e0a56d8dd1075 Mon Sep 17 00:00:00 2001 From: "bryner%netscape.com" Date: Fri, 19 Jul 2002 00:43:00 +0000 Subject: [PATCH] Enable full-screen mode for unix. Bug 126685, r=blizzard, sr=sfraser, a=asa. --- widget/src/gtk/nsWindow.cpp | 7 +++++-- .../resources/content/unix/platformNavigationBindings.xul | 4 +++- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/widget/src/gtk/nsWindow.cpp b/widget/src/gtk/nsWindow.cpp index a565ebfe7b1d..d32e3e4adb8c 100644 --- a/widget/src/gtk/nsWindow.cpp +++ b/widget/src/gtk/nsWindow.cpp @@ -4045,8 +4045,11 @@ NS_IMETHODIMP nsWindow::HideWindowChrome(PRBool aShouldHide) { if (!mShell) { - // This is not a top-level window widget. - return NS_ERROR_FAILURE; + // Pass the request to the toplevel window. + GtkWidget *top_mozarea = GetOwningWidget(); + void *data = gtk_object_get_data(GTK_OBJECT(top_mozarea), "nsWindow"); + nsWindow *mozAreaWindow = NS_STATIC_CAST(nsWindow *, data); + return mozAreaWindow->HideWindowChrome(aShouldHide); } // Sawfish, metacity, and presumably other window managers get diff --git a/xpfe/browser/resources/content/unix/platformNavigationBindings.xul b/xpfe/browser/resources/content/unix/platformNavigationBindings.xul index 32864124546c..5edb9ec23ec2 100644 --- a/xpfe/browser/resources/content/unix/platformNavigationBindings.xul +++ b/xpfe/browser/resources/content/unix/platformNavigationBindings.xul @@ -16,8 +16,10 @@ - + + +