Title: Message
I tried the following MouseAdapter but it listens only right click of mouse. What about left button click? I want to capture double click of left mouse button but I don't see any method in mouselistener.
 
 class LogMessageTableMouseListener extends MouseAdapter {
 
  JTable logMessageTable;
 
  public LogMessageTableMouseListener(JTable logMessageTable) {
   this.logMessageTable = logMessageTable;
  }
 
  public void mouseReleased(MouseEvent event) {
 
   if (event.isShiftDown() || event.isControlDown() || event.isAltDown()) {
    return;
   }
 
   if (event.isMetaDown()) {
    int row = logMessageTable.rowAtPoint(event.getPoint());
    int column = logMessageTable.columnAtPoint(event.getPoint());
    LogManager.log.debug("The clicked row data " + logMessageTable.getModel().getValueAt(row, column));
   }
  }
 }
 
-----Original Message-----
From: Bhangale, Bhushan [mailto:[EMAIL PROTECTED]]
Sent: Thursday, September 05, 2002 2:20 PM
To: 'Advanced-Swing'
Subject: JTable row selection

Hi All,
 
I have a JTable in which I am showing 4 columns. When a user double clicks on a particular row I have to open a popup and show the data of that row in some form. How to do it? Can I add mouse double click kind of listener on table rows? If yes then how?
 
Thanks & Regards
Bhushan Bhangale
Sr. Software Engineer
Fusion Infotech India Private Ltd.
Ph. no. - 1-212-641-6932 (O)
 


"The information in this e-mail, and any attachment therein, is

confidential and for use by the addressee only. If you are not the

intended recipient, please return the e-mail to the sender and delete

it from your computer. Although The Bank of New York attempts to

sweep e-mail and attachments for viruses, it does not guarantee that

either are virus-free and accepts no liability for any damage sustained

as a result of viruses."




"The information in this e-mail, and any attachment therein, is

confidential and for use by the addressee only. If you are not the

intended recipient, please return the e-mail to the sender and delete

it from your computer. Although The Bank of New York attempts to

sweep e-mail and attachments for viruses, it does not guarantee that

either are virus-free and accepts no liability for any damage sustained

as a result of viruses."


Reply via email to