]> git.lyx.org Git - features.git/commit
Close a tab on middle-click (#10288)
authorScott Kostyshak <skostysh@lyx.org>
Wed, 13 Jul 2016 06:42:35 +0000 (02:42 -0400)
committerScott Kostyshak <skostysh@lyx.org>
Fri, 22 Jul 2016 02:31:29 +0000 (22:31 -0400)
commit4803c7697b27fb420a4b9cdffc6b8ad5092f4ce2
tree11969560b71bf36525bc787558b8be628603bf0e
parentb236450e617b2b2e9baf8091f4a70803e88300c5
Close a tab on middle-click (#10288)

This is the default behavior of Chromium and Firefox. The main
appeal is that instead of having to precisely click on the 'x' to
close a tab, one can more easily middle-click anywhere in the tab.

The tab is closed if the middle button is pressed on a tab and is
relased on the same tab. After pressing, the user may move the mouse
over other tabs but as long as they move it back to the tab where
they initiated the press before they release, the close will
execute. This is how the feature works in Chromium and Firefox.

Nothing is done if the user middle-clicks on the blank part of the
tab bar. This is consistent with Chromium. Firefox, on the other
hand, opens a new tab. In LyX one can already double-click the blank
part to open a new tab, and in feedback from lyx-users [1] most
expected and desired that nothing be done in this case.

[1] https://www.mail-archive.com/search?l=mid&q=20160720063306.6fyarf3kywexbxvd%40steph
src/frontends/qt4/GuiWorkArea.cpp
src/frontends/qt4/GuiWorkArea.h