UI-related questions regarding the OpenAPI
1) How do I display a dialog on top of another. The first one is derived
from DialogWrapper and calls the DialogWrapper(Project, boolean)
constructor. Should I use the DialogWrapper(Component, boolean) constructor
to show another dialog with the first one as parent? What component to pass
as first constructor parameter?
2) I want to let the user enter an expression, which should resolve to int.
Is there a code-completion text-field available, which I can configure to
accept only int values, e.g. '100' or 'hashCode()' or 'foo.getX()'?
--
Thanks in advance,
Tom
Please sign in to leave a comment.
1) Use new DialogWrapper(oldDialog.getContentPane(), true). Generally saying
DialogWrapper(component) shows dialog centered to component.
DialogWrapper(project) shows dialog centered to project frame.
DialogWrapper() shows dialog centered to last active project's frame.
2) Not currently possible. It took us a while to understand. The good news
are though this API is quite easy to implement. JIRA request?
-
Maxim Shafirov
http://www.jetbrains.com
"Develop with pleasure!"
Thanks, Maxim.
IDEA-1386
Tom