Skip to content

Instantly share code, notes, and snippets.

@codenameone
Created December 18, 2013 12:01
Show Gist options
  • Save codenameone/8021169 to your computer and use it in GitHub Desktop.
Save codenameone/8021169 to your computer and use it in GitHub Desktop.
x.addActionListener(new ActionListener() {
public void actionPerformed(ActionEvent ev) {
// notice we do nothing, this is an event on a stateless component of the renderer
xWasClicked = true;
}
});
list.addActionListener(new ActionListener() {
public void actionPerformed(ActionEvent ev) {
if(xWasClicked) {
xWasClicked = false;
// handle the button click event and return
return;
}
// handle standard list action event
}
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment