fx115: fix layout on Windows

This commit is contained in:
windingwind 2024-03-03 17:33:14 +08:00 committed by Dan Stillman
parent f7ac2a348f
commit e51739e1d4
4 changed files with 19 additions and 13 deletions

View file

@ -159,7 +159,8 @@
<image class="titlebar-icon" src="chrome://zotero/skin/z.svg"></image>
</hbox>
<!-- Menu -->
<toolbar type="menubar" id="toolbar-menubar" class="chromeclass-menubar" customizable="true"
<!-- TEMP: Should be <toolbar>, but only HTML -moz-window-dragging: drag elements have rclick menu on Windows -->
<html:div type="menubar" id="toolbar-menubar" class="chromeclass-menubar" customizable="true"
defaultset="menubar-items"
mode="icons" iconsize="small" defaulticonsize="small" autohide="false"
context="toolbar-context-menu">
@ -357,7 +358,7 @@
</menu>
</menubar>
</toolbaritem>
</toolbar>
</html:div>
<hbox class="titlebar-buttonbox titlebar-color">
<!-- TODO: remove `titlebar-btn` when we are on FX115. See https://phabricator.services.mozilla.com/D162757 -->
<toolbarbutton class="titlebar-button titlebar-min"
@ -478,7 +479,7 @@
</vbox>
</tabpanel>
<tabpanel flex="1" id="tabpanel-tests">
<vbox flex="1">
<vbox flex="1" style="max-width: 100%;">
<!-- The `height` attribute on the vbox and iframe is overridden by `flex`. Without it,
though, the richlistbox grows when tests are added. -->
<vbox flex="1" height="auto">

View file

@ -195,7 +195,8 @@
<html:div class="titlebar-icon"></html:div>
</hbox>
<!-- Menu -->
<toolbar type="menubar" id="toolbar-menubar" class="chromeclass-menubar" customizable="true"
<!-- TEMP: Should be <toolbar>, but only HTML -moz-window-dragging: drag elements have rclick menu on Windows -->
<html:div type="menubar" id="toolbar-menubar" class="chromeclass-menubar" customizable="true"
defaultset="menubar-items"
mode="icons" iconsize="small" defaulticonsize="small" autohide="false"
context="toolbar-context-menu">
@ -793,27 +794,22 @@
</menu>
</menubar>
</toolbaritem>
</toolbar>
</html:div>
<hbox class="titlebar-buttonbox titlebar-color">
<!-- TODO: remove `titlebar-btn` when we are on FX115. See https://phabricator.services.mozilla.com/D162757 -->
<toolbarbutton class="titlebar-button titlebar-min"
titlebar-btn="min"
oncommand="window.minimize();"
data-l10n-id="browser-window-minimize-button"
/>
<toolbarbutton class="titlebar-button titlebar-max"
titlebar-btn="max"
oncommand="window.maximize();"
data-l10n-id="browser-window-maximize-button"
/>
<toolbarbutton class="titlebar-button titlebar-restore"
titlebar-btn="max"
oncommand="window.fullScreen ? BrowserFullScreen() : window.restore();"
data-l10n-id="browser-window-restore-down-button"
/>
<toolbarbutton class="titlebar-button titlebar-close"
titlebar-btn="close"
oncommand="window.close();"
data-l10n-id="browser-window-close-button"
/>

View file

@ -2,13 +2,13 @@
// Need this to force show the menubar
display: initial;
// Allow right-click context menu on menubar
pointer-events: none;
visibility: visible;
flex: 1;
}
#menubar-items {
pointer-events: all;
-moz-window-dragging: drag;
}
.titlebar-buttonbox {
@ -19,9 +19,9 @@
#titlebar,
.menubar-container {
appearance: none;
flex-direction: row;
height :var(--tab-min-height);
-moz-box-pack: center;
pointer-events: none;
border-bottom: var(--material-border);
background: var(--material-tabbar);
toolbar {
@ -34,7 +34,11 @@
menu {
border-radius: 4px;
}
#main-menubar {
align-self: flex-start;
}
#main-menubar > menu {
height: 100%;
padding: 0px 4px 0px 4px;
}
#main-menubar > menu > menupopup {

View file

@ -7,7 +7,7 @@ tabbox {
background: transparent;
spacer:first-of-type {
-moz-box-flex: 1;
flex: 1;
}
tab {
@ -63,5 +63,10 @@ tabbox {
border-radius: 8px;
// 8 (original) + 14 (from tabs)
padding-top: 22px;
tabpanel {
min-width: 500px;
max-width: 100%;
}
}
}