mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 685476 - App tab icons should not act as drag handlers for groupItems; r=dietrich
This commit is contained in:
parent
e56193e6e8
commit
e1b485937d
@ -1211,6 +1211,10 @@ GroupItem.prototype = Utils.extend(new Item(), new Subscribable(), {
|
||||
.attr("src", iconUrl)
|
||||
.data("xulTab", xulTab)
|
||||
.appendTo(this.$appTabTray)
|
||||
.mousedown(function onAppTabMousedown(event) {
|
||||
// stop mousedown propagation to disable group dragging on app tabs
|
||||
event.stopPropagation();
|
||||
})
|
||||
.click(function(event) {
|
||||
if (!Utils.isLeftClick(event))
|
||||
return;
|
||||
|
@ -158,6 +158,7 @@ _BROWSER_FILES = \
|
||||
browser_tabview_bug677310.js \
|
||||
browser_tabview_bug679853.js \
|
||||
browser_tabview_bug681599.js \
|
||||
browser_tabview_bug685476.js \
|
||||
browser_tabview_bug685692.js \
|
||||
browser_tabview_bug686654.js \
|
||||
browser_tabview_click_group.js \
|
||||
|
@ -0,0 +1,24 @@
|
||||
/* Any copyright is dedicated to the Public Domain.
|
||||
http://creativecommons.org/publicdomain/zero/1.0/ */
|
||||
|
||||
function test() {
|
||||
waitForExplicitFinish();
|
||||
|
||||
showTabView(function () {
|
||||
let tab = gBrowser.addTab();
|
||||
gBrowser.pinTab(tab);
|
||||
registerCleanupFunction(function () gBrowser.removeTab(tab));
|
||||
|
||||
let cw = TabView.getContentWindow();
|
||||
let body = cw.document.body;
|
||||
let [appTabIcon] = cw.iQ(".appTabTray .appTabIcon");
|
||||
|
||||
EventUtils.synthesizeMouseAtCenter(appTabIcon, {type: "mousedown"}, cw);
|
||||
EventUtils.synthesizeMouse(body, 500, 100, {type: "mousemove"}, cw);
|
||||
EventUtils.synthesizeMouse(body, 500, 100, {type: "mouseup"}, cw);
|
||||
|
||||
ok(TabView.isVisible(), "tabview is still visible");
|
||||
|
||||
hideTabView(finish);
|
||||
});
|
||||
}
|
Loading…
Reference in New Issue
Block a user