From 100a0a54e123ac6bf027c4e00804a5485cf6b4df Mon Sep 17 00:00:00 2001 From: magenoxx Date: Sun, 12 Dec 2010 23:39:50 +0300 Subject: [PATCH] CardsList: replaced mouseClicked by mousePressed (better interaction). --- .../src/main/java/mage/client/cards/CardsList.java | 12 ++++++------ .../java/mage/client/deckeditor/DeckEditorPanel.java | 2 +- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/Mage.Client/src/main/java/mage/client/cards/CardsList.java b/Mage.Client/src/main/java/mage/client/cards/CardsList.java index 158bbd08fe..d3c1fa9ec1 100644 --- a/Mage.Client/src/main/java/mage/client/cards/CardsList.java +++ b/Mage.Client/src/main/java/mage/client/cards/CardsList.java @@ -136,9 +136,13 @@ public class CardsList extends javax.swing.JPanel implements MouseListener { @Override public void mouseClicked(MouseEvent e) { - if (e.getClickCount() == 2 && !e.isConsumed()) { + } + + @Override + public void mousePressed(MouseEvent e) { + if (e.getClickCount() == 2 && !e.isConsumed()) { e.consume(); - Object obj = e.getSource(); + Object obj = e.getSource(); if (obj instanceof Card) { cardEventSource.doubleClick(((Card)obj).getCardId(), "double-click"); } else if (obj instanceof MageCard) { @@ -147,10 +151,6 @@ public class CardsList extends javax.swing.JPanel implements MouseListener { } } - @Override - public void mousePressed(MouseEvent e) { - } - @Override public void mouseReleased(MouseEvent e) { } diff --git a/Mage.Client/src/main/java/mage/client/deckeditor/DeckEditorPanel.java b/Mage.Client/src/main/java/mage/client/deckeditor/DeckEditorPanel.java index b5ce0b36af..2bd6faf9af 100644 --- a/Mage.Client/src/main/java/mage/client/deckeditor/DeckEditorPanel.java +++ b/Mage.Client/src/main/java/mage/client/deckeditor/DeckEditorPanel.java @@ -63,7 +63,7 @@ public class DeckEditorPanel extends javax.swing.JPanel { private JFileChooser fcSelectDeck; private JFileChooser fcImportDeck; - private Deck deck = new Deck();; + private Deck deck = new Deck(); /** Creates new form DeckEditorPanel */ public DeckEditorPanel() {