mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 969376 - correctly size Australis' menu button, make it hug right border on Windows and Linux, r=jaws
--HG-- rename : browser/base/content/test/general/browser_backButtonFitts.js => browser/base/content/test/general/browser_menuButtonFitts.js
This commit is contained in:
parent
5259bcbfed
commit
e286c53fff
@ -269,6 +269,8 @@ skip-if = true # browser_drag.js is disabled, as it needs to be updated for the
|
||||
[browser_locationBarCommand.js]
|
||||
skip-if = os == "linux" # Intermittent failures, bug 917535
|
||||
[browser_locationBarExternalLoad.js]
|
||||
[browser_menuButtonFitts.js]
|
||||
skip-if = os != "win" # The Fitts Law menu button is only supported on Windows (bug 969376)
|
||||
[browser_middleMouse_inherit.js]
|
||||
[browser_minimize.js]
|
||||
[browser_mixedcontent_securityflags.js]
|
||||
|
32
browser/base/content/test/general/browser_menuButtonFitts.js
Normal file
32
browser/base/content/test/general/browser_menuButtonFitts.js
Normal file
@ -0,0 +1,32 @@
|
||||
/* Any copyright is dedicated to the Public Domain.
|
||||
* http://creativecommons.org/publicdomain/zero/1.0/
|
||||
*/
|
||||
|
||||
function test () {
|
||||
waitForExplicitFinish();
|
||||
window.maximize();
|
||||
|
||||
// Find where the nav-bar is vertically.
|
||||
var navBar = document.getElementById("nav-bar");
|
||||
var boundingRect = navBar.getBoundingClientRect();
|
||||
var yPixel = boundingRect.top + Math.floor(boundingRect.height / 2);
|
||||
var xPixel = boundingRect.width - 1; // Use the last pixel of the screen since it is maximized.
|
||||
|
||||
function onPopupHidden() {
|
||||
PanelUI.panel.removeEventListener("popuphidden", onPopupHidden);
|
||||
window.restore();
|
||||
finish();
|
||||
}
|
||||
function onPopupShown() {
|
||||
PanelUI.panel.removeEventListener("popupshown", onPopupShown);
|
||||
ok(true, "Clicking at the far edge of the window opened the menu popup.");
|
||||
PanelUI.panel.addEventListener("popuphidden", onPopupHidden);
|
||||
PanelUI.hide();
|
||||
}
|
||||
registerCleanupFunction(function() {
|
||||
PanelUI.panel.removeEventListener("popupshown", onPopupShown);
|
||||
PanelUI.panel.removeEventListener("popuphidden", onPopupHidden);
|
||||
});
|
||||
PanelUI.panel.addEventListener("popupshown", onPopupShown);
|
||||
EventUtils.synthesizeMouseAtPoint(xPixel, yPixel, {}, window);
|
||||
}
|
@ -591,6 +591,10 @@ toolbarbutton[sdk-button="true"][cui-areatype="toolbar"] > .toolbarbutton-icon {
|
||||
width: 32px;
|
||||
}
|
||||
|
||||
#nav-bar #PanelUI-menu-button {
|
||||
-moz-padding-start: 7px;
|
||||
-moz-padding-end: 5px;
|
||||
}
|
||||
|
||||
:-moz-any(#TabsToolbar, #nav-bar) .toolbarbutton-1 > .toolbarbutton-menubutton-button:not([disabled]):hover > .toolbarbutton-icon,
|
||||
:-moz-any(#TabsToolbar, #nav-bar) .toolbarbutton-1:not([buttonover]):not([open]):hover > .toolbarbutton-menubutton-dropmarker > .dropmarker-icon,
|
||||
|
@ -507,6 +507,13 @@ toolbar .toolbarbutton-1:not([type="menu-button"]),
|
||||
-moz-margin-start: 10px;
|
||||
}
|
||||
|
||||
#nav-bar #PanelUI-menu-button {
|
||||
margin-top: 0;
|
||||
margin-bottom: 0;
|
||||
-moz-margin-start: 9px;
|
||||
-moz-margin-end: 7px;
|
||||
}
|
||||
|
||||
@media not all and (min-resolution: 2dppx) {
|
||||
%include ../shared/toolbarbuttons.inc.css
|
||||
%include ../shared/menupanel.inc.css
|
||||
|
@ -26,10 +26,6 @@
|
||||
background-repeat: no-repeat;
|
||||
}
|
||||
|
||||
#PanelUI-menu-button {
|
||||
margin: 0 7px 0 9px;
|
||||
}
|
||||
|
||||
.panel-subviews {
|
||||
padding: 4px;
|
||||
background-color: hsla(0,0%,100%,.97);
|
||||
|
@ -496,6 +496,11 @@ menuitem.bookmark-item {
|
||||
-moz-box-pack: center;
|
||||
}
|
||||
|
||||
#nav-bar #PanelUI-menu-button {
|
||||
-moz-padding-start: 7px;
|
||||
-moz-padding-end: 5px;
|
||||
}
|
||||
|
||||
#nav-bar .toolbarbutton-1[type=menu]:not(#back-button):not(#forward-button):not(#feed-button):not(#social-provider-button):not(#PanelUI-menu-button) {
|
||||
padding-left: 5px;
|
||||
padding-right: 5px;
|
||||
|
Loading…
Reference in New Issue
Block a user