mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
IDEA-59553 Make it possible to select code blocks via clicks on gutter
Don't close line numbers on shift+clicks in order to avoid such inadvertent action on editor text selection
This commit is contained in:
+9
-8
@@ -170,14 +170,15 @@ class EditorGutterComponentImpl extends EditorGutterComponentEx implements Mouse
|
||||
private void processClose(final MouseEvent e) {
|
||||
final IdeEventQueue queue = IdeEventQueue.getInstance();
|
||||
|
||||
if (isLineNumbersShown()) {
|
||||
if (e.getX() >= getLineNumberAreaOffset() && getLineNumberAreaOffset() + getLineNumberAreaWidth() >= e.getX()) {
|
||||
queue.blockNextEvents(e);
|
||||
myEditor.getSettings().setLineNumbersShown(false);
|
||||
e.consume();
|
||||
return;
|
||||
}
|
||||
}
|
||||
// See IDEA-59553 for rationale on why this feature is disabled
|
||||
//if (isLineNumbersShown()) {
|
||||
// if (e.getX() >= getLineNumberAreaOffset() && getLineNumberAreaOffset() + getLineNumberAreaWidth() >= e.getX()) {
|
||||
// queue.blockNextEvents(e);
|
||||
// myEditor.getSettings().setLineNumbersShown(false);
|
||||
// e.consume();
|
||||
// return;
|
||||
// }
|
||||
//}
|
||||
|
||||
if (getGutterRenderer(e) != null) return;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user