pivot-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Roger L. Whitcomb" <Roger.Whitc...@actian.com>
Subject RE: Annotation to force method execution on EDT Thread, for Pivot 2.1
Date Mon, 02 Apr 2012 16:29:37 GMT
I think this is a great idea!  And I like the possibility (from the
Android Annotations stuff) of having ButtonPressListeners and other
things get some code generation help, which would also reduce some
clutter when a lot of controls have to be registered.

~Roger Whitcomb

-----Original Message-----
From: Sandro Martini [mailto:sandro.martini@gmail.com] 
Sent: Monday, April 02, 2012 6:06 AM
To: Apache Pivot - Developers
Subject: Annotation to force method execution on EDT Thread, for Pivot
2.1

Hi all,
for the 2.1 release I'm start to think if (to make some code, even
user code, more readable) using an annotation we could try to mark a
method to run its code in the EDT event thread, so something like:

        ApplicationContext.queueCallback(new Runnable() {
            @Override
            public void run() {
                // stuff code ...
            }
        });


could be

@edt( ...optional parameters )
myStuffCode()  {
                // stuff code ...
            }

just as idea ... probably not-so-much type saving, but more readable.


And then: runtime-only annotation (this should be enough), or even
compile annotation ?

Comments ?

Bye,
Sandro

Mime
View raw message