Posted by
Fred Damen on
URL: http://imagej.273.s1.nabble.com/intermittent-problem-with-NonBlockingGenericDialog-tp5023524p5023525.html
Greetings Kenneth,
I see two issues here. The NonBlockingGenericDialog, by way of
GenericDialog being its super class, insists on setting one on the
ImageWindow(s) as the GUI parent. This causes this ImageWindow to be
raised, in my case at least, and possibly other things in your case. I
suspect that this is the source of the intermittency of your issue. It
would be nice if NonBlockingGeneriDialog had a constructor that takes a
Frame and passes it to the GenericDialog super class as the intended
parent. In my case setting the parent to IJ.instance would alleviate my
issue.
From your functional description I assume that your widgets are being
disabled (which should appear as greyed out), but from you visual
description (not highlighted) it would seem that they are not receiving
focus. This may be useful distinction when trying to debug this issue. I
do not experience what you describe, although I suspect it is specific to
the OS/GUI.
What I have done to avoid this annoyance is to create a benign ImageWindow
and have that window current when I start up my NonBlockingGenericDialog.
Fred
On Mon, June 15, 2020 12:10 pm, Kenneth Sloan wrote:
> I am in the wonderful position of having to deal with an INTERMITTENT
> problem. Even worse,
> the problem seems to occur more frequently on one of my "client" machines
> - but not so much on my development machine.
>
> Both are 2019 macBook Pro laptops, running the latest Mac OSX and ImageJ
> 1.52r.
>
> The problem is that *sometimes* (my client reports "roughly every second
> time") when a dialog box is displayed, it is not possible to edit any of
> the fields. Nothing is highlighted, and clicking on the window has no
> effect (I think).
>
> The good news is that most of the time, he wants to accept the (remembered
> in Preferences) previously set values, and merely needs to hit Enter - and
> all is well.
>
> So...I'm unlikely to spend a LOT of time worrying about this, but I
> thought I would report it just in case it rings any bells with anyone
> else.
>
> Has anyone else seen this kind of problem?
>
> Does anyone know what the cause might be?
>
> For context, the relevant plugin displays an image, asks you to select a
> rectangular region, and then displays a NonBlockingGenericDialog with many
> parameters (some numbers, some text, one checkbox). The symptom is that
> *sometimes* none of the fields are highlighted, and nothing seems to be
> able to change that. The dialog can be *accepted* - but not updated.
>
> I'm stumped.
>
> --
> Kenneth Sloan
>
[hidden email]
> Vision is the art of seeing what is invisible to others.
>
> --
> ImageJ mailing list:
http://imagej.nih.gov/ij/list.html>
--
ImageJ mailing list:
http://imagej.nih.gov/ij/list.html