[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
|
[news.eclipse.platform.swt] Button in a table
|
- From: Doug Pearson <doug-list@xxxxxxxxxxxxxx>
- Date: Tue, 07 Jun 2005 17:36:17 -0700
- Newsgroups: eclipse.platform.swt
- Organization: EclipseCorner
- User-agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.4) Gecko/20030624 Netscape/7.1 (ax)
I'd like to insert a button in a table.
Here's the code I'm using:
m_Button = new Button(table, SWT.PUSH) ;
m_Button.setText(first) ;
m_Button.addSelectionListener(new SelectionAdapter() {
public void widgetSelection(SelectionEvent e) {
// Do something here
} } ) ;
TableEditor editor = new TableEditor (table);
editor.grabHorizontal = true;
editor.setEditor(m_Button, item, 1);
The button appears perfectly in the table but I just can't get the
selection event to fire.
Am I doing something dumb? Is there another way to do this?
Doug