This is the mail archive of the java@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: removing or using AWT/Swing


Hi Tom,

>I've heard on the grapevine that this isn't really possible, the rumor
>being that SWT does not expose enough low-level bits for a full AWT
>implementation.  But I don't really know -- do you?

I don't really know either. It seemed like a nice idea.

>Mohan> I had started a Win32 peer implementation ages ago but
>Mohan> never got around to finishing it. I think I was able to bring
>Mohan> up a frame. Sources are still there:
>Mohan> http://gcc.gnu.org/ml/java/2004-06/msg00089.html
>
>Ship it!  :-)

One thing that I wasn't clear on was how to shove synthetic AWT
events back into the native event queue. It seemed to me that you'd
need a two-way translation (native events translated to AWT events
to put in the AWT event queue as well as (synthetic) AWT events translated
to native events and shoved onto the native event queue where they
would then be retranslated back into AWT events... But it seemed like
there were cases that I would be losing information this way. So I started
writing logic for determining whether a native event was really generated
from a synthetic AWT event and trying to restore this information. Plus it wasn't
apparent where this was being done in the GTK peers. I was basically just winging
it the entire time (and I couldn't find the "GNU AWT Porting HowTo" :) )
In the end I found it more rewarding to just crawl under my dining room table
and rock back and forth in the fetal position....

Someone would need to do a sanity check on this before I felt comfortable
using this as a starting point. (Like I said, the sources are still at the
above link.) But to get a review of this, I'd probably have to explain my
design better and it's been over two years since I looked at this.

-- Mohan
http://www.thisiscool.com/
http://www.animalsong.org/





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