Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [albireo-dev] SWT size/layout management

Bruno Haible wrote:

Looking at what dozens of widgets in Eclipse do, I see tons of explicit
calls to layout(), like this:

                        if (!searchInProgress)
                                goButton.setEnabled(true);
                        if (searchInProgress)
                                goButton.setText(Messages.SearchPart_stop);
                        else
                                goButton.setText(Messages.SearchPart_go);
                        goButton.getParent().layout();

This particular example (in SearchPart) is not the implementation of a widget. The code is in a a user of the button and other widgets.

Have you found examples of an actual widget calling layout() on its parent?


Back to the top