Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Standard Widget Toolkit (SWT) » Can't shake off persistent focus on a button
Can't shake off persistent focus on a button [message #442566] Wed, 08 September 2004 08:25 Go to next message
Arthur Gouros is currently offline Arthur GourosFriend
Messages: 11
Registered: July 2009
Junior Member
Can anyone help me with a SWT runtime / Mac OS X GUI issue.

I'm doing a port of my software to MacOS X 10.3.5 and experiencing unusual
SWT runtime behaiviour when my first window appears. A button in the top
right hand corner of my window (which happens to be our application's help
button with an icon in it) is consistantly getting focus (making the icon
in it flash rapidly). If you tab out of it, the focus returns immediately
to that button. This focus issue is also interfering with the ability to
cleanly click other buttons (you may have to try a couple of times before
the request registers).

The same software, particularly the GUI part which remains unchanged
across platforms, works without this issue on Linux GTK and Solaris Motif
and GTK (I have my own port of SWT for Solaris GTK - details in the
eclipse archives).

I use the latest Iteration release of the SWT runtime binaries
(swt-I20040907) (and have tried the 3.0 amd 3.1M1 releases which exhibit
the same fault).
I use JVM 1.4.2 Update 1 on MacOS X 10.3.5.
Our GUI is rendered through a jelly script and at this early stage I
suspect the culprit is a jelly command that looks like this
${shell.pack()} which is called towards the end of my jelly script.
The JVM continuously produces the following output:
Exception in thread "AWT-AppKit" org.eclipse.swt.SWTException: Invalid
thread access
at org.eclipse.swt.SWT.error(SWT.java:2691)
at org.eclipse.swt.SWT.error(SWT.java:2616)
at org.eclipse.swt.SWT.error(SWT.java:2587)
at org.eclipse.swt.widgets.Widget.error(Widget.java:546)
at org.eclipse.swt.widgets.Widget.checkWidget(Widget.java:297)
at
org.eclipse.swt.widgets.Control.internal_new_GC(Control.java :1065)
at org.eclipse.swt.graphics.GC.carbon_new(GC.java:148)
at org.eclipse.swt.widgets.Button.drawWidget(Button.java:325)
at
org.eclipse.swt.widgets.Widget.kEventControlDraw(Widget.java :867)
at org.eclipse.swt.widgets.Widget.controlProc(Widget.java:314)
at org.eclipse.swt.widgets.Display.controlProc(Display.java:743 )

Has anyone come across this before? My application is too big/complex to
detail here, but I'm more than happy to provide a basic prototype of the
problem if nobody can help.

Cheers,
Arthur.
Re: Can't shake off persistent focus on a button [message #443513 is a reply to message #442566] Mon, 27 September 2004 06:24 Go to previous messageGo to next message
Arthur Gouros is currently offline Arthur GourosFriend
Messages: 11
Registered: July 2009
Junior Member
Turns out the java_swt launcher (the SWT hack for mac) is unable to
faithfully reproduce all java error messages as it is after all a wrapper
to the real java command. Errors that should have been appearing on the
console (or even the terminal session for that matter) just weren't
happenning. Attaching a stdout/err stream reader to my code identified
that the initial problem I raised on this posting was not related to SWT.
Re: Can't shake off persistent focus on a button [message #443716 is a reply to message #443513] Wed, 29 September 2004 17:27 Go to previous message
Steve Northover is currently offline Steve NorthoverFriend
Messages: 1636
Registered: July 2009
Senior Member
Thanks for letting us know. I was worried we had some strange bug but had
no idea how to persue it with you. Glad there was a good outcome.

"Arthur Gouros" <Arthur.Gouros@managesoft.com> wrote in message
news:cj8bme$5fm$1@eclipse.org...
> Turns out the java_swt launcher (the SWT hack for mac) is unable to
> faithfully reproduce all java error messages as it is after all a wrapper
> to the real java command. Errors that should have been appearing on the
> console (or even the terminal session for that matter) just weren't
> happenning. Attaching a stdout/err stream reader to my code identified
> that the initial problem I raised on this posting was not related to SWT.
>
Previous Topic:How to : text disable with foreground color not grayed
Next Topic:Focus border on buttons
Goto Forum:
  


Current Time: Fri Mar 29 07:16:12 GMT 2024

Powered by FUDForum. Page generated in 0.03279 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top