jastrachan | 20 May 09:15 2004
Picon

Re: [groovy-dev] Groovier Console


On 20 May 2004, at 06:53, Danno Ferrin wrote:
> Good idea, since Actions and models are the only real swing classes 
> you can reuse. And you really *should* reuse them when they are the 
> same, like when a menu item and a toolbar button are the same action 
> you disable just the action amd both itmes pick up the model change.
>
> Seeing this I updates SwingBuilder to return the value of action(x) 
> and tableModel(x) to return literally x when the value is of the same 
> instance.  The modified groovy console shows this.
>
> I also updated the action creation code to use strings for 
> 'accelerator' and 'mnenomic' to play nicer with forgien types.  If 
> it's not the type it wants it toString() the object and makes it what 
> it wants. AccelleratorKey and MnenomicKey are still available for the 
> purists.
>
> Adding of actions was also fixed for "keyStroke" so that it ca be 
> added to things like text fields.  C-Enter now executes the script in 
> the bottom window.
>
> Attached patch also contains these updates.
>
> Should I just open a JIRA for these type enhancements?

Strictly speaking we should put all patches into JIRA so we don't 
forget then (its easy to miss things on the mail list). We don't want 
to miss patches as folks put lots of hard work into producing them.

I tried to go ahead and apply your patch Danno but found eclipse wasn't 
capable of applying the patch; its normally pretty good. I wonder if 
CVS has moved along since you made the patch? Could you do a cvs update 
and then try create the patch again? Failing that if you mail me the 
actual files we'll try that route instead :)

James
-------
http://radio.weblogs.com/0112098/


Gmane