This is the mail archive of the java-patches@gcc.gnu.org mailing list for the Java project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] fixes to swing button implementation


Sascha Brawer wrote:

> But probably, it would best tp use
javax.swing.event.EventListenerList here (which, by coincidence, became
functional this afternoon...).

I'm using this now.


Weird. From looking at the J2SE 1.4.2 API specification, I would expect:

  protected int stateMask; // e.g. ARMED | SELECTED
  protected int mnemonic;
  protected String actionCommand;

yes, I've updated the model (and component, and UI, etc.) to work more in line with the J2SE docs. if you want to look at what I wound up committing, I'd certainly appreciate further commentary by mail.


It seems strange that these colors are hard-coded. Shouldn't they come
from the UIManager?

perhaps, I left them there because they were there when I first opened up this class. if it needs to be delegated I'll change it.


A final comment: Please, please, please write documentation and Mauve
test cases. With javax.swing.DefaultBoundedRangeModel, I've just made the
experience myself how immensely useful this is for finding bugs, and for
making sure that changes don't break things.

ok, the version I committed to gcj and just merged to classpath has extensive javadocs and is reformatted using jalopy. I have a simple mauve test which works but doesn't exercize every aspect of the button; I'll extend it across the next few days and fix up any sense in which my code doesn't conform with the sun stuff.


-graydon


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]