From 08b3c35f7302908f84ec03b4fef730c29fccfbef Mon Sep 17 00:00:00 2001 From: "pinkerton%netscape.com" Date: Wed, 22 Mar 2000 02:55:12 +0000 Subject: [PATCH] added a metric for determining if xul popups should be allowed to display over the menubar/taskbar. r=hyatt. git-svn-id: svn://10.0.0.236/trunk@63695 18797224-902f-48f8-a5cc-f745e15eee43 --- mozilla/widget/public/nsILookAndFeel.h | 3 ++- mozilla/widget/src/gtk/nsLookAndFeel.cpp | 4 ++++ mozilla/widget/src/mac/nsLookAndFeel.cpp | 4 ++++ mozilla/widget/src/windows/nsLookAndFeel.cpp | 5 +++++ 4 files changed, 15 insertions(+), 1 deletion(-) diff --git a/mozilla/widget/public/nsILookAndFeel.h b/mozilla/widget/public/nsILookAndFeel.h index 0c67550809c..1f33b258f69 100644 --- a/mozilla/widget/public/nsILookAndFeel.h +++ b/mozilla/widget/public/nsILookAndFeel.h @@ -110,7 +110,8 @@ public: eMetric_CaretBlinkTime, // default, may be overriden by OS eMetric_CaretWidthTwips, - eMetric_SubmenuDelay + eMetric_SubmenuDelay, + eMetric_MenusCanOverlapOSBar // can popups overlap menu/task bar? } nsMetricID; typedef enum { diff --git a/mozilla/widget/src/gtk/nsLookAndFeel.cpp b/mozilla/widget/src/gtk/nsLookAndFeel.cpp index 304e5adca53..453105341bb 100644 --- a/mozilla/widget/src/gtk/nsLookAndFeel.cpp +++ b/mozilla/widget/src/gtk/nsLookAndFeel.cpp @@ -264,6 +264,10 @@ NS_IMETHODIMP nsLookAndFeel::GetMetric(const nsMetricID aID, PRInt32 & aMetric) case eMetric_SubmenuDelay: aMetric = 200; break; + case eMetric_MenusCanOverlapOSBar: + // we want XUL popups to be able to overlap the task bar. + aMetric = 1; + break; default: aMetric = 0; res = NS_ERROR_FAILURE; diff --git a/mozilla/widget/src/mac/nsLookAndFeel.cpp b/mozilla/widget/src/mac/nsLookAndFeel.cpp index 44824c2015b..ee37aa244f7 100644 --- a/mozilla/widget/src/mac/nsLookAndFeel.cpp +++ b/mozilla/widget/src/mac/nsLookAndFeel.cpp @@ -250,6 +250,10 @@ NS_IMETHODIMP nsLookAndFeel::GetMetric(const nsMetricID aID, PRInt32 & aMetric) case eMetric_SubmenuDelay: aMetric = 200; break; + case eMetric_MenusCanOverlapOSBar: + // xul popups are not allowed to overlap the menubar. + aMetric = 0; + break; default: aMetric = 0; res = NS_ERROR_FAILURE; diff --git a/mozilla/widget/src/windows/nsLookAndFeel.cpp b/mozilla/widget/src/windows/nsLookAndFeel.cpp index 485d4a48c36..759463d1688 100644 --- a/mozilla/widget/src/windows/nsLookAndFeel.cpp +++ b/mozilla/widget/src/windows/nsLookAndFeel.cpp @@ -275,6 +275,11 @@ NS_IMETHODIMP nsLookAndFeel::GetMetric(const nsMetricID aID, PRInt32 & aMetric) aMetric = sSubmenuDelay; } break; + case eMetric_MenusCanOverlapOSBar: + // we want XUL popups to be able to overlap the task bar. + aMetric = 1; + break; + default: aMetric = -1; res = NS_ERROR_FAILURE;