mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
remove unhelpful assertion (IDEA-73526)
This commit is contained in:
@@ -28,13 +28,6 @@ public final class MouseShortcut extends Shortcut {
|
||||
private final int myClickCount;
|
||||
|
||||
public MouseShortcut(int button, int modifiers, int clickCount) {
|
||||
if (
|
||||
MouseEvent.BUTTON1 != button &&
|
||||
MouseEvent.BUTTON2 != button &&
|
||||
MouseEvent.BUTTON3 != button
|
||||
) {
|
||||
throw new IllegalArgumentException("unknown button: " + button);
|
||||
}
|
||||
myButton = button;
|
||||
// TODO[vova] check modifiers?
|
||||
myModifiers = mapOldModifiers(modifiers);
|
||||
|
||||
@@ -128,7 +128,7 @@ public class KeymapUtil {
|
||||
// do nothing
|
||||
}
|
||||
else {
|
||||
throw new IllegalStateException("unknown button: " + button);
|
||||
buttonNum = button;
|
||||
}
|
||||
|
||||
if (clickCount == 1) {
|
||||
|
||||
@@ -801,7 +801,7 @@ public class KeymapImpl implements Keymap, ExternalizableScheme {
|
||||
buffer.append(' ');
|
||||
}
|
||||
else {
|
||||
throw new IllegalStateException("unknown button: " + button);
|
||||
buffer.append("button").append(button);
|
||||
}
|
||||
|
||||
if (shortcut.getClickCount() > 1) {
|
||||
|
||||
Reference in New Issue
Block a user