[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Newsgroup Home]
[news.eclipse.platform.swt] Re: JFace Dialog - change default focus

I believe I was able to set up logic that allows this to work. If I understand it right, the listener is basically mapping Return button presses to Tab button presses. Is this correct?

The only problem with this is that when the focus finally reaches the dialog OK button, pressing Return just moves focus on to the next item.

Is there a way to simply reset the "default" button (usually OK) of the dialog to another button of our choosing? Keep in mind that the dialog is just a container for a Composite that contains the button (or other widget type) that we would like to set as the new default.

I tried looking at Shell.setDefaultButton(), but wasn't able to get it to work.