Explorar el Código

LibGUI: Do not clear the selection on right-click

AnotherTest hace 4 años
padre
commit
e250591ff3
Se han modificado 1 ficheros con 1 adiciones y 1 borrados
  1. 1 1
      Libraries/LibGUI/AbstractView.cpp

+ 1 - 1
Libraries/LibGUI/AbstractView.cpp

@@ -224,7 +224,7 @@ void AbstractView::mousedown_event(MouseEvent& event)
     } else if (event.button() == MouseButton::Left && m_selection.contains(index) && !m_model->drag_data_type().is_null()) {
     } else if (event.button() == MouseButton::Left && m_selection.contains(index) && !m_model->drag_data_type().is_null()) {
         // We might be starting a drag, so don't throw away other selected items yet.
         // We might be starting a drag, so don't throw away other selected items yet.
         m_might_drag = true;
         m_might_drag = true;
-    } else {
+    } else if (event.button() != MouseButton::Right) {
         set_cursor(index, SelectionUpdate::Set);
         set_cursor(index, SelectionUpdate::Set);
     }
     }