mirror of https://github.com/lapce/lapce.git
Only react to left clicks on editor tabs headers
This commit is contained in:
parent
7b3f6a389d
commit
8189fc9d9c
|
@ -50,7 +50,10 @@ fn mouse_down(
|
||||||
mouse_event: &MouseEvent,
|
mouse_event: &MouseEvent,
|
||||||
) {
|
) {
|
||||||
for (i, tab_rect) in self.rects.iter().enumerate() {
|
for (i, tab_rect) in self.rects.iter().enumerate() {
|
||||||
if tab_rect.rect.contains(mouse_event.pos) {
|
// Only react to left button clicks
|
||||||
|
if mouse_event.button.is_left()
|
||||||
|
&& tab_rect.rect.contains(mouse_event.pos)
|
||||||
|
{
|
||||||
let editor_tab = data
|
let editor_tab = data
|
||||||
.main_split
|
.main_split
|
||||||
.editor_tabs
|
.editor_tabs
|
||||||
|
|
Loading…
Reference in New Issue