summaryrefslogtreecommitdiffstats
path: root/layout/xul/nsMenuPopupFrame.cpp
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-19 01:14:29 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-19 01:14:29 +0000
commitfbaf0bb26397aa498eb9156f06d5a6fe34dd7dd8 (patch)
tree4c1ccaf5486d4f2009f9a338a98a83e886e29c97 /layout/xul/nsMenuPopupFrame.cpp
parentReleasing progress-linux version 124.0.1-1~progress7.99u1. (diff)
downloadfirefox-fbaf0bb26397aa498eb9156f06d5a6fe34dd7dd8.tar.xz
firefox-fbaf0bb26397aa498eb9156f06d5a6fe34dd7dd8.zip
Merging upstream version 125.0.1.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to '')
-rw-r--r--layout/xul/nsMenuPopupFrame.cpp33
1 files changed, 4 insertions, 29 deletions
diff --git a/layout/xul/nsMenuPopupFrame.cpp b/layout/xul/nsMenuPopupFrame.cpp
index b41a666707..8ebb8b01d5 100644
--- a/layout/xul/nsMenuPopupFrame.cpp
+++ b/layout/xul/nsMenuPopupFrame.cpp
@@ -220,21 +220,16 @@ widget::PopupLevel nsMenuPopupFrame::GetPopupLevel(bool aIsNoAutoHide) const {
}
// If the level attribute has been set, use that.
- static Element::AttrValuesArray strings[] = {
- nsGkAtoms::top, nsGkAtoms::parent, nsGkAtoms::floating, nullptr};
+ static Element::AttrValuesArray strings[] = {nsGkAtoms::top,
+ nsGkAtoms::parent, nullptr};
switch (mContent->AsElement()->FindAttrValueIn(
kNameSpaceID_None, nsGkAtoms::level, strings, eCaseMatters)) {
case 0:
return PopupLevel::Top;
case 1:
return PopupLevel::Parent;
- case 2:
- return PopupLevel::Floating;
- }
-
- // Panels with titlebars most likely want to be floating popups.
- if (mContent->AsElement()->HasAttr(nsGkAtoms::titlebar)) {
- return PopupLevel::Floating;
+ default:
+ break;
}
// If this panel is a noautohide panel, the default is the parent level.
@@ -281,20 +276,6 @@ nsresult nsMenuPopupFrame::CreateWidgetForView(nsView* aView) {
}
}
- nsAutoString title;
- if (widgetData.mNoAutoHide &&
- mContent->AsElement()->AttrValueIs(kNameSpaceID_None, nsGkAtoms::titlebar,
- nsGkAtoms::normal, eCaseMatters)) {
- widgetData.mBorderStyle = widget::BorderStyle::Title;
-
- mContent->AsElement()->GetAttr(nsGkAtoms::label, title);
- if (mContent->AsElement()->AttrValueIs(kNameSpaceID_None, nsGkAtoms::close,
- nsGkAtoms::_true, eCaseMatters)) {
- widgetData.mBorderStyle =
- widgetData.mBorderStyle | widget::BorderStyle::Close;
- }
- }
-
bool remote = HasRemoteContent();
const auto mode = nsLayoutUtils::GetFrameTransparency(this, this);
@@ -328,12 +309,6 @@ nsresult nsMenuPopupFrame::CreateWidgetForView(nsView* aView) {
PropagateStyleToWidget();
- // most popups don't have a title so avoid setting the title if there isn't
- // one
- if (!title.IsEmpty()) {
- widget->SetTitle(title);
- }
-
return NS_OK;
}